1 | |
|
2 | |
|
3 | |
|
4 | |
|
5 | |
|
6 | |
|
7 | |
|
8 | |
|
9 | |
|
10 | |
|
11 | |
|
12 | |
|
13 | |
|
14 | |
|
15 | |
|
16 | |
|
17 | |
package org.kuali.student.enrollment.lui.dto; |
18 | |
|
19 | |
import java.io.Serializable; |
20 | |
import java.util.Date; |
21 | |
import java.util.List; |
22 | |
|
23 | |
import javax.xml.bind.annotation.XmlAccessType; |
24 | |
import javax.xml.bind.annotation.XmlAccessorType; |
25 | |
import javax.xml.bind.annotation.XmlAnyElement; |
26 | |
import javax.xml.bind.annotation.XmlElement; |
27 | |
import javax.xml.bind.annotation.XmlType; |
28 | |
|
29 | |
import org.kuali.student.enrollment.lui.infc.LuiLuiRelation; |
30 | |
import org.kuali.student.r2.common.dto.IdEntityInfo; |
31 | |
import org.w3c.dom.Element; |
32 | |
|
33 | |
@XmlAccessorType(XmlAccessType.FIELD) |
34 | |
@XmlType(name = "LuiLuiRelationInfo", propOrder = { "id", "typeKey", |
35 | |
"stateKey", "name", "descr", "luiId", "relatedLuiId", "effectiveDate", |
36 | |
"expirationDate", "meta", "attributes", "_futureElements" }) |
37 | |
public class LuiLuiRelationInfo |
38 | |
extends IdEntityInfo |
39 | |
implements Serializable, LuiLuiRelation { |
40 | |
|
41 | |
private static final long serialVersionUID = 1L; |
42 | |
|
43 | |
@XmlElement |
44 | |
private String luiId; |
45 | |
|
46 | |
@XmlElement |
47 | |
private String relatedLuiId; |
48 | |
|
49 | |
@XmlElement |
50 | |
private Date effectiveDate; |
51 | |
|
52 | |
@XmlElement |
53 | |
private Date expirationDate; |
54 | |
|
55 | |
@XmlAnyElement |
56 | |
private List<Element> _futureElements; |
57 | |
|
58 | |
|
59 | |
|
60 | |
|
61 | |
|
62 | 0 | public LuiLuiRelationInfo() { |
63 | 0 | } |
64 | |
|
65 | |
|
66 | |
|
67 | |
|
68 | |
|
69 | |
|
70 | |
public LuiLuiRelationInfo(LuiLuiRelation llr) { |
71 | 0 | super(llr); |
72 | 0 | this.luiId = llr.getLuiId(); |
73 | 0 | this.relatedLuiId = llr.getRelatedLuiId(); |
74 | 0 | this.effectiveDate = null != llr.getEffectiveDate() ? new Date(llr.getEffectiveDate().getTime()) : null; |
75 | 0 | this.expirationDate = null != llr.getExpirationDate() ? new Date(llr.getExpirationDate().getTime()) : null; |
76 | 0 | this._futureElements = null; |
77 | 0 | } |
78 | |
|
79 | |
@Override |
80 | |
public String getLuiId() { |
81 | 0 | return luiId; |
82 | |
} |
83 | |
|
84 | |
public void setLuiId(String luiId) { |
85 | 0 | this.luiId = luiId; |
86 | 0 | } |
87 | |
|
88 | |
@Override |
89 | |
public String getRelatedLuiId() { |
90 | 0 | return relatedLuiId; |
91 | |
} |
92 | |
|
93 | |
public void setRelatedLuiId(String relatedLuiId) { |
94 | 0 | this.relatedLuiId = relatedLuiId; |
95 | 0 | } |
96 | |
|
97 | |
@Override |
98 | |
public Date getEffectiveDate() { |
99 | 0 | return effectiveDate != null ? new Date(effectiveDate.getTime()) : null; |
100 | |
} |
101 | |
|
102 | |
public void setEffectiveDate(Date effectiveDate) { |
103 | 0 | if (effectiveDate != null) |
104 | 0 | this.effectiveDate = new Date(effectiveDate.getTime()); |
105 | 0 | } |
106 | |
|
107 | |
@Override |
108 | |
public Date getExpirationDate() { |
109 | 0 | return expirationDate != null ? new Date(expirationDate.getTime()) : null; |
110 | |
} |
111 | |
|
112 | |
public void setExpirationDate(Date expirationDate) { |
113 | 0 | if (expirationDate != null) |
114 | 0 | this.expirationDate = new Date(expirationDate.getTime()); |
115 | 0 | } |
116 | |
} |