Class AbstractDirectory

    • Method Detail

      • doSanityChecks

        protected boolean doSanityChecks()
      • initialize

        public void initialize()
        Description copied from interface: Directory
        INTERNAL, DO NOT CALL. Initializes the directory when Nuxeo starts. Called without a transaction.
        Specified by:
        initialize in interface Directory
      • loadDataOnInit

        protected void loadDataOnInit​(boolean tableExists)
      • initializeReferences

        public void initializeReferences()
        Description copied from interface: Directory
        INTERNAL, DO NOT CALL. Initializes the directory when Nuxeo starts. Called without a transaction.
        Specified by:
        initializeReferences in interface Directory
      • initializeInverseReferences

        public void initializeInverseReferences()
        Description copied from interface: Directory
        INTERNAL, DO NOT CALL. Initializes the directory when Nuxeo starts. Called without a transaction.
        Specified by:
        initializeInverseReferences in interface Directory
      • getName

        public String getName()
        Description copied from interface: Directory
        Gets the unique name of the directory, used for registering.
        Specified by:
        getName in interface Directory
        Returns:
        the unique directory name
      • getSchema

        public String getSchema()
        Description copied from interface: Directory
        Gets the schema name used by this directory.
        Specified by:
        getSchema in interface Directory
        Returns:
        the schema name
      • getParentDirectory

        public String getParentDirectory()
        Description copied from interface: Directory
        Gets the name of the parent directory. This is used for hierarchical vocabularies.
        Specified by:
        getParentDirectory in interface Directory
        Returns:
        the name of the parent directory, or null.
      • getIdField

        public String getIdField()
        Description copied from interface: Directory
        Gets the id field of the schema for this directory.
        Specified by:
        getIdField in interface Directory
        Returns:
        the id field.
      • getPasswordField

        public String getPasswordField()
        Description copied from interface: Directory
        Gets the password field of the schema for this directory.
        Specified by:
        getPasswordField in interface Directory
        Returns:
        the password field.
      • isReadOnly

        public boolean isReadOnly()
        Description copied from interface: Directory
        Checks if this directory is read-only.
        Specified by:
        isReadOnly in interface Directory
      • setReadOnly

        public void setReadOnly​(boolean readOnly)
      • invalidateCaches

        public void invalidateCaches()
        Description copied from interface: Directory
        Invalidate caches
        Specified by:
        invalidateCaches in interface Directory
      • getReference

        @Deprecated
        public Reference getReference​(String referenceFieldName)
        Deprecated.
        Description copied from interface: Directory
        Lookup a Reference by field name.
        Specified by:
        getReference in interface Directory
        Returns:
        the matching reference implementation or null
      • getReferences

        public List<Reference> getReferences​(String referenceFieldName)
        Description copied from interface: Directory
        Lookup the References by field name.
        Specified by:
        getReferences in interface Directory
        Returns:
        the matching references implementation or null
      • isReference

        public boolean isReference​(String referenceFieldName)
      • addReference

        public void addReference​(Reference reference)
      • addReferences

        protected void addReferences()
      • addInverseReferences

        protected void addInverseReferences()
      • orderEntries

        public void orderEntries​(List<DocumentModel> entries,
                                 Map<String,​String> orderBy)
        Helper method to order entries.
        Parameters:
        entries - the list of entries.
        orderBy - an ordered map of field name -@gt; "asc" or "desc".
      • makeOrderBy

        public static Map<String,​String> makeOrderBy​(OrderByList orders)
        Helper to create an old-style ordering map.
        Since:
        10.3
      • getCache

        public DirectoryCache getCache()
        Description copied from interface: Directory
        Gets the cache instance of the directory
        Specified by:
        getCache in interface Directory
        Returns:
        the cache of the directory
      • removeSession

        public void removeSession​(Session session)
      • addSession

        public void addSession​(Session session)
      • invalidateDirectoryCache

        public void invalidateDirectoryCache()
        Description copied from interface: Directory
        Invalidates the cache instance of the directory
        Specified by:
        invalidateDirectoryCache in interface Directory
      • isMultiTenant

        public boolean isMultiTenant()
        Description copied from interface: Directory
        Returns true if this directory is a multi tenant directory, false otherwise.
        Specified by:
        isMultiTenant in interface Directory
      • shutdown

        public void shutdown()
        Description copied from interface: Directory
        Shuts down the directory.
        Specified by:
        shutdown in interface Directory
      • initSchemaFieldMap

        protected void initSchemaFieldMap()
      • fallbackOnDefaultCache

        protected void fallbackOnDefaultCache()