6b59c27111b8095c37201e9aa33b97e2b3d230f6.svn-base
2.84 KB
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
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
/**
* Copyright © 2015-2018 ODM All rights reserved.
*/
package com.thinkgem.jeesite.common.supcan.treelist.cols;
import java.util.List;
import com.google.common.collect.Lists;
import com.thinkgem.jeesite.common.supcan.annotation.treelist.cols.SupGroup;
import com.thinkgem.jeesite.common.utils.ObjectUtils;
import com.thoughtworks.xstream.annotations.XStreamAlias;
import com.thoughtworks.xstream.annotations.XStreamAsAttribute;
import com.thoughtworks.xstream.annotations.XStreamImplicit;
import com.thoughtworks.xstream.annotations.XStreamOmitField;
/**
* 硕正TreeList Cols Group
* @author WangZhen
* @version 2013-11-04
*/
@XStreamAlias("Group")
public class Group {
/**
* 分组的id,仅用于加载采用该id代替列名的XML/JSON数据
*/
@XStreamAsAttribute
private String id;
/**
* 显示的文字 串
*/
@XStreamAsAttribute
private String name;
/**
* 采用的字体, 前面定义的<Font>的序号 数字 指向在<Fonts>中定义的字体的顺序号, 从0开始计数, 等级高于<Properties>中的同名属性
*/
@XStreamAsAttribute
private String headerFontIndex;
/**
* 文字颜色 颜色串 #000000
*/
@XStreamAsAttribute
private String textColor;
/**
* 文字对齐 left/center/right center
*/
@XStreamAsAttribute
private String align;
/**
* 分组下的列集合
*/
@XStreamAlias("Cols")
@XStreamImplicit
private List<Object> cols;
/**
* 父级组ID,注解定义时有效
*/
@XStreamOmitField
private String parentId;
/**
* 字段排序,注解定义时有效
*/
@XStreamOmitField
private int sort;
public Group() {
}
public Group(String name) {
this();
this.name = name;
}
public Group(String name, List<Object> cols) {
this(name);
this.cols = cols;
}
public Group(SupGroup supGroup){
ObjectUtils.annotationToObject(supGroup, this);
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public List<Object> getCols() {
if (cols == null){
cols = Lists.newArrayList();
}
return cols;
}
public void setCols(List<Object> cols) {
this.cols = cols;
}
public String getHeaderFontIndex() {
return headerFontIndex;
}
public void setHeaderFontIndex(String headerFontIndex) {
this.headerFontIndex = headerFontIndex;
}
public String getTextColor() {
return textColor;
}
public void setTextColor(String textColor) {
this.textColor = textColor;
}
public String getAlign() {
return align;
}
public void setAlign(String align) {
this.align = align;
}
public String getId() {
return id;
}
public void setId(String id) {
this.id = id;
}
public String getParentId() {
return parentId;
}
public void setParentId(String parentId) {
this.parentId = parentId;
}
public int getSort() {
return sort;
}
public void setSort(int sort) {
this.sort = sort;
}
}