View Javadoc
1   /**
2    * Copyright 2004-2015 The Kuali Foundation
3    *
4    * Licensed under the Educational Community License, Version 2.0 (the "License");
5    * you may not use this file except in compliance with the License.
6    * You may obtain a copy of the License at
7    *
8    * http://www.opensource.org/licenses/ecl2.php
9    *
10   * Unless required by applicable law or agreed to in writing, software
11   * distributed under the License is distributed on an "AS IS" BASIS,
12   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13   * See the License for the specific language governing permissions and
14   * limitations under the License.
15   */
16  package org.kuali.kpme.tklm.leave.accrual;
17  
18  import java.util.Date;
19  
20  import org.joda.time.DateTime;
21  import org.kuali.kpme.tklm.api.leave.accrual.PrincipalAccrualRanContract;
22  import org.kuali.rice.krad.bo.PersistableBusinessObjectBase;
23  
24  
25  public class PrincipalAccrualRan extends PersistableBusinessObjectBase implements PrincipalAccrualRanContract {
26  
27  	private static final long serialVersionUID = -8102955197478338957L;
28  	
29  	private String principalId;
30  	private Date lastRanTs;
31  
32  	public String getPrincipalId() {
33  		return principalId;
34  	}
35  
36  	public void setPrincipalId(String principalId) {
37  		this.principalId = principalId;
38  	}
39  
40  	public Date getLastRanTs() {
41  		return lastRanTs;
42  	}
43  
44  	public void setLastRanTs(Date lastRanTs) {
45  		this.lastRanTs = lastRanTs;
46  	}
47  
48  	public DateTime getLastRanDateTime() {
49  		return lastRanTs != null ? new DateTime(lastRanTs) : null;
50  	}
51  	
52  	public void setLastRanDateTime(DateTime lastRanDateTime) {
53  		lastRanTs = lastRanDateTime != null ? lastRanDateTime.toDate() : null;
54  	}
55  }