001    /**
002     * Copyright (c) 2000-2012 Liferay, Inc. All rights reserved.
003     *
004     * This library is free software; you can redistribute it and/or modify it under
005     * the terms of the GNU Lesser General Public License as published by the Free
006     * Software Foundation; either version 2.1 of the License, or (at your option)
007     * any later version.
008     *
009     * This library is distributed in the hope that it will be useful, but WITHOUT
010     * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
011     * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
012     * details.
013     */
014    
015    package com.liferay.portal.model;
016    
017    /**
018     * <p>
019     * This class is a wrapper for {@link Role}.
020     * </p>
021     *
022     * @author    Brian Wing Shun Chan
023     * @see       Role
024     * @generated
025     */
026    public class RoleWrapper implements Role, ModelWrapper<Role> {
027            public RoleWrapper(Role role) {
028                    _role = role;
029            }
030    
031            public Class<?> getModelClass() {
032                    return Role.class;
033            }
034    
035            public String getModelClassName() {
036                    return Role.class.getName();
037            }
038    
039            /**
040            * Returns the primary key of this role.
041            *
042            * @return the primary key of this role
043            */
044            public long getPrimaryKey() {
045                    return _role.getPrimaryKey();
046            }
047    
048            /**
049            * Sets the primary key of this role.
050            *
051            * @param primaryKey the primary key of this role
052            */
053            public void setPrimaryKey(long primaryKey) {
054                    _role.setPrimaryKey(primaryKey);
055            }
056    
057            /**
058            * Returns the role ID of this role.
059            *
060            * @return the role ID of this role
061            */
062            public long getRoleId() {
063                    return _role.getRoleId();
064            }
065    
066            /**
067            * Sets the role ID of this role.
068            *
069            * @param roleId the role ID of this role
070            */
071            public void setRoleId(long roleId) {
072                    _role.setRoleId(roleId);
073            }
074    
075            /**
076            * Returns the company ID of this role.
077            *
078            * @return the company ID of this role
079            */
080            public long getCompanyId() {
081                    return _role.getCompanyId();
082            }
083    
084            /**
085            * Sets the company ID of this role.
086            *
087            * @param companyId the company ID of this role
088            */
089            public void setCompanyId(long companyId) {
090                    _role.setCompanyId(companyId);
091            }
092    
093            /**
094            * Returns the fully qualified class name of this role.
095            *
096            * @return the fully qualified class name of this role
097            */
098            public java.lang.String getClassName() {
099                    return _role.getClassName();
100            }
101    
102            /**
103            * Returns the class name ID of this role.
104            *
105            * @return the class name ID of this role
106            */
107            public long getClassNameId() {
108                    return _role.getClassNameId();
109            }
110    
111            /**
112            * Sets the class name ID of this role.
113            *
114            * @param classNameId the class name ID of this role
115            */
116            public void setClassNameId(long classNameId) {
117                    _role.setClassNameId(classNameId);
118            }
119    
120            /**
121            * Returns the class p k of this role.
122            *
123            * @return the class p k of this role
124            */
125            public long getClassPK() {
126                    return _role.getClassPK();
127            }
128    
129            /**
130            * Sets the class p k of this role.
131            *
132            * @param classPK the class p k of this role
133            */
134            public void setClassPK(long classPK) {
135                    _role.setClassPK(classPK);
136            }
137    
138            /**
139            * Returns the name of this role.
140            *
141            * @return the name of this role
142            */
143            public java.lang.String getName() {
144                    return _role.getName();
145            }
146    
147            /**
148            * Sets the name of this role.
149            *
150            * @param name the name of this role
151            */
152            public void setName(java.lang.String name) {
153                    _role.setName(name);
154            }
155    
156            /**
157            * Returns the title of this role.
158            *
159            * @return the title of this role
160            */
161            public java.lang.String getTitle() {
162                    return _role.getTitle();
163            }
164    
165            /**
166            * Returns the localized title of this role in the language. Uses the default language if no localization exists for the requested language.
167            *
168            * @param locale the locale of the language
169            * @return the localized title of this role
170            */
171            public java.lang.String getTitle(java.util.Locale locale) {
172                    return _role.getTitle(locale);
173            }
174    
175            /**
176            * Returns the localized title of this role in the language, optionally using the default language if no localization exists for the requested language.
177            *
178            * @param locale the local of the language
179            * @param useDefault whether to use the default language if no localization exists for the requested language
180            * @return the localized title of this role. If <code>useDefault</code> is <code>false</code> and no localization exists for the requested language, an empty string will be returned.
181            */
182            public java.lang.String getTitle(java.util.Locale locale, boolean useDefault) {
183                    return _role.getTitle(locale, useDefault);
184            }
185    
186            /**
187            * Returns the localized title of this role in the language. Uses the default language if no localization exists for the requested language.
188            *
189            * @param languageId the ID of the language
190            * @return the localized title of this role
191            */
192            public java.lang.String getTitle(java.lang.String languageId) {
193                    return _role.getTitle(languageId);
194            }
195    
196            /**
197            * Returns the localized title of this role in the language, optionally using the default language if no localization exists for the requested language.
198            *
199            * @param languageId the ID of the language
200            * @param useDefault whether to use the default language if no localization exists for the requested language
201            * @return the localized title of this role
202            */
203            public java.lang.String getTitle(java.lang.String languageId,
204                    boolean useDefault) {
205                    return _role.getTitle(languageId, useDefault);
206            }
207    
208            public java.lang.String getTitleCurrentLanguageId() {
209                    return _role.getTitleCurrentLanguageId();
210            }
211    
212            public java.lang.String getTitleCurrentValue() {
213                    return _role.getTitleCurrentValue();
214            }
215    
216            /**
217            * Returns a map of the locales and localized titles of this role.
218            *
219            * @return the locales and localized titles of this role
220            */
221            public java.util.Map<java.util.Locale, java.lang.String> getTitleMap() {
222                    return _role.getTitleMap();
223            }
224    
225            /**
226            * Sets the title of this role.
227            *
228            * @param title the title of this role
229            */
230            public void setTitle(java.lang.String title) {
231                    _role.setTitle(title);
232            }
233    
234            /**
235            * Sets the localized title of this role in the language.
236            *
237            * @param title the localized title of this role
238            * @param locale the locale of the language
239            */
240            public void setTitle(java.lang.String title, java.util.Locale locale) {
241                    _role.setTitle(title, locale);
242            }
243    
244            /**
245            * Sets the localized title of this role in the language, and sets the default locale.
246            *
247            * @param title the localized title of this role
248            * @param locale the locale of the language
249            * @param defaultLocale the default locale
250            */
251            public void setTitle(java.lang.String title, java.util.Locale locale,
252                    java.util.Locale defaultLocale) {
253                    _role.setTitle(title, locale, defaultLocale);
254            }
255    
256            public void setTitleCurrentLanguageId(java.lang.String languageId) {
257                    _role.setTitleCurrentLanguageId(languageId);
258            }
259    
260            /**
261            * Sets the localized titles of this role from the map of locales and localized titles.
262            *
263            * @param titleMap the locales and localized titles of this role
264            */
265            public void setTitleMap(
266                    java.util.Map<java.util.Locale, java.lang.String> titleMap) {
267                    _role.setTitleMap(titleMap);
268            }
269    
270            /**
271            * Sets the localized titles of this role from the map of locales and localized titles, and sets the default locale.
272            *
273            * @param titleMap the locales and localized titles of this role
274            * @param defaultLocale the default locale
275            */
276            public void setTitleMap(
277                    java.util.Map<java.util.Locale, java.lang.String> titleMap,
278                    java.util.Locale defaultLocale) {
279                    _role.setTitleMap(titleMap, defaultLocale);
280            }
281    
282            /**
283            * Returns the description of this role.
284            *
285            * @return the description of this role
286            */
287            public java.lang.String getDescription() {
288                    return _role.getDescription();
289            }
290    
291            /**
292            * Returns the localized description of this role in the language. Uses the default language if no localization exists for the requested language.
293            *
294            * @param locale the locale of the language
295            * @return the localized description of this role
296            */
297            public java.lang.String getDescription(java.util.Locale locale) {
298                    return _role.getDescription(locale);
299            }
300    
301            /**
302            * Returns the localized description of this role in the language, optionally using the default language if no localization exists for the requested language.
303            *
304            * @param locale the local of the language
305            * @param useDefault whether to use the default language if no localization exists for the requested language
306            * @return the localized description of this role. If <code>useDefault</code> is <code>false</code> and no localization exists for the requested language, an empty string will be returned.
307            */
308            public java.lang.String getDescription(java.util.Locale locale,
309                    boolean useDefault) {
310                    return _role.getDescription(locale, useDefault);
311            }
312    
313            /**
314            * Returns the localized description of this role in the language. Uses the default language if no localization exists for the requested language.
315            *
316            * @param languageId the ID of the language
317            * @return the localized description of this role
318            */
319            public java.lang.String getDescription(java.lang.String languageId) {
320                    return _role.getDescription(languageId);
321            }
322    
323            /**
324            * Returns the localized description of this role in the language, optionally using the default language if no localization exists for the requested language.
325            *
326            * @param languageId the ID of the language
327            * @param useDefault whether to use the default language if no localization exists for the requested language
328            * @return the localized description of this role
329            */
330            public java.lang.String getDescription(java.lang.String languageId,
331                    boolean useDefault) {
332                    return _role.getDescription(languageId, useDefault);
333            }
334    
335            public java.lang.String getDescriptionCurrentLanguageId() {
336                    return _role.getDescriptionCurrentLanguageId();
337            }
338    
339            public java.lang.String getDescriptionCurrentValue() {
340                    return _role.getDescriptionCurrentValue();
341            }
342    
343            /**
344            * Returns a map of the locales and localized descriptions of this role.
345            *
346            * @return the locales and localized descriptions of this role
347            */
348            public java.util.Map<java.util.Locale, java.lang.String> getDescriptionMap() {
349                    return _role.getDescriptionMap();
350            }
351    
352            /**
353            * Sets the description of this role.
354            *
355            * @param description the description of this role
356            */
357            public void setDescription(java.lang.String description) {
358                    _role.setDescription(description);
359            }
360    
361            /**
362            * Sets the localized description of this role in the language.
363            *
364            * @param description the localized description of this role
365            * @param locale the locale of the language
366            */
367            public void setDescription(java.lang.String description,
368                    java.util.Locale locale) {
369                    _role.setDescription(description, locale);
370            }
371    
372            /**
373            * Sets the localized description of this role in the language, and sets the default locale.
374            *
375            * @param description the localized description of this role
376            * @param locale the locale of the language
377            * @param defaultLocale the default locale
378            */
379            public void setDescription(java.lang.String description,
380                    java.util.Locale locale, java.util.Locale defaultLocale) {
381                    _role.setDescription(description, locale, defaultLocale);
382            }
383    
384            public void setDescriptionCurrentLanguageId(java.lang.String languageId) {
385                    _role.setDescriptionCurrentLanguageId(languageId);
386            }
387    
388            /**
389            * Sets the localized descriptions of this role from the map of locales and localized descriptions.
390            *
391            * @param descriptionMap the locales and localized descriptions of this role
392            */
393            public void setDescriptionMap(
394                    java.util.Map<java.util.Locale, java.lang.String> descriptionMap) {
395                    _role.setDescriptionMap(descriptionMap);
396            }
397    
398            /**
399            * Sets the localized descriptions of this role from the map of locales and localized descriptions, and sets the default locale.
400            *
401            * @param descriptionMap the locales and localized descriptions of this role
402            * @param defaultLocale the default locale
403            */
404            public void setDescriptionMap(
405                    java.util.Map<java.util.Locale, java.lang.String> descriptionMap,
406                    java.util.Locale defaultLocale) {
407                    _role.setDescriptionMap(descriptionMap, defaultLocale);
408            }
409    
410            /**
411            * Returns the type of this role.
412            *
413            * @return the type of this role
414            */
415            public int getType() {
416                    return _role.getType();
417            }
418    
419            /**
420            * Sets the type of this role.
421            *
422            * @param type the type of this role
423            */
424            public void setType(int type) {
425                    _role.setType(type);
426            }
427    
428            /**
429            * Returns the subtype of this role.
430            *
431            * @return the subtype of this role
432            */
433            public java.lang.String getSubtype() {
434                    return _role.getSubtype();
435            }
436    
437            /**
438            * Sets the subtype of this role.
439            *
440            * @param subtype the subtype of this role
441            */
442            public void setSubtype(java.lang.String subtype) {
443                    _role.setSubtype(subtype);
444            }
445    
446            public boolean isNew() {
447                    return _role.isNew();
448            }
449    
450            public void setNew(boolean n) {
451                    _role.setNew(n);
452            }
453    
454            public boolean isCachedModel() {
455                    return _role.isCachedModel();
456            }
457    
458            public void setCachedModel(boolean cachedModel) {
459                    _role.setCachedModel(cachedModel);
460            }
461    
462            public boolean isEscapedModel() {
463                    return _role.isEscapedModel();
464            }
465    
466            public java.io.Serializable getPrimaryKeyObj() {
467                    return _role.getPrimaryKeyObj();
468            }
469    
470            public void setPrimaryKeyObj(java.io.Serializable primaryKeyObj) {
471                    _role.setPrimaryKeyObj(primaryKeyObj);
472            }
473    
474            public com.liferay.portlet.expando.model.ExpandoBridge getExpandoBridge() {
475                    return _role.getExpandoBridge();
476            }
477    
478            public void setExpandoBridgeAttributes(
479                    com.liferay.portal.service.ServiceContext serviceContext) {
480                    _role.setExpandoBridgeAttributes(serviceContext);
481            }
482    
483            @Override
484            public java.lang.Object clone() {
485                    return new RoleWrapper((Role)_role.clone());
486            }
487    
488            public int compareTo(com.liferay.portal.model.Role role) {
489                    return _role.compareTo(role);
490            }
491    
492            @Override
493            public int hashCode() {
494                    return _role.hashCode();
495            }
496    
497            public com.liferay.portal.model.CacheModel<com.liferay.portal.model.Role> toCacheModel() {
498                    return _role.toCacheModel();
499            }
500    
501            public com.liferay.portal.model.Role toEscapedModel() {
502                    return new RoleWrapper(_role.toEscapedModel());
503            }
504    
505            @Override
506            public java.lang.String toString() {
507                    return _role.toString();
508            }
509    
510            public java.lang.String toXmlString() {
511                    return _role.toXmlString();
512            }
513    
514            public void persist()
515                    throws com.liferay.portal.kernel.exception.SystemException {
516                    _role.persist();
517            }
518    
519            public java.lang.String getDescriptiveName()
520                    throws com.liferay.portal.kernel.exception.PortalException,
521                            com.liferay.portal.kernel.exception.SystemException {
522                    return _role.getDescriptiveName();
523            }
524    
525            public java.lang.String getTypeLabel() {
526                    return _role.getTypeLabel();
527            }
528    
529            public boolean isTeam() {
530                    return _role.isTeam();
531            }
532    
533            /**
534             * @deprecated Renamed to {@link #getWrappedModel}
535             */
536            public Role getWrappedRole() {
537                    return _role;
538            }
539    
540            public Role getWrappedModel() {
541                    return _role;
542            }
543    
544            public void resetOriginalValues() {
545                    _role.resetOriginalValues();
546            }
547    
548            private Role _role;
549    }