Class DocumentSpaceHome
- java.lang.Object
-
- fr.paris.lutece.plugins.document.business.spaces.DocumentSpaceHome
-
public final class DocumentSpaceHome extends Object
This class provides instances management methods (create, find, ...) for DocumentSpace objects
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static DocumentSpacecreate(DocumentSpace documentSpace)Creation of an instance of documentSpacestatic Collection<DocumentSpace>findAll()Select all spacesstatic DocumentSpacefindByPrimaryKey(int nKey)Returns an instance of a documentSpace whose identifier is specified in parameterstatic List<DocumentSpace>findChilds(int nParentSpaceId)Returns a collection of documentSpaces objectsstatic List<DocumentSpace>findChildsByTypeOfDocument(int nParentSpaceId, String strCodeType)Returns a collection of documentSpaces objects by type of documentstatic List<DocumentSpace>findSpacesAllowingDocumentCreationByDocumentType(String strCodeType, int createDocumentIsAllowed)Returns a collection of documentSpaces objects by type of documentstatic fr.paris.lutece.util.ReferenceListgetAllowedDocumentTypes(int nSpaceId)Returns all allowed document types for a given spacestatic fr.paris.lutece.util.ReferenceListgetDocumentSpaceList()Returns a ReferenceList of documentSpaces objectsstatic fr.paris.lutece.util.ReferenceListgetIconsList()Gets a list of icons available or space customizationstatic fr.paris.lutece.util.ReferenceListgetViewTypeList(Locale locale)Returns a ReferenceList of documentSpaces objectsstatic voidremove(int nDocumentSpaceId)Remove the DocumentSpace whose identifier is specified in parameterstatic DocumentSpaceupdate(DocumentSpace documentSpace)Update of the documentSpace which is specified in parameter
-
-
-
Method Detail
-
create
public static DocumentSpace create(DocumentSpace documentSpace)
Creation of an instance of documentSpace- Parameters:
documentSpace- The instance of the documentSpace which contains the informations to store- Returns:
- The instance of documentSpace which has been created with its primary key.
-
update
public static DocumentSpace update(DocumentSpace documentSpace)
Update of the documentSpace which is specified in parameter- Parameters:
documentSpace- The instance of the documentSpace which contains the data to store- Returns:
- The instance of the documentSpace which has been updated
-
remove
public static void remove(int nDocumentSpaceId)
Remove the DocumentSpace whose identifier is specified in parameter- Parameters:
nDocumentSpaceId- The id of the document space
-
findByPrimaryKey
public static DocumentSpace findByPrimaryKey(int nKey)
Returns an instance of a documentSpace whose identifier is specified in parameter- Parameters:
nKey- The Primary key of the documentSpace- Returns:
- An instance of documentSpace
-
findChilds
public static List<DocumentSpace> findChilds(int nParentSpaceId)
Returns a collection of documentSpaces objects- Parameters:
nParentSpaceId- The id of the parent document space- Returns:
- A collection of documentSpaces
-
findChildsByTypeOfDocument
public static List<DocumentSpace> findChildsByTypeOfDocument(int nParentSpaceId, String strCodeType)
Returns a collection of documentSpaces objects by type of document- Parameters:
nParentSpaceId- The id of the parent document spacestrCodeType- the document type- Returns:
- A collection of documentSpaces
-
findSpacesAllowingDocumentCreationByDocumentType
public static List<DocumentSpace> findSpacesAllowingDocumentCreationByDocumentType(String strCodeType, int createDocumentIsAllowed)
Returns a collection of documentSpaces objects by type of document- Parameters:
strCodeType- the document type filtercreateDocumentIsAllowed- code to define if document creation is allowed or not- Returns:
- The Collection of the DocumentSpaces
-
getDocumentSpaceList
public static fr.paris.lutece.util.ReferenceList getDocumentSpaceList()
Returns a ReferenceList of documentSpaces objects- Returns:
- A ReferenceList of documentSpaces
-
getViewTypeList
public static fr.paris.lutece.util.ReferenceList getViewTypeList(Locale locale)
Returns a ReferenceList of documentSpaces objects- Parameters:
locale- The locale- Returns:
- A ReferenceList of documentSpaces
-
getIconsList
public static fr.paris.lutece.util.ReferenceList getIconsList()
Gets a list of icons available or space customization- Returns:
- A list of icons
-
findAll
public static Collection<DocumentSpace> findAll()
Select all spaces- Returns:
- A collection of all spaces.
-
getAllowedDocumentTypes
public static fr.paris.lutece.util.ReferenceList getAllowedDocumentTypes(int nSpaceId)
Returns all allowed document types for a given space- Parameters:
nSpaceId- The space Id- Returns:
- Allowed documents types as a ReferenceList
-
-