yangys
2024-04-04 ed4a5236bab800094be4a8378f5098eebe3de6ac
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
package com.qianwen.smartman.modules.system.vo;
 
import com.google.common.collect.ImmutableMap;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import com.qianwen.core.tool.utils.Func;
import com.qianwen.smartman.modules.system.constant.FieldConstant;
 
/* loaded from: blade-api.jar:BOOT-INF/classes/org/springblade/modules/system/vo/ChartNameValueDataVO.class */
public class ChartNameValueDataVO {
    private List<Map<String, Object>> data = new ArrayList();
 
    public void setData(final List<Map<String, Object>> data) {
        this.data = data;
    }
 
    public boolean equals(final Object o) {
        if (o == this) {
            return true;
        }
        if (o instanceof ChartNameValueDataVO) {
            ChartNameValueDataVO other = (ChartNameValueDataVO) o;
            if (other.canEqual(this)) {
                Object this$data = getData();
                Object other$data = other.getData();
                return this$data == null ? other$data == null : this$data.equals(other$data);
            }
            return false;
        }
        return false;
    }
 
    protected boolean canEqual(final Object other) {
        return other instanceof ChartNameValueDataVO;
    }
 
    public int hashCode() {
        Object $data = getData();
        int result = (1 * 59) + ($data == null ? 43 : $data.hashCode());
        return result;
    }
 
    public String toString() {
        return "ChartNameValueDataVO(data=" + getData() + ")";
    }
 
    public List<Map<String, Object>> getData() {
        return this.data;
    }
 
    public ChartNameValueDataVO addValue(Object value) {
        this.data.add(ImmutableMap.of(FieldConstant.OPTION_KEY, value));
        return this;
    }
 
    public ChartNameValueDataVO addValue(String name, Object value) {
        this.data.add(ImmutableMap.of("name", name, FieldConstant.OPTION_KEY, value));
        return this;
    }
 
    public ChartNameValueDataVO addValue(String name, Object value, int progress) {
        this.data.add(ImmutableMap.of("name", name, FieldConstant.OPTION_KEY, value, "data", Integer.valueOf(progress)));
        return this;
    }
 
    public ChartNameValueDataVO addValue(String name, Object value, String suffixText, String backgroundColor) {
        this.data.add(ImmutableMap.of("name", name, "prefixText", name, FieldConstant.OPTION_KEY, value, "suffixText", Func.toStr(suffixText, ""), "backgroundColor", backgroundColor));
        return this;
    }
}