Liferay 6.1.2-ce-ga3

com.liferay.portal.model
Class RoleWrapper

java.lang.Object
  extended by com.liferay.portal.model.RoleWrapper
All Implemented Interfaces:
AttachedModel, BaseModel<Role>, ClassedModel, ModelWrapper<Role>, PersistedModel, Role, RoleModel, Serializable, Cloneable, Comparable<Role>

public class RoleWrapper
extends Object
implements Role, ModelWrapper<Role>

This class is a wrapper for Role.

See Also:
Role, Serialized Form

Field Summary
 
Fields inherited from interface com.liferay.portal.model.Role
NAME_ACCESSOR, ROLE_ID_ACCESSOR
 
Constructor Summary
RoleWrapper(Role role)
           
 
Method Summary
 Object clone()
          Creates a shallow clone of this model instance.
 int compareTo(Role role)
           
 boolean equals(Object obj)
           
 String getClassName()
          Returns the fully qualified class name of this role.
 long getClassNameId()
          Returns the class name ID of this role.
 long getClassPK()
          Returns the class p k of this role.
 long getCompanyId()
          Returns the company ID of this role.
 String getDescription()
          Returns the description of this role.
 String getDescription(Locale locale)
          Returns the localized description of this role in the language.
 String getDescription(Locale locale, boolean useDefault)
          Returns the localized description of this role in the language, optionally using the default language if no localization exists for the requested language.
 String getDescription(String languageId)
          Returns the localized description of this role in the language.
 String getDescription(String languageId, boolean useDefault)
          Returns the localized description of this role in the language, optionally using the default language if no localization exists for the requested language.
 String getDescriptionCurrentLanguageId()
           
 String getDescriptionCurrentValue()
           
 Map<Locale,String> getDescriptionMap()
          Returns a map of the locales and localized descriptions of this role.
 String getDescriptiveName()
           
 ExpandoBridge getExpandoBridge()
          Returns the expando bridge for this model instance.
 Map<String,Object> getModelAttributes()
           
 Class<?> getModelClass()
           
 String getModelClassName()
           
 String getName()
          Returns the name of this role.
 long getPrimaryKey()
          Returns the primary key of this role.
 Serializable getPrimaryKeyObj()
          Returns the primary key of this model instance.
 long getRoleId()
          Returns the role ID of this role.
 String getSubtype()
          Returns the subtype of this role.
 String getTitle()
          Returns the title of this role.
 String getTitle(Locale locale)
          Returns the localized title of this role in the language.
 String getTitle(Locale locale, boolean useDefault)
          Returns the localized title of this role in the language, optionally using the default language if no localization exists for the requested language.
 String getTitle(String languageId)
          Returns the localized title of this role in the language.
 String getTitle(String languageId, boolean useDefault)
          Returns the localized title of this role in the language, optionally using the default language if no localization exists for the requested language.
 String getTitleCurrentLanguageId()
           
 String getTitleCurrentValue()
           
 Map<Locale,String> getTitleMap()
          Returns a map of the locales and localized titles of this role.
 int getType()
          Returns the type of this role.
 String getTypeLabel()
           
 Role getWrappedModel()
           
 Role getWrappedRole()
          Deprecated. Renamed to getWrappedModel()
 int hashCode()
           
 boolean isCachedModel()
          Returns true if this model instance was retrieved from the entity cache.
 boolean isEscapedModel()
          Returns true if this model instance is escaped.
 boolean isNew()
          Returns true if this model instance does not yet exist in the database.
 boolean isTeam()
           
 void persist()
          Updates this model instance in the database or adds it if it does not yet exist.
 void prepareLocalizedFieldsForImport(Locale defaultImportLocale)
           
 void resetOriginalValues()
          Reset all original fields to current values.
 void setCachedModel(boolean cachedModel)
          Sets whether this model instance was retrieved from the entity cache.
 void setClassName(String className)
           
 void setClassNameId(long classNameId)
          Sets the class name ID of this role.
 void setClassPK(long classPK)
          Sets the class p k of this role.
 void setCompanyId(long companyId)
          Sets the company ID of this role.
 void setDescription(String description)
          Sets the description of this role.
 void setDescription(String description, Locale locale)
          Sets the localized description of this role in the language.
 void setDescription(String description, Locale locale, Locale defaultLocale)
          Sets the localized description of this role in the language, and sets the default locale.
 void setDescriptionCurrentLanguageId(String languageId)
           
 void setDescriptionMap(Map<Locale,String> descriptionMap)
          Sets the localized descriptions of this role from the map of locales and localized descriptions.
 void setDescriptionMap(Map<Locale,String> descriptionMap, Locale defaultLocale)
          Sets the localized descriptions of this role from the map of locales and localized descriptions, and sets the default locale.
 void setExpandoBridgeAttributes(ServiceContext serviceContext)
          Sets the expando bridge attributes for this model instance to the attributes stored in the service context.
 void setModelAttributes(Map<String,Object> attributes)
           
 void setName(String name)
          Sets the name of this role.
 void setNew(boolean n)
          Sets whether this model instance does not yet exist in the database.
 void setPrimaryKey(long primaryKey)
          Sets the primary key of this role.
 void setPrimaryKeyObj(Serializable primaryKeyObj)
          Sets the primary key of this model instance.
 void setRoleId(long roleId)
          Sets the role ID of this role.
 void setSubtype(String subtype)
          Sets the subtype of this role.
 void setTitle(String title)
          Sets the title of this role.
 void setTitle(String title, Locale locale)
          Sets the localized title of this role in the language.
 void setTitle(String title, Locale locale, Locale defaultLocale)
          Sets the localized title of this role in the language, and sets the default locale.
 void setTitleCurrentLanguageId(String languageId)
           
 void setTitleMap(Map<Locale,String> titleMap)
          Sets the localized titles of this role from the map of locales and localized titles.
 void setTitleMap(Map<Locale,String> titleMap, Locale defaultLocale)
          Sets the localized titles of this role from the map of locales and localized titles, and sets the default locale.
 void setType(int type)
          Sets the type of this role.
 CacheModel<Role> toCacheModel()
          Returns a cache model object for this entity used by entity cache.
 Role toEscapedModel()
          Returns a copy of this entity as an escaped model instance by wrapping it with an AutoEscapeBeanHandler.
 String toString()
           
 Role toUnescapedModel()
           
 String toXmlString()
          Returns the XML representation of this model instance.
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

RoleWrapper

public RoleWrapper(Role role)
Method Detail

getModelClass

public Class<?> getModelClass()
Specified by:
getModelClass in interface ClassedModel

getModelClassName

public String getModelClassName()
Specified by:
getModelClassName in interface ClassedModel

getModelAttributes

public Map<String,Object> getModelAttributes()
Specified by:
getModelAttributes in interface BaseModel<Role>

setModelAttributes

public void setModelAttributes(Map<String,Object> attributes)
Specified by:
setModelAttributes in interface BaseModel<Role>

getPrimaryKey

public long getPrimaryKey()
Returns the primary key of this role.

Specified by:
getPrimaryKey in interface RoleModel
Returns:
the primary key of this role

setPrimaryKey

public void setPrimaryKey(long primaryKey)
Sets the primary key of this role.

Specified by:
setPrimaryKey in interface RoleModel
Parameters:
primaryKey - the primary key of this role

getRoleId

public long getRoleId()
Returns the role ID of this role.

Specified by:
getRoleId in interface RoleModel
Returns:
the role ID of this role

setRoleId

public void setRoleId(long roleId)
Sets the role ID of this role.

Specified by:
setRoleId in interface RoleModel
Parameters:
roleId - the role ID of this role

getCompanyId

public long getCompanyId()
Returns the company ID of this role.

Specified by:
getCompanyId in interface RoleModel
Returns:
the company ID of this role

setCompanyId

public void setCompanyId(long companyId)
Sets the company ID of this role.

Specified by:
setCompanyId in interface RoleModel
Parameters:
companyId - the company ID of this role

getClassName

public String getClassName()
Returns the fully qualified class name of this role.

Specified by:
getClassName in interface AttachedModel
Specified by:
getClassName in interface RoleModel
Returns:
the fully qualified class name of this role

setClassName

public void setClassName(String className)
Specified by:
setClassName in interface RoleModel

getClassNameId

public long getClassNameId()
Returns the class name ID of this role.

Specified by:
getClassNameId in interface AttachedModel
Specified by:
getClassNameId in interface RoleModel
Returns:
the class name ID of this role

setClassNameId

public void setClassNameId(long classNameId)
Sets the class name ID of this role.

Specified by:
setClassNameId in interface AttachedModel
Specified by:
setClassNameId in interface RoleModel
Parameters:
classNameId - the class name ID of this role

getClassPK

public long getClassPK()
Returns the class p k of this role.

Specified by:
getClassPK in interface AttachedModel
Specified by:
getClassPK in interface RoleModel
Returns:
the class p k of this role

setClassPK

public void setClassPK(long classPK)
Sets the class p k of this role.

Specified by:
setClassPK in interface AttachedModel
Specified by:
setClassPK in interface RoleModel
Parameters:
classPK - the class p k of this role

getName

public String getName()
Returns the name of this role.

Specified by:
getName in interface RoleModel
Returns:
the name of this role

setName

public void setName(String name)
Sets the name of this role.

Specified by:
setName in interface RoleModel
Parameters:
name - the name of this role

getTitle

public String getTitle()
Returns the title of this role.

Specified by:
getTitle in interface RoleModel
Returns:
the title of this role

getTitle

public String getTitle(Locale locale)
Returns the localized title of this role in the language. Uses the default language if no localization exists for the requested language.

Specified by:
getTitle in interface RoleModel
Parameters:
locale - the locale of the language
Returns:
the localized title of this role

getTitle

public String getTitle(Locale locale,
                       boolean useDefault)
Returns the localized title of this role in the language, optionally using the default language if no localization exists for the requested language.

Specified by:
getTitle in interface RoleModel
Parameters:
locale - the local of the language
useDefault - whether to use the default language if no localization exists for the requested language
Returns:
the localized title of this role. If useDefault is false and no localization exists for the requested language, an empty string will be returned.

getTitle

public String getTitle(String languageId)
Returns the localized title of this role in the language. Uses the default language if no localization exists for the requested language.

Specified by:
getTitle in interface Role
Specified by:
getTitle in interface RoleModel
Parameters:
languageId - the ID of the language
Returns:
the localized title of this role

getTitle

public String getTitle(String languageId,
                       boolean useDefault)
Returns the localized title of this role in the language, optionally using the default language if no localization exists for the requested language.

Specified by:
getTitle in interface Role
Specified by:
getTitle in interface RoleModel
Parameters:
languageId - the ID of the language
useDefault - whether to use the default language if no localization exists for the requested language
Returns:
the localized title of this role

getTitleCurrentLanguageId

public String getTitleCurrentLanguageId()
Specified by:
getTitleCurrentLanguageId in interface RoleModel

getTitleCurrentValue

public String getTitleCurrentValue()
Specified by:
getTitleCurrentValue in interface RoleModel

getTitleMap

public Map<Locale,String> getTitleMap()
Returns a map of the locales and localized titles of this role.

Specified by:
getTitleMap in interface RoleModel
Returns:
the locales and localized titles of this role

setTitle

public void setTitle(String title)
Sets the title of this role.

Specified by:
setTitle in interface RoleModel
Parameters:
title - the title of this role

setTitle

public void setTitle(String title,
                     Locale locale)
Sets the localized title of this role in the language.

Specified by:
setTitle in interface RoleModel
Parameters:
title - the localized title of this role
locale - the locale of the language

setTitle

public void setTitle(String title,
                     Locale locale,
                     Locale defaultLocale)
Sets the localized title of this role in the language, and sets the default locale.

Specified by:
setTitle in interface RoleModel
Parameters:
title - the localized title of this role
locale - the locale of the language
defaultLocale - the default locale

setTitleCurrentLanguageId

public void setTitleCurrentLanguageId(String languageId)
Specified by:
setTitleCurrentLanguageId in interface RoleModel

setTitleMap

public void setTitleMap(Map<Locale,String> titleMap)
Sets the localized titles of this role from the map of locales and localized titles.

Specified by:
setTitleMap in interface RoleModel
Parameters:
titleMap - the locales and localized titles of this role

setTitleMap

public void setTitleMap(Map<Locale,String> titleMap,
                        Locale defaultLocale)
Sets the localized titles of this role from the map of locales and localized titles, and sets the default locale.

Specified by:
setTitleMap in interface RoleModel
Parameters:
titleMap - the locales and localized titles of this role
defaultLocale - the default locale

getDescription

public String getDescription()
Returns the description of this role.

Specified by:
getDescription in interface RoleModel
Returns:
the description of this role

getDescription

public String getDescription(Locale locale)
Returns the localized description of this role in the language. Uses the default language if no localization exists for the requested language.

Specified by:
getDescription in interface RoleModel
Parameters:
locale - the locale of the language
Returns:
the localized description of this role

getDescription

public String getDescription(Locale locale,
                             boolean useDefault)
Returns the localized description of this role in the language, optionally using the default language if no localization exists for the requested language.

Specified by:
getDescription in interface RoleModel
Parameters:
locale - the local of the language
useDefault - whether to use the default language if no localization exists for the requested language
Returns:
the localized description of this role. If useDefault is false and no localization exists for the requested language, an empty string will be returned.

getDescription

public String getDescription(String languageId)
Returns the localized description of this role in the language. Uses the default language if no localization exists for the requested language.

Specified by:
getDescription in interface RoleModel
Parameters:
languageId - the ID of the language
Returns:
the localized description of this role

getDescription

public String getDescription(String languageId,
                             boolean useDefault)
Returns the localized description of this role in the language, optionally using the default language if no localization exists for the requested language.

Specified by:
getDescription in interface RoleModel
Parameters:
languageId - the ID of the language
useDefault - whether to use the default language if no localization exists for the requested language
Returns:
the localized description of this role

getDescriptionCurrentLanguageId

public String getDescriptionCurrentLanguageId()
Specified by:
getDescriptionCurrentLanguageId in interface RoleModel

getDescriptionCurrentValue

public String getDescriptionCurrentValue()
Specified by:
getDescriptionCurrentValue in interface RoleModel

getDescriptionMap

public Map<Locale,String> getDescriptionMap()
Returns a map of the locales and localized descriptions of this role.

Specified by:
getDescriptionMap in interface RoleModel
Returns:
the locales and localized descriptions of this role

setDescription

public void setDescription(String description)
Sets the description of this role.

Specified by:
setDescription in interface RoleModel
Parameters:
description - the description of this role

setDescription

public void setDescription(String description,
                           Locale locale)
Sets the localized description of this role in the language.

Specified by:
setDescription in interface RoleModel
Parameters:
description - the localized description of this role
locale - the locale of the language

setDescription

public void setDescription(String description,
                           Locale locale,
                           Locale defaultLocale)
Sets the localized description of this role in the language, and sets the default locale.

Specified by:
setDescription in interface RoleModel
Parameters:
description - the localized description of this role
locale - the locale of the language
defaultLocale - the default locale

setDescriptionCurrentLanguageId

public void setDescriptionCurrentLanguageId(String languageId)
Specified by:
setDescriptionCurrentLanguageId in interface RoleModel

setDescriptionMap

public void setDescriptionMap(Map<Locale,String> descriptionMap)
Sets the localized descriptions of this role from the map of locales and localized descriptions.

Specified by:
setDescriptionMap in interface RoleModel
Parameters:
descriptionMap - the locales and localized descriptions of this role

setDescriptionMap

public void setDescriptionMap(Map<Locale,String> descriptionMap,
                              Locale defaultLocale)
Sets the localized descriptions of this role from the map of locales and localized descriptions, and sets the default locale.

Specified by:
setDescriptionMap in interface RoleModel
Parameters:
descriptionMap - the locales and localized descriptions of this role
defaultLocale - the default locale

getType

public int getType()
Returns the type of this role.

Specified by:
getType in interface RoleModel
Returns:
the type of this role

setType

public void setType(int type)
Sets the type of this role.

Specified by:
setType in interface RoleModel
Parameters:
type - the type of this role

getSubtype

public String getSubtype()
Returns the subtype of this role.

Specified by:
getSubtype in interface RoleModel
Returns:
the subtype of this role

setSubtype

public void setSubtype(String subtype)
Sets the subtype of this role.

Specified by:
setSubtype in interface RoleModel
Parameters:
subtype - the subtype of this role

isNew

public boolean isNew()
Description copied from interface: BaseModel
Returns true if this model instance does not yet exist in the database.

Specified by:
isNew in interface BaseModel<Role>
Specified by:
isNew in interface RoleModel
Returns:
true if this model instance does not yet exist in the database; false otherwise

setNew

public void setNew(boolean n)
Description copied from interface: BaseModel
Sets whether this model instance does not yet exist in the database.

Specified by:
setNew in interface BaseModel<Role>
Specified by:
setNew in interface RoleModel
Parameters:
n - whether this model instance does not yet exist in the database

isCachedModel

public boolean isCachedModel()
Description copied from interface: BaseModel
Returns true if this model instance was retrieved from the entity cache.

Specified by:
isCachedModel in interface BaseModel<Role>
Specified by:
isCachedModel in interface RoleModel
Returns:
true if this model instance was retrieved from the entity cache; false otherwise
See Also:
BaseModel.setCachedModel(boolean)

setCachedModel

public void setCachedModel(boolean cachedModel)
Description copied from interface: BaseModel
Sets whether this model instance was retrieved from the entity cache.

Specified by:
setCachedModel in interface BaseModel<Role>
Specified by:
setCachedModel in interface RoleModel
Parameters:
cachedModel - whether this model instance was retrieved from the entity cache
See Also:
EntityCache

isEscapedModel

public boolean isEscapedModel()
Description copied from interface: BaseModel
Returns true if this model instance is escaped.

Specified by:
isEscapedModel in interface BaseModel<Role>
Specified by:
isEscapedModel in interface RoleModel
Returns:
true if this model instance is escaped; false otherwise

getPrimaryKeyObj

public Serializable getPrimaryKeyObj()
Description copied from interface: BaseModel
Returns the primary key of this model instance.

Specified by:
getPrimaryKeyObj in interface BaseModel<Role>
Specified by:
getPrimaryKeyObj in interface ClassedModel
Specified by:
getPrimaryKeyObj in interface RoleModel
Returns:
the primary key of this model instance

setPrimaryKeyObj

public void setPrimaryKeyObj(Serializable primaryKeyObj)
Description copied from interface: BaseModel
Sets the primary key of this model instance.

Specified by:
setPrimaryKeyObj in interface BaseModel<Role>
Specified by:
setPrimaryKeyObj in interface ClassedModel
Specified by:
setPrimaryKeyObj in interface RoleModel
Parameters:
primaryKeyObj - the primary key of this model instance

getExpandoBridge

public ExpandoBridge getExpandoBridge()
Description copied from interface: BaseModel
Returns the expando bridge for this model instance.

Specified by:
getExpandoBridge in interface BaseModel<Role>
Specified by:
getExpandoBridge in interface ClassedModel
Specified by:
getExpandoBridge in interface RoleModel
Returns:
the expando bridge for this model instance

setExpandoBridgeAttributes

public void setExpandoBridgeAttributes(ServiceContext serviceContext)
Description copied from interface: BaseModel
Sets the expando bridge attributes for this model instance to the attributes stored in the service context.

Specified by:
setExpandoBridgeAttributes in interface BaseModel<Role>
Specified by:
setExpandoBridgeAttributes in interface RoleModel
Parameters:
serviceContext - the service context
See Also:
ServiceContext.getExpandoBridgeAttributes( )

prepareLocalizedFieldsForImport

public void prepareLocalizedFieldsForImport(Locale defaultImportLocale)
                                     throws LocaleException
Specified by:
prepareLocalizedFieldsForImport in interface RoleModel
Throws:
LocaleException

clone

public Object clone()
Description copied from interface: BaseModel
Creates a shallow clone of this model instance.

Specified by:
clone in interface BaseModel<Role>
Specified by:
clone in interface RoleModel
Overrides:
clone in class Object
Returns:
the shallow clone of this model instance

compareTo

public int compareTo(Role role)
Specified by:
compareTo in interface RoleModel
Specified by:
compareTo in interface Comparable<Role>

hashCode

public int hashCode()
Specified by:
hashCode in interface RoleModel
Overrides:
hashCode in class Object

toCacheModel

public CacheModel<Role> toCacheModel()
Description copied from interface: BaseModel
Returns a cache model object for this entity used by entity cache.

Specified by:
toCacheModel in interface BaseModel<Role>
Specified by:
toCacheModel in interface RoleModel
Returns:
the cache model object

toEscapedModel

public Role toEscapedModel()
Description copied from interface: BaseModel
Returns a copy of this entity as an escaped model instance by wrapping it with an AutoEscapeBeanHandler.

Specified by:
toEscapedModel in interface BaseModel<Role>
Specified by:
toEscapedModel in interface RoleModel
Returns:
the escaped model instance
See Also:
AutoEscapeBeanHandler

toUnescapedModel

public Role toUnescapedModel()
Specified by:
toUnescapedModel in interface BaseModel<Role>
Specified by:
toUnescapedModel in interface RoleModel

toString

public String toString()
Specified by:
toString in interface RoleModel
Overrides:
toString in class Object

toXmlString

public String toXmlString()
Description copied from interface: BaseModel
Returns the XML representation of this model instance.

Specified by:
toXmlString in interface BaseModel<Role>
Specified by:
toXmlString in interface RoleModel
Returns:
the XML representation of this model instance

persist

public void persist()
             throws SystemException
Description copied from interface: PersistedModel
Updates this model instance in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.

Specified by:
persist in interface PersistedModel
Throws:
SystemException - if a system exception occurred

getDescriptiveName

public String getDescriptiveName()
                          throws PortalException,
                                 SystemException
Specified by:
getDescriptiveName in interface Role
Throws:
PortalException
SystemException

getTypeLabel

public String getTypeLabel()
Specified by:
getTypeLabel in interface Role

isTeam

public boolean isTeam()
Specified by:
isTeam in interface Role

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

getWrappedRole

public Role getWrappedRole()
Deprecated. Renamed to getWrappedModel()


getWrappedModel

public Role getWrappedModel()
Specified by:
getWrappedModel in interface ModelWrapper<Role>

resetOriginalValues

public void resetOriginalValues()
Description copied from interface: BaseModel
Reset all original fields to current values.

Specified by:
resetOriginalValues in interface BaseModel<Role>

Liferay 6.1.2-ce-ga3