org.apache.chemistry.opencmis.inmemory.storedobj.api
Interface Content

All Known Subinterfaces:
Document, DocumentVersion
All Known Implementing Classes:
DocumentImpl, DocumentVersionImpl

public interface Content


Method Summary
 ContentStream getContent(long offset, long length)
          retrieve the content of a document
 boolean hasContent()
          return true if this object has content or false if there is no content attached.
 void setContent(ContentStream content, boolean mustPersist)
          Assign content do a document.
 

Method Detail

hasContent

boolean hasContent()
return true if this object has content or false if there is no content attached.

Returns:

getContent

ContentStream getContent(long offset,
                         long length)
retrieve the content of a document

Returns:
object containing mime-type, length and a stream with content

setContent

void setContent(ContentStream content,
                boolean mustPersist)
Assign content do a document. Existing content gets overwritten. The document is not yet persisted in the new state.

Parameters:
content - content to be assigned to the document.
mustPersist - persist document (set to false if content is set during creation of a document)


Copyright © 2009-2011 The Apache Software Foundation. All Rights Reserved.