View Javadoc
1   /*
2    * Copyright 2009 The Kuali Foundation Licensed under the Educational Community
3    * License, Version 1.0 (the "License"); you may not use this file except in
4    * compliance with the License. You may obtain a copy of the License at
5    * http://www.opensource.org/licenses/ecl1.php Unless required by applicable law
6    * or agreed to in writing, software distributed under the License is
7    * distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
8    * KIND, either express or implied. See the License for the specific language
9    * governing permissions and limitations under the License.
10   */
11  package org.kuali.student.r2.lum.program.dto;
12  
13  import java.io.Serializable;
14  import java.util.ArrayList;
15  import java.util.Date;
16  import java.util.List;
17  
18  import javax.xml.bind.annotation.*;
19  
20  
21  import org.kuali.student.r2.common.dto.TimeAmountInfo;
22  import org.kuali.student.r2.lum.program.infc.CommonWithProgramVariation;
23  import org.kuali.student.r2.lum.program.infc.ProgramVariation;
24  
25  @SuppressWarnings("serial")
26  @XmlTransient
27  public class CommonWithProgramVariationInfo extends CommonWithCoreProgramInfo implements ProgramVariation, Serializable {
28  
29      @XmlElement
30      private String intensity;
31      @XmlElement
32      private String cip2000Code;
33      @XmlElement
34      private String cip2010Code;
35      @XmlElement
36      private String hegisCode;
37      @XmlElement
38      private String selectiveEnrollmentCode;
39      @XmlElement
40      private Date effectiveDate;
41      @XmlElement
42      private String diplomaTitle;
43      @XmlElement
44      private List<String> campusLocations;
45      @XmlElement
46      private List<String> resultOptions;
47      @XmlElement
48      private TimeAmountInfo stdDuration;
49      @XmlElement
50      private List<String> divisionsDeployment;
51      @XmlElement
52      private List<String> divisionsFinancialResources;
53      @XmlElement
54      private List<String> divisionsFinancialControl;
55      @XmlElement
56      private List<String> unitsDeployment;
57      @XmlElement
58      private List<String> unitsFinancialResources;
59      @XmlElement
60      private List<String> unitsFinancialControl;
61  
62      public CommonWithProgramVariationInfo() {
63          super();
64      }
65  
66      public CommonWithProgramVariationInfo(CommonWithProgramVariation input) {
67          super (input);
68          this.intensity = input.getIntensity();
69          this.cip2000Code = input.getCip2000Code();
70          this.cip2010Code = input.getCip2010Code();
71          this.hegisCode = input.getHegisCode();
72          this.selectiveEnrollmentCode = input.getSelectiveEnrollmentCode();
73          if (effectiveDate != null) {
74              this.effectiveDate = new Date(input.getEffectiveDate().getTime());
75          }
76          this.diplomaTitle = input.getDiplomaTitle();
77          if (input.getCampusLocations() != null) {
78              this.campusLocations = new ArrayList<String>(input.getCampusLocations());
79          }
80          if (input.getResultOptions() != null) {
81              this.resultOptions = new ArrayList<String>(input.getResultOptions());
82          }
83          if (input.getStdDuration() != null) {
84              this.stdDuration = new TimeAmountInfo(input.getStdDuration());
85          }
86          if (input.getDivisionsDeployment() != null) {
87              this.divisionsDeployment = new ArrayList<String>(input.getDivisionsDeployment());
88          }
89          if (input.getDivisionsFinancialResources() != null) {
90              this.divisionsFinancialResources = new ArrayList<String>(input.getDivisionsFinancialResources());
91          }
92          if (input.getDivisionsFinancialControl() != null) {
93              this.divisionsFinancialControl = new ArrayList<String>(input.getDivisionsFinancialControl());
94          }
95          if (input.getUnitsDeployment() != null) {
96              this.unitsDeployment = new ArrayList<String>(input.getUnitsDeployment());
97          }
98          if (input.getUnitsFinancialResources() != null) {
99              this.unitsFinancialResources = new ArrayList<String>(input.getUnitsFinancialResources());
100         }
101         if (input.getUnitsFinancialControl() != null) {
102             this.unitsFinancialResources = new ArrayList<String>(input.getUnitsFinancialControl());
103         }
104     }
105 
106     @Override
107     public String getIntensity() {
108         return intensity;
109     }
110 
111     public void setIntensity(String intensity) {
112         this.intensity = intensity;
113     }
114 
115     @Override
116     public List<String> getResultOptions() {
117         return resultOptions;
118     }
119 
120     public void setResultOptions(List<String> resultOptions) {
121         this.resultOptions = resultOptions;
122     }
123 
124     @Override
125     public TimeAmountInfo getStdDuration() {
126         return stdDuration;
127     }
128 
129     public void setStdDuration(TimeAmountInfo stdDuration) {
130         this.stdDuration = stdDuration;
131     }
132 
133     @Override
134     public Date getEffectiveDate() {
135         return effectiveDate;
136     }
137 
138     public void setEffectiveDate(Date effectiveDate) {
139         this.effectiveDate = effectiveDate;
140     }
141 
142     @Override
143     public String getDiplomaTitle() {
144         return diplomaTitle;
145     }
146 
147     public void setDiplomaTitle(String diplomaTitle) {
148         this.diplomaTitle = diplomaTitle;
149     }
150 
151     @Override
152     public List<String> getCampusLocations() {
153         if (campusLocations == null) {
154             campusLocations = new ArrayList<String>(0);
155         }
156         return campusLocations;
157     }
158 
159     public void setCampusLocations(List<String> campusLocations) {
160         this.campusLocations = campusLocations;
161     }
162 
163     @Override
164     public List<String> getDivisionsDeployment() {
165         return divisionsDeployment;
166     }
167 
168     public void setDivisionsDeployment(List<String> divisionsDeployment) {
169         this.divisionsDeployment = divisionsDeployment;
170     }
171 
172     @Override
173     public List<String> getDivisionsFinancialResources() {
174         return divisionsFinancialResources;
175     }
176 
177     public void setDivisionsFinancialResources(List<String> divisionsFinancialResources) {
178         this.divisionsFinancialResources = divisionsFinancialResources;
179     }
180 
181     @Override
182     public List<String> getDivisionsFinancialControl() {
183         return divisionsFinancialControl;
184     }
185 
186     public void setDivisionsFinancialControl(List<String> divisionsFinancialControl) {
187         this.divisionsFinancialControl = divisionsFinancialControl;
188     }
189 
190     @Override
191     public List<String> getUnitsDeployment() {
192         return unitsDeployment;
193     }
194 
195     public void setUnitsDeployment(List<String> unitsDeployment) {
196         this.unitsDeployment = unitsDeployment;
197     }
198 
199     @Override
200     public List<String> getUnitsFinancialResources() {
201         return unitsFinancialResources;
202     }
203 
204     public void setUnitsFinancialResources(List<String> unitsFinancialResources) {
205         this.unitsFinancialResources = unitsFinancialResources;
206     }
207 
208     @Override
209     public List<String> getUnitsFinancialControl() {
210         return unitsFinancialControl;
211     }
212 
213     public void setUnitsFinancialControl(List<String> unitsFinancialControl) {
214         this.unitsFinancialControl = unitsFinancialControl;
215     }
216 
217     @Override
218     public String getCip2000Code() {
219         return cip2000Code;
220     }
221 
222     public void setCip2000Code(String cip2000Code) {
223         this.cip2000Code = cip2000Code;
224     }
225 
226     @Override
227     public String getCip2010Code() {
228         return cip2010Code;
229     }
230 
231     public void setCip2010Code(String cip2010Code) {
232         this.cip2010Code = cip2010Code;
233     }
234 
235     @Override
236     public String getHegisCode() {
237         return hegisCode;
238     }
239 
240     public void setHegisCode(String hegisCode) {
241         this.hegisCode = hegisCode;
242     }
243 
244     @Override
245     public String getSelectiveEnrollmentCode() {
246         return selectiveEnrollmentCode;
247     }
248 
249     public void setSelectiveEnrollmentCode(String selectiveEnrollmentCode) {
250         this.selectiveEnrollmentCode = selectiveEnrollmentCode;
251     }
252 }