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 RoleWrapper implements Role, ModelWrapper<Role> {
031 public RoleWrapper(Role role) {
032 _role = role;
033 }
034
035 public Class<?> getModelClass() {
036 return Role.class;
037 }
038
039 public String getModelClassName() {
040 return Role.class.getName();
041 }
042
043 public Map<String, Object> getModelAttributes() {
044 Map<String, Object> attributes = new HashMap<String, Object>();
045
046 attributes.put("uuid", getUuid());
047 attributes.put("roleId", getRoleId());
048 attributes.put("companyId", getCompanyId());
049 attributes.put("userId", getUserId());
050 attributes.put("userName", getUserName());
051 attributes.put("createDate", getCreateDate());
052 attributes.put("modifiedDate", getModifiedDate());
053 attributes.put("classNameId", getClassNameId());
054 attributes.put("classPK", getClassPK());
055 attributes.put("name", getName());
056 attributes.put("title", getTitle());
057 attributes.put("description", getDescription());
058 attributes.put("type", getType());
059 attributes.put("subtype", getSubtype());
060
061 return attributes;
062 }
063
064 public void setModelAttributes(Map<String, Object> attributes) {
065 String uuid = (String)attributes.get("uuid");
066
067 if (uuid != null) {
068 setUuid(uuid);
069 }
070
071 Long roleId = (Long)attributes.get("roleId");
072
073 if (roleId != null) {
074 setRoleId(roleId);
075 }
076
077 Long companyId = (Long)attributes.get("companyId");
078
079 if (companyId != null) {
080 setCompanyId(companyId);
081 }
082
083 Long userId = (Long)attributes.get("userId");
084
085 if (userId != null) {
086 setUserId(userId);
087 }
088
089 String userName = (String)attributes.get("userName");
090
091 if (userName != null) {
092 setUserName(userName);
093 }
094
095 Date createDate = (Date)attributes.get("createDate");
096
097 if (createDate != null) {
098 setCreateDate(createDate);
099 }
100
101 Date modifiedDate = (Date)attributes.get("modifiedDate");
102
103 if (modifiedDate != null) {
104 setModifiedDate(modifiedDate);
105 }
106
107 Long classNameId = (Long)attributes.get("classNameId");
108
109 if (classNameId != null) {
110 setClassNameId(classNameId);
111 }
112
113 Long classPK = (Long)attributes.get("classPK");
114
115 if (classPK != null) {
116 setClassPK(classPK);
117 }
118
119 String name = (String)attributes.get("name");
120
121 if (name != null) {
122 setName(name);
123 }
124
125 String title = (String)attributes.get("title");
126
127 if (title != null) {
128 setTitle(title);
129 }
130
131 String description = (String)attributes.get("description");
132
133 if (description != null) {
134 setDescription(description);
135 }
136
137 Integer type = (Integer)attributes.get("type");
138
139 if (type != null) {
140 setType(type);
141 }
142
143 String subtype = (String)attributes.get("subtype");
144
145 if (subtype != null) {
146 setSubtype(subtype);
147 }
148 }
149
150
155 public long getPrimaryKey() {
156 return _role.getPrimaryKey();
157 }
158
159
164 public void setPrimaryKey(long primaryKey) {
165 _role.setPrimaryKey(primaryKey);
166 }
167
168
173 public java.lang.String getUuid() {
174 return _role.getUuid();
175 }
176
177
182 public void setUuid(java.lang.String uuid) {
183 _role.setUuid(uuid);
184 }
185
186
191 public long getRoleId() {
192 return _role.getRoleId();
193 }
194
195
200 public void setRoleId(long roleId) {
201 _role.setRoleId(roleId);
202 }
203
204
209 public long getCompanyId() {
210 return _role.getCompanyId();
211 }
212
213
218 public void setCompanyId(long companyId) {
219 _role.setCompanyId(companyId);
220 }
221
222
227 public long getUserId() {
228 return _role.getUserId();
229 }
230
231
236 public void setUserId(long userId) {
237 _role.setUserId(userId);
238 }
239
240
246 public java.lang.String getUserUuid()
247 throws com.liferay.portal.kernel.exception.SystemException {
248 return _role.getUserUuid();
249 }
250
251
256 public void setUserUuid(java.lang.String userUuid) {
257 _role.setUserUuid(userUuid);
258 }
259
260
265 public java.lang.String getUserName() {
266 return _role.getUserName();
267 }
268
269
274 public void setUserName(java.lang.String userName) {
275 _role.setUserName(userName);
276 }
277
278
283 public java.util.Date getCreateDate() {
284 return _role.getCreateDate();
285 }
286
287
292 public void setCreateDate(java.util.Date createDate) {
293 _role.setCreateDate(createDate);
294 }
295
296
301 public java.util.Date getModifiedDate() {
302 return _role.getModifiedDate();
303 }
304
305
310 public void setModifiedDate(java.util.Date modifiedDate) {
311 _role.setModifiedDate(modifiedDate);
312 }
313
314
319 public java.lang.String getClassName() {
320 return _role.getClassName();
321 }
322
323 public void setClassName(java.lang.String className) {
324 _role.setClassName(className);
325 }
326
327
332 public long getClassNameId() {
333 return _role.getClassNameId();
334 }
335
336
341 public void setClassNameId(long classNameId) {
342 _role.setClassNameId(classNameId);
343 }
344
345
350 public long getClassPK() {
351 return _role.getClassPK();
352 }
353
354
359 public void setClassPK(long classPK) {
360 _role.setClassPK(classPK);
361 }
362
363
368 public java.lang.String getName() {
369 return _role.getName();
370 }
371
372
377 public void setName(java.lang.String name) {
378 _role.setName(name);
379 }
380
381
386 public java.lang.String getTitle() {
387 return _role.getTitle();
388 }
389
390
396 public java.lang.String getTitle(java.util.Locale locale) {
397 return _role.getTitle(locale);
398 }
399
400
407 public java.lang.String getTitle(java.util.Locale locale, boolean useDefault) {
408 return _role.getTitle(locale, useDefault);
409 }
410
411
417 public java.lang.String getTitle(java.lang.String languageId) {
418 return _role.getTitle(languageId);
419 }
420
421
428 public java.lang.String getTitle(java.lang.String languageId,
429 boolean useDefault) {
430 return _role.getTitle(languageId, useDefault);
431 }
432
433 public java.lang.String getTitleCurrentLanguageId() {
434 return _role.getTitleCurrentLanguageId();
435 }
436
437 public java.lang.String getTitleCurrentValue() {
438 return _role.getTitleCurrentValue();
439 }
440
441
446 public java.util.Map<java.util.Locale, java.lang.String> getTitleMap() {
447 return _role.getTitleMap();
448 }
449
450
455 public void setTitle(java.lang.String title) {
456 _role.setTitle(title);
457 }
458
459
465 public void setTitle(java.lang.String title, java.util.Locale locale) {
466 _role.setTitle(title, locale);
467 }
468
469
476 public void setTitle(java.lang.String title, java.util.Locale locale,
477 java.util.Locale defaultLocale) {
478 _role.setTitle(title, locale, defaultLocale);
479 }
480
481 public void setTitleCurrentLanguageId(java.lang.String languageId) {
482 _role.setTitleCurrentLanguageId(languageId);
483 }
484
485
490 public void setTitleMap(
491 java.util.Map<java.util.Locale, java.lang.String> titleMap) {
492 _role.setTitleMap(titleMap);
493 }
494
495
501 public void setTitleMap(
502 java.util.Map<java.util.Locale, java.lang.String> titleMap,
503 java.util.Locale defaultLocale) {
504 _role.setTitleMap(titleMap, defaultLocale);
505 }
506
507
512 public java.lang.String getDescription() {
513 return _role.getDescription();
514 }
515
516
522 public java.lang.String getDescription(java.util.Locale locale) {
523 return _role.getDescription(locale);
524 }
525
526
533 public java.lang.String getDescription(java.util.Locale locale,
534 boolean useDefault) {
535 return _role.getDescription(locale, useDefault);
536 }
537
538
544 public java.lang.String getDescription(java.lang.String languageId) {
545 return _role.getDescription(languageId);
546 }
547
548
555 public java.lang.String getDescription(java.lang.String languageId,
556 boolean useDefault) {
557 return _role.getDescription(languageId, useDefault);
558 }
559
560 public java.lang.String getDescriptionCurrentLanguageId() {
561 return _role.getDescriptionCurrentLanguageId();
562 }
563
564 public java.lang.String getDescriptionCurrentValue() {
565 return _role.getDescriptionCurrentValue();
566 }
567
568
573 public java.util.Map<java.util.Locale, java.lang.String> getDescriptionMap() {
574 return _role.getDescriptionMap();
575 }
576
577
582 public void setDescription(java.lang.String description) {
583 _role.setDescription(description);
584 }
585
586
592 public void setDescription(java.lang.String description,
593 java.util.Locale locale) {
594 _role.setDescription(description, locale);
595 }
596
597
604 public void setDescription(java.lang.String description,
605 java.util.Locale locale, java.util.Locale defaultLocale) {
606 _role.setDescription(description, locale, defaultLocale);
607 }
608
609 public void setDescriptionCurrentLanguageId(java.lang.String languageId) {
610 _role.setDescriptionCurrentLanguageId(languageId);
611 }
612
613
618 public void setDescriptionMap(
619 java.util.Map<java.util.Locale, java.lang.String> descriptionMap) {
620 _role.setDescriptionMap(descriptionMap);
621 }
622
623
629 public void setDescriptionMap(
630 java.util.Map<java.util.Locale, java.lang.String> descriptionMap,
631 java.util.Locale defaultLocale) {
632 _role.setDescriptionMap(descriptionMap, defaultLocale);
633 }
634
635
640 public int getType() {
641 return _role.getType();
642 }
643
644
649 public void setType(int type) {
650 _role.setType(type);
651 }
652
653
658 public java.lang.String getSubtype() {
659 return _role.getSubtype();
660 }
661
662
667 public void setSubtype(java.lang.String subtype) {
668 _role.setSubtype(subtype);
669 }
670
671 public boolean isNew() {
672 return _role.isNew();
673 }
674
675 public void setNew(boolean n) {
676 _role.setNew(n);
677 }
678
679 public boolean isCachedModel() {
680 return _role.isCachedModel();
681 }
682
683 public void setCachedModel(boolean cachedModel) {
684 _role.setCachedModel(cachedModel);
685 }
686
687 public boolean isEscapedModel() {
688 return _role.isEscapedModel();
689 }
690
691 public java.io.Serializable getPrimaryKeyObj() {
692 return _role.getPrimaryKeyObj();
693 }
694
695 public void setPrimaryKeyObj(java.io.Serializable primaryKeyObj) {
696 _role.setPrimaryKeyObj(primaryKeyObj);
697 }
698
699 public com.liferay.portlet.expando.model.ExpandoBridge getExpandoBridge() {
700 return _role.getExpandoBridge();
701 }
702
703 public void setExpandoBridgeAttributes(
704 com.liferay.portal.model.BaseModel<?> baseModel) {
705 _role.setExpandoBridgeAttributes(baseModel);
706 }
707
708 public void setExpandoBridgeAttributes(
709 com.liferay.portlet.expando.model.ExpandoBridge expandoBridge) {
710 _role.setExpandoBridgeAttributes(expandoBridge);
711 }
712
713 public void setExpandoBridgeAttributes(
714 com.liferay.portal.service.ServiceContext serviceContext) {
715 _role.setExpandoBridgeAttributes(serviceContext);
716 }
717
718 public void prepareLocalizedFieldsForImport(
719 java.util.Locale defaultImportLocale)
720 throws com.liferay.portal.LocaleException {
721 _role.prepareLocalizedFieldsForImport(defaultImportLocale);
722 }
723
724 @Override
725 public java.lang.Object clone() {
726 return new RoleWrapper((Role)_role.clone());
727 }
728
729 public int compareTo(com.liferay.portal.model.Role role) {
730 return _role.compareTo(role);
731 }
732
733 @Override
734 public int hashCode() {
735 return _role.hashCode();
736 }
737
738 public com.liferay.portal.model.CacheModel<com.liferay.portal.model.Role> toCacheModel() {
739 return _role.toCacheModel();
740 }
741
742 public com.liferay.portal.model.Role toEscapedModel() {
743 return new RoleWrapper(_role.toEscapedModel());
744 }
745
746 public com.liferay.portal.model.Role toUnescapedModel() {
747 return new RoleWrapper(_role.toUnescapedModel());
748 }
749
750 @Override
751 public java.lang.String toString() {
752 return _role.toString();
753 }
754
755 public java.lang.String toXmlString() {
756 return _role.toXmlString();
757 }
758
759 public void persist()
760 throws com.liferay.portal.kernel.exception.SystemException {
761 _role.persist();
762 }
763
764 public java.lang.String getDescriptiveName()
765 throws com.liferay.portal.kernel.exception.PortalException,
766 com.liferay.portal.kernel.exception.SystemException {
767 return _role.getDescriptiveName();
768 }
769
770 public java.lang.String getTypeLabel() {
771 return _role.getTypeLabel();
772 }
773
774 public boolean isTeam() {
775 return _role.isTeam();
776 }
777
778
781 public Role getWrappedRole() {
782 return _role;
783 }
784
785 public Role getWrappedModel() {
786 return _role;
787 }
788
789 public void resetOriginalValues() {
790 _role.resetOriginalValues();
791 }
792
793 private Role _role;
794 }