|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--oracle.ifs.beans.LibraryObjectDefinition | +--oracle.ifs.beans.PublicObjectDefinition | +--oracle.ifs.beans.DocumentDefinition
The DocumentDefinition class is used construct a Document object. This subclass of PublicObjectDefinition sets the default ClassObject to "DOCUMENT"
Document maintains Content via a reference to a ContentObject. Thus, to create Content a ContentObjectDefinition is used. This Definition has convenience methods to manipulate a ContentObjectDefinition for you; or you may access the ContentObjectDefinition directly. Note that the only way to modify the attributes of a ContentObject (for non-admin users) is to pass a ContentObjectDefinition to a DocumentDefinition and call update on a Document to which you have access. For that reason, all ContentObjectDefinition methods have been implemented as wrappers in the DocumentDefinition class, thus eliminating the need to deal with ContentObjectDefinition directly.
ContentObjectDefinition
Constructor Summary | |
DocumentDefinition(LibrarySession session)
Constructs a DocumentDefinition explicitly capturing the session. |
Method Summary | |
java.lang.String |
getCharacterSet(LibrarySession sess)
Gets the characterset for this DocumentDefinition. |
java.lang.String |
getContent()
Gets the previously set String of content as set in this definition, or null if no String was specified. |
ContentObjectDefinition |
getContentObjectDefinition()
Gets the currently allocated ContentObjectDefinition, whether set explicitly by setContentObjectDefinition, or allocated by one of the content convenience methods. |
java.lang.String |
getContentPath()
Gets the path of the local file content, or null if no local file was specified. |
java.io.Reader |
getContentReader()
Gets the Reader from which this document will be loaded. |
java.io.InputStream |
getContentStream()
Gets the InputStream from which this document will be loaded. |
Format |
getFormat(LibrarySession sess)
Gets the format for this DocumentDefinition. |
java.lang.String |
getLanguage(LibrarySession sess)
Gets the language for this DocumentDefinition. |
LibraryObject |
getReferringLibraryObject()
Gets the referring LibraryObject through which access is granted to the shared ContentObject or null if no existing ContentObject was specified. |
ContentObject |
getSharedContentObject()
Gets the existing ContentObject with which this Document will share content. |
void |
setCharacterSet(java.lang.String charset)
Sets the characterset of the content. |
void |
setContent(java.lang.String content)
Sets the content of the document that will be loaded/created. |
void |
setContentObjectDefinition(ContentObjectDefinition cod)
Sets the ContentObjectDefinition of the document that will be used to create/update the content object associated with this document. |
void |
setContentPath(java.lang.String contentPath)
Sets the path of the local file from which this document will be loaded/created. |
void |
setContentReader(java.io.Reader contentReader)
Sets the content Reader from which the document will be loaded/created. |
void |
setContentStream(java.io.InputStream contentStream)
Sets the content InputStream from which the document will be loaded/created. |
void |
setEmptyContent()
Creates content of zero length. |
void |
setFormat(Format format)
Sets the format describing the type of content. |
void |
setLanguage(java.lang.String language)
Sets the language of the content. |
void |
setNullContent()
Calling this method specifies that the target document should not have content. |
void |
setSharedContentObject(ContentObject contentObject,
LibraryObject refObj)
Shares the content of an existing object. |
Methods inherited from class oracle.ifs.beans.LibraryObjectDefinition |
clone, getAttribute, getAttributes, getClassObject, getOption, getOptionKeys, removeAttribute, removeOption, setAttribute, setAttribute, setAttributeByUpperCaseName, setAttributes, setClassObject, setOption |
Constructor Detail |
public DocumentDefinition(LibrarySession session) throws IfsException
session
- current LibrarySessionIfsException
- if the operation failsMethod Detail |
public void setFormat(Format format) throws IfsException
format
- the desired Format object.IfsException
- if operation fails.public void setCharacterSet(java.lang.String charset) throws IfsException
charset
- the java name of the desired character setIfsException
- if operation fails.public void setLanguage(java.lang.String language) throws IfsException
language
- the Oracle name of the desired languageIfsException
- if operation fails.public void setContentPath(java.lang.String contentPath) throws IfsException
contentPath
- the file from which content will be loaded/created.IfsException
- if operation fails.public void setContentStream(java.io.InputStream contentStream) throws IfsException
contentStream
- an InputStream from which content will be loaded/created.IfsException
- if operation fails.public void setContentReader(java.io.Reader contentReader) throws IfsException
contentReader
- a Reader from which content will be loaded/created.IfsException
- if operation fails.public void setContent(java.lang.String content) throws IfsException
content
- A String which contains the content which will be loaded
into the new document.IfsException
- if operation fails.public void setEmptyContent() throws IfsException
IfsException
- if operation fails.public void setSharedContentObject(ContentObject contentObject, LibraryObject refObj) throws IfsException
ContentObject
- An existing contentObject to which this new document will refer.refObj
- An existing object through which you are allowed access to the existing
ContentObjectIfsException
- if operation fails.public void setContentObjectDefinition(ContentObjectDefinition cod) throws IfsException
cod
- a ContentObjectDefinition which contains the content
to be loaded into the new document.IfsException
- if operation fails.public ContentObjectDefinition getContentObjectDefinition() throws IfsException
IfsException
- if the operation failspublic void setNullContent() throws IfsException
IfsException
- if operation fails.public Format getFormat(LibrarySession sess) throws IfsException
IfsException
- if the operation failspublic java.lang.String getCharacterSet(LibrarySession sess) throws IfsException
IfsException
- if the operation failspublic java.lang.String getLanguage(LibrarySession sess) throws IfsException
IfsException
- if the operation failspublic java.lang.String getContentPath() throws IfsException
IfsException
- if the operation failspublic java.lang.String getContent() throws IfsException
IfsException
- if the operation failspublic java.io.InputStream getContentStream() throws IfsException
IfsException
- if the operation failspublic java.io.Reader getContentReader() throws IfsException
IfsException
- if the operation failspublic ContentObject getSharedContentObject() throws IfsException
IfsException
- if the operation failspublic LibraryObject getReferringLibraryObject() throws IfsException
IfsException
- if the operation fails
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |