View Javadoc

1   /**
2    * Copyright 2004-2014 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.pm.positionappointment;
17  
18  import org.kuali.kpme.core.bo.HrBusinessObject;
19  import org.kuali.kpme.core.institution.Institution;
20  import org.kuali.kpme.core.location.Location;
21  import org.kuali.kpme.pm.api.positionappointment.PositionAppointmentContract;
22  
23  public class PositionAppointment extends HrBusinessObject implements PositionAppointmentContract {
24  	
25  	private static final long serialVersionUID = 1L;
26  	
27  	private String pmPositionAppointmentId;
28  	private String positionAppointment;
29  	private String description;
30  	private String institution;
31  	private String location;
32  	
33  	private Location locationObj;
34  	private Institution institutionObj;
35  	private boolean history;
36  	
37  	public boolean isHistory() {
38  		return history;
39  	}
40  
41  	public void setHistory(boolean history) {
42  		this.history = history;
43  	}
44  
45  	public String getPmPositionAppointmentId() {
46  		return pmPositionAppointmentId;
47  	}
48  
49  	public void setPmPositionAppointmentId(String pmPositionAppointmentId) {
50  		this.pmPositionAppointmentId = pmPositionAppointmentId;
51  	}
52  
53  	public String getPositionAppointment() {
54  		return positionAppointment;
55  	}
56  
57  	public void setPositionAppointment(String positionAppointment) {
58  		this.positionAppointment = positionAppointment;
59  	}
60  
61  	public String getDescription() {
62  		return description;
63  	}
64  
65  	public void setDescription(String description) {
66  		this.description = description;
67  	}
68  
69  	public String getInstitution() {
70  		return institution;
71  	}
72  
73  	public void setInstitution(String institution) {
74  		this.institution = institution;
75  	}
76  
77  	public String getLocation() {
78  		return location;
79  	}
80  
81  	public void setLocation(String location) {
82  		this.location = location;
83  	}
84  	@Override
85  	public String getId() {
86  		return getPmPositionAppointmentId();
87  	}
88  
89  	@Override
90  	public void setId(String pmPositionAppointmentId) {
91  		setPmPositionAppointmentId(pmPositionAppointmentId);
92  	}
93  	
94  	/**
95  	 * @return the locationObj
96  	 */
97  	public Location getLocationObj() {
98  		return locationObj;
99  	}
100 
101 	/**
102 	 * @param locationObj the locationObj to set
103 	 */
104 	public void setLocationObj(Location locationObj) {
105 		this.locationObj = locationObj;
106 	}
107 
108 	/**
109 	 * @return the institutionObj
110 	 */
111 	public Institution getInstitutionObj() {
112 		return institutionObj;
113 	}
114 
115 	/**
116 	 * @param institutionObj the institutionObj to set
117 	 */
118 	public void setInstitutionObj(Institution institutionObj) {
119 		this.institutionObj = institutionObj;
120 	}
121 
122 	@Override
123 	protected String getUniqueKey() {
124 		return getPositionAppointment() + "_" + getInstitution() + "_" + getLocation();
125 	}
126 
127 }