Interface CreationContainerListProvider

All Known Implementing Classes:
AbstractCreationContainerListProvider, DefaultCreationContainerListProvider

public interface CreationContainerListProvider
Interface to implement for contributions to the FileManagerService creationContainerListProvider extension point.

The provider should tell for a given (handled) document type the list of candidate container the user can create new document in.

Author:
Olivier Grisel
  • Method Details

    • getName

      String getName()
      Unique name of the CreationContainerListProvider. The name of a provider should be used for the equals.
      Returns:
      the name
    • setName

      void setName(String name)
    • getDocTypes

      String[] getDocTypes()
      Arrays of the document types accepted by the CreationContainerListProvider instance. null or empty array mean any document type is accepted.
      Returns:
      arrays of document types
    • setDocTypes

      void setDocTypes(String[] docTypes)
    • accept

      boolean accept(String docType)
      Tell whether docType is handled by the provider.
      Parameters:
      docType - name of the document core type
      Returns:
      true is the docType is accepted
    • getCreationContainerList

      DocumentModelList getCreationContainerList(CoreSession documentManager, String docType)
      Build the list of candidate containers for the given document type and session.
      Parameters:
      documentManager - the current session context
      docType - the type of document to create
      Returns:
      the list of candidate containers