View Javadoc
1   package org.kuali.student.enrollment.class2.appointment.dto;
2   
3   import org.apache.commons.lang.StringUtils;
4   import org.kuali.student.enrollment.class2.acal.dto.TimeSetWrapper;
5   import org.kuali.student.r2.common.util.date.DateFormatters;
6   import org.kuali.student.r2.core.appointment.dto.AppointmentWindowInfo;
7   
8   import java.util.Date;
9   
10  public class AppointmentWindowWrapper extends TimeSetWrapper {
11      AppointmentWindowInfo appointmentWindowInfo;
12      //termType and termYear fields are used for AppointmentWindowWrapper lookup view only
13      String termType;
14      String termYear;
15  
16      String id;
17      String windowName;
18      String periodName;
19      String periodKey;
20      String assignedPopulationName;
21      String windowTypeKey;
22      String windowTypeName;
23  
24      //Assignment Info -- for inquiry view
25      Integer numberOfStudents;
26      Integer numberOfSlots;
27      Float meanStudentsPerSlot;
28  
29      String firstSlotPopulated;
30      String lastSlotPopulated;
31  
32      Date assignmentsCreated;
33      
34      //Appt rule type
35      String slotRuleEnumType;
36      
37      public String getTermType() {
38          return termType;
39      }
40  
41      public void setTermType(String termType) {
42          this.termType = termType;
43      }
44  
45      public String getTermYear() {
46          return termYear;
47      }
48  
49      public void setTermYear(String termYear) {
50          this.termYear = termYear;
51      }
52  
53      public String getId() {
54          return id;
55      }
56  
57      public void setId(String id) {
58          this.id = id;
59      }
60  
61      public String getWindowName() {
62          return windowName;
63      }
64  
65      public void setWindowName(String windowName) {
66          this.windowName = windowName;
67      }
68  
69      public AppointmentWindowWrapper() {
70          appointmentWindowInfo = new AppointmentWindowInfo();
71      }
72  
73      public AppointmentWindowInfo getAppointmentWindowInfo() {
74          return appointmentWindowInfo;
75      }
76  
77      public void setAppointmentWindowInfo(AppointmentWindowInfo appointmentWindowInfo) {
78          this.appointmentWindowInfo = appointmentWindowInfo;
79      }
80  
81      public String getPeriodName() {
82          return periodName;
83      }
84  
85      public void setPeriodName(String periodName) {
86          this.periodName = periodName;
87      }
88  
89      public String getPeriodKey() {
90          return periodKey;
91      }
92  
93      public void setPeriodKey(String periodKey) {
94          this.periodKey = periodKey;
95      }
96  
97      public String getAssignedPopulationName() {
98          return assignedPopulationName;
99      }
100 
101     public void setAssignedPopulationName(String assignedPopulationName) {
102         this.assignedPopulationName = assignedPopulationName;
103     }
104 
105     public String getWindowTypeKey() {
106         return windowTypeKey;
107     }
108 
109     public void setWindowTypeKey(String windowTypeKey) {
110         this.windowTypeKey = windowTypeKey;
111     }
112 
113     public String getWindowTypeName() {
114         return windowTypeName;
115     }
116 
117     public void setWindowTypeName(String windowTypeName) {
118         this.windowTypeName = windowTypeName;
119     }
120 
121     public Integer getNumberOfStudents() {
122         return numberOfStudents;
123     }
124 
125     public void setNumberOfStudents(Integer numberOfStudents) {
126         this.numberOfStudents = numberOfStudents;
127     }
128 
129     public Integer getNumberOfSlots() {
130         return numberOfSlots;
131     }
132 
133     public void setNumberOfSlots(Integer numberOfSlots) {
134         this.numberOfSlots = numberOfSlots;
135     }
136 
137     public Float getMeanStudentsPerSlot() {
138         return meanStudentsPerSlot;
139     }
140 
141     public void setMeanStudentsPerSlot(Float meanStudentsPerSlot) {
142         this.meanStudentsPerSlot = meanStudentsPerSlot;
143     }
144 
145     public String getLastSlotPopulated() {
146         return lastSlotPopulated;
147     }
148 
149     public void setLastSlotPopulated(String lastSlotPopulated) {
150         this.lastSlotPopulated = lastSlotPopulated;
151     }
152 
153     public Date getAssignmentsCreated() {
154         return assignmentsCreated;
155     }
156 
157     public void setAssignmentsCreated(Date assignmentsCreated) {
158         this.assignmentsCreated = assignmentsCreated;
159     }
160     
161     public void setSlotRuleEnumType(String slotRuleEnumType){
162         this.slotRuleEnumType = slotRuleEnumType;
163     }
164     
165     public String getSlotRuleEnumType() {
166         return slotRuleEnumType;
167     }
168 
169     public String getFirstSlotPopulated() {
170         return firstSlotPopulated;
171     }
172 
173     public void setFirstSlotPopulated(String firstSlotPopulated) {
174         this.firstSlotPopulated = firstSlotPopulated;
175     }
176 
177     //This is for UI display purpose
178     public String getStartDateUI(){
179         if (getStartDate() != null) {
180            return DateFormatters.MONTH_DAY_YEAR_DATE_FORMATTER.format(getStartDate());
181 
182         }else{
183             return StringUtils.EMPTY;
184         }
185 
186     }
187 
188     //This is for UI display purpose
189     public String getEndDateUI(){
190         if (endDateUI != null) {
191             return DateFormatters.MONTH_DAY_YEAR_DATE_FORMATTER.format(endDateUI);
192         }else{
193             return StringUtils.EMPTY;
194         }
195 
196     }
197 
198 }