• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2021 Huawei Device Co., Ltd.
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  *     http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 
16 package ohos.devtools.sdk.model.bean;
17 
18 import java.awt.Color;
19 
20 /**
21  * legend Color Block In Chart
22  *
23  * @since 2021/3/1 9:48
24  */
25 public class Legend {
26     /**
27      * legend name
28      */
29     private String legendName;
30 
31     private Color legendColor;
32 
33     private int legendWidth;
34 
35     private int legendHeight;
36 
37     private int index;
38 
getLegendName()39     public String getLegendName() {
40         return legendName;
41     }
42 
setLegendName(String legendName)43     public void setLegendName(String legendName) {
44         this.legendName = legendName;
45     }
46 
getLegendColor()47     public Color getLegendColor() {
48         return legendColor;
49     }
50 
setLegendColor(Color legendColor)51     public void setLegendColor(Color legendColor) {
52         this.legendColor = legendColor;
53     }
54 
getLegendWidth()55     public int getLegendWidth() {
56         return legendWidth;
57     }
58 
setLegendWidth(int legendWidth)59     public void setLegendWidth(int legendWidth) {
60         this.legendWidth = legendWidth;
61     }
62 
getLegendHeight()63     public int getLegendHeight() {
64         return legendHeight;
65     }
66 
setLegendHeight(int legendHeight)67     public void setLegendHeight(int legendHeight) {
68         this.legendHeight = legendHeight;
69     }
70 
getIndex()71     public int getIndex() {
72         return index;
73     }
74 
setIndex(int index)75     public void setIndex(int index) {
76         this.index = index;
77     }
78 
79     @Override
toString()80     public String toString() {
81         return "Legend{" + "legendName='" + legendName + '\'' + ", legendColor=" + legendColor + ", legendWidth="
82             + legendWidth + ", legendHeight=" + legendHeight + ", index=" + index + '}';
83     }
84 }
85