Class NuxeoDocument

  • All Implemented Interfaces:
    org.apache.chemistry.opencmis.client.api.CmisObject, org.apache.chemistry.opencmis.client.api.CmisObjectProperties, org.apache.chemistry.opencmis.client.api.Document, org.apache.chemistry.opencmis.client.api.DocumentProperties, org.apache.chemistry.opencmis.client.api.FileableCmisObject, org.apache.chemistry.opencmis.client.api.ObjectId

    public class NuxeoDocument
    extends NuxeoFileableObject
    implements org.apache.chemistry.opencmis.client.api.Document
    Live local CMIS Document, which is backed by a Nuxeo document.
    • Constructor Detail

      • NuxeoDocument

        public NuxeoDocument​(NuxeoSession session,
                             NuxeoObjectData data,
                             org.apache.chemistry.opencmis.client.api.ObjectType type,
                             List<org.apache.chemistry.opencmis.client.api.SecondaryType> secondaryTypes)
    • Method Detail

      • getDocumentType

        public org.apache.chemistry.opencmis.client.api.DocumentType getDocumentType()
        Specified by:
        getDocumentType in interface org.apache.chemistry.opencmis.client.api.Document
      • cancelCheckOut

        public void cancelCheckOut()
        Specified by:
        cancelCheckOut in interface org.apache.chemistry.opencmis.client.api.Document
      • checkIn

        public org.apache.chemistry.opencmis.client.api.ObjectId checkIn​(boolean major,
                                                                         Map<String,​?> properties,
                                                                         org.apache.chemistry.opencmis.commons.data.ContentStream contentStream,
                                                                         String checkinComment)
        Specified by:
        checkIn in interface org.apache.chemistry.opencmis.client.api.Document
      • checkIn

        public org.apache.chemistry.opencmis.client.api.ObjectId checkIn​(boolean major,
                                                                         Map<String,​?> properties,
                                                                         org.apache.chemistry.opencmis.commons.data.ContentStream contentStream,
                                                                         String checkinComment,
                                                                         List<org.apache.chemistry.opencmis.client.api.Policy> policies,
                                                                         List<org.apache.chemistry.opencmis.commons.data.Ace> addAces,
                                                                         List<org.apache.chemistry.opencmis.commons.data.Ace> removeAces)
        Specified by:
        checkIn in interface org.apache.chemistry.opencmis.client.api.Document
      • checkOut

        public org.apache.chemistry.opencmis.client.api.ObjectId checkOut()
        Specified by:
        checkOut in interface org.apache.chemistry.opencmis.client.api.Document
      • copy

        public NuxeoDocument copy​(org.apache.chemistry.opencmis.client.api.ObjectId target)
        Specified by:
        copy in interface org.apache.chemistry.opencmis.client.api.Document
      • copy

        public NuxeoDocument copy​(org.apache.chemistry.opencmis.client.api.ObjectId target,
                                  Map<String,​?> properties,
                                  org.apache.chemistry.opencmis.commons.enums.VersioningState versioningState,
                                  List<org.apache.chemistry.opencmis.client.api.Policy> policies,
                                  List<org.apache.chemistry.opencmis.commons.data.Ace> addACEs,
                                  List<org.apache.chemistry.opencmis.commons.data.Ace> removeACEs,
                                  org.apache.chemistry.opencmis.client.api.OperationContext context)
        Specified by:
        copy in interface org.apache.chemistry.opencmis.client.api.Document
      • deleteAllVersions

        public void deleteAllVersions()
        Specified by:
        deleteAllVersions in interface org.apache.chemistry.opencmis.client.api.Document
      • deleteContentStream

        public NuxeoDocument deleteContentStream()
        Specified by:
        deleteContentStream in interface org.apache.chemistry.opencmis.client.api.Document
      • deleteContentStream

        public org.apache.chemistry.opencmis.client.api.ObjectId deleteContentStream​(boolean refresh)
        Specified by:
        deleteContentStream in interface org.apache.chemistry.opencmis.client.api.Document
      • getAllVersions

        public List<org.apache.chemistry.opencmis.client.api.Document> getAllVersions()
        Specified by:
        getAllVersions in interface org.apache.chemistry.opencmis.client.api.Document
      • getAllVersions

        public List<org.apache.chemistry.opencmis.client.api.Document> getAllVersions​(org.apache.chemistry.opencmis.client.api.OperationContext context)
        Specified by:
        getAllVersions in interface org.apache.chemistry.opencmis.client.api.Document
      • getCheckinComment

        public String getCheckinComment()
        Specified by:
        getCheckinComment in interface org.apache.chemistry.opencmis.client.api.DocumentProperties
      • getContentStream

        public org.apache.chemistry.opencmis.commons.data.ContentStream getContentStream()
        Specified by:
        getContentStream in interface org.apache.chemistry.opencmis.client.api.Document
      • getContentStream

        public org.apache.chemistry.opencmis.commons.data.ContentStream getContentStream​(String streamId)
        Specified by:
        getContentStream in interface org.apache.chemistry.opencmis.client.api.Document
      • getContentStream

        public org.apache.chemistry.opencmis.commons.data.ContentStream getContentStream​(BigInteger offset,
                                                                                         BigInteger length)
        Specified by:
        getContentStream in interface org.apache.chemistry.opencmis.client.api.Document
      • getContentStream

        public org.apache.chemistry.opencmis.commons.data.ContentStream getContentStream​(String streamId,
                                                                                         BigInteger offset,
                                                                                         BigInteger length)
        Specified by:
        getContentStream in interface org.apache.chemistry.opencmis.client.api.Document
      • getContentStreamFileName

        public String getContentStreamFileName()
        Specified by:
        getContentStreamFileName in interface org.apache.chemistry.opencmis.client.api.DocumentProperties
      • getContentStreamId

        public String getContentStreamId()
        Specified by:
        getContentStreamId in interface org.apache.chemistry.opencmis.client.api.DocumentProperties
      • getContentStreamLength

        public long getContentStreamLength()
        Specified by:
        getContentStreamLength in interface org.apache.chemistry.opencmis.client.api.DocumentProperties
      • getContentStreamMimeType

        public String getContentStreamMimeType()
        Specified by:
        getContentStreamMimeType in interface org.apache.chemistry.opencmis.client.api.DocumentProperties
      • getObjectOfLatestVersion

        public org.apache.chemistry.opencmis.client.api.Document getObjectOfLatestVersion​(boolean major)
        Specified by:
        getObjectOfLatestVersion in interface org.apache.chemistry.opencmis.client.api.Document
      • getObjectOfLatestVersion

        public org.apache.chemistry.opencmis.client.api.Document getObjectOfLatestVersion​(boolean major,
                                                                                          org.apache.chemistry.opencmis.client.api.OperationContext context)
        Specified by:
        getObjectOfLatestVersion in interface org.apache.chemistry.opencmis.client.api.Document
      • getVersionLabel

        public String getVersionLabel()
        Specified by:
        getVersionLabel in interface org.apache.chemistry.opencmis.client.api.DocumentProperties
      • getVersionSeriesCheckedOutBy

        public String getVersionSeriesCheckedOutBy()
        Specified by:
        getVersionSeriesCheckedOutBy in interface org.apache.chemistry.opencmis.client.api.DocumentProperties
      • getVersionSeriesCheckedOutId

        public String getVersionSeriesCheckedOutId()
        Specified by:
        getVersionSeriesCheckedOutId in interface org.apache.chemistry.opencmis.client.api.DocumentProperties
      • getVersionSeriesId

        public String getVersionSeriesId()
        Specified by:
        getVersionSeriesId in interface org.apache.chemistry.opencmis.client.api.DocumentProperties
      • isImmutable

        public Boolean isImmutable()
        Specified by:
        isImmutable in interface org.apache.chemistry.opencmis.client.api.DocumentProperties
      • isVersionable

        public boolean isVersionable()
        Specified by:
        isVersionable in interface org.apache.chemistry.opencmis.client.api.Document
      • isVersionSeriesPrivateWorkingCopy

        public Boolean isVersionSeriesPrivateWorkingCopy()
        Specified by:
        isVersionSeriesPrivateWorkingCopy in interface org.apache.chemistry.opencmis.client.api.Document
      • isLatestMajorVersion

        public Boolean isLatestMajorVersion()
        Specified by:
        isLatestMajorVersion in interface org.apache.chemistry.opencmis.client.api.DocumentProperties
      • isLatestVersion

        public Boolean isLatestVersion()
        Specified by:
        isLatestVersion in interface org.apache.chemistry.opencmis.client.api.DocumentProperties
      • isMajorVersion

        public Boolean isMajorVersion()
        Specified by:
        isMajorVersion in interface org.apache.chemistry.opencmis.client.api.DocumentProperties
      • isVersionSeriesCheckedOut

        public Boolean isVersionSeriesCheckedOut()
        Specified by:
        isVersionSeriesCheckedOut in interface org.apache.chemistry.opencmis.client.api.DocumentProperties
      • isPrivateWorkingCopy

        public Boolean isPrivateWorkingCopy()
        Specified by:
        isPrivateWorkingCopy in interface org.apache.chemistry.opencmis.client.api.DocumentProperties
      • getLatestAccessibleStateId

        public String getLatestAccessibleStateId()
        Specified by:
        getLatestAccessibleStateId in interface org.apache.chemistry.opencmis.client.api.DocumentProperties
      • setContentStream

        public org.apache.chemistry.opencmis.client.api.Document setContentStream​(org.apache.chemistry.opencmis.commons.data.ContentStream contentStream,
                                                                                  boolean overwrite)
        Specified by:
        setContentStream in interface org.apache.chemistry.opencmis.client.api.Document
      • setContentStream

        public org.apache.chemistry.opencmis.client.api.ObjectId setContentStream​(org.apache.chemistry.opencmis.commons.data.ContentStream contentStream,
                                                                                  boolean overwrite,
                                                                                  boolean refresh)
        Specified by:
        setContentStream in interface org.apache.chemistry.opencmis.client.api.Document
      • appendContentStream

        public org.apache.chemistry.opencmis.client.api.Document appendContentStream​(org.apache.chemistry.opencmis.commons.data.ContentStream contentStream,
                                                                                     boolean isLastChunk)
        Specified by:
        appendContentStream in interface org.apache.chemistry.opencmis.client.api.Document
      • appendContentStream

        public org.apache.chemistry.opencmis.client.api.ObjectId appendContentStream​(org.apache.chemistry.opencmis.commons.data.ContentStream contentStream,
                                                                                     boolean isLastChunk,
                                                                                     boolean refresh)
        Specified by:
        appendContentStream in interface org.apache.chemistry.opencmis.client.api.Document
      • getContentStreamHashes

        public List<org.apache.chemistry.opencmis.commons.data.ContentStreamHash> getContentStreamHashes()
        Specified by:
        getContentStreamHashes in interface org.apache.chemistry.opencmis.client.api.DocumentProperties
      • getContentUrl

        public String getContentUrl()
        Specified by:
        getContentUrl in interface org.apache.chemistry.opencmis.client.api.Document
      • getContentUrl

        public String getContentUrl​(String streamId)
        Specified by:
        getContentUrl in interface org.apache.chemistry.opencmis.client.api.Document
      • createAppendOutputStream

        public OutputStream createAppendOutputStream​(int bufferSize)
        Specified by:
        createAppendOutputStream in interface org.apache.chemistry.opencmis.client.api.Document