|
Copyright © 2000, 2009, Oracle and/or its affiliates. All rights reserved. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface IVersionManager
Interface to manage content node versions in the content system.
Methods returning an ISortableFilterablePagedList
may perform sorting and filtering. See the documentation
in com.bea.content.paging
, VirtualNode
and Version
.
Note: new methods may be added to this interface periodically -- therefore, this is not a good CM extension point. The recommended extension point is at the Service Provider Interface, in package com.bea.content.spi
Method Summary | |
---|---|
void |
checkIn(ContentContext context,
ID nodeId,
VersionableContent content)
Checks in the the specified version of the node with the specified id. |
JobResult |
checkIn(ContentContext context,
List<ID> nodeIds,
String description,
int endStatus)
CheckIn a group of nodes with the given end status. |
VirtualNode |
checkOut(ContentContext context,
ID nodeId,
String version)
Check out the specified version of a content node. |
JobResult |
checkOut(ContentContext context,
List<ID> nodeIds)
CheckOut a list of nodes. |
ISortableFilterablePagedList<VirtualNode> |
getCheckedOutNodes(ContentContext context)
Return all the checked-out nodes for the user. |
Version |
getLatestPublishedVersion(ContentContext context,
ID nodeId)
Return the latest published version for the given node. |
VirtualNode |
getNode(ContentContext context,
ID nodeId)
Get the VirtualNode representing the Node. |
ISortableFilterablePagedList<VirtualNode> |
getOnlyAssignedNodes(ContentContext context)
Return all the assigned nodes for the user. |
InputStream |
getStream(ContentContext context,
ID nodeId,
ID versionedPropertyId)
Gets the property bytes of a given version. |
Version |
getVersion(ContentContext context,
ID nodeId,
String versionName)
Get the specified version for a given node. |
ISortableFilterablePagedList<Version> |
getVersions(ContentContext context,
ID nodeId)
Returns all the versions for a given node. |
ISortableFilterablePagedList<VirtualNode> |
getWorkingNodes(ContentContext context)
Return all the working nodes for the user. |
boolean |
isCheckedOut(ContentContext context,
ID nodeId)
Convenience method to help determine whether a node is checked out or not. |
void |
revert(ContentContext context,
ID nodeId)
Reverts a given checked out node. |
void |
save(ContentContext context,
ID nodeId,
VersionableContent versionableContent)
Updates the current version of the node with the specified data. |
ISortableFilterablePagedList<Version> |
search(ContentContext context,
Search search)
Perform a meta-data search on the versioning system |
Method Detail |
---|
VirtualNode getNode(ContentContext context, ID nodeId) throws AuthorizationException, NoSuchNodeException, RepositoryException
context
- The content context object which contains the user profile information.nodeId
- The id of the node to get.
AuthorizationException
- Thrown if user is not authorized to perform action.
NoSuchNodeException
- Thrown if the node does not exist.
RepositoryException
- Thrown if an error occurs during this operation.VirtualNode checkOut(ContentContext context, ID nodeId, String version) throws AuthorizationException, NoSuchNodeException, RepositoryException
If the user does not have UPDATE privileges on the node, this operation will be disallowed.
A node can only be checked once. Multiple checkouts of a node is not allowed.
With the returned VirtualNode, the user can retrieve the current version and perform updates on it and either save it, then check it in, or simply check it in. A new version, based on the changes to the checked out one, will be created upon checkin.
context
- The content context object which contains the user profile information.nodeId
- The id of the node to check outversion
- The name of the version to be checked out, null if the latest version is desired.
AuthorizationException
- Thrown if user is not authorized to perform action.
NoSuchNodeException
- Thrown if the node does not exist.
RepositoryException
- Thrown if an error occurs during this operation.JobResult checkOut(ContentContext context, List<ID> nodeIds) throws AuthorizationException, NoSuchNodeException, RepositoryException
context
- The content context object which contains the user profile information.nodeIds
- The list of node ids to be checked out.
AuthorizationException
NoSuchNodeException
RepositoryException
void checkIn(ContentContext context, ID nodeId, VersionableContent content) throws AuthorizationException, NoSuchNodeException, RepositoryException
context
- The content context object which contains the user profile information.nodeId
- The id of the node being checked in.content
- The content to be checked in. If null, the latest version will be checked in.
AuthorizationException
- Thrown if user is not authorized to perform action.
NoSuchNodeException
- Thrown if the node does not exist.
RepositoryException
- Thrown if an error occurs during this operation.JobResult checkIn(ContentContext context, List<ID> nodeIds, String description, int endStatus) throws RepositoryException
context
- The ContentContext objectnodeIds
- The list of node id objectsdescription
- The description for the changesendStatus
- The new checkedIn status of the nodes.
RepositoryException
- if there's an error in checking in the nodesVersion getVersion(ContentContext context, ID nodeId, String versionName) throws AuthorizationException, NoSuchNodeException, RepositoryException
context
- The content context object which contains the user profile information.nodeId
- The id of the node.versionName
- The version to be retrieved.
AuthorizationException
- Thrown if user is not authorized to perform action.
NoSuchNodeException
- Thrown if the node does not exist.
RepositoryException
- Thrown if an error occurs during this operation.ISortableFilterablePagedList<Version> getVersions(ContentContext context, ID nodeId) throws AuthorizationException, NoSuchNodeException, RepositoryException
context
- The content context object which contains the user profile information.nodeId
- The id of the node.
AuthorizationException
- Thrown if user is not authorized to perform action.
NoSuchNodeException
- Thrown if the node does not exist.
RepositoryException
- Thrown if an error occurs during this operation.Version getLatestPublishedVersion(ContentContext context, ID nodeId) throws AuthorizationException, NoSuchNodeException, RepositoryException
context
- The content context object which contains the user profile information.nodeId
- The id of the node.
AuthorizationException
- Thrown if user is not authorized to perform action.
NoSuchNodeException
- Thrown if the node or the virtual node does not exist.
RepositoryException
- Thrown if an error occurs during this operation.ISortableFilterablePagedList<VirtualNode> getWorkingNodes(ContentContext context) throws RepositoryException
context
- The content context object which contains the user profile information.
RepositoryException
- Thrown if an error occurs during this operation.ISortableFilterablePagedList<VirtualNode> getCheckedOutNodes(ContentContext context) throws RepositoryException
context
- The content context object which contains the user profile information.
RepositoryException
- Thrown if an error occurs during this operation.ISortableFilterablePagedList<VirtualNode> getOnlyAssignedNodes(ContentContext context) throws RepositoryException
context
- The content context object which contains the user profile information.
RepositoryException
- Thrown if an error occurs during this operation.void revert(ContentContext context, ID nodeId) throws AuthorizationException, NoSuchNodeException, RepositoryException
context
- The content context object which contains the user profile information.nodeId
- The id of the node.
AuthorizationException
- Thrown if user is not authorized to perform action.
NoSuchNodeException
- Thrown if the node does not exist.
RepositoryException
- Thrown if an error occurs during this operation.boolean isCheckedOut(ContentContext context, ID nodeId) throws RepositoryException
context
- The content context object which contains the user profile information.nodeId
- The id of the node.
RepositoryException
- Thrown if an error occurs during this operation.InputStream getStream(ContentContext context, ID nodeId, ID versionedPropertyId) throws AuthorizationException, NoSuchPropertyException, RepositoryException
context
- The content context object which contains the user profile information.nodeId
- The id of the node.versionedPropertyId
- The ID of the versioned property. ID should contain a valid repositoryName and a UID.
AuthorizationException
- Thrown if user is not authorized to perform action.
NoSuchPropertyException
- Thrown if the property does not exist.
RepositoryException
- Thrown if an error occurs during this operation.void save(ContentContext context, ID nodeId, VersionableContent versionableContent) throws AuthorizationException, RepositoryException
context
- The content context object which contains the user profile information.nodeId
- The id of the node.versionableContent
- The data to save.
AuthorizationException
- Thrown if user is not authorized to perform action.
RepositoryException
- If the node is not checked out by the user, or if the repository
is non library service enabled, or if any other error occurs.ISortableFilterablePagedList<Version> search(ContentContext context, Search search) throws RepositoryException
context
- The content contextsearch
- The search object containing the query criteria
RepositoryException
- Thrown if the search fails.
|
Copyright © 2000, 2009, Oracle and/or its affiliates. All rights reserved. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |