001
014
015 package com.liferay.portal.model;
016
017 import java.util.Date;
018 import java.util.HashMap;
019 import java.util.Map;
020
021
030 public class PhoneWrapper implements Phone, ModelWrapper<Phone> {
031 public PhoneWrapper(Phone phone) {
032 _phone = phone;
033 }
034
035 public Class<?> getModelClass() {
036 return Phone.class;
037 }
038
039 public String getModelClassName() {
040 return Phone.class.getName();
041 }
042
043 public Map<String, Object> getModelAttributes() {
044 Map<String, Object> attributes = new HashMap<String, Object>();
045
046 attributes.put("phoneId", getPhoneId());
047 attributes.put("companyId", getCompanyId());
048 attributes.put("userId", getUserId());
049 attributes.put("userName", getUserName());
050 attributes.put("createDate", getCreateDate());
051 attributes.put("modifiedDate", getModifiedDate());
052 attributes.put("classNameId", getClassNameId());
053 attributes.put("classPK", getClassPK());
054 attributes.put("number", getNumber());
055 attributes.put("extension", getExtension());
056 attributes.put("typeId", getTypeId());
057 attributes.put("primary", getPrimary());
058
059 return attributes;
060 }
061
062 public void setModelAttributes(Map<String, Object> attributes) {
063 Long phoneId = (Long)attributes.get("phoneId");
064
065 if (phoneId != null) {
066 setPhoneId(phoneId);
067 }
068
069 Long companyId = (Long)attributes.get("companyId");
070
071 if (companyId != null) {
072 setCompanyId(companyId);
073 }
074
075 Long userId = (Long)attributes.get("userId");
076
077 if (userId != null) {
078 setUserId(userId);
079 }
080
081 String userName = (String)attributes.get("userName");
082
083 if (userName != null) {
084 setUserName(userName);
085 }
086
087 Date createDate = (Date)attributes.get("createDate");
088
089 if (createDate != null) {
090 setCreateDate(createDate);
091 }
092
093 Date modifiedDate = (Date)attributes.get("modifiedDate");
094
095 if (modifiedDate != null) {
096 setModifiedDate(modifiedDate);
097 }
098
099 Long classNameId = (Long)attributes.get("classNameId");
100
101 if (classNameId != null) {
102 setClassNameId(classNameId);
103 }
104
105 Long classPK = (Long)attributes.get("classPK");
106
107 if (classPK != null) {
108 setClassPK(classPK);
109 }
110
111 String number = (String)attributes.get("number");
112
113 if (number != null) {
114 setNumber(number);
115 }
116
117 String extension = (String)attributes.get("extension");
118
119 if (extension != null) {
120 setExtension(extension);
121 }
122
123 Integer typeId = (Integer)attributes.get("typeId");
124
125 if (typeId != null) {
126 setTypeId(typeId);
127 }
128
129 Boolean primary = (Boolean)attributes.get("primary");
130
131 if (primary != null) {
132 setPrimary(primary);
133 }
134 }
135
136
141 public long getPrimaryKey() {
142 return _phone.getPrimaryKey();
143 }
144
145
150 public void setPrimaryKey(long primaryKey) {
151 _phone.setPrimaryKey(primaryKey);
152 }
153
154
159 public long getPhoneId() {
160 return _phone.getPhoneId();
161 }
162
163
168 public void setPhoneId(long phoneId) {
169 _phone.setPhoneId(phoneId);
170 }
171
172
177 public long getCompanyId() {
178 return _phone.getCompanyId();
179 }
180
181
186 public void setCompanyId(long companyId) {
187 _phone.setCompanyId(companyId);
188 }
189
190
195 public long getUserId() {
196 return _phone.getUserId();
197 }
198
199
204 public void setUserId(long userId) {
205 _phone.setUserId(userId);
206 }
207
208
214 public java.lang.String getUserUuid()
215 throws com.liferay.portal.kernel.exception.SystemException {
216 return _phone.getUserUuid();
217 }
218
219
224 public void setUserUuid(java.lang.String userUuid) {
225 _phone.setUserUuid(userUuid);
226 }
227
228
233 public java.lang.String getUserName() {
234 return _phone.getUserName();
235 }
236
237
242 public void setUserName(java.lang.String userName) {
243 _phone.setUserName(userName);
244 }
245
246
251 public java.util.Date getCreateDate() {
252 return _phone.getCreateDate();
253 }
254
255
260 public void setCreateDate(java.util.Date createDate) {
261 _phone.setCreateDate(createDate);
262 }
263
264
269 public java.util.Date getModifiedDate() {
270 return _phone.getModifiedDate();
271 }
272
273
278 public void setModifiedDate(java.util.Date modifiedDate) {
279 _phone.setModifiedDate(modifiedDate);
280 }
281
282
287 public java.lang.String getClassName() {
288 return _phone.getClassName();
289 }
290
291 public void setClassName(java.lang.String className) {
292 _phone.setClassName(className);
293 }
294
295
300 public long getClassNameId() {
301 return _phone.getClassNameId();
302 }
303
304
309 public void setClassNameId(long classNameId) {
310 _phone.setClassNameId(classNameId);
311 }
312
313
318 public long getClassPK() {
319 return _phone.getClassPK();
320 }
321
322
327 public void setClassPK(long classPK) {
328 _phone.setClassPK(classPK);
329 }
330
331
336 public java.lang.String getNumber() {
337 return _phone.getNumber();
338 }
339
340
345 public void setNumber(java.lang.String number) {
346 _phone.setNumber(number);
347 }
348
349
354 public java.lang.String getExtension() {
355 return _phone.getExtension();
356 }
357
358
363 public void setExtension(java.lang.String extension) {
364 _phone.setExtension(extension);
365 }
366
367
372 public int getTypeId() {
373 return _phone.getTypeId();
374 }
375
376
381 public void setTypeId(int typeId) {
382 _phone.setTypeId(typeId);
383 }
384
385
390 public boolean getPrimary() {
391 return _phone.getPrimary();
392 }
393
394
399 public boolean isPrimary() {
400 return _phone.isPrimary();
401 }
402
403
408 public void setPrimary(boolean primary) {
409 _phone.setPrimary(primary);
410 }
411
412 public boolean isNew() {
413 return _phone.isNew();
414 }
415
416 public void setNew(boolean n) {
417 _phone.setNew(n);
418 }
419
420 public boolean isCachedModel() {
421 return _phone.isCachedModel();
422 }
423
424 public void setCachedModel(boolean cachedModel) {
425 _phone.setCachedModel(cachedModel);
426 }
427
428 public boolean isEscapedModel() {
429 return _phone.isEscapedModel();
430 }
431
432 public java.io.Serializable getPrimaryKeyObj() {
433 return _phone.getPrimaryKeyObj();
434 }
435
436 public void setPrimaryKeyObj(java.io.Serializable primaryKeyObj) {
437 _phone.setPrimaryKeyObj(primaryKeyObj);
438 }
439
440 public com.liferay.portlet.expando.model.ExpandoBridge getExpandoBridge() {
441 return _phone.getExpandoBridge();
442 }
443
444 public void setExpandoBridgeAttributes(
445 com.liferay.portal.model.BaseModel<?> baseModel) {
446 _phone.setExpandoBridgeAttributes(baseModel);
447 }
448
449 public void setExpandoBridgeAttributes(
450 com.liferay.portlet.expando.model.ExpandoBridge expandoBridge) {
451 _phone.setExpandoBridgeAttributes(expandoBridge);
452 }
453
454 public void setExpandoBridgeAttributes(
455 com.liferay.portal.service.ServiceContext serviceContext) {
456 _phone.setExpandoBridgeAttributes(serviceContext);
457 }
458
459 @Override
460 public java.lang.Object clone() {
461 return new PhoneWrapper((Phone)_phone.clone());
462 }
463
464 public int compareTo(com.liferay.portal.model.Phone phone) {
465 return _phone.compareTo(phone);
466 }
467
468 @Override
469 public int hashCode() {
470 return _phone.hashCode();
471 }
472
473 public com.liferay.portal.model.CacheModel<com.liferay.portal.model.Phone> toCacheModel() {
474 return _phone.toCacheModel();
475 }
476
477 public com.liferay.portal.model.Phone toEscapedModel() {
478 return new PhoneWrapper(_phone.toEscapedModel());
479 }
480
481 public com.liferay.portal.model.Phone toUnescapedModel() {
482 return new PhoneWrapper(_phone.toUnescapedModel());
483 }
484
485 @Override
486 public java.lang.String toString() {
487 return _phone.toString();
488 }
489
490 public java.lang.String toXmlString() {
491 return _phone.toXmlString();
492 }
493
494 public void persist()
495 throws com.liferay.portal.kernel.exception.SystemException {
496 _phone.persist();
497 }
498
499 public com.liferay.portal.model.ListType getType()
500 throws com.liferay.portal.kernel.exception.PortalException,
501 com.liferay.portal.kernel.exception.SystemException {
502 return _phone.getType();
503 }
504
505
508 public Phone getWrappedPhone() {
509 return _phone;
510 }
511
512 public Phone getWrappedModel() {
513 return _phone;
514 }
515
516 public void resetOriginalValues() {
517 _phone.resetOriginalValues();
518 }
519
520 private Phone _phone;
521 }