Package org.silverpeas.core.admin.space
Class SpaceInstLight
- java.lang.Object
-
- org.silverpeas.core.i18n.AbstractI18NBean<SpaceI18N>
-
- org.silverpeas.core.admin.space.SpaceInstLight
-
- All Implemented Interfaces:
Serializable
,Comparable<SpaceInstLight>
,I18NBean<SpaceI18N>
,LocalizedResource
,Translatable
,Identifiable
,Nameable
,Securable
,SilverpeasResource
public class SpaceInstLight extends AbstractI18NBean<SpaceI18N> implements Serializable, LocalizedResource, Identifiable, Securable, Comparable<SpaceInstLight>
- Author:
- neysseri
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description SpaceInstLight()
SpaceInstLight(SpaceRow spaceRow)
SpaceInstLight(SpaceInst spaceInst)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
canBeAccessedBy(User user)
Checks the given user can access this resource.boolean
canBeFiledInBy(User user)
Can the user add spaces or component instances into this space?boolean
canBeModifiedBy(User user)
Is the user can modify this collaboration space?int
compareTo(SpaceInstLight o)
boolean
equals(Object obj)
int
getCreatedBy()
Date
getCreationDate()
Gets the date at which the resource has been created.User
getCreator()
Gets the user that has created the resource.String
getCreatorName()
String
getFatherId()
String
getId()
Gets the unique identifier of the object in Silverpeas.BasicIdentifier
getIdentifier()
Gets the unique identifier of this resource.Date
getLastUpdateDate()
Gets the date at which the resource has been lastly updated.User
getLastUpdater()
Gets the user that has lastly updated the resource.int
getLevel()
int
getLocalId()
String
getLook()
String
getName(String language)
Gets the name of the bean in the given language.int
getOrderNum()
String
getPath(String separator)
Date
getRemovalDate()
int
getRemovedBy()
String
getRemoverName()
String
getStatus()
protected Class<SpaceI18N>
getTranslationType()
int
getUpdatedBy()
String
getUpdaterName()
int
hashCode()
boolean
isDisplaySpaceFirst()
boolean
isInheritanceBlocked()
boolean
isPersonalSpace()
boolean
isRemoved()
boolean
isRoot()
static boolean
isRoot(String spaceId)
void
setCreatorName(String creatorName)
void
setDisplaySpaceFirst(boolean displaySpaceFirst)
void
setFatherId(int fatherId)
void
setFatherId(String fatherId)
void
setInheritanceBlocked(boolean isInheritanceBlocked)
void
setLevel(int i)
void
setLocalId(int id)
void
setLook(String look)
void
setOrderNum(int orderNum)
void
setPersonalSpace(boolean isPersonalSpace)
void
setRemoverName(String removerName)
void
setStatus(String status)
void
setUpdaterName(String updaterName)
-
Methods inherited from class org.silverpeas.core.i18n.AbstractI18NBean
addTranslation, getClonedTranslations, getDescription, getDescription, getLanguage, getLanguages, getLanguageToDisplay, getName, getNextTranslation, getTranslation, getTranslationId, getTranslations, isRemoveTranslation, setDescription, setLanguage, setName, setRemoveTranslation, setTranslationId, setTranslations, setTranslations
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.silverpeas.core.i18n.LocalizedResource
getTranslation
-
Methods inherited from interface org.silverpeas.core.Nameable
getDescription, getName
-
Methods inherited from interface org.silverpeas.core.security.Securable
canBeDeletedBy
-
-
-
-
Method Detail
-
getTranslationType
protected Class<SpaceI18N> getTranslationType()
- Specified by:
getTranslationType
in classAbstractI18NBean<SpaceI18N>
-
getId
public String getId()
Description copied from interface:Identifiable
Gets the unique identifier of the object in Silverpeas. If he's also identified by a local identifier, then this method should return the one global to Silverpeas.- Specified by:
getId
in interfaceIdentifiable
- Returns:
- the identifier encoded as a String. If the identifier is a complex one, that is made up of several identification parts, then the returned representation should take care of such a structure.
-
getIdentifier
public BasicIdentifier getIdentifier()
Description copied from interface:SilverpeasResource
Gets the unique identifier of this resource.- Specified by:
getIdentifier
in interfaceSilverpeasResource
- Returns:
- the
ResourceIdentifier
object representing the unique identifier of the resource.
-
getFatherId
public String getFatherId()
-
getLevel
public int getLevel()
-
getName
public String getName(String language)
Description copied from class:AbstractI18NBean
Gets the name of the bean in the given language. This method is a shortcut of the following code:myBean.getTranslation(language).getName();
- Overrides:
getName
in classAbstractI18NBean<SpaceI18N>
- Parameters:
language
- the ISO 631-1 code of the language- Returns:
- the name of the bean in the specified language.
-
setFatherId
public void setFatherId(int fatherId)
-
setFatherId
public void setFatherId(String fatherId)
-
setLocalId
public void setLocalId(int id)
-
getLocalId
public int getLocalId()
-
setLevel
public void setLevel(int i)
-
isRoot
public boolean isRoot()
-
isRoot
public static boolean isRoot(String spaceId)
-
getOrderNum
public int getOrderNum()
-
setOrderNum
public void setOrderNum(int orderNum)
-
getCreationDate
public Date getCreationDate()
Description copied from interface:SilverpeasResource
Gets the date at which the resource has been created.- Specified by:
getCreationDate
in interfaceSilverpeasResource
- Returns:
- the date of creation of the resource.
-
getRemovalDate
public Date getRemovalDate()
-
getStatus
public String getStatus()
-
setStatus
public void setStatus(String status)
-
getLastUpdateDate
public Date getLastUpdateDate()
Description copied from interface:SilverpeasResource
Gets the date at which the resource has been lastly updated. If the resource doesn't have such an information, then this method should return the date of the resource creation.- Specified by:
getLastUpdateDate
in interfaceSilverpeasResource
- Returns:
- the date of the last update of the resource.
-
getCreatorName
public String getCreatorName()
-
setCreatorName
public void setCreatorName(String creatorName)
-
getRemoverName
public String getRemoverName()
-
setRemoverName
public void setRemoverName(String removerName)
-
getUpdaterName
public String getUpdaterName()
-
setUpdaterName
public void setUpdaterName(String updaterName)
-
getCreatedBy
public int getCreatedBy()
-
getRemovedBy
public int getRemovedBy()
-
getUpdatedBy
public int getUpdatedBy()
-
getCreator
public User getCreator()
Description copied from interface:SilverpeasResource
Gets the user that has created the resource.- Specified by:
getCreator
in interfaceSilverpeasResource
- Returns:
- a
User
in Silverpeas.
-
getLastUpdater
public User getLastUpdater()
Description copied from interface:SilverpeasResource
Gets the user that has lastly updated the resource. If the resource doesn't have such an information, then this method should return the user that has created the resource.- Specified by:
getLastUpdater
in interfaceSilverpeasResource
- Returns:
- a
User
in Silverpeas.
-
compareTo
public int compareTo(SpaceInstLight o)
- Specified by:
compareTo
in interfaceComparable<SpaceInstLight>
-
getLook
public String getLook()
-
setLook
public void setLook(String look)
-
isDisplaySpaceFirst
public boolean isDisplaySpaceFirst()
-
setDisplaySpaceFirst
public void setDisplaySpaceFirst(boolean displaySpaceFirst)
-
isPersonalSpace
public boolean isPersonalSpace()
-
setPersonalSpace
public void setPersonalSpace(boolean isPersonalSpace)
-
isInheritanceBlocked
public boolean isInheritanceBlocked()
-
setInheritanceBlocked
public void setInheritanceBlocked(boolean isInheritanceBlocked)
-
isRemoved
public boolean isRemoved()
-
canBeAccessedBy
public boolean canBeAccessedBy(User user)
Description copied from interface:Securable
Checks the given user can access this resource.- Specified by:
canBeAccessedBy
in interfaceSecurable
- Parameters:
user
- a user in Silverpeas.- Returns:
- true if the user can access the data managed by this instance, false otherwise.
-
canBeModifiedBy
public boolean canBeModifiedBy(User user)
Is the user can modify this collaboration space?- Specified by:
canBeModifiedBy
in interfaceSecurable
- Parameters:
user
- a user in Silverpeas.- Returns:
- true if the user can both access this collaboration space and has management privilege on this space (by being either an administrator or a space manager)
-
canBeFiledInBy
public boolean canBeFiledInBy(User user)
Can the user add spaces or component instances into this space?- Specified by:
canBeFiledInBy
in interfaceSecurable
- Parameters:
user
- a user in Silverpeas.- Returns:
- true if he can, false otherwise.
- See Also:
Securable.canBeFiledInBy(User)
-
-