|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Document
Interface for the Document object. A document is a file that is stored in the docstore.
Nested Class Summary | |
---|---|
static class |
Document.Property
Enumeration listing document properties |
Field Summary | |
---|---|
static java.lang.String |
copyright
|
Method Summary | |
---|---|
Document |
copyTo(java.lang.String documentPath)
Copies the document to documentPath. |
void |
delete()
Deletes this document. |
AccessControlGroup |
getAccessControlGroup()
Fetches the access control group for this document. |
java.util.Collection<DocumentAuditLog> |
getAuditLog()
Fetches the audit log for this document. |
java.lang.String |
getContent()
Fetches the content of this document object as a String |
java.io.OutputStream |
getContent(java.io.OutputStream content)
Fetches the content of this document as an OutputStream. |
java.io.Reader |
getContentReader()
Fetches the content of the document in a Reader |
java.io.Reader |
getContentReader(CharSet charSet)
Fetches the content of the document in a Reader using the encoding passed as the argument |
java.util.Date |
getLastModifiedTimestamp()
Fetches the date and time at which this document was last modified. |
java.lang.String |
getPath()
Fetches the path of the document in the docstore. |
java.lang.String |
getProperty(Document.Property propertyName)
Fetches the value of the property given by property name |
java.lang.String |
getProperty(java.lang.String propertyName)
Fetches the value of the property given by propertyName |
java.util.Collection<java.lang.String> |
getPropertyNames()
Returns a collection of names of properties of this document. |
java.lang.String |
getRealPath()
Returns the path of the document in the file system, if the document is present in the file system. |
java.lang.String |
getURL()
Fetches the absolute path for the document. |
Document |
moveTo(java.lang.String documentPath)
Moves this document to documentPath. |
void |
setAccessControlGroup(AccessControlGroup accessControlGroup)
Sets the access control group for this document. |
void |
setContent(java.io.InputStream content)
Sets the content of this document from the InputStream. |
void |
setContent(java.lang.String content)
Sets the content of this document. |
void |
setProperty(Document.Property propertyName,
java.lang.String propertyValue)
Sets the value for the property, the property name is specified by propertyName and the value is given by propertyValue. |
void |
setProperty(java.lang.String propertyName,
java.lang.String propertyValue)
Sets the value for the property, the property name is specified by propertyName and the value is given by propertyValue. |
long |
size()
Fetches the size of this document |
Field Detail |
---|
static final java.lang.String copyright
Method Detail |
---|
java.lang.String getContent()
PIMInternalException
- If an internal error occurred.java.io.OutputStream getContent(java.io.OutputStream content)
content
- The OutputStream object to which the content has to be written.
PIMInternalException
- If an internal error occurred.
java.lang.IllegalArgumentException
- If content is null.java.io.Reader getContentReader()
PIMInternalException
- If an internal error occursjava.io.Reader getContentReader(CharSet charSet)
charSet
- The charset to be used for the reader.
PIMInternalException
- If an internal error occurs
java.lang.IllegalArgumentException
- If the encoding is emptyjava.util.Collection<java.lang.String> getPropertyNames()
PIMInternalException
- If an internal error occurred.java.lang.String getProperty(Document.Property propertyName)
propertyName
- The name of the property whose value has to be fetched
PIMInternalException
- If an internal error occurred.
java.lang.IllegalArgumentException
- If propertyName is null.java.lang.String getProperty(java.lang.String propertyName)
propertyName
- The name of the property whose value has to be fetched.
PIMInternalException
- If an internal error occurred.
java.lang.IllegalArgumentException
- If propertyName is null or empty.AccessControlGroup getAccessControlGroup()
PIMInternalException
- If an internal error occurred.
PIMAuthorizationException
- Reserved for future use.java.util.Date getLastModifiedTimestamp()
PIMInternalException
- If an internal error occurred.long size()
PIMInternalException
- If an internal error occurred.java.util.Collection<DocumentAuditLog> getAuditLog()
PIMInternalException
- If an internal error occurred.java.lang.String getPath()
PIMInternalException
- If an internal error occurred.java.lang.String getURL() throws java.io.UnsupportedEncodingException
PIMInternalException
- If an internal error occurred.
java.io.UnsupportedEncodingException
- If the character encoding is not supported.java.lang.String getRealPath()
PIMInternalException
- If an internal error occurred.void setContent(java.lang.String content)
content
- The content for this document
PIMInternalException
- If an internal error occurred.
PIMAuthorizationException
- Reserved for future use.
java.lang.IllegalArgumentException
- If content is null or empty.void setContent(java.io.InputStream content)
content
- An InputStream
PIMInternalException
- If an internal error occurred.
PIMAuthorizationException
- Reserved for future use.
java.lang.IllegalArgumentException
- If content is null.void setProperty(Document.Property propertyName, java.lang.String propertyValue)
propertyName
- The property whose value has to be setpropertyValue
- The value for the property
PIMInternalException
- If an internal error occurred.
PIMAuthorizationException
- Reserved for future use
java.lang.IllegalArgumentException
- If propertyName is null.void setProperty(java.lang.String propertyName, java.lang.String propertyValue)
propertyName
- The property whose value has to be setpropertyValue
- The value for the property
PIMInternalException
- If an internal error occurred.
PIMAuthorizationException
- Reserved for future use.
java.lang.IllegalArgumentException
- If propertyName is null or emptyvoid setAccessControlGroup(AccessControlGroup accessControlGroup)
accessControlGroup
- The access control group for this document
PIMInternalException
- If an internal error occurred.
PIMAuthorizationException
- Reserved for future use.
java.lang.IllegalArgumentException
- If accessControlGroup is null.
java.lang.IllegalStateException
- If the access control group has not been persisted.void delete()
PIMInternalException
- If an internal error occurred.
PIMAuthorizationException
- If the user does not have the equivalent of
Permission.DOCSTORE_DELETE_FILES
Document copyTo(java.lang.String documentPath)
documentPath
- The path to which the document has to be copied.
PIMInternalException
- If an internal error occurred.
PIMAuthorizationException
- Reserved for future use.
java.lang.IllegalArgumentException
- If the documentPath is empty.Document moveTo(java.lang.String documentPath)
documentPath
- The path to which the document has to be moved.
PIMInternalException
- If an internal error occurred.
PIMAuthorizationException
- Reserved for future use.
java.lang.IllegalArgumentException
- If the documentPath is empty.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |