Class DocumentSpaceDAO

java.lang.Object
fr.paris.lutece.plugins.document.business.spaces.DocumentSpaceDAO
All Implemented Interfaces:
IDocumentSpaceDAO

public final class DocumentSpaceDAO extends Object implements IDocumentSpaceDAO
This class provides Data Access methods for DocumentSpace objects
  • Constructor Details

    • DocumentSpaceDAO

      public DocumentSpaceDAO()
  • Method Details

    • insert

      public void insert(DocumentSpace space)
      Insert a new record in the table.
      Specified by:
      insert in interface IDocumentSpaceDAO
      Parameters:
      space - The space object
    • load

      public DocumentSpace load(int nDocumentSpaceId)
      Load the data of DocumentSpace from the table
      Specified by:
      load in interface IDocumentSpaceDAO
      Parameters:
      nDocumentSpaceId - The identifier of DocumentSpace
      Returns:
      the instance of the DocumentSpace
    • delete

      public void delete(int nSpaceId)
      Delete a record from the table
      Specified by:
      delete in interface IDocumentSpaceDAO
      Parameters:
      nSpaceId - The Id to delete
    • store

      public void store(DocumentSpace space)
      Update the record in the table
      Specified by:
      store in interface IDocumentSpaceDAO
      Parameters:
      space - The reference of space
    • selectChilds

      public List<DocumentSpace> selectChilds(int nSpaceId, String strCodeType)
      Load the list of documentSpaces childs
      Specified by:
      selectChilds in interface IDocumentSpaceDAO
      Parameters:
      strCodeType - the document type filter if needed (null if not)
      nSpaceId - The space identifier
      Returns:
      The Collection of the DocumentSpaces
    • selectSpacesAllowingDocumentCreationByDocumentType

      public List<DocumentSpace> selectSpacesAllowingDocumentCreationByDocumentType(String strCodeType, int createDocumentIsAllowed)
      Load the list of documentSpaces authorizing the selected document type
      Specified by:
      selectSpacesAllowingDocumentCreationByDocumentType in interface IDocumentSpaceDAO
      Parameters:
      strCodeType - the document type filter
      createDocumentIsAllowed - code to define if document creation is allowed or not
      Returns:
      The Collection of the DocumentSpaces
    • getDocumentSpaceList

      public fr.paris.lutece.util.ReferenceList getDocumentSpaceList()
      Load the list of documentSpaces
      Specified by:
      getDocumentSpaceList in interface IDocumentSpaceDAO
      Returns:
      The Collection of the DocumentSpaces
    • getViewTypeList

      public fr.paris.lutece.util.ReferenceList getViewTypeList(Locale locale)
      Load the list of documentSpaces
      Specified by:
      getViewTypeList in interface IDocumentSpaceDAO
      Parameters:
      locale - The locale
      Returns:
      The Collection of the DocumentSpaces
    • getIconsList

      public fr.paris.lutece.util.ReferenceList getIconsList()
      Gets a list of icons available or space customization
      Specified by:
      getIconsList in interface IDocumentSpaceDAO
      Returns:
      A list of icons
    • selectAll

      public List<DocumentSpace> selectAll()
      Select all spaces
      Specified by:
      selectAll in interface IDocumentSpaceDAO
      Returns:
      A collection of all spaces.
    • getAllowedDocumentTypes

      public fr.paris.lutece.util.ReferenceList getAllowedDocumentTypes(int nSpaceId)
      Returns all allowed document types for a given space
      Specified by:
      getAllowedDocumentTypes in interface IDocumentSpaceDAO
      Parameters:
      nSpaceId - The space Id
      Returns:
      Allowed documents types as a ReferenceList