|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface Content
A Content object represents a Content item in the WCM
repository. Each Content object is based on an
AuthoringTemplate, which defines its base properties and
attributes (such as Workflow, security etc.)
Content objects can be created and saved through the API,
and existing ones can be retrieved to be edited and saved. However, since
Content objects are based on an AuthoringTemplate
and these cannot be created through the API, templates must already exist
in the WCM system where the Content object is to be created.
Content objects can contain components that are defined in
the AuthoringTemplate which do not exist in the component
library (ie. they exist only on the Content item itself).
These components are referred to as 'content components'. New content
components cannot be added to a Content object through the
API - only ones that are defined on the template may be manipulated.
The Content interface also provides methods to access the item's
workflow properties. This includes moving the item to the next
stage in the workflow, creating a draft, checking its published/expired
status etc.
| Method Summary | |
|---|---|
void |
addCategoryIds(DocumentId[] categoryIds)
Add categories to this content. |
Content |
cancelDraft()
Deprecated. use cancelDraftDocument() instead. |
Content |
createDraft()
Deprecated. use createDraftDocument() instead. |
DocumentId |
getAuthoringTemplateID()
Returns the ID of the AuthoringTemplate that was used to
create this Content document. |
DocumentId[] |
getCategoryIds()
Return array of IDs for the categories associated with this content. |
DocumentId |
getDirectParent()
Return the parent DocumentId of this content. |
java.lang.String[] |
getKeywords()
Returns an array of keywords associated with this content. |
DocumentIdIterator |
getLinkedParents()
Return an iterator of parent DocumentIds this content is linked to. |
DocumentIdIterator |
getParents()
Returns an iterator of the parent DocumentIds of this content. |
void |
removeCategoryIds(DocumentId[] categoryIds)
Remove categories from this content. |
void |
setAuthoringTemplateID(DocumentId authoringTemplateID)
Sets the authoring template associated with this content |
void |
setKeywords(java.lang.String[] keywords)
Sets the keywords for this Content document. |
| Methods inherited from interface com.ibm.workplace.wcm.api.ContentComponentContainer |
|---|
addComponent, componentIterator, createComponent, getComponent, getComponentByReference, getComponentNames, hasComponent, removeComponent, setComponent |
| Methods inherited from interface com.ibm.workplace.wcm.api.WorkflowedDocument |
|---|
addAdditionalViewers, addApprovers, cancelDraftDocument, createDraftDocument, decline, getAdditionalViewers, getCurrentApprovers, getEffectiveDate, getExpiryDate, getGeneralDateOne, getGeneralDateTwo, getWorkflowId, getWorkflowStageId, hasApproverAccess, hasApproverAccess, hasDraft, isDraft, isExpired, isPublished, nextWorkflowStage, removeAdditionalViewers, removeApprovers, restartWorkflow, setEffectiveDate, setExpiryDate, setGeneralDateOne, setGeneralDateTwo, setWorkflowId |
| Method Detail |
|---|
DocumentId[] getCategoryIds()
void addCategoryIds(DocumentId[] categoryIds)
categoryIds - the array of category IDs to addvoid removeCategoryIds(DocumentId[] categoryIds)
categoryIds - the array of category IDs to remove
DocumentId getAuthoringTemplateID()
throws AuthorizationException,
PropertyRetrievalException
AuthoringTemplate that was used to
create this Content document.
AuthoringTemplate
AuthorizationException - if the user does not have access to the template
PropertyRetrievalException - if an error occurred while retrieving the template
void setAuthoringTemplateID(DocumentId authoringTemplateID)
throws IllegalDocumentTypeException
Note: This method updates the authoring template reference only and does not change the elements on the content to match the authoring template, this must be done manually via the add/update/remove component methods.
authoringTemplateID - The ID of the authoring template to associate with this content. Can not be null.
IllegalDocumentTypeException - If the supplied ID is not to an authoring templatejava.lang.String[] getKeywords()
void setKeywords(java.lang.String[] keywords)
Content document. Duplicate
keywords will be removed. Keywords will not be added if this content
does not have a profile.
keywords - the array of keywordsDocumentIdIterator getParents()
DocumentIds of this content.
The parent of a content is the site area it belongs to. If
this content is linked to additional site areas, the links are listed after the
direct parent.
This method will only return DocumentIds of parents
the user has access to.
DocumentId of this contentDocumentId getDirectParent()
DocumentId of this content.
The parent of a content is the site area it belongs to.
SiteArea of this content
DocumentIdIterator getLinkedParents()
throws DocumentRetrievalException
DocumentIds this content is linked to.
DocumentId this content is linked to.
DocumentRetrievalException - if there was a problem retrieving the linked parents.
Content createDraft()
throws AuthorizationException,
OperationFailedException
createDraftDocument() instead.
NOTE: Creating a draft saves the original, so any changes already made to the original before a draft is created will be seen in both documents.
NOTE: You do not need to save the new draft after it is created, unless you have made changes to the draft document after creating the draft.
AuthorizationException - if the user does not have the appropriate
access permission
OperationFailedException - if this content is not workflowable or
an error occurred while creating the draft
Content cancelDraft()
throws AuthorizationException,
OperationFailedException
cancelDraftDocument() instead.
NOTE: This method may be performed on either the draft or the published content.
AuthorizationException - if the user does not have the appropriate
access permission
OperationFailedException - if this content is not workflowable or
an error occurred while cancelling the draft
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||