View Javadoc
1   package org.kuali.ole.select.bo;
2   
3   import org.kuali.rice.core.api.CoreApiServiceLocator;
4   import org.kuali.rice.krad.bo.PersistableBusinessObjectBase;
5   import org.kuali.rice.krad.util.GlobalVariables;
6   
7   import java.sql.Timestamp;
8   
9   /**
10   * OleEventLogBo is the business object class for License Request Maintenance Document.
11   */
12  public class OleEventLogBo extends PersistableBusinessObjectBase {
13  
14      private String oleEventLogId;
15      private String eventType;
16      private Timestamp createdDate;
17      private String createdBy;
18      private String eventDescription;
19      private String oleLicenseRequestId;
20  
21      private OleLicenseRequestBo oleLicenseRequestBo = new OleLicenseRequestBo();
22  
23      /**
24       * Gets the oleEventLogId attribute.
25       *
26       * @return Returns the oleEventLogId
27       */
28      public String getOleEventLogId() {
29          return oleEventLogId;
30      }
31  
32      /**
33       * Sets the oleEventLogId attribute value.
34       *
35       * @param oleEventLogId The oleEventLogId to set.
36       */
37      public void setOleEventLogId(String oleEventLogId) {
38          this.oleEventLogId = oleEventLogId;
39      }
40  
41      /**
42       * Gets the eventType attribute.
43       *
44       * @return Returns the eventType
45       */
46      public String getEventType() {
47          return eventType;
48      }
49  
50      /**
51       * Sets the eventType attribute value.
52       *
53       * @param eventType The eventType to set.
54       */
55      public void setEventType(String eventType) {
56          this.eventType = eventType;
57      }
58  
59      /**
60       * Gets the createdDate attribute.
61       *
62       * @return Returns the createdDate
63       */
64      public Timestamp getCreatedDate() {
65          return createdDate;
66      }
67  
68      /**
69       * Sets the createdDate attribute value.
70       *
71       * @param createdDate The createdDate to set.
72       */
73      public void setCreatedDate(Timestamp createdDate) {
74          this.createdDate = createdDate;
75      }
76  
77      /**
78       * Gets the createdBy attribute.
79       *
80       * @return Returns the createdBy
81       */
82      public String getCreatedBy() {
83          if (createdBy == null) {
84              createdBy = GlobalVariables.getUserSession().getPrincipalName();
85          }
86          return createdBy;
87      }
88  
89      /**
90       * Sets the createdBy attribute value.
91       *
92       * @param createdBy The createdBy to set.
93       */
94      public void setCreatedBy(String createdBy) {
95          this.createdBy = createdBy;
96      }
97  
98      /**
99       * Gets the eventDescription attribute.
100      *
101      * @return Returns the eventDescription
102      */
103     public String getEventDescription() {
104         return eventDescription;
105     }
106 
107     /**
108      * Sets the eventDescription attribute value.
109      *
110      * @param eventDescription The eventDescription to set.
111      */
112     public void setEventDescription(String eventDescription) {
113         this.eventDescription = eventDescription;
114     }
115 
116     /**
117      * Gets the oleLicenseRequestId attribute.
118      *
119      * @return Returns the oleLicenseRequestId
120      */
121     public String getOleLicenseRequestId() {
122         return oleLicenseRequestId;
123     }
124 
125     /**
126      * Sets the oleLicenseRequestId attribute value.
127      *
128      * @param oleLicenseRequestId The oleLicenseRequestId to set.
129      */
130     public void setOleLicenseRequestId(String oleLicenseRequestId) {
131         this.oleLicenseRequestId = oleLicenseRequestId;
132     }
133 
134     /**
135      * Gets the oleLicenseRequestBo attribute.
136      *
137      * @return Returns the oleLicenseRequestBo
138      */
139     public OleLicenseRequestBo getOleLicenseRequestBo() {
140         return oleLicenseRequestBo;
141     }
142 
143     /**
144      * Sets the oleLicenseRequestBo attribute value.
145      *
146      * @param oleLicenseRequestBo The oleLicenseRequestBo to set.
147      */
148     public void setOleLicenseRequestBo(OleLicenseRequestBo oleLicenseRequestBo) {
149         this.oleLicenseRequestBo = oleLicenseRequestBo;
150     }
151 
152     /**
153      * set the timestamp attribute value.
154      */
155     public void setCurrentTimeStamp() {
156         final Timestamp now = CoreApiServiceLocator.getDateTimeService().getCurrentTimestamp();
157         this.setCreatedDate(now);
158     }
159 }