Class CMISConnector

  • All Implemented Interfaces:
    java.util.EventListener, org.alfresco.repo.tenant.TenantDeployer, org.springframework.beans.factory.Aware, org.springframework.context.ApplicationContextAware, org.springframework.context.ApplicationListener<org.springframework.context.event.ApplicationContextEvent>

    public class CMISConnector
    extends java.lang.Object
    implements org.springframework.context.ApplicationContextAware, org.springframework.context.ApplicationListener<org.springframework.context.event.ApplicationContextEvent>, org.alfresco.repo.tenant.TenantDeployer
    Bridge connecting Alfresco and OpenCMIS.

    This class provides many of the typical services that the CmisService implementation will need to use Alfresco.

    Author:
    florian.mueller, Derek Hulley, steveglover
    • Constructor Summary

      Constructors 
      Constructor Description
      CMISConnector()  
    • Method Summary

      All Methods Instance Methods Concrete Methods Deprecated Methods 
      Modifier and Type Method Description
      void addSecondaryTypes​(org.alfresco.service.cmr.repository.NodeRef nodeRef, java.util.List<java.lang.String> secondaryTypes)  
      void appendContent​(org.alfresco.opencmis.dictionary.CMISNodeInfo nodeInfo, org.apache.chemistry.opencmis.commons.data.ContentStream contentStream, boolean isLastChunk)  
      void applyACL​(org.alfresco.service.cmr.repository.NodeRef nodeRef, org.alfresco.opencmis.dictionary.TypeDefinitionWrapper type, org.apache.chemistry.opencmis.commons.data.Acl aces)
      Sets the given ACL.
      void applyACL​(org.alfresco.service.cmr.repository.NodeRef nodeRef, org.alfresco.opencmis.dictionary.TypeDefinitionWrapper type, org.apache.chemistry.opencmis.commons.data.Acl addAces, org.apache.chemistry.opencmis.commons.data.Acl removeAces)
      Applies the given ACLs.
      void applyPolicies​(org.alfresco.service.cmr.repository.NodeRef nodeRef, org.alfresco.opencmis.dictionary.TypeDefinitionWrapper type, java.util.List<java.lang.String> policies)  
      void applyVersioningState​(org.alfresco.service.cmr.repository.NodeRef nodeRef, org.apache.chemistry.opencmis.commons.enums.VersioningState versioningState)
      Applies a versioning state to a document.
      void checkChildObjectType​(org.alfresco.opencmis.dictionary.CMISNodeInfo folderInfo, java.lang.String childType)
      Checks if a child of a given type can be added to a given folder.
      java.lang.String constructObjectId​(java.lang.String incomingObjectId)  
      java.lang.String constructObjectId​(java.lang.String incomingNodeId, java.lang.String versionLabel)  
      java.lang.String constructObjectId​(java.lang.String incomingNodeId, java.lang.String versionLabel, boolean dropStoreRef)  
      java.lang.String constructObjectId​(org.alfresco.service.cmr.repository.AssociationRef assocRef, java.lang.String versionLabel)  
      java.lang.String constructObjectId​(org.alfresco.service.cmr.repository.AssociationRef assocRef, java.lang.String versionLabel, boolean dropStoreRef)  
      java.lang.String constructObjectId​(org.alfresco.service.cmr.repository.NodeRef incomingNodeRef, java.lang.String versionLabel)  
      java.lang.String constructObjectId​(org.alfresco.service.cmr.repository.NodeRef incomingNodeRef, java.lang.String versionLabel, boolean dropStoreRef)  
      org.apache.chemistry.opencmis.commons.data.ObjectData createCMISObject​(org.alfresco.opencmis.dictionary.CMISNodeInfo info, java.lang.String filter, boolean includeAllowableActions, org.apache.chemistry.opencmis.commons.enums.IncludeRelationships includeRelationships, java.lang.String renditionFilter, boolean includePolicyIds, boolean includeAcl)
      Creates the CMIS object for a node.
      CMISNodeInfoImpl createNodeInfo​(java.lang.String objectId)
      Creates an object info object.
      CMISNodeInfoImpl createNodeInfo​(org.alfresco.service.cmr.repository.AssociationRef assocRef)
      Creates an object info object.
      CMISNodeInfoImpl createNodeInfo​(org.alfresco.service.cmr.repository.NodeRef nodeRef)
      Creates an object info object.
      CMISNodeInfoImpl createNodeInfo​(org.alfresco.service.cmr.repository.NodeRef nodeRef, org.alfresco.service.namespace.QName nodeType, java.util.Map<org.alfresco.service.namespace.QName,​java.io.Serializable> nodeProps, VersionHistory versionHistory, boolean checkExists)
      Creates an object info object.
      java.lang.String createObjectId​(org.alfresco.service.cmr.repository.NodeRef nodeRef)
      Compiles a CMIS object if for a live node.
      java.lang.String createObjectId​(org.alfresco.service.cmr.repository.NodeRef nodeRef, boolean dropStoreRef)  
      void createThumbnails​(org.alfresco.service.cmr.repository.NodeRef nodeRef, java.util.Set<java.lang.String> thumbnailNames)
      Asynchronously generates thumbnails for the given node.
      void createVersion​(org.alfresco.service.cmr.repository.NodeRef nodeRef, VersionType versionType, java.lang.String reason)  
      void deleteNode​(org.alfresco.service.cmr.repository.NodeRef nodeRef, boolean postActivity)  
      void destroy()  
      boolean disableBehaviour​(org.alfresco.service.namespace.QName className)  
      boolean disableBehaviour​(org.alfresco.service.namespace.QName className, org.alfresco.service.cmr.repository.NodeRef nodeRef)  
      boolean enableBehaviour​(org.alfresco.service.namespace.QName className)  
      boolean enableBehaviour​(org.alfresco.service.namespace.QName className, org.alfresco.service.cmr.repository.NodeRef nodeRef)  
      protected org.apache.chemistry.opencmis.commons.data.Acl excludeInheritedAces​(org.alfresco.service.cmr.repository.NodeRef nodeRef, org.apache.chemistry.opencmis.commons.data.Acl acl)
      Filter acl to ignore inherited ACEs
      void extractMetadata​(org.alfresco.service.cmr.repository.NodeRef nodeRef)
      Extracts metadata for the node.
      boolean filter​(org.alfresco.service.cmr.repository.NodeRef nodeRef)
      Should the node be filtered?
      org.apache.chemistry.opencmis.commons.data.Acl getACL​(org.alfresco.service.cmr.repository.NodeRef nodeRef, boolean onlyBasicPermissions)  
      CmisActivityPoster getActivityPoster()  
      org.apache.chemistry.opencmis.commons.data.AllowableActions getAllowableActions​(org.alfresco.opencmis.dictionary.CMISNodeInfo info)  
      java.util.List<org.apache.chemistry.opencmis.commons.data.CmisExtensionElement> getAspectExtensions​(org.alfresco.opencmis.dictionary.CMISNodeInfo info, java.lang.String filter, java.util.Set<java.lang.String> alreadySetProperties)
      Builds aspect extension.
      org.apache.chemistry.opencmis.commons.data.Properties getAssocProperties​(org.alfresco.opencmis.dictionary.CMISNodeInfo info, java.lang.String filter)  
      AuthenticationService getAuthenticationService()  
      int getBulkBatchSize()  
      int getBulkMaxItems()  
      int getBulkWorkerThreads()  
      CheckOutCheckInService getCheckOutCheckInService()  
      org.apache.chemistry.opencmis.commons.data.ObjectList getContentChanges​(org.apache.chemistry.opencmis.commons.spi.Holder<java.lang.String> changeLogToken, java.math.BigInteger maxItems)
      Returns content changes.
      ContentService getContentService()  
      org.apache.chemistry.opencmis.commons.data.ContentStream getContentStream​(org.alfresco.opencmis.dictionary.CMISNodeInfo info, java.lang.String streamId, java.math.BigInteger offset, java.math.BigInteger length)
      Gets the content from the repository.
      java.lang.String getCurrentVersionId​(java.lang.String objectId)
      Cuts of the version information from an object id.
      DescriptorService getDescriptorService()  
      org.alfresco.service.cmr.dictionary.DictionaryService getDictionaryService()  
      FileFolderService getFileFolderService()  
      java.lang.String getIdProperty​(org.apache.chemistry.opencmis.commons.data.Properties properties, java.lang.String propertyId)
      Returns the value of the given property if it exists and is of the correct type.
      LockService getLockService()
      Sets the lock service.
      org.alfresco.service.cmr.repository.MimetypeService getMimetypeService()  
      java.lang.String getName​(org.alfresco.service.cmr.repository.NodeRef nodeRef)  
      java.lang.String getNameProperty​(org.apache.chemistry.opencmis.commons.data.Properties properties, java.lang.String fallback)  
      org.apache.chemistry.opencmis.commons.data.Properties getNodeProperties​(org.alfresco.opencmis.dictionary.CMISNodeInfo info, java.lang.String filter)  
      org.alfresco.service.cmr.repository.NodeService getNodeService()  
      org.apache.chemistry.opencmis.commons.data.ObjectList getObjectRelationships​(org.alfresco.service.cmr.repository.NodeRef nodeRef, org.apache.chemistry.opencmis.commons.enums.RelationshipDirection relationshipDirection, java.lang.String typeId, java.lang.String filter, java.lang.Boolean includeAllowableActions, java.math.BigInteger maxItems, java.math.BigInteger skipCount)  
      java.math.BigInteger getObjectsDefaultDepth()  
      java.math.BigInteger getObjectsDefaultMaxItems()  
      java.lang.String getObjectTypeIdProperty​(org.apache.chemistry.opencmis.commons.data.Properties properties)  
      org.alfresco.opencmis.dictionary.CMISDictionaryService getOpenCMISDictionaryService()  
      CMISQueryService getOpenCMISQueryService()  
      java.lang.String getPath​(org.alfresco.service.cmr.repository.NodeRef nodeRef)  
      java.lang.String getProxyUser()  
      java.util.List<org.apache.chemistry.opencmis.commons.data.ObjectData> getRelationships​(org.alfresco.service.cmr.repository.NodeRef nodeRef, org.apache.chemistry.opencmis.commons.enums.IncludeRelationships includeRelationships)  
      java.util.List<org.apache.chemistry.opencmis.commons.data.RenditionData> getRenditions​(org.alfresco.service.cmr.repository.NodeRef nodeRef, java.lang.String renditionFilter, java.math.BigInteger maxItems, java.math.BigInteger skipCount)  
      java.lang.String getRepositoryId()
      Returns the repository id.
      org.apache.chemistry.opencmis.commons.data.RepositoryInfo getRepositoryInfo​(org.apache.chemistry.opencmis.commons.enums.CmisVersion cmisVersion)
      Returns the repository info object.
      org.apache.chemistry.opencmis.commons.enums.CmisVersion getRequestCmisVersion()  
      RetryingTransactionHelper getRetryingTransactionHelper()  
      org.alfresco.service.cmr.repository.NodeRef getRootNodeRef()
      Returns the root folder node ref.
      org.alfresco.service.cmr.repository.StoreRef getRootStoreRef()  
      org.alfresco.service.cmr.search.SearchService getSearchService()  
      ServiceRegistry getServiceRegistry()
      Return the service registry
      SiteInfo getSite​(org.alfresco.service.cmr.repository.NodeRef nodeRef)  
      org.alfresco.util.Pair<org.alfresco.service.namespace.QName,​java.lang.Boolean> getSortProperty​(java.lang.String cmisPropertyName, java.lang.String direction)  
      java.lang.String getSourceIdProperty​(org.apache.chemistry.opencmis.commons.data.Properties properties)  
      java.lang.String getStringProperty​(org.apache.chemistry.opencmis.commons.data.Properties properties, java.lang.String propertyId)
      Returns the value of the given property if it exists and is of the correct type.
      java.lang.String getTargetIdProperty​(org.apache.chemistry.opencmis.commons.data.Properties properties)  
      TransactionService getTransactionService()  
      org.alfresco.opencmis.dictionary.TypeDefinitionWrapper getType​(java.lang.String cmisTypeId)
      Returns the type definition of a node or null if no type definition could be found.
      org.alfresco.opencmis.dictionary.TypeDefinitionWrapper getType​(org.alfresco.service.cmr.repository.AssociationRef assocRef)
      Returns the type definition of an association or null if no type definition could be found.
      org.alfresco.opencmis.dictionary.TypeDefinitionWrapper getType​(org.alfresco.service.cmr.repository.NodeRef nodeRef)
      Returns the type definition of a node or null if no type definition could be found.
      org.alfresco.opencmis.dictionary.TypeDefinitionWrapper getTypeForCreate​(java.lang.String cmisTypeId, org.apache.chemistry.opencmis.commons.enums.BaseTypeId baseTypeId)
      Returns the definition after it has checked if the type can be used for object creation.
      java.math.BigInteger getTypesDefaultDepth()  
      java.math.BigInteger getTypesDefaultMaxItems()  
      VersionService getVersionService()  
      void init()  
      boolean isHidden​(org.alfresco.service.cmr.repository.NodeRef nodeRef)  
      void onApplicationEvent​(org.springframework.context.event.ApplicationContextEvent event)  
      void onDisableTenant()  
      void onEnableTenant()  
      boolean openHttpSession()  
      protected void publishReadEvent​(org.alfresco.service.cmr.repository.NodeRef nodeRef, java.lang.String name, java.lang.String mimeType, long contentSize, java.lang.String encoding, java.lang.String range)
      Notifies listeners that a read has taken place.
      org.apache.chemistry.opencmis.commons.data.ObjectList query​(java.lang.String statement, java.lang.Boolean includeAllowableActions, org.apache.chemistry.opencmis.commons.enums.IncludeRelationships includeRelationships, java.lang.String renditionFilter, java.math.BigInteger maxItems, java.math.BigInteger skipCount)  
      void removeSecondaryTypes​(org.alfresco.service.cmr.repository.NodeRef nodeRef, java.util.List<java.lang.String> secondaryTypes)  
      void setActionService​(ActionService actionService)  
      void setActivityPoster​(CmisActivityPoster activityPoster)  
      void setApplicationContext​(org.springframework.context.ApplicationContext applicationContext)  
      void setAuditService​(AuditService auditService)
      Sets the audit service.
      void setAuthenticationService​(AuthenticationService authenticationService)
      Sets the authentication service.
      void setBehaviourFilter​(BehaviourFilter behaviourFilter)  
      void setBulkBatchSize​(int size)  
      void setBulkMaxItems​(int size)
      Sets bulk update properties.
      void setBulkWorkerThreads​(int threads)  
      void setCheckOutCheckInService​(CheckOutCheckInService checkOutCheckInService)
      Sets the checkOut/checkIn service.
      void setContentChangesDefaultMaxItems​(int contentChangesDefaultMaxItems)
      Set the default number of content changes to return if nothing is specified
      void setContentService​(ContentService contentService)
      Sets the content service.
      void setDescriptorService​(DescriptorService descriptorService)
      Sets the descriptor service.
      void setDictionaryService​(org.alfresco.service.cmr.dictionary.DictionaryService dictionaryService)  
      void setEventPublisher​(org.alfresco.sync.repo.events.EventPublisher eventPublisher)
      Sets the event publisher
      void setFileFolderService​(FileFolderService fileFolderService)
      Sets the file folder service.
      void setHiddenAspect​(HiddenAspect hiddenAspect)  
      void setLockService​(LockService lockService)  
      void setMimetypeService​(org.alfresco.service.cmr.repository.MimetypeService mimetypeService)
      Sets the MIME type service.
      void setNamespaceService​(org.alfresco.service.namespace.NamespaceService namespaceService)
      Sets the namespace service.
      void setNodeService​(org.alfresco.service.cmr.repository.NodeService nodeService)
      Sets the node service.
      void setObjectFilter​(ObjectFilter objectFilter)  
      void setObjectsDefaultDepth​(java.math.BigInteger objectsDefaultDepth)  
      void setObjectsDefaultMaxItems​(java.math.BigInteger objectsDefaultMaxItems)  
      void setOpenCMISDictionaryService​(org.alfresco.opencmis.dictionary.CMISDictionaryService cmisDictionaryService)  
      void setOpenCMISDictionaryService11​(org.alfresco.opencmis.dictionary.CMISDictionaryService cmisDictionaryService)  
      void setOpenCMISQueryService​(CMISQueryService cmisQueryService)
      Sets the OpenCMIS query service.
      void setOpenCMISQueryService11​(CMISQueryService cmisQueryService)  
      void setOpenHttpSession​(boolean openHttpSession)  
      void setPermissionModelDao​(ModelDAO permissionModelDao)
      Sets the permission model DAO.
      void setPermissionService​(org.alfresco.service.cmr.security.PermissionService permissionService)
      Sets the permission service.
      void setProperties​(org.alfresco.service.cmr.repository.NodeRef nodeRef, org.alfresco.opencmis.dictionary.TypeDefinitionWrapper type, org.apache.chemistry.opencmis.commons.data.Properties properties, java.lang.String... exclude)
      Sets property values.
      void setProperty​(org.alfresco.service.cmr.repository.NodeRef nodeRef, org.alfresco.opencmis.dictionary.TypeDefinitionWrapper type, java.lang.String propertyId, java.io.Serializable value)
      Sets a property value.
      void setProxyUser​(java.lang.String proxyUser)
      Not implemented
      void setRenditionKindMapping​(java.util.Map<java.lang.String,​java.util.List<java.lang.String>> renditionKinds)
      Set rendition kind mapping.
      void setrenditionService​(RenditionService renditionService)
      Deprecated.
      The RenditionService is being replace by the simpler async RenditionService2.
      void setRootPath​(java.lang.String path)
      Sets the root path.
      void setSearchService​(org.alfresco.service.cmr.search.SearchService searchService)
      Sets the search service.
      void setServiceRegistry​(ServiceRegistry serviceRegistry)  
      void setSingletonCache​(org.alfresco.repo.cache.SimpleCache<java.lang.String,​java.lang.Object> singletonCache)  
      void setSiteService​(SiteService siteService)  
      void setStore​(java.lang.String store)
      Sets the root store.
      void setTenantAdminService​(TenantAdminService tenantAdminService)
      Sets the tenant admin service.
      void setThumbnailService​(ThumbnailService thumbnailService)
      Deprecated.
      The thumbnails code is being moved out of the codebase and replaced by the new async RenditionService2 or other external libraries.
      void setTransactionService​(TransactionService transactionService)
      Sets the transaction service.
      void setTypesDefaultDepth​(java.math.BigInteger typesDefaultDepth)  
      void setTypesDefaultMaxItems​(java.math.BigInteger typesDefaultMaxItems)  
      void setup()  
      void setVersionService​(VersionService versionService)
      Sets the version service.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • CMISConnector

        public CMISConnector()
    • Method Detail

      • setObjectFilter

        public void setObjectFilter​(ObjectFilter objectFilter)
      • setStore

        public void setStore​(java.lang.String store)
        Sets the root store.
        Parameters:
        store - store_type://store_id
      • setSiteService

        public void setSiteService​(SiteService siteService)
      • setActivityPoster

        public void setActivityPoster​(CmisActivityPoster activityPoster)
      • setHiddenAspect

        public void setHiddenAspect​(HiddenAspect hiddenAspect)
      • isHidden

        public boolean isHidden​(org.alfresco.service.cmr.repository.NodeRef nodeRef)
      • setRootPath

        public void setRootPath​(java.lang.String path)
        Sets the root path.
        Parameters:
        path - path within default store
      • getTypesDefaultMaxItems

        public java.math.BigInteger getTypesDefaultMaxItems()
      • setTypesDefaultMaxItems

        public void setTypesDefaultMaxItems​(java.math.BigInteger typesDefaultMaxItems)
      • getTypesDefaultDepth

        public java.math.BigInteger getTypesDefaultDepth()
      • setTypesDefaultDepth

        public void setTypesDefaultDepth​(java.math.BigInteger typesDefaultDepth)
      • getObjectsDefaultMaxItems

        public java.math.BigInteger getObjectsDefaultMaxItems()
      • setObjectsDefaultMaxItems

        public void setObjectsDefaultMaxItems​(java.math.BigInteger objectsDefaultMaxItems)
      • getObjectsDefaultDepth

        public java.math.BigInteger getObjectsDefaultDepth()
      • setObjectsDefaultDepth

        public void setObjectsDefaultDepth​(java.math.BigInteger objectsDefaultDepth)
      • setContentChangesDefaultMaxItems

        public void setContentChangesDefaultMaxItems​(int contentChangesDefaultMaxItems)
        Set the default number of content changes to return if nothing is specified
      • setRenditionKindMapping

        public void setRenditionKindMapping​(java.util.Map<java.lang.String,​java.util.List<java.lang.String>> renditionKinds)
        Set rendition kind mapping.
      • setOpenHttpSession

        public void setOpenHttpSession​(boolean openHttpSession)
      • openHttpSession

        public boolean openHttpSession()
      • setThumbnailService

        @Deprecated
        public void setThumbnailService​(ThumbnailService thumbnailService)
        Deprecated.
        The thumbnails code is being moved out of the codebase and replaced by the new async RenditionService2 or other external libraries.
      • setServiceRegistry

        public void setServiceRegistry​(ServiceRegistry serviceRegistry)
      • getServiceRegistry

        public final ServiceRegistry getServiceRegistry()
        Return the service registry
      • setDescriptorService

        public void setDescriptorService​(DescriptorService descriptorService)
        Sets the descriptor service.
      • setBehaviourFilter

        public void setBehaviourFilter​(BehaviourFilter behaviourFilter)
      • setNodeService

        public void setNodeService​(org.alfresco.service.cmr.repository.NodeService nodeService)
        Sets the node service.
      • getNodeService

        public org.alfresco.service.cmr.repository.NodeService getNodeService()
      • setActionService

        public void setActionService​(ActionService actionService)
      • setVersionService

        public void setVersionService​(VersionService versionService)
        Sets the version service.
      • setCheckOutCheckInService

        public void setCheckOutCheckInService​(CheckOutCheckInService checkOutCheckInService)
        Sets the checkOut/checkIn service.
      • getLockService

        public LockService getLockService()
        Sets the lock service.
      • setLockService

        public void setLockService​(LockService lockService)
      • setContentService

        public void setContentService​(ContentService contentService)
        Sets the content service.
      • setEventPublisher

        public void setEventPublisher​(org.alfresco.sync.repo.events.EventPublisher eventPublisher)
        Sets the event publisher
      • setrenditionService

        @Deprecated
        public void setrenditionService​(RenditionService renditionService)
        Deprecated.
        The RenditionService is being replace by the simpler async RenditionService2.
        Sets the rendition service.
      • setFileFolderService

        public void setFileFolderService​(FileFolderService fileFolderService)
        Sets the file folder service.
      • setTenantAdminService

        public void setTenantAdminService​(TenantAdminService tenantAdminService)
        Sets the tenant admin service.
      • setSingletonCache

        public void setSingletonCache​(org.alfresco.repo.cache.SimpleCache<java.lang.String,​java.lang.Object> singletonCache)
      • setTransactionService

        public void setTransactionService​(TransactionService transactionService)
        Sets the transaction service.
      • setAuthenticationService

        public void setAuthenticationService​(AuthenticationService authenticationService)
        Sets the authentication service.
      • setPermissionService

        public void setPermissionService​(org.alfresco.service.cmr.security.PermissionService permissionService)
        Sets the permission service.
      • setPermissionModelDao

        public void setPermissionModelDao​(ModelDAO permissionModelDao)
        Sets the permission model DAO.
      • setOpenCMISDictionaryService

        public void setOpenCMISDictionaryService​(org.alfresco.opencmis.dictionary.CMISDictionaryService cmisDictionaryService)
      • setOpenCMISDictionaryService11

        public void setOpenCMISDictionaryService11​(org.alfresco.opencmis.dictionary.CMISDictionaryService cmisDictionaryService)
      • getOpenCMISDictionaryService

        public org.alfresco.opencmis.dictionary.CMISDictionaryService getOpenCMISDictionaryService()
      • setOpenCMISQueryService

        public void setOpenCMISQueryService​(CMISQueryService cmisQueryService)
        Sets the OpenCMIS query service.
      • setOpenCMISQueryService11

        public void setOpenCMISQueryService11​(CMISQueryService cmisQueryService)
      • setMimetypeService

        public void setMimetypeService​(org.alfresco.service.cmr.repository.MimetypeService mimetypeService)
        Sets the MIME type service.
      • getMimetypeService

        public org.alfresco.service.cmr.repository.MimetypeService getMimetypeService()
      • setAuditService

        public void setAuditService​(AuditService auditService)
        Sets the audit service.
      • setNamespaceService

        public void setNamespaceService​(org.alfresco.service.namespace.NamespaceService namespaceService)
        Sets the namespace service.
      • setSearchService

        public void setSearchService​(org.alfresco.service.cmr.search.SearchService searchService)
        Sets the search service.
      • getSearchService

        public org.alfresco.service.cmr.search.SearchService getSearchService()
      • setDictionaryService

        public void setDictionaryService​(org.alfresco.service.cmr.dictionary.DictionaryService dictionaryService)
      • getDictionaryService

        public org.alfresco.service.cmr.dictionary.DictionaryService getDictionaryService()
      • setProxyUser

        public void setProxyUser​(java.lang.String proxyUser)
        Not implemented
        Throws:
        java.lang.UnsupportedOperationException - always
      • getProxyUser

        public java.lang.String getProxyUser()
      • setBulkMaxItems

        public void setBulkMaxItems​(int size)
        Sets bulk update properties.
      • getBulkMaxItems

        public int getBulkMaxItems()
      • setBulkBatchSize

        public void setBulkBatchSize​(int size)
      • getBulkBatchSize

        public int getBulkBatchSize()
      • setBulkWorkerThreads

        public void setBulkWorkerThreads​(int threads)
      • getBulkWorkerThreads

        public int getBulkWorkerThreads()
      • setup

        public void setup()
      • init

        public void init()
        Specified by:
        init in interface org.alfresco.repo.tenant.TenantDeployer
      • destroy

        public void destroy()
        Specified by:
        destroy in interface org.alfresco.repo.tenant.TenantDeployer
      • onEnableTenant

        public void onEnableTenant()
        Specified by:
        onEnableTenant in interface org.alfresco.repo.tenant.TenantDeployer
      • onDisableTenant

        public void onDisableTenant()
        Specified by:
        onDisableTenant in interface org.alfresco.repo.tenant.TenantDeployer
      • setApplicationContext

        public void setApplicationContext​(org.springframework.context.ApplicationContext applicationContext)
                                   throws org.springframework.beans.BeansException
        Specified by:
        setApplicationContext in interface org.springframework.context.ApplicationContextAware
        Throws:
        org.springframework.beans.BeansException
      • onApplicationEvent

        public void onApplicationEvent​(org.springframework.context.event.ApplicationContextEvent event)
        Specified by:
        onApplicationEvent in interface org.springframework.context.ApplicationListener<org.springframework.context.event.ApplicationContextEvent>
      • getSortProperty

        public org.alfresco.util.Pair<org.alfresco.service.namespace.QName,​java.lang.Boolean> getSortProperty​(java.lang.String cmisPropertyName,
                                                                                                                    java.lang.String direction)
      • createThumbnails

        public void createThumbnails​(org.alfresco.service.cmr.repository.NodeRef nodeRef,
                                     java.util.Set<java.lang.String> thumbnailNames)
        Asynchronously generates thumbnails for the given node.
        Parameters:
        nodeRef - NodeRef
      • extractMetadata

        public void extractMetadata​(org.alfresco.service.cmr.repository.NodeRef nodeRef)
        Extracts metadata for the node.
        Parameters:
        nodeRef - NodeRef
      • getSite

        public SiteInfo getSite​(org.alfresco.service.cmr.repository.NodeRef nodeRef)
      • filter

        public boolean filter​(org.alfresco.service.cmr.repository.NodeRef nodeRef)
        Should the node be filtered?
      • disableBehaviour

        public boolean disableBehaviour​(org.alfresco.service.namespace.QName className)
      • enableBehaviour

        public boolean enableBehaviour​(org.alfresco.service.namespace.QName className)
      • disableBehaviour

        public boolean disableBehaviour​(org.alfresco.service.namespace.QName className,
                                        org.alfresco.service.cmr.repository.NodeRef nodeRef)
      • enableBehaviour

        public boolean enableBehaviour​(org.alfresco.service.namespace.QName className,
                                       org.alfresco.service.cmr.repository.NodeRef nodeRef)
      • getRootStoreRef

        public org.alfresco.service.cmr.repository.StoreRef getRootStoreRef()
      • deleteNode

        public void deleteNode​(org.alfresco.service.cmr.repository.NodeRef nodeRef,
                               boolean postActivity)
      • getRootNodeRef

        public org.alfresco.service.cmr.repository.NodeRef getRootNodeRef()
        Returns the root folder node ref.
      • getName

        public java.lang.String getName​(org.alfresco.service.cmr.repository.NodeRef nodeRef)
      • getCurrentVersionId

        public java.lang.String getCurrentVersionId​(java.lang.String objectId)
        Cuts of the version information from an object id.
      • createNodeInfo

        public CMISNodeInfoImpl createNodeInfo​(java.lang.String objectId)
        Creates an object info object.
      • createNodeInfo

        public CMISNodeInfoImpl createNodeInfo​(org.alfresco.service.cmr.repository.NodeRef nodeRef)
        Creates an object info object.
      • createNodeInfo

        public CMISNodeInfoImpl createNodeInfo​(org.alfresco.service.cmr.repository.NodeRef nodeRef,
                                               org.alfresco.service.namespace.QName nodeType,
                                               java.util.Map<org.alfresco.service.namespace.QName,​java.io.Serializable> nodeProps,
                                               VersionHistory versionHistory,
                                               boolean checkExists)
        Creates an object info object.
      • createNodeInfo

        public CMISNodeInfoImpl createNodeInfo​(org.alfresco.service.cmr.repository.AssociationRef assocRef)
        Creates an object info object.
      • constructObjectId

        public java.lang.String constructObjectId​(org.alfresco.service.cmr.repository.AssociationRef assocRef,
                                                  java.lang.String versionLabel)
      • constructObjectId

        public java.lang.String constructObjectId​(org.alfresco.service.cmr.repository.AssociationRef assocRef,
                                                  java.lang.String versionLabel,
                                                  boolean dropStoreRef)
      • constructObjectId

        public java.lang.String constructObjectId​(java.lang.String incomingObjectId)
      • constructObjectId

        public java.lang.String constructObjectId​(java.lang.String incomingNodeId,
                                                  java.lang.String versionLabel)
      • constructObjectId

        public java.lang.String constructObjectId​(java.lang.String incomingNodeId,
                                                  java.lang.String versionLabel,
                                                  boolean dropStoreRef)
      • createVersion

        public void createVersion​(org.alfresco.service.cmr.repository.NodeRef nodeRef,
                                  VersionType versionType,
                                  java.lang.String reason)
      • getRequestCmisVersion

        public org.apache.chemistry.opencmis.commons.enums.CmisVersion getRequestCmisVersion()
      • constructObjectId

        public java.lang.String constructObjectId​(org.alfresco.service.cmr.repository.NodeRef incomingNodeRef,
                                                  java.lang.String versionLabel)
      • constructObjectId

        public java.lang.String constructObjectId​(org.alfresco.service.cmr.repository.NodeRef incomingNodeRef,
                                                  java.lang.String versionLabel,
                                                  boolean dropStoreRef)
      • createObjectId

        public java.lang.String createObjectId​(org.alfresco.service.cmr.repository.NodeRef nodeRef)
        Compiles a CMIS object if for a live node.
      • createObjectId

        public java.lang.String createObjectId​(org.alfresco.service.cmr.repository.NodeRef nodeRef,
                                               boolean dropStoreRef)
      • getType

        public org.alfresco.opencmis.dictionary.TypeDefinitionWrapper getType​(org.alfresco.service.cmr.repository.NodeRef nodeRef)
        Returns the type definition of a node or null if no type definition could be found.
      • getType

        public org.alfresco.opencmis.dictionary.TypeDefinitionWrapper getType​(org.alfresco.service.cmr.repository.AssociationRef assocRef)
        Returns the type definition of an association or null if no type definition could be found.
      • getType

        public org.alfresco.opencmis.dictionary.TypeDefinitionWrapper getType​(java.lang.String cmisTypeId)
        Returns the type definition of a node or null if no type definition could be found.
      • getTypeForCreate

        public org.alfresco.opencmis.dictionary.TypeDefinitionWrapper getTypeForCreate​(java.lang.String cmisTypeId,
                                                                                       org.apache.chemistry.opencmis.commons.enums.BaseTypeId baseTypeId)
        Returns the definition after it has checked if the type can be used for object creation.
      • applyVersioningState

        public void applyVersioningState​(org.alfresco.service.cmr.repository.NodeRef nodeRef,
                                         org.apache.chemistry.opencmis.commons.enums.VersioningState versioningState)
        Applies a versioning state to a document.
      • checkChildObjectType

        public void checkChildObjectType​(org.alfresco.opencmis.dictionary.CMISNodeInfo folderInfo,
                                         java.lang.String childType)
        Checks if a child of a given type can be added to a given folder.
      • createCMISObject

        public org.apache.chemistry.opencmis.commons.data.ObjectData createCMISObject​(org.alfresco.opencmis.dictionary.CMISNodeInfo info,
                                                                                      java.lang.String filter,
                                                                                      boolean includeAllowableActions,
                                                                                      org.apache.chemistry.opencmis.commons.enums.IncludeRelationships includeRelationships,
                                                                                      java.lang.String renditionFilter,
                                                                                      boolean includePolicyIds,
                                                                                      boolean includeAcl)
        Creates the CMIS object for a node.
      • getPath

        public java.lang.String getPath​(org.alfresco.service.cmr.repository.NodeRef nodeRef)
      • getContentStream

        public org.apache.chemistry.opencmis.commons.data.ContentStream getContentStream​(org.alfresco.opencmis.dictionary.CMISNodeInfo info,
                                                                                         java.lang.String streamId,
                                                                                         java.math.BigInteger offset,
                                                                                         java.math.BigInteger length)
        Gets the content from the repository.
      • publishReadEvent

        protected void publishReadEvent​(org.alfresco.service.cmr.repository.NodeRef nodeRef,
                                        java.lang.String name,
                                        java.lang.String mimeType,
                                        long contentSize,
                                        java.lang.String encoding,
                                        java.lang.String range)
        Notifies listeners that a read has taken place.
        Parameters:
        nodeRef - NodeRef
        name - String
        mimeType - String
        contentSize - long
        encoding - String
        range - String
      • appendContent

        public void appendContent​(org.alfresco.opencmis.dictionary.CMISNodeInfo nodeInfo,
                                  org.apache.chemistry.opencmis.commons.data.ContentStream contentStream,
                                  boolean isLastChunk)
                           throws java.io.IOException
        Throws:
        java.io.IOException
      • getNodeProperties

        public org.apache.chemistry.opencmis.commons.data.Properties getNodeProperties​(org.alfresco.opencmis.dictionary.CMISNodeInfo info,
                                                                                       java.lang.String filter)
      • getAssocProperties

        public org.apache.chemistry.opencmis.commons.data.Properties getAssocProperties​(org.alfresco.opencmis.dictionary.CMISNodeInfo info,
                                                                                        java.lang.String filter)
      • getAspectExtensions

        public java.util.List<org.apache.chemistry.opencmis.commons.data.CmisExtensionElement> getAspectExtensions​(org.alfresco.opencmis.dictionary.CMISNodeInfo info,
                                                                                                                   java.lang.String filter,
                                                                                                                   java.util.Set<java.lang.String> alreadySetProperties)
        Builds aspect extension.
      • getAllowableActions

        public org.apache.chemistry.opencmis.commons.data.AllowableActions getAllowableActions​(org.alfresco.opencmis.dictionary.CMISNodeInfo info)
      • getRelationships

        public java.util.List<org.apache.chemistry.opencmis.commons.data.ObjectData> getRelationships​(org.alfresco.service.cmr.repository.NodeRef nodeRef,
                                                                                                      org.apache.chemistry.opencmis.commons.enums.IncludeRelationships includeRelationships)
      • getObjectRelationships

        public org.apache.chemistry.opencmis.commons.data.ObjectList getObjectRelationships​(org.alfresco.service.cmr.repository.NodeRef nodeRef,
                                                                                            org.apache.chemistry.opencmis.commons.enums.RelationshipDirection relationshipDirection,
                                                                                            java.lang.String typeId,
                                                                                            java.lang.String filter,
                                                                                            java.lang.Boolean includeAllowableActions,
                                                                                            java.math.BigInteger maxItems,
                                                                                            java.math.BigInteger skipCount)
      • getRenditions

        public java.util.List<org.apache.chemistry.opencmis.commons.data.RenditionData> getRenditions​(org.alfresco.service.cmr.repository.NodeRef nodeRef,
                                                                                                      java.lang.String renditionFilter,
                                                                                                      java.math.BigInteger maxItems,
                                                                                                      java.math.BigInteger skipCount)
      • getACL

        public org.apache.chemistry.opencmis.commons.data.Acl getACL​(org.alfresco.service.cmr.repository.NodeRef nodeRef,
                                                                     boolean onlyBasicPermissions)
      • applyACL

        public void applyACL​(org.alfresco.service.cmr.repository.NodeRef nodeRef,
                             org.alfresco.opencmis.dictionary.TypeDefinitionWrapper type,
                             org.apache.chemistry.opencmis.commons.data.Acl addAces,
                             org.apache.chemistry.opencmis.commons.data.Acl removeAces)
        Applies the given ACLs.
      • excludeInheritedAces

        protected org.apache.chemistry.opencmis.commons.data.Acl excludeInheritedAces​(org.alfresco.service.cmr.repository.NodeRef nodeRef,
                                                                                      org.apache.chemistry.opencmis.commons.data.Acl acl)
        Filter acl to ignore inherited ACEs
        Parameters:
        nodeRef - NodeRef
        acl - Acl
        Returns:
        Acl
      • applyACL

        public void applyACL​(org.alfresco.service.cmr.repository.NodeRef nodeRef,
                             org.alfresco.opencmis.dictionary.TypeDefinitionWrapper type,
                             org.apache.chemistry.opencmis.commons.data.Acl aces)
        Sets the given ACL.
      • applyPolicies

        public void applyPolicies​(org.alfresco.service.cmr.repository.NodeRef nodeRef,
                                  org.alfresco.opencmis.dictionary.TypeDefinitionWrapper type,
                                  java.util.List<java.lang.String> policies)
      • query

        public org.apache.chemistry.opencmis.commons.data.ObjectList query​(java.lang.String statement,
                                                                           java.lang.Boolean includeAllowableActions,
                                                                           org.apache.chemistry.opencmis.commons.enums.IncludeRelationships includeRelationships,
                                                                           java.lang.String renditionFilter,
                                                                           java.math.BigInteger maxItems,
                                                                           java.math.BigInteger skipCount)
      • setProperties

        public void setProperties​(org.alfresco.service.cmr.repository.NodeRef nodeRef,
                                  org.alfresco.opencmis.dictionary.TypeDefinitionWrapper type,
                                  org.apache.chemistry.opencmis.commons.data.Properties properties,
                                  java.lang.String... exclude)
        Sets property values.
      • addSecondaryTypes

        public void addSecondaryTypes​(org.alfresco.service.cmr.repository.NodeRef nodeRef,
                                      java.util.List<java.lang.String> secondaryTypes)
      • removeSecondaryTypes

        public void removeSecondaryTypes​(org.alfresco.service.cmr.repository.NodeRef nodeRef,
                                         java.util.List<java.lang.String> secondaryTypes)
      • setProperty

        public void setProperty​(org.alfresco.service.cmr.repository.NodeRef nodeRef,
                                org.alfresco.opencmis.dictionary.TypeDefinitionWrapper type,
                                java.lang.String propertyId,
                                java.io.Serializable value)
        Sets a property value.
      • getContentChanges

        public org.apache.chemistry.opencmis.commons.data.ObjectList getContentChanges​(org.apache.chemistry.opencmis.commons.spi.Holder<java.lang.String> changeLogToken,
                                                                                       java.math.BigInteger maxItems)
        Returns content changes.
      • getStringProperty

        public java.lang.String getStringProperty​(org.apache.chemistry.opencmis.commons.data.Properties properties,
                                                  java.lang.String propertyId)
        Returns the value of the given property if it exists and is of the correct type.
      • getIdProperty

        public java.lang.String getIdProperty​(org.apache.chemistry.opencmis.commons.data.Properties properties,
                                              java.lang.String propertyId)
        Returns the value of the given property if it exists and is of the correct type.
      • getNameProperty

        public java.lang.String getNameProperty​(org.apache.chemistry.opencmis.commons.data.Properties properties,
                                                java.lang.String fallback)
      • getObjectTypeIdProperty

        public java.lang.String getObjectTypeIdProperty​(org.apache.chemistry.opencmis.commons.data.Properties properties)
      • getSourceIdProperty

        public java.lang.String getSourceIdProperty​(org.apache.chemistry.opencmis.commons.data.Properties properties)
      • getTargetIdProperty

        public java.lang.String getTargetIdProperty​(org.apache.chemistry.opencmis.commons.data.Properties properties)
      • getRepositoryInfo

        public org.apache.chemistry.opencmis.commons.data.RepositoryInfo getRepositoryInfo​(org.apache.chemistry.opencmis.commons.enums.CmisVersion cmisVersion)
        Returns the repository info object.
      • getRepositoryId

        public java.lang.String getRepositoryId()
        Returns the repository id.