1 | |
|
2 | |
|
3 | |
|
4 | |
|
5 | |
|
6 | |
|
7 | |
|
8 | |
|
9 | |
|
10 | |
|
11 | |
|
12 | |
|
13 | |
|
14 | |
|
15 | |
|
16 | |
package org.kuali.student.r2.core.organization.dto; |
17 | |
|
18 | |
import java.io.Serializable; |
19 | |
import java.util.List; |
20 | |
|
21 | |
import javax.xml.bind.annotation.XmlAccessType; |
22 | |
import javax.xml.bind.annotation.XmlAccessorType; |
23 | |
import javax.xml.bind.annotation.XmlAnyElement; |
24 | |
import javax.xml.bind.annotation.XmlAttribute; |
25 | |
import javax.xml.bind.annotation.XmlElement; |
26 | |
import javax.xml.bind.annotation.XmlType; |
27 | |
|
28 | |
import org.kuali.student.r2.common.dto.HasAttributesAndMetaInfo; |
29 | |
import org.kuali.student.r2.common.dto.RichTextInfo; |
30 | |
import org.kuali.student.r2.core.organization.infc.OrgPositionRestriction; |
31 | |
import org.kuali.student.r2.common.dto.TimeAmountInfo; |
32 | |
import org.w3c.dom.Element; |
33 | |
|
34 | |
|
35 | |
|
36 | |
|
37 | |
|
38 | |
|
39 | |
|
40 | |
|
41 | 0 | @XmlAccessorType(XmlAccessType.FIELD) |
42 | |
@XmlType(name = "OrgPersonRestrictionInfo", propOrder = { |
43 | |
"id", |
44 | |
"orgId", "orgPersonRelationTypeKey", |
45 | |
"title", "descr", |
46 | |
"stdDuration", |
47 | |
"minNumRelations", "maxNumRelations", |
48 | |
"meta", "attributes", "_futureElements"}) |
49 | |
public class OrgPositionRestrictionInfo extends HasAttributesAndMetaInfo |
50 | |
implements OrgPositionRestriction, Serializable { |
51 | |
|
52 | |
private static final long serialVersionUID = 1L; |
53 | |
@XmlAttribute |
54 | |
private String id; |
55 | |
@XmlElement |
56 | |
private String orgId; |
57 | |
@XmlElement |
58 | |
private String title; |
59 | |
@XmlElement |
60 | |
private RichTextInfo descr; |
61 | |
@XmlElement |
62 | |
private String orgPersonRelationTypeKey; |
63 | |
@XmlElement |
64 | |
private TimeAmountInfo stdDuration; |
65 | |
@XmlElement |
66 | |
private Integer minNumRelations; |
67 | |
@XmlElement |
68 | |
private String maxNumRelations; |
69 | |
@XmlAnyElement |
70 | |
private List<Element> _futureElements; |
71 | |
|
72 | |
|
73 | |
|
74 | |
|
75 | 0 | public OrgPositionRestrictionInfo() { |
76 | 0 | } |
77 | |
|
78 | |
|
79 | |
|
80 | |
|
81 | |
|
82 | |
|
83 | |
|
84 | |
public OrgPositionRestrictionInfo(OrgPositionRestriction restriction) { |
85 | 0 | super(restriction); |
86 | |
|
87 | 0 | if (restriction != null) { |
88 | 0 | this.id = restriction.getId(); |
89 | 0 | this.orgId = restriction.getOrgId(); |
90 | 0 | this.orgPersonRelationTypeKey = restriction.getOrgPersonRelationTypeKey(); |
91 | 0 | this.title = restriction.getTitle(); |
92 | 0 | if (restriction.getDescr() != null) { |
93 | 0 | this.descr = new RichTextInfo(restriction.getDescr()); |
94 | |
} |
95 | 0 | if (restriction.getStdDuration() != null) { |
96 | 0 | this.stdDuration = new TimeAmountInfo(restriction.getStdDuration()); |
97 | |
} |
98 | 0 | this.minNumRelations = restriction.getMinNumRelations(); |
99 | 0 | this.maxNumRelations = restriction.getMaxNumRelations(); |
100 | |
} |
101 | 0 | } |
102 | |
|
103 | |
@Override |
104 | |
public String getId() { |
105 | 0 | return id; |
106 | |
} |
107 | |
|
108 | |
public void setId(String id) { |
109 | 0 | this.id = id; |
110 | 0 | } |
111 | |
|
112 | |
@Override |
113 | |
public RichTextInfo getDescr() { |
114 | 0 | return descr; |
115 | |
} |
116 | |
|
117 | |
public void setDescr(RichTextInfo descr) { |
118 | 0 | this.descr = descr; |
119 | 0 | } |
120 | |
|
121 | |
@Override |
122 | |
public String getTitle() { |
123 | 0 | return title; |
124 | |
} |
125 | |
|
126 | |
public void setTitle(String title) { |
127 | 0 | this.title = title; |
128 | 0 | } |
129 | |
|
130 | |
@Override |
131 | |
public String getOrgId() { |
132 | 0 | return orgId; |
133 | |
} |
134 | |
|
135 | |
public void setOrgId(String orgId) { |
136 | 0 | this.orgId = orgId; |
137 | 0 | } |
138 | |
|
139 | |
@Override |
140 | |
public String getOrgPersonRelationTypeKey() { |
141 | 0 | return orgPersonRelationTypeKey; |
142 | |
} |
143 | |
|
144 | |
public void setOrgPersonRelationTypeKey(String orgPersonRelationTypeKey) { |
145 | 0 | this.orgPersonRelationTypeKey = orgPersonRelationTypeKey; |
146 | 0 | } |
147 | |
|
148 | |
@Override |
149 | |
public TimeAmountInfo getStdDuration() { |
150 | 0 | return stdDuration; |
151 | |
} |
152 | |
|
153 | |
public void setStdDuration(TimeAmountInfo stdDuration) { |
154 | 0 | this.stdDuration = stdDuration; |
155 | 0 | } |
156 | |
|
157 | |
@Override |
158 | |
public Integer getMinNumRelations() { |
159 | 0 | return minNumRelations; |
160 | |
} |
161 | |
|
162 | |
public void setMinNumRelations(Integer minNumRelations) { |
163 | 0 | this.minNumRelations = minNumRelations; |
164 | 0 | } |
165 | |
|
166 | |
@Override |
167 | |
public String getMaxNumRelations() { |
168 | 0 | return maxNumRelations; |
169 | |
} |
170 | |
|
171 | |
public void setMaxNumRelations(String maxNumRelations) { |
172 | 0 | this.maxNumRelations = maxNumRelations; |
173 | 0 | } |
174 | |
} |