001: /*
002: * Copyright 2007 The Kuali Foundation.
003: *
004: * Licensed under the Educational Community License, Version 1.0 (the "License");
005: * you may not use this file except in compliance with the License.
006: * You may obtain a copy of the License at
007: *
008: * http://www.opensource.org/licenses/ecl1.php
009: *
010: * Unless required by applicable law or agreed to in writing, software
011: * distributed under the License is distributed on an "AS IS" BASIS,
012: * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
013: * See the License for the specific language governing permissions and
014: * limitations under the License.
015: */
016:
017: package org.kuali.module.vendor.bo;
018:
019: import java.util.LinkedHashMap;
020: import java.util.List;
021:
022: import org.kuali.core.bo.Inactivateable;
023: import org.kuali.core.bo.PersistableBusinessObjectBase;
024: import org.kuali.core.util.TypedArrayList;
025: import org.kuali.kfs.bo.Country;
026: import org.kuali.kfs.bo.State;
027:
028: /**
029: * Container for information about how to get in Contact with a person at a Vendor for a particular purpose.
030: */
031: public class VendorContact extends PersistableBusinessObjectBase
032: implements Inactivateable {
033:
034: private Integer vendorContactGeneratedIdentifier;
035: private Integer vendorHeaderGeneratedIdentifier;
036: private Integer vendorDetailAssignedIdentifier;
037: private String vendorContactTypeCode;
038: private String vendorContactName;
039: private String vendorContactEmailAddress;
040: private String vendorContactCommentText;
041: private String vendorLine1Address;
042: private String vendorLine2Address;
043: private String vendorCityName;
044: private String vendorStateCode;
045: private String vendorZipCode;
046: private String vendorCountryCode;
047: private String vendorAttentionName;
048: private String vendorAddressInternationalProvinceName;
049: private boolean active;
050:
051: // These aren't persisted in db, only for lookup page
052: private String phoneNumberForLookup;
053: private String tollFreeForLookup;
054: private String faxForLookup;
055:
056: private List<VendorContactPhoneNumber> vendorContactPhoneNumbers;
057:
058: private VendorDetail vendorDetail;
059: private ContactType vendorContactType;
060: private State vendorState;
061: private Country vendorCountry;
062:
063: /**
064: * Default constructor.
065: */
066: public VendorContact() {
067: vendorContactPhoneNumbers = new TypedArrayList(
068: VendorContactPhoneNumber.class);
069: }
070:
071: public Integer getVendorContactGeneratedIdentifier() {
072: return vendorContactGeneratedIdentifier;
073: }
074:
075: public void setVendorContactGeneratedIdentifier(
076: Integer vendorContactGeneratedIdentifier) {
077: this .vendorContactGeneratedIdentifier = vendorContactGeneratedIdentifier;
078: }
079:
080: public Integer getVendorHeaderGeneratedIdentifier() {
081: return vendorHeaderGeneratedIdentifier;
082: }
083:
084: public void setVendorHeaderGeneratedIdentifier(
085: Integer vendorHeaderGeneratedIdentifier) {
086: this .vendorHeaderGeneratedIdentifier = vendorHeaderGeneratedIdentifier;
087: }
088:
089: public Integer getVendorDetailAssignedIdentifier() {
090: return vendorDetailAssignedIdentifier;
091: }
092:
093: public void setVendorDetailAssignedIdentifier(
094: Integer vendorDetailAssignedIdentifier) {
095: this .vendorDetailAssignedIdentifier = vendorDetailAssignedIdentifier;
096: }
097:
098: public String getVendorContactTypeCode() {
099: return vendorContactTypeCode;
100: }
101:
102: public void setVendorContactTypeCode(String vendorContactTypeCode) {
103: this .vendorContactTypeCode = vendorContactTypeCode;
104: }
105:
106: public String getVendorContactName() {
107: return vendorContactName;
108: }
109:
110: public void setVendorContactName(String vendorContactName) {
111: this .vendorContactName = vendorContactName;
112: }
113:
114: public String getVendorContactEmailAddress() {
115: return vendorContactEmailAddress;
116: }
117:
118: public void setVendorContactEmailAddress(
119: String vendorContactEmailAddress) {
120: this .vendorContactEmailAddress = vendorContactEmailAddress;
121: }
122:
123: public String getVendorContactCommentText() {
124: return vendorContactCommentText;
125: }
126:
127: public void setVendorContactCommentText(
128: String vendorContactCommentText) {
129: this .vendorContactCommentText = vendorContactCommentText;
130: }
131:
132: public ContactType getVendorContactType() {
133: return vendorContactType;
134: }
135:
136: /**
137: * Sets the vendorContactType attribute.
138: *
139: * @param vendorContactType The vendorContactType to set.
140: * @deprecated
141: */
142: public void setVendorContactType(ContactType vendorContactType) {
143: this .vendorContactType = vendorContactType;
144: }
145:
146: public VendorDetail getVendorDetail() {
147: return vendorDetail;
148: }
149:
150: public void setVendorDetail(VendorDetail vendorDetail) {
151: this .vendorDetail = vendorDetail;
152: }
153:
154: public String getVendorAddressInternationalProvinceName() {
155: return vendorAddressInternationalProvinceName;
156: }
157:
158: public void setVendorAddressInternationalProvinceName(
159: String vendorAddressInternationalProvinceName) {
160: this .vendorAddressInternationalProvinceName = vendorAddressInternationalProvinceName;
161: }
162:
163: public boolean isActive() {
164: return active;
165: }
166:
167: public void setActive(boolean active) {
168: this .active = active;
169: }
170:
171: public String getVendorAttentionName() {
172: return vendorAttentionName;
173: }
174:
175: public void setVendorAttentionName(String vendorAttentionName) {
176: this .vendorAttentionName = vendorAttentionName;
177: }
178:
179: public String getVendorCityName() {
180: return vendorCityName;
181: }
182:
183: public void setVendorCityName(String vendorCityName) {
184: this .vendorCityName = vendorCityName;
185: }
186:
187: public String getVendorCountryCode() {
188: return vendorCountryCode;
189: }
190:
191: public void setVendorCountryCode(String vendorCountryCode) {
192: this .vendorCountryCode = vendorCountryCode;
193: }
194:
195: public String getVendorLine1Address() {
196: return vendorLine1Address;
197: }
198:
199: public void setVendorLine1Address(String vendorLine1Address) {
200: this .vendorLine1Address = vendorLine1Address;
201: }
202:
203: public String getVendorLine2Address() {
204: return vendorLine2Address;
205: }
206:
207: public void setVendorLine2Address(String vendorLine2Address) {
208: this .vendorLine2Address = vendorLine2Address;
209: }
210:
211: public String getVendorStateCode() {
212: return vendorStateCode;
213: }
214:
215: public void setVendorStateCode(String vendorStateCode) {
216: this .vendorStateCode = vendorStateCode;
217: }
218:
219: public String getVendorZipCode() {
220: return vendorZipCode;
221: }
222:
223: public void setVendorZipCode(String vendorZipCode) {
224: this .vendorZipCode = vendorZipCode;
225: }
226:
227: public Country getVendorCountry() {
228: return vendorCountry;
229: }
230:
231: /**
232: * Sets the vendorCountry attribute value.
233: *
234: * @param vendorCountry The vendorCountry to set.
235: * @deprecated
236: */
237: public void setVendorCountry(Country vendorCountry) {
238: this .vendorCountry = vendorCountry;
239: }
240:
241: public State getVendorState() {
242: return vendorState;
243: }
244:
245: /**
246: * Sets the vendorState attribute value.
247: *
248: * @param vendorState The vendorState to set.
249: * @deprecated
250: */
251: public void setVendorState(State vendorState) {
252: this .vendorState = vendorState;
253: }
254:
255: public String getFaxForLookup() {
256: return faxForLookup;
257: }
258:
259: public void setFaxForLookup(String faxForLookup) {
260: this .faxForLookup = faxForLookup;
261: }
262:
263: public String getPhoneNumberForLookup() {
264: return phoneNumberForLookup;
265: }
266:
267: public void setPhoneNumberForLookup(String phoneNumberForLookup) {
268: this .phoneNumberForLookup = phoneNumberForLookup;
269: }
270:
271: public String getTollFreeForLookup() {
272: return tollFreeForLookup;
273: }
274:
275: public void setTollFreeForLookup(String tollFreeForLookup) {
276: this .tollFreeForLookup = tollFreeForLookup;
277: }
278:
279: /**
280: * @see org.kuali.core.bo.BusinessObjectBase#toStringMapper()
281: */
282: protected LinkedHashMap toStringMapper() {
283: LinkedHashMap m = new LinkedHashMap();
284: if (this .vendorContactGeneratedIdentifier != null) {
285: m.put("vendorContactGeneratedIdentifier",
286: this .vendorContactGeneratedIdentifier.toString());
287: }
288: return m;
289: }
290:
291: public List<VendorContactPhoneNumber> getVendorContactPhoneNumbers() {
292: return vendorContactPhoneNumbers;
293: }
294:
295: public void setVendorContactPhoneNumbers(
296: List<VendorContactPhoneNumber> vendorContactPhoneNumbers) {
297: this.vendorContactPhoneNumbers = vendorContactPhoneNumbers;
298: }
299:
300: }
|