Class CmisFolder

  • All Implemented Interfaces:
    Serializable, org.apache.chemistry.opencmis.commons.data.ExtensionsData, org.apache.chemistry.opencmis.commons.data.MutableObjectData, org.apache.chemistry.opencmis.commons.data.ObjectData, Fileable, Folding
    Direct Known Subclasses:
    Application, ContributionFolder, Publication, Space

    public abstract class CmisFolder
    extends CmisFile
    implements Folding
    The abstract representation of a Silverpeas resource as a CMIS folder. In CMIS, a Folder is a file-able CMIS object that can contain others file-ables CMIS objects. In Silverpeas, a space, a component instance (aka application), a topic in an EDM, a gallery in a media library, ... are all a container of other objects and hence they can be represented by a CMIS folder.
    Author:
    mmoquillon
    See Also:
    Serialized Form
    • Method Detail

      • getAllowedChildrenType

        public static List<TypeId> getAllowedChildrenType()
        Gets the types of the objects this type of folder accept as children. This method returns an empty list by default and requires to be overridden by the children classes in the case the CmisFolder is a CMIS Folder. Otherwise, nothing is returned.
        Returns:
        a list with all the TypeId that can be a children of such a folder type. If it isn't a folder, then returns an empty list. By default, this implementation returns an empty list.
      • setParentId

        public CmisFolder setParentId​(String parentId)
        Sets the unique identifier of the parent to this folder if any. If null, then this folder is a root one in the CMIS objects tree. Otherwise, the identifier must be the one of another CMIS folder; a folder cannot be orphaned.
        Overrides:
        setParentId in class CmisFile
        Parameters:
        parentId - the unique identifier of the parent folder.
        Returns:
        either the unique identifier of a folder, parent of it, or null if this folder is a root one in the CMIS objects tree.
      • isOrphaned

        public boolean isOrphaned()
        A folder cannot be orphaned.
        Specified by:
        isOrphaned in interface Fileable
        Returns:
        false.
      • isFolding

        public boolean isFolding()
        Description copied from class: CmisFile
        Is this file has folding capabilities? A file has such capabilities when it can wrap others file-able objects.
        Overrides:
        isFolding in class CmisFile
        Returns:
        by default false.
      • completeWithFolderActions

        protected Set<org.apache.chemistry.opencmis.commons.enums.Action> completeWithFolderActions​(Set<org.apache.chemistry.opencmis.commons.enums.Action> actions)