Interface ContentService
- All Superinterfaces:
com.appiancorp.services.ContextSensitiveService
,Service
This interface provides access to the Content service (formerly the Collaboration
service). Whereas previously there were separate services to deal with different
types of content (e.g., FolderService
),
all content can now be manipulated through this interface. The content service comes
with an entirely new API and bean hierarchy, which cannot be used with the old
Collaboration services. Inversely, the old beans cannot be used with the new
Content service.
The methods in this service that check whether a user can act on a content item,
such as canUserView(java.lang.Long, java.lang.String)
, only permit checking whether the user whose context was
used to obtain the service can act on that item. To check whether another user has
a certain role for the item, use getRoleMap(java.lang.Long, java.lang.Boolean)
and check whether the user is
listed for the desired role or is a member of a group in the desired role.
There is also an associated service, the
ContentStatisticsService
, which can be used
to get various statistics on content (such as the number of content items fitting
specific criteria).
Type Masks:
Types in Content are all powers of 2. This means that you can specify a filter of
multiple types by using the bitwise or operator |. For instance, if you want to both
documents and folders, you can set your typemask filter to:
ContentConstants.TYPE_FOLDER | ContentConstants.TYPE_DOCUMENT
Some of these combination filters are already defined as additional type constants
at ContentConstants.TYPE_XXX
To obtain the root IDs for Rules and Document Management hierarchies:
- Rules - Use
getIdByUuid(String)
and passcom.appiancorp.suiteapi.content.ContentConstants.UUID_RULES_ROOT_FOLDER
- Document Management - Use
getIdByUuid(String)
and passcom.appiancorp.suiteapi.content.ContentConstants.UUID_COMMUNITY_ROOT
ServiceLocator
and
ServiceContext
):
ServiceContext sc = ServiceLocator.getAdministratorServiceContext();
ContentService cs = ServiceLocator.getContentService(sc);
Long rulesRootId = cs.getIdByUuid(ContentConstants.UUID_RULES_ROOT_FOLDER);
-
Field Summary
Modifier and TypeFieldDescriptionstatic final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
static final boolean
Fields inherited from interface com.appiancorp.services.ContextSensitiveService
SET_SERVICE_CONTEXT_METHOD_NAME
-
Method Summary
Modifier and TypeMethodDescriptionvoid
activateUserSession
(Long[] memberOfGroups_, Long[] adminOfGroups_, Integer userTypeSysAdmin_) Deprecated.addFavorite
(Long id_) Deprecated.void
addFavoriteForUsers
(Long id, String[] usernames) Deprecated.addFavorites
(Long[] ids_) Deprecated.void
addGroupInRole
(Long id, String role, Long groupId) Add group to content in given role.void
addGroupsInRole
(Long id, String role, Long[] groupId) Add groups to content in given role.void
Deprecated.void
addUserInRole
(Long id_, String role_, String username_) Add user to content in given role.void
addUsersInRole
(Long id, String role, String[] username) Add users to content in given role.adjustCounter
(Long id_, Double value) Adjust a rules based constant (counter) of type integer or double by the given adjustment value.adjustCounter
(Long id_, Integer value) Adjust a rules based constant (counter) of type integer or double by the given adjustment value.Deprecated.Approved[]
Deprecated.String[]
approveUsers
(Long id_, String[] users_) Approve access to the specified content item for a set of users.approveVersion
(Long id_, Integer versionNumber_) Deprecated.Boolean[]
areFavorites
(Content[] contents_) Deprecated.Boolean[]
areFavorites
(Long[] ids_) Deprecated.Long[]
Deprecated.Long[]
Deprecated.Content[]
browse
(Long root, ContentFilter filter) Deprecated.Long[]
browseIds
(Long root, ContentFilter filter) Browse includes: what the user may see via group permissions, including favorites, no personal content items, including advertised content items not visible, but not already in favorites.browsePaging
(Long root, ContentFilter filter, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) Browse includes: what the user may see via group permissions, including favorites, no personal content items, including advertised content items not visible, but not already in favorites.Boolean[]
canAdministrate
(Content[] content) Can current user Administrate?canAdministrate
(Long id) Can current user Administrate?Boolean[]
canAdministrate
(Long[] ids) Can current user Administrate?Boolean[]
Can current user Edit?Can current user Edit?Boolean[]
Can current user Edit?Boolean[]
canGroupAdministrate
(Long[] ids, Long groupId) Can given Group Administrate?canGroupAdministrate
(Long id, Long groupId) Can given Group Administrate?Boolean[]
canGroupEdit
(Long[] ids, Long groupId) Can given Group Edit?canGroupEdit
(Long id, Long groupId) Can given Group Edit?Boolean[]
canGroupView
(Long[] ids, Long groupId) Can given Group View?canGroupView
(Long id, Long groupId) Can given Group View?Boolean[]
canUserAdministrate
(Long[] ids, String username) Can given User Administrate?canUserAdministrate
(Long id, String username) Can given User Administrate?Boolean[]
canUserEdit
(Long[] ids, String username) Can given User Edit?canUserEdit
(Long id, String username) Can given User Edit?Boolean[]
canUserView
(Long[] ids, String username) Can given User View?canUserView
(Long id, String username) Can given User View?Boolean[]
Can current user View?Can current user View?Boolean[]
Can current user View?checkAccess
(Long id_) Returns the current user access to a content item.Integer[]
checkAccess
(Long[] ids_) Returns the current user access to a content items.void
Deprecated.Long[]
Deprecated.void
Deprecated.copy
(CopySource[] source, Long target) This copies Content item from one location to another.This copies Content item from one location to another.This copies Content item from one location to another.Long[]
Creates content.Creates a content object.createApproval
(Content[] contents_, Integer unique_) Attempts to create content, and gets the approval statuses back in anApproval
bean.createApproval
(Content content_, Integer unique_) Attempts to create content, and gets the approval status back in anApproval
bean.createVersion
(Content[] contents_, Integer unique_) Deprecated.createVersion
(Content content_, Integer unique_) Creates a new version of content.deactivate
(Long[] ids_, Boolean deactivateChildren_) Deactivates all versions of the given content items.deactivate
(Long id_, Boolean deactivateChildren_) Deactivates all versions of the given content item.deactivateVersion
(Long id_, Integer versionNumber_, Boolean deactivateChildren_) Deactivates specified version of the given content item.deactivateVersions
(Long id_, Integer[] versionNumbers_, Boolean deactivateChildren_) Deactivates specified version(s) of the given content item.Deletes all versions of the given content item.Deletes all versions of the given content item.deleteContent
(Long[] ids_, Boolean deleteChildren_) Deletes the given content items.This is an 'empty Recycle Bin/Trashcan' method.deleteVersion
(Long id_, Integer versionNumber_, Boolean children_) Deletes specified version(s) of the given content item.deleteVersions
(Long id_, Integer[] versionNumbers_, Boolean children_) Deletes specified version(s) of the given content item.Document[]
Gets a piece of content and log the transaction if logging is enabled.generateSearchIndex
(Timestamp timestamp_) Generates search index text file bodies for: "content".Integer[]
getAccessLevel
(Long[] ids_, int typemask_) Get the Access Level for the current user for a list of content items.Integer[]
getAccessLevel
(Long[] ids_, Integer typemask_) Get the Access Level for the current user for a list of content items.getAccessLevel
(Long id_, int typemask_) Get the Access Level for the current user for a content item.getAccessLevel
(Long id_, Integer typemask_) Get the Access Level for the current user for a content item.Integer[]
getAccessLevelForUser
(Long[] ids_, Integer typemask_, String username_) Get the Access Level for the given user for a list of content items.getAccessLevelForUser
(Long id_, Integer typemask_, String username_) Get the Access Level for the given user for a content item.Long[]
getAdministratable
(Long root, ContentFilter filter) Deprecated.Long[]
getAdministratableByUser
(Long root, ContentFilter filter, String username) Get all active, non-expired ids off the root, where administratable role held by user.getAdministratablePaging
(Long rootId_, ContentFilter filter_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) Get Administratable Content objects paging.Members of this group will be considered administrators for all content (appadmins).Content[]
getAdvertisedChildren
(Long containerId_, ContentFilter filter_, Integer modifiers_) Deprecated.Long[]
getAdvertisedChildrenIds
(Long containerId_, ContentFilter filter_, Integer modifiers_) getAdvertisedChildrenPaging
(Long containerId_, ContentFilter filter_, Integer modifiers_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) Content[]
getAllChildren
(Long containerId_, ContentFilter filter_, Integer modifiers_) Deprecated.Long[]
getAllChildrenAndVersionIds
(Long containerId_, ContentFilter filter_) Get ids of all versions of all children in a given container.Content[]
getAllChildrenAndVersions
(Long containerId_, ContentFilter filter_) Deprecated.getAllChildrenAndVersionsPaging
(Long containerId_, ContentFilter filter_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) Get all versions of all children in a given container.Long[]
getAllChildrenIds
(Long containerId_, ContentFilter filter_, Integer modifiers_) Returns all descendant ids in a recursive descent from root.getAllChildrenPaging
(Long containerId_, ContentFilter filter_, Integer modifiers_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) Returns all descendants in a recursive descent from root.Long[]
getAllVersionIds
(Long id_) Gets the IDs of all of the versions of a particular versioned content item.Content[]
getAllVersions
(Long id_) Deprecated.getAllVersionsPaging
(Long id_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) Gets all of the versions of a particular versioned content item.Get the application name (in this case, "Appian Collaboration").Gets the content at the specified path relative to the given root.Content[]
getChildren
(Long containerId_, ContentFilter filter_, Integer modifiers_) Deprecated.Long[]
getChildrenIds
(Long containerId_, ContentFilter filter_, Integer modifiers_) Returns the ids of the children of a container.getChildrenPaging
(Long containerId_, ContentFilter filter_, Integer modifiers_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) Returns the children of a container.Integer[]
getChildrenTypes
(Content[] containers_) Returns typemasks of all children types found within each container.getChildrenTypes
(Long containerId_) Returns a typemask of all children types found within a container.Integer[]
getChildrenTypes
(Long[] containerIds_) Returns typemasks of all children types found within each container.Integer[]
getChildrenTypesOfType
(Long[] containerIds_, Integer typemask_) Returns typemasks of all children types found within each container.getChildrenTypesOfType
(Long containerId_, Integer typemask_) Returns a typemask of all children types found within a container.getContent
(Long id_) Deprecated.usegetVersion(Long, Integer)
insteadContent[]
getContent
(Long[] ids_) Deprecated.Long[]
getContentIdsWhereViewable
(Long[] ids_) Gets the specified content IDs where viewable, rather than giving an error that the content is not viewable.getContentList
(Long[] ids_, Integer typemask_) Does the same thing asgetContent(Long[])
, except it takes a type mask and returns error codes instead of throwing exceptions.getContentPaging
(Long[] ids_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) Deprecated.Content[]
getContentTree
(Long rootContentId_, Integer maxDepth_, Integer typemask_, Integer accessLevel_) Deprecated.getContentTreePaging
(Long rootContentId_, Integer maxDepth_, Integer typemask_, Integer accessLevel_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) Get the content tree, and page the results.getContentUrl
(long contentId) Gets the URL for a given content.Content[]
getContentWhereViewable
(Long[] ids_) Deprecated.getContentWhereViewablePaging
(Long[] ids_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) Gets the specified content where viewable, rather than giving an error that the content is not viewable.Long[]
getDatatypeIds
(Long... contentIds) Gets the datatype ids that content ids map to.getDocumentInputStream
(long id_) Opens a stream to a Document allowing for the caller to read its contents.getDocumentInputStream
(long[] ids_) Opens streams to multiple Documents allowing the caller to read their contents.Gets the download log type.Long[]
getEditable
(Long root, ContentFilter filter) Deprecated.Long[]
getEditableByUser
(Long root_, ContentFilter filter_, String username_) Get all active, non-expired ids off the root, where editor role held by user.getEditablePaging
(Long rootId_, ContentFilter filter_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) Get Editable Content objects paging.Content[]
getExpired
(Long root_, Integer days_, ContentFilter filter_) Deprecated.Long[]
getExpiredIds
(Long root_, Integer days_, ContentFilter filter_) Deprecated.getExpiredPaging
(Long root_, Integer days_, ContentFilter filter_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) Deprecated.getExternalFilename
(Long id_) Gets the external filename (the name that the file would be saved as by the client, or the name within a .zip file) of a document.String[]
getExternalFilenames
(Long[] ids_) Gets the external filenames (the name that the file would be saved as by the client, or the name within a .zip file) of a set of document.Long[]
getFavoriteByRootIds
(Long rootId_, ContentFilter filter_, Boolean includeExpiredContent_) Deprecated.Content[]
getFavoritesByRoot
(Long rootId_, ContentFilter filter_, Boolean includeExpiredContent_) Deprecated.getFavoritesByRootPaging
(Long rootId_, ContentFilter filter_, Boolean includeExpiredContent_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) Deprecated.getIdByPath
(Long root_, String path_) Gets the ID of the content at the specified path relative to the given root.getIdByUuid
(String uuid) Gets a content id by UUID.Long[]
getIdsByUuid
(String[] uuids) Gets content ids by UUID.Long[]
getImageIdsForUsers
(String[] usernames) Get the image document ids for the given users.Content[]
getInactive
(Long root_, ContentFilter filter_) Deprecated.Long[]
getInactiveIds
(Long root_, ContentFilter filter_) Gets all inactive content ids within the specified root.Long[]
getInactiveIdsNoSystem
(Long root_, ContentFilter filter_) Gets all inactive content ids within the specified root but filters out system ids.getInactivePaging
(Long root_, ContentFilter filter_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) Gets all inactive content items within the specified root.getInternalFilename
(Long id_) Deprecated.since 23.2.String[]
getInternalFilenames
(Long[] ids_) Deprecated.since 23.2.Long[]
getLinkedBy
(Long id_) Returns the ids of those content items that link to the given id.Long[]
getLinkIds
(Long id_) Returns all link ids to a given content id.Long[]
getLinkIdsOfType
(Long id_, Integer typemask_) Returns all links to a given content id.Content[]
Returns all links to a given content id.Content[]
getLinksOfType
(Long id_, Integer typemask_) Returns all links to a given content id.Content[]
Deprecated.usegetMyInactivePaging(int, int, Integer, Integer)
insteadLong[]
This retrieves the content ids in the 'Recycle Bin/Trashcan' of the current user.getMyInactivePaging
(int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) This retrieves the content items in the 'Recycle Bin/Trashcan' of the current user.Integer[]
getNumberOfChildren
(Long[] containerIds_, Integer typemask_) This returns the number of children matching the typemask for each root id specified.getNumberOfChildren
(Long containerId_, Integer typemask_) This returns the number of children matching the typemask.This returns the count of the requests returned by getRequests.getOpaqueContentUri
(long contentId) Gets the opaque id for a given content.Gets the parent of the specified content.getParentId
(Long id_) Gets the parents of the specified content items.Long[]
getParentIds
(Long[] ids_) Gets the IDs of the parents of the specified content items.Content[]
getParents
(Long[] ids_) Gets the parents of the specified content items.Content[]
getParentsFromRoot
(Long id_, Integer typemask_) This returns all of direct ancestors of a node, starting with the root and tracing down to the node's parent.Long[]
getParentsFromRootIds
(Long id_, Integer typemask_) This return ids of all of direct ancestors of a node, starting with the root and tracing down to the node's parent.Content[]
getParentsToRoot
(Long id_, Integer typemask_) This returns all of direct ancestors of a node, starting with the node's parent and tracing up to the root.Long[]
getParentsToRootIds
(Long id_, Integer typemask_) This returns ids of all of direct ancestors of a node, starting with the node's parent and tracing up to the root.Content[]
getPending
(Long id, ContentFilter filter) Deprecated.getPendingPaging
(Long id, ContentFilter filter, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) Deprecated.getPendingReview
(Long id_) Deprecated.Integer[]
getPendingReviews
(Long[] ids_) Deprecated.String[]
getPendingUsers
(Long id_) This accumulates all users pending for the given content item, returning only the unique names.Get your Personal content item.Content[]
getPersonalAndTeams
(ContentFilter filter_) Deprecated.Long[]
getPersonalAndTeamsIds
(ContentFilter filter_) Get children of 'Personal and Teams'.getPersonalAndTeamsPaging
(ContentFilter filter_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) Get children of 'Personal and Teams'.Get the id for your Personal content item.Content[]
Once a user requests an action on a Content item that requires approval, that request is stored with the Content item.getRestrictionMap
(Long id_) Deprecated.getRoleMap
(Long id_, Boolean includeAggregate_) Get the role map for a content item.getRoleSet
(Long id_) Get theContentRoleSet
associated with the content with the ID provided.getRoleSetForGroup
(Long groupId_, Long id_) Get theContentRoleSet
associated with the given content for a specific group.getRoleSetForUser
(String username_, Long id_) Deprecated.Requires two sets of credentials.getRoleSets
(Content[] contents_) Get theContentRoleSet
s associated with the given contents.getRoleSets
(Long[] ids_) Get theContentRoleSet
s associated with the given content ids.getRoleSetsForGroup
(Long groupId_, Long[] ids_) Get theContentRoleSet
s associated with the given contents for a specific group.getRoleSetsForUser
(String username_, Long[] ids_) Deprecated.Requires two sets of credentials.getSystemId
(String name_) Deprecated.usegetIdByUuid(String)
instead.Long[]
getSystemIds
(String[] names_) Deprecated.usegetIdsByUuid(String[])
instead.String[]
Deprecated.Long[]
getThumbnailIdsForUsers
(String[] usernames, int size) Get the document ids of the thumbnail images of the given size for the given users.Deprecated.User quotas have been removed.getUserSpaceAvailableForUser
(String username) Deprecated.User quotas have been removed.Deprecated.User quotas have been removed.getVersion
(Long id_, Integer versionNumber_) Gets the specified version of the content.getVersion
(String uuid, Integer versionNumber) Gets the specified version of the content.getVersionId
(Long id_, Integer versionNumber_) Gets the ID of the specified version of the content.getVersionId
(String uuid, Integer versionNumber) Gets the ID of the specified version of the content.Long[]
getVersionIds
(Long[] ids_, Integer versionNumber_) Gets the specified version of a bunch of pieces of content.Long[]
getVersionIds
(Long id_, Integer[] versionNumbers_) Gets the specified versions of a particular piece of content.Content[]
getVersions
(Long[] ids_, Integer versionNumber_) Deprecated.Content[]
getVersions
(Long id_, Integer[] versionNumbers_) Gets the specified versions of a particular piece of content.getVersionsList
(Long[] ids, Integer versionNumber, Integer typemask) Retrieves the specified version of the content objects identified by the given ids and of the given type.getVersionsPaging
(Long[] ids_, Integer versionNumber_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) Gets the specified version of a bunch of pieces of content.getVersionsPaging
(Long id_, Integer[] versionNumbers_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) Gets the specified versions of a particular piece of content.Long[]
getViewable
(Long root, ContentFilter filter) Deprecated.Long[]
getViewableByUser
(Long root, ContentFilter filter, String username) Get all active, non-expired ids off the root, where view role held by user.getViewablePaging
(Long rootId_, ContentFilter filter_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) Get Viewable Content objects paging.Content[]
getWhatsNew
(Long root_, Integer maxResults_, ContentFilter filter_) Deprecated.Long[]
getWhatsNewIds
(Long root_, Integer maxResults_, ContentFilter filter_) Returns id list of most recently modified content items within the specified root.getWhatsNewPaging
(Long root_, Integer maxResults_, ContentFilter filter_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) Returns list of most recently modified content items within the specified root.hasChildren
(Long containerId_) Checks whether the specified container has children.hasChildrenOfType
(Long containerId_, Integer typemask_) Checks whether the specified container has children of a the specified type(s).hasNoChildren
(Long containerId_) Checks whether the specified container has no children.hasNoChildrenOfType
(Long containerId_, Integer typemask_) Checks whether the specified container has no children of the specified type(s).Boolean[]
haveChildren
(Content[] containers_) Checks whether each of the specified containers has children.Boolean[]
haveChildren
(Long[] containerIds_) Checks whether each of the specified containers has children.Boolean[]
haveChildrenOfType
(Long[] containerIds_, Integer typemask_) Checks whether the specified container has children of a the specified type(s).Boolean[]
haveNoChildren
(Long[] containerIds_) Checks whether each of the specified containers has no children.Boolean[]
haveNoChildrenOfType
(Long[] containerIds_, Integer typemask_) Checks whether each of the specified containers has no children of the specified type(s).Long[]
importContent
(Content[] contents_, Integer unique_) Deprecated.This API is no longer supported and will be removed in the next release.Integer[]
importValidate
(Content[] contents_) Checks the validity of the Content items for import, returning an import status for each.Is administrate privilege restricted?isEditNotRestricted
(Long id_) Is edit privilege restricted?isFavorite
(Long id_) Returns true if content is marked as a favorite for the current user.isViewNotRestricted
(Long id_) Is view privilege restricted?void
Localizes the name, description, and parent name for the given content(s).void
Localizes the name, description, and parent name for the given content(s).void
Localizes the name, description, and parent name for the given content(s).void
Localizes the name, description, and parent name for the given content(s).void
Deprecated.void
Deprecated.void
This moves Content items from one location to another, cutting connection from current parent, setting connection to new parent, updating bytes used in parents.void
This moves a Content item from one location to another, cutting connection from current parent, setting connection to new parent, updating bytes used in parents.void
moveKnowledgeCenter
(Long kcId_, Long communityId_) Move a KC to a community.void
moveKnowledgeCenters
(Long[] kcIds_, Long communityId_) Moves KCs to a community.void
notifyApproved
(Approved... approved) Deprecated.void
notifyGroupDeletion
(Long groupId_) Notify the server that a group was deleted so any new group with the same id will not assume the same permissions.void
notifyGroupsDeletion
(Long[] groupIds_) Notify the server that groups were deleted so any new group with the same id will not assume the same permissions.void
notifyUserCreation
(String userName_) Deprecated.done automatically by UserService.createUservoid
notifyUsersCreation
(String[] userNames_) Deprecated.done automatically by UserService.createUservoid
populateExtensionInfo
(Content[] contents_) Populates the extensionInfo field in the document beans you pass in.void
populateFavorites
(Content[] contents_) Deprecated.void
populateRoleSets
(Content[] contents_) Populates the roleSet field in the content beans you pass in.void
populateTypesOfChildren
(Content[] containers_) Populate the typesOfChildren field in the content beans you pass in.Content[]
queryByRoot
(Long root_, String queryText_, ContentFilter filter_) Deprecated.queryByRootPaging
(Long root_, String queryText_, ContentFilter filter_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) This is more advanced search, accepting special keywords.Long[]
queryIdsByRoot
(Long root_, String queryText_, ContentFilter filter_) This is more advanced search, accepting special keywords.void
reactivate
(Long id_) Reactivates the given content item.void
reactivate
(Long[] ids_) Reactivates the given content items.Deprecated.Approved[]
Deprecated.String[]
rejectUsers
(Long id_, String[] users_) Reject access to the specified content item for a set of users.rejectVersion
(Long id_, Integer versionNumber_) Deprecated.void
removeFavorite
(Long id_) Deprecated.void
removeFavoriteForUsers
(Long id_, String[] username_) Deprecated.void
removeFavorites
(Long[] ids_) Deprecated.void
removeGroupFromRole
(Long id, String role, Long groupId) Remove group from content in given role.void
removeGroupsFromRole
(Long id, String role, Long[] groupId) Remove groups from content in given role.void
removeLinks
(Long id_, Long[] links_) Deprecated.void
removeUserFromRole
(Long id, String role, String username) Remove user from content in given role.void
removeUsersFromRole
(Long id, String role, String[] username) Remove users from content in given role.void
requestAccess
(Long id_) Deprecated.void
requestAccess
(Long[] ids_) Deprecated.void
resetGroupMembership
(Timestamp timestamp_) Deprecated.No longer necessary with credential systemvoid
Deprecated.Content[]
searchByRoot
(Long rootId_, String regex_, ContentFilter filter_) Deprecated.searchByRootPaging
(Long rootId_, String regex_, ContentFilter filter_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) Searches for content from a given root.Long[]
searchIdsByRoot
(Long rootId_, String regex_, ContentFilter filter_) Searches for content from a given root.Long[]
searchIdsWithin
(String regex, Long[] ids_) Search for content within the given containers.Content[]
searchWithin
(String regex, Long[] ids_) Deprecated.searchWithinPaging
(String regex_, Long[] ids_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) Search for content within the given containers.void
setActorsInRoles
(Long id_, String[] users_, String[][] userRoles_, Long[] groups_, String[][] groupRoles_) Set security roles for a content item by users and groups.void
setAdministratorGroup
(Long groupId_) Set the group that will be considered administrators for all content (appadmins).void
Sets the given id as its own root, splitting it from its existing hierarchy.void
setPersonalId
(Long id_) Set the id for your Personal content item.void
setRestrictionMap
(Long id_, RoleMap roleMap_) Deprecated.setRoleMap
(Long id_, ContentRoleMap rolemap_, Boolean contract_) Set the role map for a content item.void
setRoleMapForAllVersions
(Long id_, ContentRoleMap rolemap_, Boolean contract_) Sets the role map for all the versions of a content item.void
Deprecated.usesetAsRoot(Long)
int
setSizeOfDocumentVersion
(Long documentContentId) Deprecated.since 23.2.void
setSystemId
(String name_, Long id_) Deprecated.Usecreate(Content, Integer)
with a pre-populated UUID and the flagContentConstants.VIS_SYSTEM
.void
setSystemIds
(String[] names_, Long[] ids_) Deprecated.Usecreate(Content[], Integer)
with pre-populated UUIDs and the flagContentConstants.VIS_SYSTEM
.void
setUserSpaceAvailable
(String username_, Long bytes_) Deprecated.User quotas have been removed.void
setUserSpaceUsage
(String username_, Long bytesUsed_) Deprecated.User quotas have been removed.suggest
(String query_, int maxItems_, SuggestParam[] params_, Boolean groupResults_) Queries for content and returns a JSON formatted string to be used by autocomplete.suggest
(String query_, int maxItems_, SuggestParam[] params_, Boolean groupResults_, Long[] allowList) Queries for content and returns a JSON formatted string to be used by autocomplete.void
Deprecated.void
Deprecated.Long[]
Deprecated.Long[]
Deprecated.void
updateAllChildrenAndVersionsExpiration
(Long id, Integer expirationDays) Update the expiration days for all children and versions of the given id (including the content with the given id).void
updateAllChildrenAndVersionsVisibility
(Long id, boolean maskType, int bitmask) Update the visibility bitmask for all children and versions of the given id.void
updateFields
(Content[] contents_, Integer[] fields_, Integer unique_) Updates the specified fields of the content items.void
updateFields
(Content content_, Integer[] fields_, Integer unique_) Updates the specified fields of a content item's LATEST version.void
updateUsernames
(String[] oldUsernames_, String[] newUsernames_, long maxExpirationTimeInSeconds_) Deprecated.void
updateVersionFields
(Content content_, Integer versionNumber, Integer[] fields_, Integer unique_) Updates the specified fields of a content item's specific version.Deprecated.since 23.2.uploadDocument
(Document doc, Integer unique) Creates a document and provides an output stream to which the document's content should be written.Gets the type of the content specified.Integer[]
Gets the types of the content specified.validateGroupMembership
(Long[] memberOfGroups_, Long[] adminOfGroups_) Deprecated.No longer necessary with credential systemboolean
validateTypedValues
(TypedValue[] typedValues) Validates given TypedValues.Methods inherited from interface com.appiancorp.services.ContextSensitiveService
setServiceContext
-
Field Details
-
getApplicationName$UPDATES
static final boolean getApplicationName$UPDATES- See Also:
-
generateSearchIndex$UPDATES
static final boolean generateSearchIndex$UPDATES- See Also:
-
setAdministratorGroup$UPDATES
static final boolean setAdministratorGroup$UPDATES- See Also:
-
getAdministratorGroup$UPDATES
static final boolean getAdministratorGroup$UPDATES- See Also:
-
activateUserSession$UPDATES
static final boolean activateUserSession$UPDATES- See Also:
-
validateGroupMembership$UPDATES
static final boolean validateGroupMembership$UPDATES- See Also:
-
resetGroupMembership$UPDATES
static final boolean resetGroupMembership$UPDATES- See Also:
-
notifyUserCreation$UPDATES
static final boolean notifyUserCreation$UPDATES- See Also:
-
notifyUsersCreation$UPDATES
static final boolean notifyUsersCreation$UPDATES- See Also:
-
notifyGroupDeletion$UPDATES
static final boolean notifyGroupDeletion$UPDATES- See Also:
-
notifyGroupsDeletion$UPDATES
static final boolean notifyGroupsDeletion$UPDATES- See Also:
-
setUserSpaceUsage$UPDATES
static final boolean setUserSpaceUsage$UPDATES- See Also:
-
getUserSpaceUsage$UPDATES
static final boolean getUserSpaceUsage$UPDATES- See Also:
-
setUserSpaceAvailable$UPDATES
static final boolean setUserSpaceAvailable$UPDATES- See Also:
-
getUserSpaceAvailable$UPDATES
static final boolean getUserSpaceAvailable$UPDATES- See Also:
-
getUserSpaceAvailableForUser$UPDATES
static final boolean getUserSpaceAvailableForUser$UPDATES- See Also:
-
getImageIdsForUsers$UPDATES
static final boolean getImageIdsForUsers$UPDATES- See Also:
-
getThumbnailIdsForUsers$UPDATES
static final boolean getThumbnailIdsForUsers$UPDATES- See Also:
-
validate$UPDATES
static final boolean validate$UPDATES- See Also:
-
createApproval$UPDATES
static final boolean createApproval$UPDATES- See Also:
-
create$UPDATES
static final boolean create$UPDATES- See Also:
-
createVersion$UPDATES
static final boolean createVersion$UPDATES- See Also:
-
upload$UPDATES
static final boolean upload$UPDATES- See Also:
-
importContent$UPDATES
static final boolean importContent$UPDATES- See Also:
-
importValidate$UPDATES
static final boolean importValidate$UPDATES- See Also:
-
getContent$UPDATES
static final boolean getContent$UPDATES- See Also:
-
getContentList$UPDATES
static final boolean getContentList$UPDATES- See Also:
-
getContentPaging$UPDATES
static final boolean getContentPaging$UPDATES- See Also:
-
getContentTree$UPDATES
static final boolean getContentTree$UPDATES- See Also:
-
getContentTreePaging$UPDATES
static final boolean getContentTreePaging$UPDATES- See Also:
-
getContentWhereViewable$UPDATES
static final boolean getContentWhereViewable$UPDATES- See Also:
-
getContentIdsWhereViewable$UPDATES
static final boolean getContentIdsWhereViewable$UPDATES- See Also:
-
getContentWhereViewablePaging$UPDATES
static final boolean getContentWhereViewablePaging$UPDATES- See Also:
-
getContentUrl$UPDATES
static final boolean getContentUrl$UPDATES- See Also:
-
getOpaqueContentUri$UPDATES
static final boolean getOpaqueContentUri$UPDATES- See Also:
-
getVersion$UPDATES
static final boolean getVersion$UPDATES- See Also:
-
getVersions$UPDATES
static final boolean getVersions$UPDATES- See Also:
-
getVersionsList$UPDATES
static final boolean getVersionsList$UPDATES- See Also:
-
getVersionId$UPDATES
static final boolean getVersionId$UPDATES- See Also:
-
getVersionsPaging$UPDATES
static final boolean getVersionsPaging$UPDATES- See Also:
-
getVersionIds$UPDATES
static final boolean getVersionIds$UPDATES- See Also:
-
getAllVersions$UPDATES
static final boolean getAllVersions$UPDATES- See Also:
-
getAllVersionsPaging$UPDATES
static final boolean getAllVersionsPaging$UPDATES- See Also:
-
getAllVersionIds$UPDATES
static final boolean getAllVersionIds$UPDATES- See Also:
-
download$UPDATES
static final boolean download$UPDATES- See Also:
-
getInternalFilename$UPDATES
static final boolean getInternalFilename$UPDATES- See Also:
-
getInternalFilenames$UPDATES
static final boolean getInternalFilenames$UPDATES- See Also:
-
getExternalFilename$UPDATES
static final boolean getExternalFilename$UPDATES- See Also:
-
getExternalFilenames$UPDATES
static final boolean getExternalFilenames$UPDATES- See Also:
-
getByPath$UPDATES
static final boolean getByPath$UPDATES- See Also:
-
getIdByPath$UPDATES
static final boolean getIdByPath$UPDATES- See Also:
-
getParent$UPDATES
static final boolean getParent$UPDATES- See Also:
-
getParents$UPDATES
static final boolean getParents$UPDATES- See Also:
-
getParentId$UPDATES
static final boolean getParentId$UPDATES- See Also:
-
getParentIds$UPDATES
static final boolean getParentIds$UPDATES- See Also:
-
hasNoChildren$UPDATES
static final boolean hasNoChildren$UPDATES- See Also:
-
haveNoChildren$UPDATES
static final boolean haveNoChildren$UPDATES- See Also:
-
hasNoChildrenOfType$UPDATES
static final boolean hasNoChildrenOfType$UPDATES- See Also:
-
haveNoChildrenOfType$UPDATES
static final boolean haveNoChildrenOfType$UPDATES- See Also:
-
hasChildren$UPDATES
static final boolean hasChildren$UPDATES- See Also:
-
haveChildren$UPDATES
static final boolean haveChildren$UPDATES- See Also:
-
hasChildrenOfType$UPDATES
static final boolean hasChildrenOfType$UPDATES- See Also:
-
haveChildrenOfType$UPDATES
static final boolean haveChildrenOfType$UPDATES- See Also:
-
getChildrenTypesOfType$UPDATES
static final boolean getChildrenTypesOfType$UPDATES- See Also:
-
getChildrenTypes$UPDATES
static final boolean getChildrenTypes$UPDATES- See Also:
-
populateTypesOfChildren$UPDATES
static final boolean populateTypesOfChildren$UPDATES- See Also:
-
getChildren$UPDATES
static final boolean getChildren$UPDATES- See Also:
-
getChildrenIds$UPDATES
static final boolean getChildrenIds$UPDATES- See Also:
-
getChildrenPaging$UPDATES
static final boolean getChildrenPaging$UPDATES- See Also:
-
getAdvertisedChildren$UPDATES
static final boolean getAdvertisedChildren$UPDATES- See Also:
-
getAdvertisedChildrenIds$UPDATES
static final boolean getAdvertisedChildrenIds$UPDATES- See Also:
-
getAdvertisedChildrenPaging$UPDATES
static final boolean getAdvertisedChildrenPaging$UPDATES- See Also:
-
getEditablePaging$UPDATES
static final boolean getEditablePaging$UPDATES- See Also:
-
getAdministratablePaging$UPDATES
static final boolean getAdministratablePaging$UPDATES- See Also:
-
getViewablePaging$UPDATES
static final boolean getViewablePaging$UPDATES- See Also:
-
getAllChildren$UPDATES
static final boolean getAllChildren$UPDATES- See Also:
-
getAllChildrenIds$UPDATES
static final boolean getAllChildrenIds$UPDATES- See Also:
-
getAllChildrenPaging$UPDATES
static final boolean getAllChildrenPaging$UPDATES- See Also:
-
getAllChildrenAndVersions$UPDATES
static final boolean getAllChildrenAndVersions$UPDATES- See Also:
-
getAllChildrenAndVersionIds$UPDATES
static final boolean getAllChildrenAndVersionIds$UPDATES- See Also:
-
getAllChildrenAndVersionsPaging$UPDATES
static final boolean getAllChildrenAndVersionsPaging$UPDATES- See Also:
-
getNumberOfChildren$UPDATES
static final boolean getNumberOfChildren$UPDATES- See Also:
-
getParentsToRoot$UPDATES
static final boolean getParentsToRoot$UPDATES- See Also:
-
getParentsToRootIds$UPDATES
static final boolean getParentsToRootIds$UPDATES- See Also:
-
getParentsFromRoot$UPDATES
static final boolean getParentsFromRoot$UPDATES- See Also:
-
getParentsFromRootIds$UPDATES
static final boolean getParentsFromRootIds$UPDATES- See Also:
-
updateVersionFields$UPDATES
static final boolean updateVersionFields$UPDATES- See Also:
-
updateFields$UPDATES
static final boolean updateFields$UPDATES- See Also:
-
setSizeOfDocumentVersion$UPDATES
static final boolean setSizeOfDocumentVersion$UPDATES- See Also:
-
updateAllChildrenAndVersionsVisibility$UPDATES
static final boolean updateAllChildrenAndVersionsVisibility$UPDATES- See Also:
-
updateAllChildrenAndVersionsExpiration$UPDATES
static final boolean updateAllChildrenAndVersionsExpiration$UPDATES- See Also:
-
move$UPDATES
static final boolean move$UPDATES- See Also:
-
copy$UPDATES
static final boolean copy$UPDATES- See Also:
-
delete$UPDATES
static final boolean delete$UPDATES- See Also:
-
deleteContent$UPDATES
static final boolean deleteContent$UPDATES- See Also:
-
deleteVersion$UPDATES
static final boolean deleteVersion$UPDATES- See Also:
-
deleteVersions$UPDATES
static final boolean deleteVersions$UPDATES- See Also:
-
deactivate$UPDATES
static final boolean deactivate$UPDATES- See Also:
-
deactivateVersion$UPDATES
static final boolean deactivateVersion$UPDATES- See Also:
-
deactivateVersions$UPDATES
static final boolean deactivateVersions$UPDATES- See Also:
-
reactivate$UPDATES
static final boolean reactivate$UPDATES- See Also:
-
getInactive$UPDATES
static final boolean getInactive$UPDATES- See Also:
-
getInactiveIds$UPDATES
static final boolean getInactiveIds$UPDATES- See Also:
-
getInactiveIdsNoSystem$UPDATES
static final boolean getInactiveIdsNoSystem$UPDATES- See Also:
-
getInactivePaging$UPDATES
static final boolean getInactivePaging$UPDATES- See Also:
-
getMyInactiveIds$UPDATES
static final boolean getMyInactiveIds$UPDATES- See Also:
-
getMyInactive$UPDATES
static final boolean getMyInactive$UPDATES- See Also:
-
getMyInactivePaging$UPDATES
static final boolean getMyInactivePaging$UPDATES- See Also:
-
deleteMyInactive$UPDATES
static final boolean deleteMyInactive$UPDATES- See Also:
-
getLinks$UPDATES
static final boolean getLinks$UPDATES- See Also:
-
getLinkIds$UPDATES
static final boolean getLinkIds$UPDATES- See Also:
-
getLinksOfType$UPDATES
static final boolean getLinksOfType$UPDATES- See Also:
-
getLinkIdsOfType$UPDATES
static final boolean getLinkIdsOfType$UPDATES- See Also:
-
addLinks$UPDATES
static final boolean addLinks$UPDATES- See Also:
-
removeLinks$UPDATES
static final boolean removeLinks$UPDATES- See Also:
-
getLinkedBy$UPDATES
static final boolean getLinkedBy$UPDATES- See Also:
-
searchByRoot$UPDATES
static final boolean searchByRoot$UPDATES- See Also:
-
searchIdsByRoot$UPDATES
static final boolean searchIdsByRoot$UPDATES- See Also:
-
searchByRootPaging$UPDATES
static final boolean searchByRootPaging$UPDATES- See Also:
-
searchWithin$UPDATES
static final boolean searchWithin$UPDATES- See Also:
-
searchIdsWithin$UPDATES
static final boolean searchIdsWithin$UPDATES- See Also:
-
searchWithinPaging$UPDATES
static final boolean searchWithinPaging$UPDATES- See Also:
-
queryByRoot$UPDATES
static final boolean queryByRoot$UPDATES- See Also:
-
queryIdsByRoot$UPDATES
static final boolean queryIdsByRoot$UPDATES- See Also:
-
queryByRootPaging$UPDATES
static final boolean queryByRootPaging$UPDATES- See Also:
-
getExpired$UPDATES
static final boolean getExpired$UPDATES- See Also:
-
getExpiredIds$UPDATES
static final boolean getExpiredIds$UPDATES- See Also:
-
getExpiredPaging$UPDATES
static final boolean getExpiredPaging$UPDATES- See Also:
-
unexpire$UPDATES
static final boolean unexpire$UPDATES- See Also:
-
lock$UPDATES
static final boolean lock$UPDATES- See Also:
-
unlock$UPDATES
static final boolean unlock$UPDATES- See Also:
-
breakLock$UPDATES
static final boolean breakLock$UPDATES- See Also:
-
approve$UPDATES
static final boolean approve$UPDATES- See Also:
-
approveVersion$UPDATES
static final boolean approveVersion$UPDATES- See Also:
-
reject$UPDATES
static final boolean reject$UPDATES- See Also:
-
rejectVersion$UPDATES
static final boolean rejectVersion$UPDATES- See Also:
-
notifyApproved$UPDATES
static final boolean notifyApproved$UPDATES- See Also:
-
requestAccess$UPDATES
static final boolean requestAccess$UPDATES- See Also:
-
checkAccess$UPDATES
static final boolean checkAccess$UPDATES- See Also:
-
approveUsers$UPDATES
static final boolean approveUsers$UPDATES- See Also:
-
rejectUsers$UPDATES
static final boolean rejectUsers$UPDATES- See Also:
-
getPending$UPDATES
static final boolean getPending$UPDATES- See Also:
-
getPendingPaging$UPDATES
static final boolean getPendingPaging$UPDATES- See Also:
-
getNumberOfRequests$UPDATES
static final boolean getNumberOfRequests$UPDATES- See Also:
-
getRequests$UPDATES
static final boolean getRequests$UPDATES- See Also:
-
getPendingUsers$UPDATES
static final boolean getPendingUsers$UPDATES- See Also:
-
getPendingReview$UPDATES
static final boolean getPendingReview$UPDATES- See Also:
-
getPendingReviews$UPDATES
static final boolean getPendingReviews$UPDATES- See Also:
-
getFavoritesByRoot$UPDATES
static final boolean getFavoritesByRoot$UPDATES- See Also:
-
getFavoriteByRootIds$UPDATES
static final boolean getFavoriteByRootIds$UPDATES- See Also:
-
getFavoritesByRootPaging$UPDATES
static final boolean getFavoritesByRootPaging$UPDATES- See Also:
-
isFavorite$UPDATES
static final boolean isFavorite$UPDATES- See Also:
-
areFavorites$UPDATES
static final boolean areFavorites$UPDATES- See Also:
-
populateFavorites$UPDATES
static final boolean populateFavorites$UPDATES- See Also:
-
addFavorite$UPDATES
static final boolean addFavorite$UPDATES- See Also:
-
addFavoriteForUsers$UPDATES
static final boolean addFavoriteForUsers$UPDATES- See Also:
-
addFavorites$UPDATES
static final boolean addFavorites$UPDATES- See Also:
-
removeFavorite$UPDATES
static final boolean removeFavorite$UPDATES- See Also:
-
removeFavorites$UPDATES
static final boolean removeFavorites$UPDATES- See Also:
-
removeFavoriteForUsers$UPDATES
static final boolean removeFavoriteForUsers$UPDATES- See Also:
-
cleanseFavorites$UPDATES
static final boolean cleanseFavorites$UPDATES- See Also:
-
cleanseApprovals$UPDATES
static final boolean cleanseApprovals$UPDATES- See Also:
-
getRoleMap$UPDATES
static final boolean getRoleMap$UPDATES- See Also:
-
setRoleMap$UPDATES
static final boolean setRoleMap$UPDATES- See Also:
-
setRoleMapForAllVersions$UPDATES
static final boolean setRoleMapForAllVersions$UPDATES- See Also:
-
getRestrictionMap$UPDATES
static final boolean getRestrictionMap$UPDATES- See Also:
-
setRestrictionMap$UPDATES
static final boolean setRestrictionMap$UPDATES- See Also:
-
setActorsInRoles$UPDATES
static final boolean setActorsInRoles$UPDATES- See Also:
-
getRoleSet$UPDATES
static final boolean getRoleSet$UPDATES- See Also:
-
getRoleSets$UPDATES
static final boolean getRoleSets$UPDATES- See Also:
-
getRoleSetForUser$UPDATES
static final boolean getRoleSetForUser$UPDATES- See Also:
-
getRoleSetsForUser$UPDATES
static final boolean getRoleSetsForUser$UPDATES- See Also:
-
getRoleSetForGroup$UPDATES
static final boolean getRoleSetForGroup$UPDATES- See Also:
-
getRoleSetsForGroup$UPDATES
static final boolean getRoleSetsForGroup$UPDATES- See Also:
-
populateRoleSets$UPDATES
static final boolean populateRoleSets$UPDATES- See Also:
-
populateExtensionInfo$UPDATES
static final boolean populateExtensionInfo$UPDATES- See Also:
-
localize$UPDATES
static final boolean localize$UPDATES- See Also:
-
addUserInRole$UPDATES
static final boolean addUserInRole$UPDATES- See Also:
-
addUsersInRole$UPDATES
static final boolean addUsersInRole$UPDATES- See Also:
-
removeUserFromRole$UPDATES
static final boolean removeUserFromRole$UPDATES- See Also:
-
removeUsersFromRole$UPDATES
static final boolean removeUsersFromRole$UPDATES- See Also:
-
addGroupInRole$UPDATES
static final boolean addGroupInRole$UPDATES- See Also:
-
addGroupsInRole$UPDATES
static final boolean addGroupsInRole$UPDATES- See Also:
-
removeGroupFromRole$UPDATES
static final boolean removeGroupFromRole$UPDATES- See Also:
-
removeGroupsFromRole$UPDATES
static final boolean removeGroupsFromRole$UPDATES- See Also:
-
getViewable$UPDATES
static final boolean getViewable$UPDATES- See Also:
-
getViewableByUser$UPDATES
static final boolean getViewableByUser$UPDATES- See Also:
-
getEditable$UPDATES
static final boolean getEditable$UPDATES- See Also:
-
getEditableByUser$UPDATES
static final boolean getEditableByUser$UPDATES- See Also:
-
getAdministratable$UPDATES
static final boolean getAdministratable$UPDATES- See Also:
-
getAdministratableByUser$UPDATES
static final boolean getAdministratableByUser$UPDATES- See Also:
-
canAdministrate$UPDATES
static final boolean canAdministrate$UPDATES- See Also:
-
canUserAdministrate$UPDATES
static final boolean canUserAdministrate$UPDATES- See Also:
-
canGroupAdministrate$UPDATES
static final boolean canGroupAdministrate$UPDATES- See Also:
-
isViewNotRestricted$UPDATES
static final boolean isViewNotRestricted$UPDATES- See Also:
-
isEditNotRestricted$UPDATES
static final boolean isEditNotRestricted$UPDATES- See Also:
-
isAdministrateNotRestricted$UPDATES
static final boolean isAdministrateNotRestricted$UPDATES- See Also:
-
canEdit$UPDATES
static final boolean canEdit$UPDATES- See Also:
-
canUserEdit$UPDATES
static final boolean canUserEdit$UPDATES- See Also:
-
canGroupEdit$UPDATES
static final boolean canGroupEdit$UPDATES- See Also:
-
canView$UPDATES
static final boolean canView$UPDATES- See Also:
-
canUserView$UPDATES
static final boolean canUserView$UPDATES- See Also:
-
canGroupView$UPDATES
static final boolean canGroupView$UPDATES- See Also:
-
getAccessLevel$UPDATES
static final boolean getAccessLevel$UPDATES- See Also:
-
getAccessLevelForUser$UPDATES
static final boolean getAccessLevelForUser$UPDATES- See Also:
-
getWhatsNew$UPDATES
static final boolean getWhatsNew$UPDATES- See Also:
-
getWhatsNewIds$UPDATES
static final boolean getWhatsNewIds$UPDATES- See Also:
-
getWhatsNewPaging$UPDATES
static final boolean getWhatsNewPaging$UPDATES- See Also:
-
setPersonalId$UPDATES
static final boolean setPersonalId$UPDATES- See Also:
-
getPersonalId$UPDATES
static final boolean getPersonalId$UPDATES- See Also:
-
getPersonal$UPDATES
static final boolean getPersonal$UPDATES- See Also:
-
getPersonalAndTeamsIds$UPDATES
static final boolean getPersonalAndTeamsIds$UPDATES- See Also:
-
getPersonalAndTeams$UPDATES
static final boolean getPersonalAndTeams$UPDATES- See Also:
-
getPersonalAndTeamsPaging$UPDATES
static final boolean getPersonalAndTeamsPaging$UPDATES- See Also:
-
browse$UPDATES
static final boolean browse$UPDATES- See Also:
-
browseIds$UPDATES
static final boolean browseIds$UPDATES- See Also:
-
browsePaging$UPDATES
static final boolean browsePaging$UPDATES- See Also:
-
getDownloadLogType$UPDATES
static final boolean getDownloadLogType$UPDATES- See Also:
-
updateUsernames$UPDATES
static final boolean updateUsernames$UPDATES- See Also:
-
rollbackUpdateUsernames$UPDATES
static final boolean rollbackUpdateUsernames$UPDATES- See Also:
-
commitUpdateUsernames$UPDATES
static final boolean commitUpdateUsernames$UPDATES- See Also:
-
getSystemId$UPDATES
static final boolean getSystemId$UPDATES- See Also:
-
getSystemIds$UPDATES
static final boolean getSystemIds$UPDATES- See Also:
-
getSystemNames$UPDATES
static final boolean getSystemNames$UPDATES- See Also:
-
setSystemId$UPDATES
static final boolean setSystemId$UPDATES- See Also:
-
setSystemIds$UPDATES
static final boolean setSystemIds$UPDATES- See Also:
-
setRoot$UPDATES
static final boolean setRoot$UPDATES- See Also:
-
setAsRoot$UPDATES
static final boolean setAsRoot$UPDATES- See Also:
-
suggest$UPDATES
static final boolean suggest$UPDATES- See Also:
-
adjustCounter$UPDATES
static final boolean adjustCounter$UPDATES- See Also:
-
moveKnowledgeCenter$UPDATES
static final boolean moveKnowledgeCenter$UPDATES- See Also:
-
moveKnowledgeCenters$UPDATES
static final boolean moveKnowledgeCenters$UPDATES- See Also:
-
validateTypedValues$UPDATES
static final boolean validateTypedValues$UPDATES- See Also:
-
getIdByUuid$UPDATES
static final boolean getIdByUuid$UPDATES- See Also:
-
getIdsByUuid$UPDATES
static final boolean getIdsByUuid$UPDATES- See Also:
-
getDatatypeIds$UPDATES
static final boolean getDatatypeIds$UPDATES- See Also:
-
getDocumentInputStream$UPDATES
static final boolean getDocumentInputStream$UPDATES- See Also:
-
uploadDocument$UPDATES
static final boolean uploadDocument$UPDATES- See Also:
-
-
Method Details
-
getApplicationName
String getApplicationName()Get the application name (in this case, "Appian Collaboration").- Returns:
- the name of the application
-
generateSearchIndex
Generates search index text file bodies for: "content". Fields in generated file:- id
- n - name
- d - description
- t - type
- st - state
- sec - security
- vis - visibility
- crt - creator
- tsc - timestamp created
- tsm - timestamp modified
- ed - expiration days
- edt - expiration date timestamp
- b - bytes
- p - parent
- Parameters:
timestamp_
- only include content modified since timestamp (may benull
for all)- Returns:
- a string representation of the URI of the search index output
-
setAdministratorGroup
Set the group that will be considered administrators for all content (appadmins).- Parameters:
groupId_
- the ID of the group to set as administrators- See Also:
-
getAdministratorGroup
Long getAdministratorGroup()Members of this group will be considered administrators for all content (appadmins).- Returns:
- the ID of the group set as administrators
- See Also:
-
activateUserSession
@Deprecated void activateUserSession(Long[] memberOfGroups_, Long[] adminOfGroups_, Integer userTypeSysAdmin_) Deprecated.Notify the Content server of group membership and application privileges.- Parameters:
memberOfGroups_
- ID(s) of groups for which the current user is a memberadminOfGroups_
- ID(s) of groups for which the current user is an adminuserTypeSysAdmin_
- user type (0 basic; 1 sysadmin)
-
validateGroupMembership
@Deprecated Boolean validateGroupMembership(Long[] memberOfGroups_, Long[] adminOfGroups_) throws InvalidUserException Deprecated.No longer necessary with credential systemValidate that the group membership passed is incorrect or incomplete (whether activateUserSession needs to be called).- Parameters:
memberOfGroups_
- ID(s) of groups for which the current user is a memberadminOfGroups_
- ID(s) of groups for which the current user is an admin- Returns:
- whether activateUserSession needs to be called
- Throws:
InvalidUserException
- if an invalid user is referenced
-
resetGroupMembership
Deprecated.No longer necessary with credential systemClear group membership for users who have not logged in since the given timestamp.- Parameters:
timestamp_
- group membership will be cleared for users who have not logged in since this timestamp
-
notifyUserCreation
Deprecated.done automatically by UserService.createUserNotify the server that the user was created.- Parameters:
userName_
- username of the user that was created
-
notifyUsersCreation
Deprecated.done automatically by UserService.createUserNotify the server that the users were created.- Parameters:
userNames_
- usernames of the users that were created
-
notifyGroupDeletion
Notify the server that a group was deleted so any new group with the same id will not assume the same permissions.- Parameters:
groupId_
- the ID of the group that was deleted
-
notifyGroupsDeletion
Notify the server that groups were deleted so any new group with the same id will not assume the same permissions.- Parameters:
groupIds_
- the IDs of the groups that were deleted
-
setUserSpaceUsage
@Deprecated void setUserSpaceUsage(String username_, Long bytesUsed_) throws InvalidUserException, StorageLimitException Deprecated.User quotas have been removed. Calls to this method will be ignored.Set the amount of space (in bytes) currently used by the specified user. This will override the automatically tracked value, and automatic tracking will continue from this value. Application administrator (sysadmin) privileges are required for the user calling this method.- Parameters:
username_
- the username of the user for which to set the space usagebytesUsed_
- the number of bytes that user has used. Passing a negative value will throw an IllegalArgumentException.- Throws:
InvalidUserException
- if an invalid user is referencedStorageLimitException
- if there is no more available space- See Also:
-
getUserSpaceUsage
Deprecated.User quotas have been removed. This method will always return 0Get the amount of space (in bytes) currently used by the specified user.- Returns:
- the number of bytes currently used
- See Also:
-
setUserSpaceAvailable
Deprecated.User quotas have been removed. Calls to this method will be ignored.Set the remaining disk space (in bytes) available to the specified user. Application administrator (sysadmin) privileges are required for the user calling this method.- Parameters:
username_
- the username of the user for which to set the quotabytes_
- the number of bytes to set the quota to. Passing 0 will cause it to use the value set for server.conf.collaboration.DEFAULTSPACE in custom.properties. Passing a negative value will throw an IllegalArgumentException.- Throws:
InvalidUserException
- if an invalid user is referenced- See Also:
-
getUserSpaceAvailable
Deprecated.User quotas have been removed. This method will always return- 1
Get the total available space (quota) in bytes for the user. In order to get the remaining available space, please subtract the available space to the remaining space: Example:Long availableSpace = contentService.getUserSpaceAvailable() - contentService.getUserSpaceUsage();
- Returns:
- the current user's disk quota
- See Also:
-
getUserSpaceAvailableForUser
Deprecated.User quotas have been removed. This method will always return- 1
Get the total available space (quota, in bytes) available to the specified user.- Parameters:
username
- the username of the user for which to get the quota- Returns:
- the specified user's disk quota
- See Also:
-
getImageIdsForUsers
Get the image document ids for the given users.- Parameters:
usernames
- the usernames for which to query- Returns:
- the id of the image document for each user, with nulls where an image was not found or the user is invalid
-
getThumbnailIdsForUsers
Get the document ids of the thumbnail images of the given size for the given users.- Parameters:
usernames
- the usernames for which to querysize
- the thumbnail size (width in pixels)- Returns:
- the id of the thumbnail image document for each user, with nulls where an image of the given size was not found or the user is invalid
-
validate
Gets the type of the content specified.- Parameters:
id_
- the ID of the content- Returns:
- the type of the content. Will return 0 if the content does not exist, and -1 if the content is type 0 (atypical)
-
validate
Gets the types of the content specified.- Parameters:
ids_
- the IDs of the content- Returns:
- the types of the content in the same order as the IDs passed in. Will return 0 if the content does not exist, and -1 if the content is type 0 (atypical)
-
createApproval
Approval createApproval(Content content_, Integer unique_) throws InvalidContentException, StorageLimitException, PrivilegeException, InsufficientNameUniquenessException, DuplicateUuidException Attempts to create content, and gets the approval status back in anApproval
bean. Seecreate(Content[], Integer)
.- Parameters:
content_
- the content to createunique_
- how unique the name must be (one ofContentConstants.UNIQUE_NONE
,ContentConstants.UNIQUE_FOR_TYPE
,ContentConstants.UNIQUE_FOR_PARENT
, orContentConstants.UNIQUE_FOR_ALL
)- Returns:
- the approval status in an
Approval
bean - Throws:
InvalidContentException
- if an invalid content item is referencedStorageLimitException
- if there is no more available spacePrivilegeException
- if the user does not have permission to take this actionInsufficientNameUniquenessException
- if the content name is not unique according to the unique_ parameterDuplicateUuidException
- if a content item with the same uuid already exists
-
createApproval
Approval createApproval(Content[] contents_, Integer unique_) throws InvalidContentException, StorageLimitException, PrivilegeException, InsufficientNameUniquenessException, DuplicateUuidException Attempts to create content, and gets the approval statuses back in anApproval
bean.- Parameters:
contents_
- the content to createunique_
- how unique the name must be (one ofContentConstants.UNIQUE_NONE
,ContentConstants.UNIQUE_FOR_TYPE
,ContentConstants.UNIQUE_FOR_PARENT
, orContentConstants.UNIQUE_FOR_ALL
)- Returns:
- the approval status in an
Approval
bean - Throws:
InvalidContentException
- if an invalid content item is referencedStorageLimitException
- if there is no more available spacePrivilegeException
- if the user does not have permission to take this actionInsufficientNameUniquenessException
- if the content name is not unique according to the unique_ parameterDuplicateUuidException
- if a content item with the same uuid already exists
-
create
Long create(Content content_, Integer unique_) throws InvalidContentException, StorageLimitException, PrivilegeException, InsufficientNameUniquenessException, DuplicateUuidException Creates a content object. If the Content object is of typeContentConstants.TYPE_DOCUMENT
, you must separately create the actual file on disk in the path specified by theinternalFileName
property of the object. This method does not create the file on disk.- Parameters:
content_
- the content to createunique_
- how unique the name must be (one ofContentConstants.UNIQUE_NONE
,ContentConstants.UNIQUE_FOR_TYPE
,ContentConstants.UNIQUE_FOR_PARENT
, orContentConstants.UNIQUE_FOR_ALL
)- Returns:
- the ID of the content
- Throws:
InvalidContentException
- if an invalid content item is referencedStorageLimitException
- if there is no more available spacePrivilegeException
- if the user does not have permission to take this actionInsufficientNameUniquenessException
- if the content name is not unique according to the unique_ parameterDuplicateUuidException
- if a content item with the same uuid already exists
-
create
Long[] create(Content[] contents_, Integer unique_) throws InvalidContentException, StorageLimitException, PrivilegeException, InsufficientNameUniquenessException, DuplicateUuidException Creates content. The following fields are required:- name
- parent
- attributes
- description
- expirationDays
- expirationTimestamp
- extension
- fileSystemId
- forum
- metadataIds
- name
- parent
- partition
- security
- size
- subtype
- type
- uuid
- visibility
- Parameters:
contents_
- an array of Content objectsunique_
- how unique the name must be (one ofContentConstants.UNIQUE_NONE
,ContentConstants.UNIQUE_FOR_TYPE
,ContentConstants.UNIQUE_FOR_PARENT
, orContentConstants.UNIQUE_FOR_ALL
)- Returns:
- the IDs of the content
- Throws:
InvalidContentException
- if an invalid content item is referencedStorageLimitException
- if there is no more available spacePrivilegeException
- if the user does not have permission to take this actionInsufficientNameUniquenessException
- if the content name is not unique according to the unique_ parameterDuplicateUuidException
- if a content item with the same uuid already exists
-
createVersion
Approval createVersion(Content content_, Integer unique_) throws InvalidContentException, NotLockOwnerException, PendingApprovalException, ContentExpiredException, StorageLimitException, PrivilegeException, InsufficientNameUniquenessException Creates a new version of content. This call does not update the parent of the content. If the new version has a new parent, make sure to callmove(Long, Long)
. The new version will have the same security role map as its parent, even if the content is not otherwise set to inherit security. For content that should not inherit security from its parent, callsetRoleMap(java.lang.Long, com.appiancorp.suiteapi.content.ContentRoleMap, java.lang.Boolean)
after creating the new version. When creating a new version of a Document, set the file system id on the document to be auto-allocated before passing it to createVersion. The following code example demonstrates using this method:Document doc = contentService.getVersion(docId, ContentConstants.VERSION_CURRENT); // prepare the document, indicating the service to assign a new file path // to the new version of the document doc.setFileSystemId(ContentConstants.ALLOCATE_FSID); // create a new version Approval a = contentService.createVersion(doc, unique); // get the file path of the new version Long newVersionContentId = a.getId()[0]; Document newDocumentVersion = cs.download(newVersionContentId, VERSION_CURRENT, false); try (OutputStream outStream = newDocumentVersion.getOutputStream()) { IOUtils.copy(inStream, outStream); }
- Parameters:
content_
- a Content objectunique_
- how unique the name must be (one ofContentConstants.UNIQUE_NONE
,ContentConstants.UNIQUE_FOR_TYPE
,ContentConstants.UNIQUE_FOR_PARENT
, orContentConstants.UNIQUE_FOR_ALL
)- Returns:
- the approval status in an
Approval
bean - Throws:
InvalidContentException
- if an invalid content item is referencedNotLockOwnerException
- if the content is locked and the current user is not the ownerPendingApprovalException
- if the content is pending approvalContentExpiredException
- if the content you reference is expiredStorageLimitException
- if there is no more available spacePrivilegeException
- if the user does not have permission to take this actionInsufficientNameUniquenessException
- if the content name is not unique according to the unique_ parameter
-
createVersion
@Deprecated Approval createVersion(Content[] contents_, Integer unique_) throws InvalidContentException, NotLockOwnerException, PendingApprovalException, ContentExpiredException, StorageLimitException, PrivilegeException, InsufficientNameUniquenessException Deprecated.Creates new versions of content. This may be used to create another version of any piece of Content. Each new Content bean passed into this function must be just like the existing one, except where you want the modifications to be. This is really a create, except that the version chain is extended to include this new Content. The id field in Content is used to determine which piece of content to create a new version of; any id in the version chain will suffice. The fields updated are the same list as those for create. This call does not update the parent of the contents. If the new versions have new parents, make sure to callmove(Long[], Long)
for bulk move ormove(Long, Long)
individually if each has a different parent.- Parameters:
contents_
- the content to create as new versionsunique_
- how unique the name must be (one ofContentConstants.UNIQUE_NONE
,ContentConstants.UNIQUE_FOR_TYPE
,ContentConstants.UNIQUE_FOR_PARENT
, orContentConstants.UNIQUE_FOR_ALL
)- Returns:
- the approval status in an
Approval
bean - Throws:
InvalidContentException
- if an invalid content item is referencedNotLockOwnerException
- if the content is locked and the current user is not the ownerPendingApprovalException
- if the content is pending approvalContentExpiredException
- if the content you reference is expiredStorageLimitException
- if there is no more available spacePrivilegeException
- if the user does not have permission to take this actionInsufficientNameUniquenessException
- if the content name is not unique according to the unique_ parameter
-
upload
@Deprecated ContentOutputStream upload(Document doc, Integer unique) throws InvalidContentException, StorageLimitException, PrivilegeException, InsufficientNameUniquenessException, DuplicateUuidException Deprecated.since 23.2. UseuploadDocument(Document, Integer)
insteadCreates a document and provides an output stream to which the document's content should be written. The document is created using thecreateApproval(Content, Integer)
API. The caller must write the document's data to the returned output stream and complete the upload by callingContentOutputStream.close()
. Invoking the stream's close method will calculate the size of the data written to the stream and save it as metadata for the document.- Parameters:
doc
- The Document to create.unique
- How unique the name must be.- Returns:
- The output stream to which the document's data should be written.
- Throws:
InvalidContentException
StorageLimitException
PrivilegeException
InsufficientNameUniquenessException
DuplicateUuidException
-
importContent
@Deprecated Long[] importContent(Content[] contents_, Integer unique_) throws InvalidContentException, NotLockOwnerException, PendingApprovalException, ContentExpiredException, StorageLimitException, PrivilegeException, InsufficientNameUniquenessException, DuplicateUuidException Deprecated.This API is no longer supported and will be removed in the next release. Only objects that are exported using the Applications import/export will be importable in the next release.Imports content. For each content bean, if the UUID exists already in the same location, this function callscreateVersion(Content[], Integer)
. Otherwise, it callscreate(Content[], Integer)
This does a create or createVersion, as necessary.- Parameters:
contents_
- an array of Content objects to importunique_
- how unique the name must be (one ofContentConstants.UNIQUE_NONE
,ContentConstants.UNIQUE_FOR_TYPE
,ContentConstants.UNIQUE_FOR_PARENT
, orContentConstants.UNIQUE_FOR_ALL
)- Returns:
- the IDs of the new content
- Throws:
InvalidContentException
- if an invalid content item is referencedNotLockOwnerException
- if the content is locked and the current user is not the ownerPendingApprovalException
- if the content is pending approvalContentExpiredException
- if the content you reference is expiredStorageLimitException
- if there is no more available spacePrivilegeException
- if the user does not have permission to take this actionInsufficientNameUniquenessException
- if the content name is not unique according to the unique_ parameterDuplicateUuidException
- if the UUID of any of the content items already exists or if the same UUID is passed in for several content items
-
importValidate
Integer[] importValidate(Content[] contents_) throws InvalidContentException, NotLockOwnerException, PendingApprovalException, ContentExpiredException, StorageLimitException, PrivilegeException Checks the validity of the Content items for import, returning an import status for each.- Parameters:
contents_
- an array of Content objects to validate- Returns:
- one of
ContentConstants.IMPORT_VALID
,ContentConstants.IMPORT_INVALID_PRIVILEGE
,ContentConstants.IMPORT_UUID_EXISTS_ELSEWHERE
,ContentConstants.IMPORT_INVALID_PRIVILEGE
,ContentConstants.IMPORT_NAME_EXISTS_WITHIN_TYPE
, orContentConstants.IMPORT_NAME_EXISTS_WITHIN_PARENT
- Throws:
InvalidContentException
- if an invalid content item is referencedNotLockOwnerException
- if the content is locked and the current user is not the ownerPendingApprovalException
- if the content is pending approvalContentExpiredException
- if the content you reference is expiredStorageLimitException
- if there is no more available spacePrivilegeException
- if the user does not have permission to take this actionInsufficientNameUniquenessException
- if the content name is not unique according to the unique_ parameter
-
getContent
Deprecated.usegetVersion(Long, Integer)
instead.- Parameters:
id_
- the ID of the content- Returns:
- the
Content
bean - Throws:
InvalidContentException
- if an invalid content item is referencedPrivilegeException
- if the user does not have permission to take this action
-
getContent
Deprecated.Gets Contents by id. This will get the exact Content items specified, including the specific version implied by the Content id. If you want to get only the latest item of Content, usegetVersion(Long, Integer)
with version numberContentConstants.VERSION_CURRENT
instead. If retrieving aDocument
theinternalFilename
property won't be populated; usedownload(Long, Integer, Boolean)
instead.- Parameters:
ids_
- the IDs of the content- Returns:
- the
Content
beans - Throws:
InvalidContentException
- if an invalid content item is referenced- See Also:
-
getContentList
Does the same thing asgetContent(Long[])
, except it takes a type mask and returns error codes instead of throwing exceptions.- Parameters:
ids_
- the IDs of the contenttypemask_
- the types of content to return- Returns:
- a
ResultList
ofContent
beans. - Throws:
InvalidTypeMaskException
- if an invalid typemask was passed in
-
getContentPaging
@Deprecated ResultPage getContentPaging(Long[] ids_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidContentException Deprecated.Does the same thing asgetContent(Long[])
, except it pages and returns error codes instead of throwing exceptions.- Parameters:
ids_
- the IDs of the contentstartIndex_
- the index into the collection of total results at which to start. Negative numbers are treated as zeros.batchSize_
- the number of results to return. UseConstants.COUNT_ALL
to return the entire collection, but this is STRONGLY discouraged.sortProperty_
- the property by which the results will be sorted. This is one of theCOLUMN_XXX
constants inContentConstants
.sortOrder_
- the order in which to sort the results.This is one ofConstants.SORT_ORDER_ASCENDING
orConstants.SORT_ORDER_DESCENDING
- Returns:
- a ResultPage containing the list of
Content
objects - Throws:
InvalidContentException
- if an invalid content item is referenced- See Also:
-
getContentTree
@Deprecated Content[] getContentTree(Long rootContentId_, Integer maxDepth_, Integer typemask_, Integer accessLevel_) throws InvalidContentException, InvalidTypeMaskException Deprecated.Get the content tree starting from the specified root. Returns the list of contents ordered by a depth first traversal. This populates the depth field in theContent
beans.- Parameters:
rootContentId_
- (atomic efficient)maxDepth_
- the maximum depth to traverse the treetypemask_
- only return contents that match this typemaskaccessLevel_
- the minimum access level required (one ofContentConstants.AL_NONE
,ContentConstants.AL_VIEWER
,ContentConstants.AL_EDITOR
, andContentConstants.AL_ADMIN
- Returns:
- list of Content (Content but with additional depth field filled in)
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if an invalid typemask was passed in- See Also:
-
getContentTreePaging
ResultPage getContentTreePaging(Long rootContentId_, Integer maxDepth_, Integer typemask_, Integer accessLevel_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidContentException, InvalidTypeMaskException Get the content tree, and page the results. Returns the list of contents ordered by a depth first traversal. This populates the depth field in theContent
beans.- Parameters:
rootContentId_
- (atomic efficient)maxDepth_
- the maximum depth to traverse the treetypemask_
- only return contents that match this typemaskaccessLevel_
- (0 is view, 1 is edit, 2 is admin)startIndex_
- the index into the collection of total results at which to start. Negative numbers are treated as zeros.batchSize_
- the number of results to return. UseConstants.COUNT_ALL
to return the entire collection, but this is STRONGLY discouraged.sortProperty_
- the property by which the results will be sorted. This is one of theCOLUMN_XXX
constants inContentConstants
.sortOrder_
- the order in which to sort the results.This is one ofConstants.SORT_ORDER_ASCENDING
orConstants.SORT_ORDER_DESCENDING
- Returns:
- list of Content (Content but with additional depth field filled in)
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if an invalid typemask was passed in- See Also:
-
getContentWhereViewable
Deprecated.Gets the specified content where viewable, rather than giving an error that the content is not viewable. Note: The length of the array ofContent
beans returned may not be the same length as the array of IDs passed in.- Parameters:
ids_
- the IDs of the content- Returns:
- an array of the
Content
beans that are viewable - Throws:
InvalidContentException
- See Also:
-
getContentIdsWhereViewable
Gets the specified content IDs where viewable, rather than giving an error that the content is not viewable. Note: The length of the array of IDs returned may not be the same length as the array of IDs passed in.- Parameters:
ids_
- the IDs of the content- Returns:
- an array of the IDs of the viewable content
- Throws:
InvalidContentException
-
getContentWhereViewablePaging
ResultPage getContentWhereViewablePaging(Long[] ids_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidContentException Gets the specified content where viewable, rather than giving an error that the content is not viewable. Note: The number of results returned may not be the same length as the array of IDs passed in.- Parameters:
ids_
- the IDs of the contentstartIndex_
- the index into the collection of total results at which to start. Negative numbers are treated as zeros.batchSize_
- the number of results to return. UseConstants.COUNT_ALL
to return the entire collection, but this is STRONGLY discouraged.sortProperty_
- the property by which the results will be sorted. This is one of theCOLUMN_XXX
constants inContentConstants
.sortOrder_
- the order in which to sort the results.This is one ofConstants.SORT_ORDER_ASCENDING
orConstants.SORT_ORDER_DESCENDING
- Returns:
- an array of the
Content
beans that are viewable - Throws:
InvalidContentException
- See Also:
-
getContentUrl
Gets the URL for a given content.- Parameters:
contentId
- the internal identifier of the content- Returns:
- the complete Tempo URL for the content
-
getOpaqueContentUri
Gets the opaque id for a given content.- Parameters:
contentId
- the internal identifier of the content- Returns:
- the opaque uri for the content
-
getVersion
Content getVersion(Long id_, Integer versionNumber_) throws InvalidContentException, InvalidVersionException, PrivilegeException Gets the specified version of the content. If retrieving aDocument
theinternalFilename
property won't be populated; usedownload(Long, Integer, Boolean)
instead.- Parameters:
id_
- the content id (any id within a version chain will do)versionNumber_
- the version number of content to get (useContentConstants.VERSION_ORIGINAL
to get the first version of the content andContentConstants.VERSION_CURRENT
to get the current version of the content)- Returns:
- the
Content
bean - Throws:
InvalidContentException
- if an invalid content item is referencedInvalidVersionException
- if an invalid version is referencedPrivilegeException
- if the user does not have permission to take this action
-
getVersion
Content getVersion(@ConvertWith(com.appiancorp.kougar.mapper.parameters.UuidParameterConverter.class) String uuid, Integer versionNumber) throws InvalidContentException, InvalidVersionException, PrivilegeException Gets the specified version of the content. If retrieving aDocument
theinternalFilename
property won't be populated; usedownload(Long, Integer, Boolean)
instead.- Parameters:
uuid
- the content UUID (any UUID within a version chain will do), as if by getIdByUuidversionNumber
- the version number of content to get (useContentConstants.VERSION_ORIGINAL
to get the first version of the content andContentConstants.VERSION_CURRENT
to get the current version of the content)- Returns:
- the
Content
bean - Throws:
InvalidContentException
- if an invalid content item is referencedInvalidVersionException
- if an invalid version is referencedPrivilegeException
- if the user does not have permission to take this action
-
getVersions
@Deprecated Content[] getVersions(Long[] ids_, Integer versionNumber_) throws InvalidContentException, InvalidVersionException, PrivilegeException Deprecated.Gets the specified version of a bunch of pieces of content.- Parameters:
ids_
- the content ids (any id within a version chain will do)versionNumber_
- the version number of content to get (useContentConstants.VERSION_ORIGINAL
to get the first version of the content andContentConstants.VERSION_CURRENT
to get the current version of the content)- Returns:
- the
Content
beans - Throws:
InvalidContentException
- if an invalid content item is referencedInvalidVersionException
- if an invalid version is referencedPrivilegeException
- if the user does not have permission to take this action- See Also:
-
getVersions
Content[] getVersions(Long id_, Integer[] versionNumbers_) throws InvalidContentException, InvalidVersionException, PrivilegeException Gets the specified versions of a particular piece of content.- Parameters:
id_
- the content id (any id within a version chain will do)versionNumbers_
- the version numbers of content to get (useContentConstants.VERSION_ORIGINAL
to get the first version of the content andContentConstants.VERSION_CURRENT
to get the current version of the content)- Returns:
- the
Content
beans - Throws:
InvalidContentException
- if an invalid content item is referencedInvalidVersionException
- if an invalid version is referencedPrivilegeException
- if the user does not have permission to take this action- See Also:
-
getVersionsPaging
ResultPage getVersionsPaging(Long[] ids_, Integer versionNumber_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidContentException, InvalidVersionException, PrivilegeException Gets the specified version of a bunch of pieces of content.- Parameters:
ids_
- the content ids (any id within a version chain will do)versionNumber_
- the version number of content to get (useContentConstants.VERSION_ORIGINAL
to get the first version of the content andContentConstants.VERSION_CURRENT
to get the current version of the content)startIndex_
- the index into the collection of total results at which to start. Negative numbers are treated as zeros.batchSize_
- the number of results to return. UseConstants.COUNT_ALL
to return the entire collection, but this is STRONGLY discouraged.sortProperty_
- the property by which the results will be sorted. This is one of theCOLUMN_XXX
constants inContentConstants
.sortOrder_
- the order in which to sort the results.This is one ofConstants.SORT_ORDER_ASCENDING
orConstants.SORT_ORDER_DESCENDING
- Returns:
- a ResultPage containing the list of
Content
objects - Throws:
InvalidContentException
- if an invalid content item is referencedInvalidVersionException
- if an invalid version is referencedPrivilegeException
- if the user does not have permission to take this action
-
getVersionsPaging
ResultPage getVersionsPaging(Long id_, Integer[] versionNumbers_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidContentException, InvalidVersionException, PrivilegeException Gets the specified versions of a particular piece of content.- Parameters:
id_
- the content id (any id within a version chain will do)versionNumbers_
- the version numbers of content to get (useContentConstants.VERSION_ORIGINAL
to get the first version of the content andContentConstants.VERSION_CURRENT
to get the current version of the content)startIndex_
- the index into the collection of total results at which to start. Negative numbers are treated as zeros.batchSize_
- the number of results to return. UseConstants.COUNT_ALL
to return the entire collection, but this is STRONGLY discouraged.sortProperty_
- the property by which the results will be sorted. This is one of theCOLUMN_XXX
constants inContentConstants
.sortOrder_
- the order in which to sort the results.This is one ofConstants.SORT_ORDER_ASCENDING
orConstants.SORT_ORDER_DESCENDING
- Returns:
- A
ResultList
ofContent
objects. In the case where there is an exception (such as access restriction) the ResultList.getResultCodes() will have an entry for every id passed to it, but theResult.getResults()
will only have an entry for every valid result returned. i.e. ResultList.getResultCodes().length does not always equal Result.getResults().length. They are equal only when *all* items in the ResultList array are >= ResultList.CODE_VALID. - Throws:
InvalidContentException
- if an invalid content item is referencedInvalidVersionException
- if an invalid version is referencedPrivilegeException
- if the user does not have permission to take this action
-
getVersionsList
ResultList getVersionsList(Long[] ids, Integer versionNumber, Integer typemask) throws InvalidTypeMaskException, InvalidVersionException Retrieves the specified version of the content objects identified by the given ids and of the given type. Like allResultList
APIs, this method returns error codes instead of throwing exceptions. Note that the result array is not castable to something other than Content[]. The results should then be cast individually.- Parameters:
ids
- The ids of the content objects to retrieve.versionNumber
- The version of the content objects to retrieve.typemask
- The type of content objects to retrieve.- Returns:
- A
ResultList
ofContent
objects. In the case where there is an exception (such as access restriction) the ResultList.getResultCodes() will have an entry for every id passed to it, but theResult.getResults()
will only have an entry for every valid result returned. i.e. ResultList.getResultCodes().length does not always equal Result.getResults().length. They are equal only when all items in the ResultList array are >= ResultList.CODE_VALID. - Throws:
InvalidTypeMaskException
- if an invalid type is passed inInvalidVersionException
- if an invalid version number is passed in
-
getVersionId
Long getVersionId(Long id_, Integer versionNumber_) throws InvalidContentException, InvalidVersionException, PrivilegeException Gets the ID of the specified version of the content.- Parameters:
id_
- the content id (any id within a version chain will do)versionNumber_
- the version number of content to get (useContentConstants.VERSION_ORIGINAL
to get the first version of the content andContentConstants.VERSION_CURRENT
to get the current version of the content)- Returns:
- the ID
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidVersionException
- if an invalid version is referencedPrivilegeException
- if the user does not have permission to take this action
-
getVersionId
Long getVersionId(@ConvertWith(com.appiancorp.kougar.mapper.parameters.UuidParameterConverter.class) String uuid, Integer versionNumber) throws InvalidContentException, InvalidVersionException, PrivilegeException Gets the ID of the specified version of the content.- Parameters:
uuid
- the content UUID (any UUID within a version chain will do), as if by getIdByUuidversionNumber
- the version number of content to get (useContentConstants.VERSION_ORIGINAL
to get the first version of the content andContentConstants.VERSION_CURRENT
to get the current version of the content)- Returns:
- the ID
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidVersionException
- if an invalid version is referencedPrivilegeException
- if the user does not have permission to take this action
-
getVersionIds
Long[] getVersionIds(Long[] ids_, Integer versionNumber_) throws InvalidContentException, InvalidVersionException, PrivilegeException Gets the specified version of a bunch of pieces of content.- Parameters:
ids_
- the content id (any id within a version chain will do)versionNumber_
- the version number of content to get (useContentConstants.VERSION_ORIGINAL
to get the first version of the content andContentConstants.VERSION_CURRENT
to get the current version of the content)- Returns:
- the IDs
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidVersionException
- if an invalid version is referencedPrivilegeException
- if the user does not have permission to take this action
-
getVersionIds
Long[] getVersionIds(Long id_, Integer[] versionNumbers_) throws InvalidContentException, InvalidVersionException, PrivilegeException Gets the specified versions of a particular piece of content.- Parameters:
id_
- the content id (any id within a version chain will do)versionNumbers_
- the version number of content to get (useContentConstants.VERSION_ORIGINAL
to get the first version of the content andContentConstants.VERSION_CURRENT
to get the current version of the content)- Returns:
- the IDs
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidVersionException
- if an invalid version is referencedPrivilegeException
- if the user does not have permission to take this action
-
getAllVersions
Deprecated.Gets all of the versions of a particular versioned content item. It will return empty for an unversioned content item.- Parameters:
id_
- the content id (any id within a version chain will do)- Returns:
- all of the versions of the content specified, or an empty array if the content is unversioned
- Throws:
InvalidContentException
- if an invalid content item is referenced- See Also:
-
getAllVersionsPaging
ResultPage getAllVersionsPaging(Long id_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidContentException Gets all of the versions of a particular versioned content item. It will return empty for an unversioned content item.- Parameters:
id_
- the content id (any id within a version chain will do)startIndex_
- the index into the collection of total results at which to start. Negative numbers are treated as zeros.batchSize_
- the number of results to return. UseConstants.COUNT_ALL
to return the entire collection, but this is STRONGLY discouraged.sortProperty_
- the property by which the results will be sorted. This is one of theCOLUMN_XXX
constants inContentConstants
.sortOrder_
- the order in which to sort the results.This is one ofConstants.SORT_ORDER_ASCENDING
orConstants.SORT_ORDER_DESCENDING
- Returns:
- a ResultPage containing the list of
Content
objects - Throws:
InvalidContentException
- if an invalid content item is referenced- See Also:
-
getAllVersionIds
Gets the IDs of all of the versions of a particular versioned content item. It will return empty for an unversioned content item.- Parameters:
id_
- the content id (any id within a version chain will do)- Returns:
- the Ids of the versions of the content
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
download
Document[] download(Long id_, Integer versionNumber_, Boolean includeExpired_) throws InvalidContentException, InvalidVersionException, PrivilegeException Gets a piece of content and log the transaction if logging is enabled. If the content passed in is a document, this method functions similarly togetVersion(java.lang.Long, java.lang.Integer)
, but the download is logged if logging is enabled. If the content passed in is a container (e.g., a folder), all documents inside the container will be returned, and each document obtained is logged if logging is enabled. This function will only be used for Knowledge content.- Parameters:
id_
- the id of content to downloadversionNumber_
- the version number of content to downloadincludeExpired_
- whether to include expired content- Returns:
- the documents
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidVersionException
- if an invalid version is referencedPrivilegeException
- if the user does not have permission to take this action
-
getInternalFilename
Deprecated.since 23.2. UsegetDocumentInputStream(long)
for reads anduploadDocument(Document, Integer)
for writes, or calland use supported APIs on {@link com.appiancorp.suiteapi.knowledge.Document}
Gets the internal filename (physical location on disk) for a document. To always get the internal filename for the most current version, callgetVersionId(Long, Integer)
withContentConstants.VERSION_CURRENT
to get the most current Id.- Parameters:
id_
- the content ID of the version of the document; usegetVersionId(Long, Integer)
to obtain the id of the version of the document- Returns:
- a string representation of the internal filename
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
getInternalFilenames
Deprecated.since 23.2. UsegetDocumentInputStream(long[])
Gets the internal filenames (physical locations on disk) for a set of documents.- Parameters:
ids_
- the content IDs of the versions of the documents; usegetVersionIds(Long, Integer[])
to obtain the ids of the versions of the document- Returns:
- the string representations of the internal filenames
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
getExternalFilename
Gets the external filename (the name that the file would be saved as by the client, or the name within a .zip file) of a document.- Parameters:
id_
- the content ID- Returns:
- the string representation of the external filename
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
getExternalFilenames
Gets the external filenames (the name that the file would be saved as by the client, or the name within a .zip file) of a set of document.- Parameters:
ids_
- the content IDs- Returns:
- the string representations of the external filenames
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
getByPath
Gets the content at the specified path relative to the given root.- Parameters:
root_
- the id of the root Content itempath_
- the path relative to the root. containers are separated by "/"- Returns:
- the
Content
bean - Throws:
InvalidContentException
- if an invalid content item is referenced
-
getIdByPath
Gets the ID of the content at the specified path relative to the given root.- Parameters:
root_
- the id of the root Content itempath_
- the path relative to the root. containers are separated by "/"- Returns:
- the ID
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
getParent
Gets the parent of the specified content.- Parameters:
id_
- the id of the Content item- Returns:
- the
Content
bean - Throws:
InvalidContentException
- if an invalid content item is referenced
-
getParents
Gets the parents of the specified content items.- Parameters:
ids_
- the id of the Content items- Returns:
- the
Content
beans - Throws:
InvalidContentException
- if an invalid content item is referenced
-
getParentId
Gets the parents of the specified content items.- Parameters:
id_
- the id of the Content item- Returns:
- the ID of the parent
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
getParentIds
Gets the IDs of the parents of the specified content items.- Parameters:
ids_
- the ids of the Content items- Returns:
- the IDs of the parents
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
hasNoChildren
Checks whether the specified container has no children. This is the inverse ofhasChildren(Long)
.- Parameters:
containerId_
- the ID of the container- Returns:
- true if the container has no children; false if the container has children
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
haveNoChildren
Checks whether each of the specified containers has no children. This is the inverse ofhaveChildren(Long[])
.- Parameters:
containerIds_
- the IDs of the containers- Returns:
- true if the container has no children; false if the container has children
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
hasNoChildrenOfType
Checks whether the specified container has no children of the specified type(s).- Parameters:
containerId_
- the ID of the containertypemask_
- specifies which content types to look for- Returns:
- true if container has no children of given type(s), false if it does have children
- Throws:
InvalidTypeMaskException
- if an invalid typemask was passed in
-
haveNoChildrenOfType
Boolean[] haveNoChildrenOfType(Long[] containerIds_, Integer typemask_) throws InvalidTypeMaskException Checks whether each of the specified containers has no children of the specified type(s).- Parameters:
containerIds_
- the IDs of the containerstypemask_
- specifies which content types to look for- Returns:
- for each container, true if container has no children of given type(s), false if it does have children
- Throws:
InvalidTypeMaskException
- if an invalid typemask was passed in
-
hasChildren
Checks whether the specified container has children. This is the inverse ofhasNoChildren(Long)
- Parameters:
containerId_
- the ID of the container- Returns:
- true if container has children, false if it does not
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
haveChildren
Checks whether each of the specified containers has children. This is the inverse ofhaveNoChildren(Long[])
.- Parameters:
containerIds_
- the IDs of the containers- Returns:
- for each container, true if container has children, false if it does not
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
haveChildren
Checks whether each of the specified containers has children. This method extracts the IDs from theContent
beans passed in, and callshaveChildren(Long[])
with those IDs.- Parameters:
containers_
- the containers to check- Returns:
- for each container, true if container has children, false if it does not
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
hasChildrenOfType
Boolean hasChildrenOfType(Long containerId_, Integer typemask_) throws InvalidContentException, InvalidTypeMaskException Checks whether the specified container has children of a the specified type(s).- Parameters:
containerId_
- the ID of the containertypemask_
- children types to look for- Returns:
- true if container has children of the specified type(s), false if it does not
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if an invalid typemask was passed in
-
haveChildrenOfType
Boolean[] haveChildrenOfType(Long[] containerIds_, Integer typemask_) throws InvalidContentException, InvalidTypeMaskException Checks whether the specified container has children of a the specified type(s).- Parameters:
containerIds_
- the IDs of the containerstypemask_
- children types to look for- Returns:
- for each container, true if container has children, false if it does not
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if an invalid typemask was passed in
-
getChildrenTypesOfType
Integer getChildrenTypesOfType(Long containerId_, Integer typemask_) throws InvalidContentException, InvalidTypeMaskException Returns a typemask of all children types found within a container.- Parameters:
containerId_
- container idtypemask_
- children types to look for- Returns:
- typemask of the children found
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if an invalid typemask was passed in
-
getChildrenTypesOfType
Integer[] getChildrenTypesOfType(Long[] containerIds_, Integer typemask_) throws InvalidContentException, InvalidTypeMaskException Returns typemasks of all children types found within each container.- Parameters:
containerIds_
- container idstypemask_
- children types to look for- Returns:
- typemasks of the children found
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if an invalid typemask was passed in
-
getChildrenTypes
Returns a typemask of all children types found within a container.- Parameters:
containerId_
- container id- Returns:
- typemask of the children found
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
getChildrenTypes
Returns typemasks of all children types found within each container.- Parameters:
containerIds_
- container ids- Returns:
- typemasks of the children found
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
getChildrenTypes
Returns typemasks of all children types found within each container.- Parameters:
containers_
- containers- Returns:
- typemasks of the children found
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
populateTypesOfChildren
Populate the typesOfChildren field in the content beans you pass in.- Parameters:
containers_
- list of containers- Throws:
InvalidContentException
- if an invalid content item is referenced
-
getChildren
@Deprecated Content[] getChildren(Long containerId_, ContentFilter filter_, Integer modifiers_) throws InvalidContentException, InvalidTypeMaskException Deprecated.Returns the children of a container.- Parameters:
containerId_
- root content idfilter_
- applies to what children are returnedmodifiers_
- one ofContentConstants.GC_MOD_DRAFT
,ContentConstants.GC_MOD_LINKS
,ContentConstants.GC_MOD_NORMAL
, orContentConstants.GC_MOD_POPULATE_TYPES_OF_CHILDREN
- Returns:
- Content[]
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemask- See Also:
-
getChildrenIds
Long[] getChildrenIds(Long containerId_, ContentFilter filter_, Integer modifiers_) throws InvalidContentException, InvalidTypeMaskException Returns the ids of the children of a container.- Parameters:
containerId_
- root content idfilter_
- applies to what children are returnedmodifiers_
- one ofContentConstants.GC_MOD_DRAFT
,ContentConstants.GC_MOD_LINKS
,ContentConstants.GC_MOD_NORMAL
, orContentConstants.GC_MOD_POPULATE_TYPES_OF_CHILDREN
- Returns:
- content ids[]
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemask
-
getChildrenPaging
ResultPage getChildrenPaging(Long containerId_, ContentFilter filter_, Integer modifiers_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidContentException, InvalidTypeMaskException Returns the children of a container.- Parameters:
containerId_
- root content idfilter_
- applies to what children are returnedmodifiers_
- one ofContentConstants.GC_MOD_DRAFT
,ContentConstants.GC_MOD_LINKS
,ContentConstants.GC_MOD_NORMAL
, orContentConstants.GC_MOD_POPULATE_TYPES_OF_CHILDREN
startIndex_
- the index into the collection of total results at which to start. Negative numbers are treated as zeros.batchSize_
- the number of results to return. UseConstants.COUNT_ALL
to return the entire collection, but this is STRONGLY discouraged.sortProperty_
- the property by which the results will be sorted. This is one of theCOLUMN_XXX
constants inContentConstants
.sortOrder_
- the order in which to sort the results.This is one ofConstants.SORT_ORDER_ASCENDING
orConstants.SORT_ORDER_DESCENDING
- Returns:
- ResultPage of Content
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemask- See Also:
-
getAdvertisedChildren
@Deprecated Content[] getAdvertisedChildren(Long containerId_, ContentFilter filter_, Integer modifiers_) throws InvalidContentException, InvalidTypeMaskException Deprecated.Returns the advertised children of a container. This includes the content items normally visible as well as those with the visibility bit VIS_ADVERTISE set to true.- Parameters:
containerId_
- root content idfilter_
- applies to what children are returnedmodifiers_
- one ofContentConstants.GC_MOD_DRAFT
,ContentConstants.GC_MOD_LINKS
,ContentConstants.GC_MOD_NORMAL
, orContentConstants.GC_MOD_POPULATE_TYPES_OF_CHILDREN
- Returns:
- Content[]
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemask- See Also:
-
getAdvertisedChildrenIds
Long[] getAdvertisedChildrenIds(Long containerId_, ContentFilter filter_, Integer modifiers_) throws InvalidContentException, InvalidTypeMaskException -
getAdvertisedChildrenPaging
ResultPage getAdvertisedChildrenPaging(Long containerId_, ContentFilter filter_, Integer modifiers_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidContentException, InvalidTypeMaskException -
getEditablePaging
ResultPage getEditablePaging(Long rootId_, ContentFilter filter_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidContentException, InvalidTypeMaskException Get Editable Content objects paging. Retrieves all editable objects from a give root, not just direct children.- Parameters:
rootId_
- root content id: atomicfilter_
- applies to what children are returnedstartIndex_
- the index into the collection of total results at which to start. Negative numbers are treated as zeros.batchSize_
- the number of results to return. UseConstants.COUNT_ALL
to return the entire collection, but this is STRONGLY discouraged.sortProperty_
- the property by which the results will be sorted. This is one of theCOLUMN_XXX
constants inContentConstants
.sortOrder_
- the order in which to sort the results.This is one ofConstants.SORT_ORDER_ASCENDING
orConstants.SORT_ORDER_DESCENDING
- Returns:
- ResultPage of Content
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemask- See Also:
-
getAdministratablePaging
ResultPage getAdministratablePaging(Long rootId_, ContentFilter filter_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidContentException, InvalidTypeMaskException Get Administratable Content objects paging. Retrieves all objects from a given root that the user has admin rights to, not just direct children.- Parameters:
rootId_
- root content id: atomicfilter_
- applies to what children are returnedstartIndex_
- the index into the collection of total results at which to start. Negative numbers are treated as zeros.batchSize_
- the number of results to return. UseConstants.COUNT_ALL
to return the entire collection, but this is STRONGLY discouraged.sortProperty_
- the property by which the results will be sorted. This is one of theCOLUMN_XXX
constants inContentConstants
.sortOrder_
- the order in which to sort the results.This is one ofConstants.SORT_ORDER_ASCENDING
orConstants.SORT_ORDER_DESCENDING
- Returns:
- ResultPage of Content
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemask- See Also:
-
getViewablePaging
ResultPage getViewablePaging(Long rootId_, ContentFilter filter_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidContentException, InvalidTypeMaskException Get Viewable Content objects paging. Retrieves all objects from a given root that the user has viewer rights to, not just direct children.- Parameters:
rootId_
- root content id: atomicfilter_
- applies to what children are returnedstartIndex_
- the index into the collection of total results at which to start. Negative numbers are treated as zeros.batchSize_
- the number of results to return. UseConstants.COUNT_ALL
to return the entire collection, but this is STRONGLY discouraged.sortProperty_
- the property by which the results will be sorted. This is one of theCOLUMN_XXX
constants inContentConstants
.sortOrder_
- the order in which to sort the results.This is one ofConstants.SORT_ORDER_ASCENDING
orConstants.SORT_ORDER_DESCENDING
- Returns:
- ResultPage of Content
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemask- See Also:
-
getAllChildren
@Deprecated Content[] getAllChildren(Long containerId_, ContentFilter filter_, Integer modifiers_) throws InvalidContentException, InvalidTypeMaskException Deprecated.Returns all descendants in a recursive descent from root.- Parameters:
containerId_
- root content idfilter_
- applies to what children are returnedmodifiers_
- one ofContentConstants.GC_MOD_DRAFT
,ContentConstants.GC_MOD_LINKS
,ContentConstants.GC_MOD_NORMAL
, orContentConstants.GC_MOD_POPULATE_TYPES_OF_CHILDREN
- Returns:
- Content[]
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemask- See Also:
-
getAllChildrenIds
Long[] getAllChildrenIds(Long containerId_, ContentFilter filter_, Integer modifiers_) throws InvalidContentException, InvalidTypeMaskException Returns all descendant ids in a recursive descent from root.- Parameters:
containerId_
- root content idfilter_
- applies to what children are returnedmodifiers_
-ContentConstants.GC_MOD_DRAFT
- Returns:
- Content[]
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemask
-
getAllChildrenPaging
ResultPage getAllChildrenPaging(Long containerId_, ContentFilter filter_, Integer modifiers_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidContentException, InvalidTypeMaskException Returns all descendants in a recursive descent from root.- Parameters:
containerId_
- root content idfilter_
- applies to what children are returnedmodifiers_
-ContentConstants.GC_MOD_DRAFT
startIndex_
- the index into the collection of total results at which to start. Negative numbers are treated as zeros.batchSize_
- the number of results to return. UseConstants.COUNT_ALL
to return the entire collection, but this is STRONGLY discouraged.sortProperty_
- the property by which the results will be sorted. This is one of theCOLUMN_XXX
constants inContentConstants
.sortOrder_
- the order in which to sort the results.This is one ofConstants.SORT_ORDER_ASCENDING
orConstants.SORT_ORDER_DESCENDING
- Returns:
- Content[]
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemask- See Also:
-
getAllChildrenAndVersions
@Deprecated Content[] getAllChildrenAndVersions(Long containerId_, ContentFilter filter_) throws InvalidContentException, InvalidTypeMaskException Deprecated.Get all versions of all children in a given container.- Parameters:
containerId_
- root content idfilter_
- applies to what children are returned- Returns:
- all versions of all children
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemask- See Also:
-
getAllChildrenAndVersionIds
Long[] getAllChildrenAndVersionIds(Long containerId_, ContentFilter filter_) throws InvalidContentException, InvalidTypeMaskException Get ids of all versions of all children in a given container.- Parameters:
containerId_
- root content idfilter_
- applies to what children are returned- Returns:
- all versions of all children
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemask
-
getAllChildrenAndVersionsPaging
ResultPage getAllChildrenAndVersionsPaging(Long containerId_, ContentFilter filter_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidContentException, InvalidTypeMaskException Get all versions of all children in a given container.- Parameters:
containerId_
- root content idfilter_
- applies to what children are returnedstartIndex_
- the index into the collection of total results at which to start. Negative numbers are treated as zeros.batchSize_
- the number of results to return. UseConstants.COUNT_ALL
to return the entire collection, but this is STRONGLY discouraged.sortProperty_
- the property by which the results will be sorted. This is one of theCOLUMN_XXX
constants inContentConstants
.sortOrder_
- the order in which to sort the results.This is one ofConstants.SORT_ORDER_ASCENDING
orConstants.SORT_ORDER_DESCENDING
- Returns:
- all versions of all children
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemask- See Also:
-
getNumberOfChildren
Integer getNumberOfChildren(Long containerId_, Integer typemask_) throws InvalidContentException, InvalidTypeMaskException This returns the number of children matching the typemask.- Parameters:
containerId_
- root content id(s)typemask_
- specifies which content types to look for- Returns:
- integer
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if an invalid typemask was passed in
-
getNumberOfChildren
Integer[] getNumberOfChildren(Long[] containerIds_, Integer typemask_) throws InvalidContentException, InvalidTypeMaskException This returns the number of children matching the typemask for each root id specified.- Parameters:
containerIds_
- root content id(s)typemask_
- specifies which content types to look for- Returns:
- integer
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if an invalid typemask was passed in
-
getParentsToRoot
Content[] getParentsToRoot(Long id_, Integer typemask_) throws InvalidContentException, InvalidTypeMaskException, PrivilegeException This returns all of direct ancestors of a node, starting with the node's parent and tracing up to the root.- Parameters:
id_
- content idtypemask_
- specifies which content types to return- Returns:
- content list of parent path to root; only matching types are included. This goes from parent to parent, ending in the root.
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if an invalid typemask was passed inPrivilegeException
- if the user does not have permission to take this action
-
getParentsToRootIds
Long[] getParentsToRootIds(Long id_, Integer typemask_) throws InvalidContentException, InvalidTypeMaskException, PrivilegeException This returns ids of all of direct ancestors of a node, starting with the node's parent and tracing up to the root.- Parameters:
id_
- content idtypemask_
- specifies which content types to return- Returns:
- content ids of parent path to root; only matching types are included. This goes from parent to parent, ending in the root.
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if an invalid typemask was passed inPrivilegeException
- if the user does not have permission to take this action
-
getParentsFromRoot
Content[] getParentsFromRoot(Long id_, Integer typemask_) throws InvalidContentException, InvalidTypeMaskException This returns all of direct ancestors of a node, starting with the root and tracing down to the node's parent.- Parameters:
id_
- content idtypemask_
- specifies which content types to return- Returns:
- content list of parent path to root; only matching types are included. This goes from root down to id.
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if an invalid typemask was passed in
-
getParentsFromRootIds
Long[] getParentsFromRootIds(Long id_, Integer typemask_) throws InvalidContentException, InvalidTypeMaskException This return ids of all of direct ancestors of a node, starting with the root and tracing down to the node's parent.- Parameters:
id_
- content idtypemask_
- specifies which content types to return- Returns:
- content ids of parent path to root; only matching types are included. This goes from parent to parent, ending in the root.
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if an invalid typemask was passed in
-
updateFields
void updateFields(Content content_, Integer[] fields_, Integer unique_) throws InvalidContentException, InvalidUserException, IllegalRecursionException, DuplicateUuidException, PrivilegeException, InsufficientNameUniquenessException Updates the specified fields of a content item's LATEST version. To move all the versions of a content usemove(Long, Long)
- Parameters:
content_
- Content object to updatefields_
- Integer[] of field names to update; others except id ignored.unique_
- how unique the name must be (one ofContentConstants.UNIQUE_NONE
,ContentConstants.UNIQUE_FOR_TYPE
,ContentConstants.UNIQUE_FOR_PARENT
, orContentConstants.UNIQUE_FOR_ALL
)- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidUserException
- if an invalid user is referencedIllegalRecursionException
- if parent refers to selfDuplicateUuidException
- if a content item with the same uuid already existsPrivilegeException
- if the user does not have the permissions to update the contentInsufficientNameUniquenessException
- if the content name is not unique according to the unique_ parameter
-
updateVersionFields
void updateVersionFields(Content content_, Integer versionNumber, Integer[] fields_, Integer unique_) throws InvalidContentException, InvalidUserException, IllegalRecursionException, DuplicateUuidException, PrivilegeException, InsufficientNameUniquenessException Updates the specified fields of a content item's specific version. To move all the versions of a content usemove(Long, Long)
- Parameters:
content_
- The content object whose data should be used for the update. The id field must be populated to indicate which persisted content object should be updated.versionNumber
- The version of the target content that should be updated.fields_
- The fields to update (other fields in the passed content object will be ignored).unique_
- How unique the name must be, if it's one of the fields being updated (the value must be one ofContentConstants.UNIQUE_NONE
,ContentConstants.UNIQUE_FOR_TYPE
,ContentConstants.UNIQUE_FOR_PARENT
, orContentConstants.UNIQUE_FOR_ALL
).- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidUserException
- if an invalid user is referenced (if creator is updated and invalid)IllegalRecursionException
- if parent refers to selfDuplicateUuidException
- if a content item with the same uuid already existsPrivilegeException
- if the user does not have the permissions to update the contentInsufficientNameUniquenessException
- if the content name is not unique according to the unique_ parameter
-
updateFields
void updateFields(Content[] contents_, Integer[] fields_, Integer unique_) throws InvalidContentException, InvalidUserException, IllegalRecursionException, DuplicateUuidException, PrivilegeException, InsufficientNameUniquenessException Updates the specified fields of the content items. To move all the versions of the contents usemove(Long[], Long)
- Parameters:
contents_
- Content objects to updatefields_
- Integer[] of field names to update; others except id ignored.unique_
- how unique the name must be (one ofContentConstants.UNIQUE_NONE
,ContentConstants.UNIQUE_FOR_TYPE
,ContentConstants.UNIQUE_FOR_PARENT
, orContentConstants.UNIQUE_FOR_ALL
)- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidUserException
- if an invalid user is referencedIllegalRecursionException
- if parent refers to selfDuplicateUuidException
- if a content item with the same uuid already existsPrivilegeException
- if the user does not have the permissions to update the contentInsufficientNameUniquenessException
- if the content name is not unique according to the unique_ parameter
-
setSizeOfDocumentVersion
int setSizeOfDocumentVersion(Long documentContentId) throws InvalidContentException, PrivilegeException Deprecated.since 23.2. Writing to a Document viaDocumentOutputStream
orContentUploadOutputStream
will update the Document size metadata automatically upon closing the stream.Sets the size property of a Document. This method calculates the size of the data saved for the given Document and saves the value within the Document's metadata (the size can then be retrieved by retrieving the Document's Content object and reading thesize field
).- Parameters:
documentContentId
- The id of the target Document. This id must be the content id of the specific version for which the size should be set.- Returns:
- The size of the Document in bytes.
- Throws:
InvalidContentException
- If there is no content object with the given id.PrivilegeException
- If the user does not have sufficient privileges to update the Document's metadata.
-
updateAllChildrenAndVersionsVisibility
void updateAllChildrenAndVersionsVisibility(Long id, boolean maskType, int bitmask) throws InvalidContentException, PrivilegeException Update the visibility bitmask for all children and versions of the given id. This is typically used to update the searchability of content. Example to set all ids under contentIdOfKnowledgeCenter as VIS_SEARCHABLE: updateAllChildrenAndVersionsVisibility(contentIdOfKnowledgeCenter, true, VIS_SEARCHABLE) Example to clear all ids under contentIdOfKnowledgeCenter from VIS_SEARCHABLE: updateAllChildrenAndVersionsVisibility(contentIdOfKnowledgeCenter, false, 255-VIS_SEARCHABLE) This is equivalent to updating the visibility on all ids returned by getAllChildrenAndVersionIds for the given id.- Parameters:
id
-maskType
- false for bitwise AND, true for bitwise ORbitmask
- (0...255) value that will be AND'd or OR'd against visibility flag- Throws:
PrivilegeException
- if no edit privilege on idInvalidContentException
- if id is invalid, deleted or deactivated- See Also:
-
updateAllChildrenAndVersionsExpiration
void updateAllChildrenAndVersionsExpiration(Long id, Integer expirationDays) throws InvalidContentException, PrivilegeException Update the expiration days for all children and versions of the given id (including the content with the given id). This is typically used to update the expiration of a knowledge center's children. Updating just the individual field will only take effect on newly created children not on existing data; use this method to update existing data. This is equivalent to updating the expirationDays on all ids returned by getAllChildrenAndVersionIds for the given id.- Parameters:
id
-expirationDays
- the number of days after which documents in the knowledge centers will expire. If null, the logid's (typically knowledge center id's) expiration days will be used.- Throws:
PrivilegeException
- if no edit privilege on idInvalidContentException
- if id is invalid, deleted or deactivated- See Also:
-
move
void move(Long id_, Long destinationParent_) throws InvalidContentException, PrivilegeException, IllegalRecursionException This moves a Content item from one location to another, cutting connection from current parent, setting connection to new parent, updating bytes used in parents. UnlikeupdateFields(Content, Integer[], Integer)
, it moves all the versions of the content, that supports versioning, i.e.Document
,FreeformRule
,Constant
andQueryRule
.- Parameters:
id_
- content id(s) to movedestinationParent_
- parent under which to move the id: atomic- Throws:
InvalidContentException
- if an invalid content item is referencedPrivilegeException
- if the user does not have permission to take this actionIllegalRecursionException
- if the destination is a descendant of the item you are moving
-
move
void move(Long[] ids_, Long destinationParent_) throws InvalidContentException, PrivilegeException, IllegalRecursionException This moves Content items from one location to another, cutting connection from current parent, setting connection to new parent, updating bytes used in parents. UnlikeupdateFields(Content[], Integer[], Integer)
, it moves all the versions of the contents, that support versioning, i.e.Document
,FreeformRule
,Constant
andQueryRule
.- Parameters:
ids_
- content id(s) to movedestinationParent_
- parent under which to move the id: atomic- Throws:
InvalidContentException
- if an invalid content item is referencedPrivilegeException
- if the user does not have permission to take this actionIllegalRecursionException
- if the destination is a descendant of the item you are moving
-
copy
This copies Content item from one location to another. The source is copied to the target using the default CopySource rules (COPY_INCLUDE_INTO+COPY_CREATOR). After copying the Content metadata, the underlying file representation must be copied (or linked, as desired). Loop through the CopyReference return list for the information. The copy method returns CopyReference[], as it can make copies of many content items. For each CopyReference you can use theCopyReference.copyContents()
API in order to complete the copy.- Parameters:
source
- content id(s) to movetarget
- parent under which to copy the id- Throws:
InvalidContentException
- if an invalid content item is referencedPrivilegeException
- if the user does not have permission to take this action
-
copy
This copies Content item from one location to another. The source ids are copied using default CopySource rules (COPY_INCLUDE_INTO+COPY_CREATOR). After copying the Content metadata, the underlying file representation must be copied (or linked, as desired). Loop through the CopyReference return list for the information. The copy method returns CopyReference[], as it can make copies of many content items. For each CopyReference you can use theCopyReference.copyContents()
API in order to complete the copy. All sources are processed, forming the desired list to copy, before any action is taken.- Parameters:
source
- content id(s) to movetarget
- parent under which to copy the id- Throws:
InvalidContentException
- if an invalid content item is referencedPrivilegeException
- if the user does not have permission to take this action
-
copy
CopyReference[] copy(CopySource[] source, Long target) throws InvalidContentException, PrivilegeException This copies Content item from one location to another. The CopySource represents explicit rules about the copying. After copying the Content metadata, the underlying file representation must be copied (or linked, as desired). Loop through the CopyReference return list for the information. The copy method returns CopyReference[], as it can make copies of many content items. For each CopyReference you can use theCopyReference.copyContents()
API in order to complete the copy. All CopySources are processed, forming the desired list to copy, before any action is taken.- Parameters:
source
- content id(s) to movetarget
- parent under which to copy the id- Throws:
InvalidContentException
- if an invalid content item is referencedPrivilegeException
- if the user does not have permission to take this action
-
delete
Approval delete(Long id_, Boolean deleteChildren_) throws InvalidContentException, HasChildrenException, PrivilegeException Deletes all versions of the given content item.- Parameters:
id_
- content id(s), may be inactivedeleteChildren_
- delete children (1 is do so, 0 is give exception if children)- Returns:
- Approval Bean (content ids:Long[];pending ids;names of pending;logging id of pending;admin users of approver;admin groups of approver)
- Throws:
InvalidContentException
- if an invalid content item is referencedHasChildrenException
- if the content item has childrenPrivilegeException
- if the user does not have permission to take this action
-
delete
Approval delete(Long[] ids_, Boolean deleteChildren_) throws InvalidContentException, HasChildrenException, PrivilegeException Deletes all versions of the given content item.- Parameters:
ids_
- content id(s), may be inactivedeleteChildren_
- delete children (1 is do so, 0 is give exception if children)- Returns:
- Approval Bean (content ids:Long[];pending ids;names of pending;logging id of pending;admin users of approver;admin groups of approver)
- Throws:
InvalidContentException
- if an invalid content item is referencedHasChildrenException
- if the content item has childrenPrivilegeException
- if the user does not have permission to take this action
-
deleteContent
Approval deleteContent(Long[] ids_, Boolean deleteChildren_) throws InvalidContentException, HasChildrenException, PrivilegeException Deletes the given content items.- Parameters:
ids_
- content id(s), may be inactivedeleteChildren_
- delete children (1 is do so, 0 is give exception if children)- Returns:
- Approval Bean (content ids:Long[];pending ids;names of pending;logging id of pending;admin users of approver;admin groups of approver)
- Throws:
InvalidContentException
- if an invalid content item is referencedHasChildrenException
- if the content item has childrenPrivilegeException
- if the user does not have permission to take this action
-
deleteVersion
Approval deleteVersion(Long id_, Integer versionNumber_, Boolean children_) throws InvalidContentException, HasChildrenException, InvalidVersionException, PrivilegeException Deletes specified version(s) of the given content item.- Parameters:
id_
- content id(s), may be inactiveversionNumber_
- version number to deletechildren_
- delete children (1 is do so, 0 is give exception if children)- Returns:
- Approval Bean (content ids:Long[];pending ids;names of pending;logging id of pending;admin users of approver;admin groups of approver)
- Throws:
InvalidContentException
- if an invalid content item is referencedHasChildrenException
- if the content item has childrenInvalidVersionException
- if an invalid version is referencedPrivilegeException
- if the user does not have permission to take this action
-
deleteVersions
Approval deleteVersions(Long id_, Integer[] versionNumbers_, Boolean children_) throws InvalidContentException, HasChildrenException, InvalidVersionException, PrivilegeException Deletes specified version(s) of the given content item.- Parameters:
id_
- content id(s), may be inactiveversionNumbers_
- version numbers to deletechildren_
- delete children (1 is do so, 0 is give exception if children)- Returns:
- Approval Bean (content ids:Long[];pending ids;names of pending;logging id of pending;admin users of approver;admin groups of approver)
- Throws:
InvalidContentException
- if an invalid content item is referencedHasChildrenException
- if the content item has childrenInvalidVersionException
- if an invalid version is referencedPrivilegeException
- if the user does not have permission to take this action
-
deactivate
Approval deactivate(Long id_, Boolean deactivateChildren_) throws InvalidContentException, HasChildrenException Deactivates all versions of the given content item. Does not remove the file from disk and does not log in deletion.log.- Parameters:
id_
- content id(s), may be inactivedeactivateChildren_
- deactivate children (1 is do so, 0 is give exception if children)- Returns:
- Approval Bean (content ids:Long[];pending ids;names of pending;logging id of pending;admin users of approver;admin groups of approver)
- Throws:
InvalidContentException
- if an invalid content item is referencedHasChildrenException
- if the content item has children
-
deactivate
Approval deactivate(Long[] ids_, Boolean deactivateChildren_) throws InvalidContentException, HasChildrenException Deactivates all versions of the given content items. Does not remove the file from disk and does not log in deletion.log.- Parameters:
ids_
- content id(s), may be inactivedeactivateChildren_
- deactivate children (1 is do so, 0 is give exception if children)- Returns:
- Approval Bean (content ids:Long[];pending ids;names of pending;logging id of pending;admin users of approver;admin groups of approver)
- Throws:
InvalidContentException
- if an invalid content item is referencedHasChildrenException
- if the content item has children
-
deactivateVersion
Approval deactivateVersion(Long id_, Integer versionNumber_, Boolean deactivateChildren_) throws InvalidContentException, HasChildrenException, InvalidVersionException Deactivates specified version of the given content item. Does not remove the file from disk and does not log in deletion.log- Parameters:
id_
- content id(s), may be inactiveversionNumber_
- version number to deactivatedeactivateChildren_
- deactivate children (1 is do so, 0 is give exception if children)- Returns:
- Approval Bean (content ids:Long[];pending ids;names of pending;logging id of pending;admin users of approver;admin groups of approver)
- Throws:
InvalidContentException
- if an invalid content item is referencedHasChildrenException
- if the content item has childrenInvalidVersionException
- if an invalid version is referenced
-
deactivateVersions
Approval deactivateVersions(Long id_, Integer[] versionNumbers_, Boolean deactivateChildren_) throws InvalidContentException, HasChildrenException, InvalidVersionException, PrivilegeException Deactivates specified version(s) of the given content item. Does not remove the file from disk and does not log in deletion.log.- Parameters:
id_
- content id(s), may be inactiveversionNumbers_
- version numbers to deactivatedeactivateChildren_
- deactivate children (1 is do so, 0 is give exception if children)- Returns:
- Approval Bean (content ids:Long[];pending ids;names of pending;logging id of pending;admin users of approver;admin groups of approver)
- Throws:
InvalidContentException
- if an invalid content item is referencedHasChildrenException
- if the content item has childrenInvalidVersionException
- if an invalid version is referencedPrivilegeException
-
reactivate
Reactivates the given content item.- Parameters:
id_
- content id(s), may be inactive- Throws:
InvalidContentException
- if an invalid content item is referenced
-
reactivate
Reactivates the given content items.- Parameters:
ids_
- content id(s), may be inactive- Throws:
InvalidContentException
- if an invalid content item is referenced
-
getInactive
@Deprecated Content[] getInactive(Long root_, ContentFilter filter_) throws InvalidContentException, InvalidTypeMaskException Deprecated.Gets all inactive content items within the specified root.- Parameters:
root_
- content id: atomicfilter_
- only content matching the filter will be returned- Returns:
- list of inactive content items
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemask- See Also:
-
getInactiveIds
Long[] getInactiveIds(Long root_, ContentFilter filter_) throws InvalidContentException, InvalidTypeMaskException Gets all inactive content ids within the specified root.- Parameters:
root_
- content id: atomicfilter_
- only content matching the filter will be returned- Returns:
- list of inactive content ids
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemask
-
getInactiveIdsNoSystem
Long[] getInactiveIdsNoSystem(Long root_, ContentFilter filter_) throws InvalidContentException, InvalidTypeMaskException Gets all inactive content ids within the specified root but filters out system ids.- Parameters:
root_
- content id: atomicfilter_
- only content matching the filter will be returned- Returns:
- list of inactive content ids
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemask
-
getInactivePaging
ResultPage getInactivePaging(Long root_, ContentFilter filter_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidContentException, InvalidTypeMaskException Gets all inactive content items within the specified root.- Parameters:
root_
- content id: atomicfilter_
- only content matching the filter will be returnedstartIndex_
- the index into the collection of total results at which to start. Negative numbers are treated as zeros.batchSize_
- the number of results to return. UseConstants.COUNT_ALL
to return the entire collection, but this is STRONGLY discouraged.sortProperty_
- the property by which the results will be sorted. This is one of theCOLUMN_XXX
constants inContentConstants
.sortOrder_
- the order in which to sort the results.This is one ofConstants.SORT_ORDER_ASCENDING
orConstants.SORT_ORDER_DESCENDING
- Returns:
- list of inactive content items
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemask- See Also:
-
getMyInactiveIds
Long[] getMyInactiveIds()This retrieves the content ids in the 'Recycle Bin/Trashcan' of the current user.- Returns:
- ids of deactivated Content items created by the current user
-
getMyInactive
Deprecated.usegetMyInactivePaging(int, int, Integer, Integer)
insteadThis retrieves the content items in the 'Recycle Bin/Trashcan' of the current user.- Returns:
- list of deactivated Content items created by the current user
- See Also:
-
getMyInactivePaging
ResultPage getMyInactivePaging(int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) This retrieves the content items in the 'Recycle Bin/Trashcan' of the current user.- Parameters:
startIndex_
- the index into the collection of total results at which to start. Negative numbers are treated as zeros.batchSize_
- the number of results to return. UseConstants.COUNT_ALL
to return the entire collection, but this is STRONGLY discouraged.sortProperty_
- the property by which the results will be sorted. This is one of theCOLUMN_XXX
constants inContentConstants
.sortOrder_
- the order in which to sort the results.This is one ofConstants.SORT_ORDER_ASCENDING
orConstants.SORT_ORDER_DESCENDING
- Returns:
- list of deactivated Content items created by the current user
- See Also:
-
deleteMyInactive
Integer deleteMyInactive()This is an 'empty Recycle Bin/Trashcan' method.- Returns:
- count of deleted items
-
getLinks
Returns all links to a given content id.- Parameters:
id_
- content id(s) from which links will be returned- Returns:
- content list
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
getLinkIds
Returns all link ids to a given content id.- Parameters:
id_
- content id(s) from which links will be returned- Returns:
- link ids
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
getLinksOfType
Content[] getLinksOfType(Long id_, Integer typemask_) throws InvalidContentException, InvalidTypeMaskException Returns all links to a given content id.- Parameters:
id_
- content id(s) from which links will be returnedtypemask_
- the types of content to return- Returns:
- content list
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if an invalid typemask was passed in
-
getLinkIdsOfType
Long[] getLinkIdsOfType(Long id_, Integer typemask_) throws InvalidContentException, InvalidTypeMaskException Returns all links to a given content id.- Parameters:
id_
- content id(s) from which links will be returnedtypemask_
- the types of content to return- Returns:
- content ids (flat if multiple)
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if an invalid typemask was passed in
-
addLinks
Deprecated.Add a link. A Link is a symbolic link, as in a filesystem for Documents. It's also used in Communities to link to 'Featured' Documents.- Parameters:
id_
- content id to which links will be added: atomiclinks_
- content ids which will be added as links to first parameter content id- Throws:
InvalidContentException
- if an invalid content item is referenced
-
removeLinks
Deprecated.Remove a link.- Parameters:
id_
- content id from which links will be removed: atomiclinks_
- ids which will be removed from links of first parameter content id- Throws:
InvalidContentException
- if an invalid content item is referenced
-
getLinkedBy
Returns the ids of those content items that link to the given id.- Parameters:
id_
- content id to which returned ids link- Returns:
- content ids
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
searchByRoot
@Deprecated Content[] searchByRoot(Long rootId_, String regex_, ContentFilter filter_) throws InvalidTypeMaskException Deprecated.Searches for content from a given root.- Parameters:
rootId_
- The root to search inregex_
- A regular expression to match against name and description. The regex "*text*" will be used.filter_
- A filter for the search results- Returns:
- list of content items matching the search
- Throws:
InvalidTypeMaskException
- if the filter contains an invalid typemask- See Also:
-
searchIdsByRoot
Long[] searchIdsByRoot(Long rootId_, String regex_, ContentFilter filter_) throws InvalidTypeMaskException Searches for content from a given root.- Parameters:
rootId_
- The root to search inregex_
- A regular expression to match against name and description. The regex "*text*" will be used.filter_
- A filter for the search results- Returns:
- list of content ids matching the search
- Throws:
InvalidTypeMaskException
- if the filter contains an invalid typemask
-
searchByRootPaging
ResultPage searchByRootPaging(Long rootId_, String regex_, ContentFilter filter_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidTypeMaskException Searches for content from a given root.- Parameters:
rootId_
- The root to search inregex_
- A regular expression to match against name and description. The regex "*text*" will be used.filter_
- A filter for the search resultsstartIndex_
- the index into the collection of total results at which to start. Negative numbers are treated as zeros.batchSize_
- the number of results to return. UseConstants.COUNT_ALL
to return the entire collection, but this is STRONGLY discouraged.sortProperty_
- the property by which the results will be sorted. This is one of theCOLUMN_XXX
constants inContentConstants
.sortOrder_
- the order in which to sort the results.This is one ofConstants.SORT_ORDER_ASCENDING
orConstants.SORT_ORDER_DESCENDING
- Returns:
- list of content items matching the search
- Throws:
InvalidTypeMaskException
- if the filter contains an invalid typemask- See Also:
-
searchWithin
Deprecated.Search for content within the given containers.- Parameters:
regex
- A regular expression to match against name and description. The regex "*contains*" will be used.ids_
- The ids of the containers within which to search- Returns:
- list of content items matching the search
- Throws:
InvalidContentException
- if an invalid content item is referenced- See Also:
-
searchIdsWithin
Search for content within the given containers.- Parameters:
regex
- A regular expression to match against name and description. The regex "*contains*" will be used.ids_
- The ids of the containers within which to search- Returns:
- list of content ids matching the search
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
searchWithinPaging
ResultPage searchWithinPaging(String regex_, Long[] ids_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidContentException Search for content within the given containers.- Parameters:
regex_
- A regular expression to match against name and description. The regex "*contains*" will be used.ids_
- The ids of the containers within which to searchstartIndex_
- the index into the collection of total results at which to start. Negative numbers are treated as zeros.batchSize_
- the number of results to return. UseConstants.COUNT_ALL
to return the entire collection, but this is STRONGLY discouraged.sortProperty_
- the property by which the results will be sorted. This is one of theCOLUMN_XXX
constants inContentConstants
.sortOrder_
- the order in which to sort the results.This is one ofConstants.SORT_ORDER_ASCENDING
orConstants.SORT_ORDER_DESCENDING
- Returns:
- list of content items matching the search
- Throws:
InvalidContentException
- if an invalid content item is referenced- See Also:
-
queryByRoot
@Deprecated Content[] queryByRoot(Long root_, String queryText_, ContentFilter filter_) throws InvalidTypeMaskException Deprecated.This is more advanced search, accepting special keywords.
Reserved Keyword Notes active By default, only active is searched. inactive or nonactiv This is the only way to search inactive. hierarchy This limits to those ids visible in hierarchy. onhierarchy This limits to those ids NOT visible in hierarchy. quota This limits to those ids that are quota constrained. nonquota This limits to those ids that are NOT quota constrained. logged This limits to those ids that are logged. unlogged or nonlogged This limits to those ids that are NOT logged. indexable This limits to those ids that are indexable. nonindexable This limits to those ids that are NOT indexable. author:name This is a case-sensitive contains for the creator's username. author (current) This limits to content created by current user. name:text description:text starts:text This is name and description text*, case-insensitive. ends:text This is name and description *text, case-insensitive. contains:text This is name and description *text*, case-insensitive. subscribed This limits to current user's subscriptions. unsubscribed or nonsubscribed This limits to current user's subscriptions. bytes:number approved unapproved created:time modified:time expiration:days extension:ext
Other text is searched for as 'contains' in name and description.
For name and description:- : and = are both equals, <> and >< and != are unequal,
- < is less than, > is greater than, <= is less than or equal to, >= is greater than or equal to.
- Parameters:
root_
- The root from which to searchqueryText_
- This is the query to perform.filter_
- A filter for the search results- Returns:
- list of content items matching the search
- Throws:
InvalidTypeMaskException
- if the filter contains an invalid typemask- See Also:
-
queryIdsByRoot
Long[] queryIdsByRoot(Long root_, String queryText_, ContentFilter filter_) throws InvalidTypeMaskException This is more advanced search, accepting special keywords.- Parameters:
root_
- The root from which to searchqueryText_
- This is the query to perform.filter_
- A filter for the search results- Returns:
- list of content ids matching the search
- Throws:
InvalidTypeMaskException
- if the filter contains an invalid typemask
-
queryByRootPaging
ResultPage queryByRootPaging(Long root_, String queryText_, ContentFilter filter_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidTypeMaskException This is more advanced search, accepting special keywords.- Parameters:
root_
- The root from which to searchqueryText_
- This is the query to perform.filter_
- A filter for the search resultsstartIndex_
- the index into the collection of total results at which to start. Negative numbers are treated as zeros.batchSize_
- the number of results to return. UseConstants.COUNT_ALL
to return the entire collection, but this is STRONGLY discouraged.sortProperty_
- the property by which the results will be sorted. This is one of theCOLUMN_XXX
constants inContentConstants
.sortOrder_
- the order in which to sort the results.This is one ofConstants.SORT_ORDER_ASCENDING
orConstants.SORT_ORDER_DESCENDING
- Returns:
- list of content items matching the search
- Throws:
InvalidTypeMaskException
- if the filter contains an invalid typemask- See Also:
-
getExpired
@Deprecated Content[] getExpired(Long root_, Integer days_, ContentFilter filter_) throws InvalidContentException, InvalidTypeMaskException Deprecated.Returns the list of content items within the given root which will be expired within the given number of days.- Parameters:
root_
- content id: only content under root will be returneddays_
- Days in the future to check for expirationfilter_
- Only content matching the filter will be returned- Returns:
- list of expired content items
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemask- See Also:
-
getExpiredIds
@Deprecated Long[] getExpiredIds(Long root_, Integer days_, ContentFilter filter_) throws InvalidContentException, InvalidTypeMaskException Deprecated.Returns the list of content items within the given root which will be expired within the given number of days.- Parameters:
root_
- content id: only content under root will be returneddays_
- Days in the future to check for expirationfilter_
- Only content matching the filter will be returned- Returns:
- list of expired content ids
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemask
-
getExpiredPaging
@Deprecated ResultPage getExpiredPaging(Long root_, Integer days_, ContentFilter filter_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidContentException, InvalidTypeMaskException Deprecated.Returns the list of content items within the given root which will be expired within the given number of days.- Parameters:
root_
- content id: only content under root will be returneddays_
- Days in the future to check for expirationfilter_
- Only content matching the filter will be returnedstartIndex_
- the index into the collection of total results at which to start. Negative numbers are treated as zeros.batchSize_
- the number of results to return. UseConstants.COUNT_ALL
to return the entire collection, but this is STRONGLY discouraged.sortProperty_
- the property by which the results will be sorted. This is one of theCOLUMN_XXX
constants inContentConstants
.sortOrder_
- the order in which to sort the results.This is one ofConstants.SORT_ORDER_ASCENDING
orConstants.SORT_ORDER_DESCENDING
- Returns:
- list of expired content items
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemask- See Also:
-
unexpire
Deprecated.This unexpires the content, adding its parent expiration days to itself.- Parameters:
id_
- content id- Throws:
InvalidContentException
- if an invalid content item is referenced
-
unexpire
Deprecated.This unexpires the contents, adding their parent expiration days to themselves.- Parameters:
ids_
- content ids- Throws:
InvalidContentException
- if an invalid content item is referenced
-
lock
@Deprecated void lock(Long id_) throws InvalidContentException, PendingApprovalException, ContentExpiredException, NotLockOwnerException, PrivilegeException Deprecated.Exclusively locks the base id.- Parameters:
id_
- content id to lock- Throws:
InvalidContentException
- if an invalid content item is referencedPendingApprovalException
- if the content is pending approvalContentExpiredException
- if the content you reference is expiredNotLockOwnerException
- if the content is locked and the current user is not the ownerPrivilegeException
-
lock
@Deprecated void lock(Long[] ids_) throws InvalidContentException, PendingApprovalException, ContentExpiredException, NotLockOwnerException, PrivilegeException Deprecated.Exclusively locks the base ids.- Parameters:
ids_
- content ids to lock- Throws:
InvalidContentException
- if an invalid content item is referencedPendingApprovalException
- if the content is pending approvalContentExpiredException
- if the content you reference is expiredNotLockOwnerException
- if the content is locked and the current user is not the ownerPrivilegeException
-
unlock
Deprecated.Only unlocks those ids currently locked by the current user.- Parameters:
id_
- id to unlock- Returns:
- ids unlocked
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
unlock
Deprecated.Only unlocks those ids currently locked by the current user.- Parameters:
ids_
- ids to unlock- Returns:
- ids unlocked
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
breakLock
Deprecated.If the user attempts to break his or her own lock (or something unlocked) then no additional security privilege is required; treat it like an unlock. If the user attempts to break another's lock, then admin security privilege is required, or an exception will be thrown.- Parameters:
id_
- content id of lock to break- Returns:
- ids with broken locks
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
breakLock
Deprecated.If the user attempts to break his or her own lock (or something unlocked) then no additional security privilege is required; treat it like an unlock. If the user attempts to break another's lock, then admin security privilege is required, or an exception will be thrown.- Parameters:
ids_
- content id of lock to break- Returns:
- ids with broken locks
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
approve
Deprecated.Approve the given content item.- Parameters:
id_
- content id(s)- Returns:
- Approved bean (those ids that were successfully approved;action approved;those users who requested said review)
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
approve
Deprecated.Approve the given content items.- Parameters:
ids_
- content id(s)- Returns:
- Approved beans (those ids that were successfully approved;action approved;those users who requested said review)
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
approveVersion
@Deprecated Approved approveVersion(Long id_, Integer versionNumber_) throws InvalidContentException, InvalidVersionException, InvalidApprovalStateException Deprecated.Approve the given version of a content item.- Parameters:
id_
- content idversionNumber_
- version number- Returns:
- Approved bean (those ids that were successfully approved;action approved;those users who requested said review)
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidVersionException
- if an invalid version is referencedInvalidApprovalStateException
- if there is an invalid content's state
-
reject
Deprecated.Reject the given content item.- Parameters:
id_
- content id(s)- Returns:
- Approved bean (those ids that were successfully rejected;action rejected;those users who requested said review)
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
reject
Deprecated.Reject the given content items.- Parameters:
ids_
- content id(s)- Returns:
- Approved beans (those ids that were successfully rejected;action rejected;those users who requested said review)
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
rejectVersion
@Deprecated Approved rejectVersion(Long id_, Integer versionNumber_) throws InvalidContentException, InvalidVersionException, InvalidRejectionStateException Deprecated.Reject the given version of a content item.- Parameters:
id_
- content idversionNumber_
- version number- Returns:
- Approved bean (those ids that were successfully rejected;action rejected;those users who requested said review)
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidVersionException
- if an invalid version is referencedInvalidRejectionStateException
-
notifyApproved
Deprecated.Sends a notification to the user associated with the approval. It receives the objects returned by any of theaccept
andreject
service methods.- Parameters:
approved
- approved bean- Throws:
InvalidContentException
- if an invalid content item is referenced
-
requestAccess
Deprecated.Request access to the given content item. Note: This is also done implicitly by adding it as a favorite when the user possesses insufficient permission.- Parameters:
id_
- content id- Throws:
InvalidContentException
- if an invalid content item is referenced
-
requestAccess
Deprecated.Request access to the given content items. Note: This is also done implicitly by adding it as a favorite when the user possesses insufficient permission.- Parameters:
ids_
- content ids- Throws:
InvalidContentException
- if an invalid content item is referenced
-
checkAccess
Returns the current user access to a content item. (This call is for Collaboration compatibility.)- Parameters:
id_
- content id- Returns:
- 0=unsubcribed, 1=subscribed/favorite, 2=pending access
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
checkAccess
Returns the current user access to a content items. (This call is for Collaboration compatibility.)- Parameters:
ids_
- content ids- Returns:
- 0=unsubcribed, 1=subscribed/favorite, 2=pending access
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
approveUsers
String[] approveUsers(Long id_, String[] users_) throws InvalidUserException, InvalidContentException Approve access to the specified content item for a set of users.- Parameters:
id_
- content idusers_
- set of users to approve- Returns:
- users who were successfully approved; they should then be notified by the caller
- Throws:
InvalidUserException
- if an invalid user is referencedInvalidContentException
- if an invalid content item is referenced
-
rejectUsers
String[] rejectUsers(Long id_, String[] users_) throws InvalidUserException, InvalidContentException Reject access to the specified content item for a set of users.- Parameters:
id_
- content idusers_
- set of users to reject- Returns:
- users who were successfully rejected; they should then be notified by the caller
- Throws:
InvalidUserException
- if an invalid user is referencedInvalidContentException
- if an invalid content item is referenced
-
getPending
@Deprecated Content[] getPending(Long id, ContentFilter filter) throws InvalidContentException, InvalidTypeMaskException Deprecated.Get the Content items that have approvals pending action by the current user. This is the inverse of the getRequests, which are requests to another from the current user. This populates the actionRequested, actionRequester.- Parameters:
id
-filter
-- Returns:
- Throws:
InvalidContentException
InvalidTypeMaskException
-
getPendingPaging
@Deprecated ResultPage getPendingPaging(Long id, ContentFilter filter, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidContentException, InvalidTypeMaskException Deprecated.Get the Content items that have approvals pending action by the current user. This is the inverse of the getRequests, which are requests to another from the current user. This populates the actionRequested, actionRequester.- Parameters:
id
- root content idfilter
- applies to what children are returnedstartIndex_
- the index into the collection of total results at which to start. Negative numbers are treated as zeros.batchSize_
- the number of results to return. UseConstants.COUNT_ALL
to return the entire collection, but this is STRONGLY discouraged.sortProperty_
- the property by which the results will be sorted. This is one of theCOLUMN_XXX
constants inContentConstants
.sortOrder_
- the order in which to sort the results.This is one ofConstants.SORT_ORDER_ASCENDING
orConstants.SORT_ORDER_DESCENDING
- Returns:
- Content[]
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemask- See Also:
-
getNumberOfRequests
Integer getNumberOfRequests()This returns the count of the requests returned by getRequests. By only returning a count, and not all the data, this method is faster and more suitable for status updates.- Returns:
- number of content ids for which a request is outstanding
-
getRequests
Content[] getRequests()Once a user requests an action on a Content item that requires approval, that request is stored with the Content item. This method returns those items that are still pending for this user or the user's group.- Returns:
- list of content items pending approval from the current user
-
getPendingUsers
This accumulates all users pending for the given content item, returning only the unique names.- Parameters:
id_
- content id- Returns:
- usernames of pending users
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
getPendingReview
Deprecated.This returns the review code for each given id; this may include NO_REVIEW (0).- Parameters:
id_
- content id- Returns:
- review id(s)
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
getPendingReviews
Deprecated.This returns the review code for each given id; this may include NO_REVIEW (0).- Parameters:
ids_
- content ids- Returns:
- review id(s)
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
getFavoritesByRoot
@Deprecated Content[] getFavoritesByRoot(Long rootId_, ContentFilter filter_, Boolean includeExpiredContent_) throws InvalidTypeMaskException Deprecated.Retrieve all content items within the given root which are marked as favorites for the current user.- Parameters:
rootId_
- root within which to get favoritesfilter_
- Only content matching the filter will be returnedincludeExpiredContent_
- set to true to include expired content- Returns:
- favorite contents
- Throws:
InvalidTypeMaskException
- if the filter contains an invalid typemask- See Also:
-
getFavoriteByRootIds
@Deprecated Long[] getFavoriteByRootIds(Long rootId_, ContentFilter filter_, Boolean includeExpiredContent_) throws InvalidTypeMaskException Deprecated.Retrieve all content items within the given root which are marked as favorites for the current user.- Parameters:
rootId_
- root within which to get favoritesfilter_
- Only content matching the filter will be returnedincludeExpiredContent_
- set to true to include expired content- Returns:
- favorite content ids
- Throws:
InvalidTypeMaskException
- if the filter contains an invalid typemask
-
getFavoritesByRootPaging
@Deprecated ResultPage getFavoritesByRootPaging(Long rootId_, ContentFilter filter_, Boolean includeExpiredContent_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidTypeMaskException Deprecated.Retrieve all content items within the given root which are marked as favorites for the current user.- Parameters:
rootId_
- root within which to get favoritesfilter_
- Only content matching the filter will be returnedincludeExpiredContent_
- set to true to include expired contentstartIndex_
- the index into the collection of total results at which to start. Negative numbers are treated as zeros.batchSize_
- the number of results to return. UseConstants.COUNT_ALL
to return the entire collection, but this is STRONGLY discouraged.sortProperty_
- the property by which the results will be sorted. This is one of theCOLUMN_XXX
constants inContentConstants
.sortOrder_
- the order in which to sort the results.This is one ofConstants.SORT_ORDER_ASCENDING
orConstants.SORT_ORDER_DESCENDING
- Returns:
- favorite contents
- Throws:
InvalidTypeMaskException
- if the filter contains an invalid typemask- See Also:
-
isFavorite
Returns true if content is marked as a favorite for the current user.- Parameters:
id_
- content id- Returns:
- true if content is marked as favorite
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
areFavorites
Deprecated.Returns true for each content which is marked as a favorite for the current user.- Parameters:
ids_
- content ids- Returns:
- true for each content which is marked as a favorite
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
areFavorites
Deprecated.Returns true for each content which is marked as a favorite for the current user.- Parameters:
contents_
- content items- Returns:
- true for each content which is marked as a favorite
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
populateFavorites
Deprecated.Populates the favorite field in the content beans you pass in.- Parameters:
contents_
- an array of Content objects- Throws:
InvalidContentException
- if an invalid content item is referenced
-
addFavorite
Deprecated.Mark the given content item as a favorite for the current user.- Parameters:
id_
- content id- Returns:
- PendingAccess bean (may be 0 length)
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
addFavoriteForUsers
@Deprecated void addFavoriteForUsers(Long id, String[] usernames) throws InvalidContentException, PrivilegeException Deprecated.Mark the given content item as a favorite for the given users. Requires administrator privileges.- Parameters:
id
- content id- Throws:
InvalidContentException
- if an invalid content item is referencedPrivilegeException
- if the user does not have permission to take this action
-
addFavorites
Deprecated.Mark the given content items as a favorite for the current user.- Parameters:
ids_
- content ids- Returns:
- PendingAccess bean (may be 0 length)
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
removeFavorite
Deprecated.Remove a content item as a favorite for the current user.- Parameters:
id_
- content id- Throws:
InvalidContentException
- if an invalid content item is referenced
-
removeFavorites
Deprecated.Remove content items as favorites for the current user.- Parameters:
ids_
- content ids- Throws:
InvalidContentException
- if an invalid content item is referenced
-
removeFavoriteForUsers
@Deprecated void removeFavoriteForUsers(Long id_, String[] username_) throws InvalidContentException, PrivilegeException Deprecated.Remove content item as a favorite for the given users.- Parameters:
id_
- content idusername_
- list of usernames- Throws:
InvalidContentException
- if an invalid content item is referencedPrivilegeException
- if the user does not have permission to take this action
-
cleanseFavorites
Deprecated.This call eliminates those favorites to which have been deactivated/deleted, or to which the user no longer has access.- Returns:
- valid favorite ids
-
cleanseApprovals
Deprecated.This call eliminates those queued approvals that have already been handled by other users. (This is done automatically whenever something is approved or rejected by the current user.) -
getRoleMap
Get the role map for a content item.- Parameters:
id_
- singularincludeAggregate_
- include aggregate (ContentConstants.RM_AGGREGATE
orContentConstants.RM_EXPLICIT
)- Returns:
- RoleMap
- Throws:
InvalidContentException
- if an invalid content item is referenced- See Also:
-
setRoleMap
RoleMapChanges setRoleMap(Long id_, ContentRoleMap rolemap_, Boolean contract_) throws InvalidContentException, InvalidUserException, PrivilegeException Set the role map for a content item.- Parameters:
id_
- singularrolemap_
- singularcontract_
- if true will remove users lower in the hierarchy who are removed from all access in this rolemap- Returns:
- bean with fields approvedGroups, rejectedGroups, approvedUser, rejectedUser
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidUserException
- if an invalid user is referencedPrivilegeException
- if the user does not have permission to take this action- See Also:
-
setRoleMapForAllVersions
void setRoleMapForAllVersions(Long id_, ContentRoleMap rolemap_, Boolean contract_) throws InvalidContentException, InvalidUserException, PrivilegeException Sets the role map for all the versions of a content item.- Parameters:
id_
- The id of the content item whose role map should be set.rolemap_
- The role map to set.contract_
- if true will remove users lower in the hierarchy who are removed from all access in this rolemap- Throws:
InvalidContentException
- if an invalid content id is specifiedInvalidUserException
- if an invalid user is referencedPrivilegeException
- if the user does not have permission to take this action
-
getRestrictionMap
Deprecated.Gets the restriction map for aContent
object.- Parameters:
id_
- Restriction map will be returned for the object specified by this id.- Returns:
- RoleMap with the same roles as a ContentRoleMap, indicating the restrictions on this object.
- Throws:
InvalidContentException
- if an invalid content item is referencedPrivilegeException
- if the user does not have permission to take this action- See Also:
-
setRestrictionMap
@Deprecated void setRestrictionMap(Long id_, RoleMap roleMap_) throws InvalidContentException, PrivilegeException, InvalidUserException Deprecated.Sets the restriction map for aContent
object.- Parameters:
id_
- Restriction map will be set for the object specified by this id.roleMap_
- RoleMap with the same roles as a ContentRoleMap, indicating the restrictions on this object.- Throws:
InvalidContentException
- if an invalid content item is referencedPrivilegeException
- if the user does not have permission to take this actionInvalidUserException
- if an invalid user is referenced- See Also:
-
setActorsInRoles
void setActorsInRoles(Long id_, String[] users_, String[][] userRoles_, Long[] groups_, String[][] groupRoles_) throws InvalidRoleException, InvalidContentException, PrivilegeException, InvalidUserException Set security roles for a content item by users and groups. (also supports imaginary "deny" role which automatically sets deny_readers and deny_authors)- Parameters:
id_
- content idusers_
- users to set security foruserRoles_
- contains an array of security roles for each corresponding entry in the users_ array. It is legal to have null within this array.groups_
- groups to set security forgroupRoles_
- contains an array of security roles for each corresponding entry in the groups_ array. It is legal to have null within this array.- Throws:
InvalidRoleException
- if an invalid role is passed inInvalidContentException
- if an invalid content item is referencedPrivilegeException
- if the user does not have permission to take this actionInvalidUserException
- if an invalid user is referenced
-
getRoleSet
Get theContentRoleSet
associated with the content with the ID provided.- Parameters:
id_
- content id- Returns:
- the role set associated with the given content
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
getRoleSets
Get theContentRoleSet
s associated with the given contents.- Parameters:
contents_
- list of content items- Returns:
- the role set associated with the given content id
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
getRoleSets
Get theContentRoleSet
s associated with the given content ids.- Parameters:
ids_
- content id- Returns:
- the role sets associated with the given content
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
getRoleSetForUser
@Deprecated ContentRoleSet getRoleSetForUser(String username_, Long id_) throws InvalidContentException, PrivilegeException, InvalidUserException, DeprecatedException Deprecated.Requires two sets of credentials.Get theContentRoleSet
associated with the given content for a specific user.- Parameters:
username_
- user to retrieve role set for (must match current user, or will throw DeprecatedException)id_
- content id- Returns:
- the role sets associated with the given content
- Throws:
InvalidContentException
- if an invalid content item is referencedPrivilegeException
- if the user does not have permission to take this actionInvalidUserException
- if an invalid user is referencedDeprecatedException
-
getRoleSetsForUser
@Deprecated ContentRoleSet[] getRoleSetsForUser(String username_, Long[] ids_) throws InvalidContentException, PrivilegeException, InvalidUserException, DeprecatedException Deprecated.Requires two sets of credentials.Get theContentRoleSet
s associated with the given contents for a specific user.- Parameters:
username_
- user to retrieve role set for (must match current user, or will throw DeprecatedException)ids_
- content ids- Returns:
- the role sets associated with the given contents
- Throws:
PrivilegeException
- if the user does not have permission to take this actionInvalidContentException
- if an invalid content item is referencedInvalidUserException
- if an invalid user is referencedDeprecatedException
-
getRoleSetForGroup
ContentRoleSet getRoleSetForGroup(Long groupId_, Long id_) throws InvalidContentException, PrivilegeException Get theContentRoleSet
associated with the given content for a specific group.- Parameters:
groupId_
- group to retrieve role set forid_
- content id- Returns:
- the role sets associated with the given content
- Throws:
InvalidContentException
- if an invalid content item is referencedPrivilegeException
- if the user does not have permission to take this action
-
getRoleSetsForGroup
ContentRoleSet[] getRoleSetsForGroup(Long groupId_, Long[] ids_) throws InvalidContentException, PrivilegeException Get theContentRoleSet
s associated with the given contents for a specific group.- Parameters:
groupId_
- group to retrieve role set forids_
- content id- Returns:
- the role sets associated with the given content
- Throws:
InvalidContentException
- if an invalid content item is referencedPrivilegeException
- if the user does not have permission to take this action
-
populateRoleSets
Populates the roleSet field in the content beans you pass in.- Parameters:
contents_
- an array of Content objects- Throws:
InvalidContentException
- if an invalid content item is referencedPrivilegeException
- if the user does not have permission to take this action
-
populateExtensionInfo
Populates the extensionInfo field in the document beans you pass in. Only applies to documents- Parameters:
contents_
- an array of Document objects- Throws:
InvalidContentException
- if an invalid content item is referencedPrivilegeException
- if the user does not have permission to take this action
-
localize
Localizes the name, description, and parent name for the given content(s).- Parameters:
content_
- content to localize
-
localize
Localizes the name, description, and parent name for the given content(s).- Parameters:
contents_
- content to localize
-
localize
Localizes the name, description, and parent name for the given content(s).- Parameters:
content_
- content to localizelocale_
- localize according to this local
-
localize
Localizes the name, description, and parent name for the given content(s).- Parameters:
contents_
- content to localizelocale_
- localize according to this local
-
addUserInRole
void addUserInRole(Long id_, String role_, String username_) throws InvalidUserException, InvalidContentException, InvalidRoleException Add user to content in given role.- Parameters:
id_
- content idrole_
- from ContentConstants (e.g.ContentConstants.ROLE_READERS
)username_
- username- Throws:
InvalidUserException
- if an invalid user is referencedInvalidContentException
- if an invalid content item is referencedInvalidRoleException
- if an invalid role is passed in
-
addUsersInRole
void addUsersInRole(Long id, String role, String[] username) throws InvalidUserException, InvalidContentException, InvalidRoleException Add users to content in given role.- Parameters:
id
- content idrole
- from ContentConstants (e.g.ContentConstants.ROLE_READERS
)username
- list of usernames to add role- Throws:
InvalidUserException
- if an invalid user is referencedInvalidContentException
- if an invalid content item is referencedInvalidRoleException
- if an invalid role is passed in
-
removeUserFromRole
void removeUserFromRole(Long id, String role, String username) throws InvalidUserException, InvalidContentException, InvalidRoleException Remove user from content in given role.- Parameters:
id
- content idrole
- from ContentConstants (e.g.ContentConstants.ROLE_READERS
)username
- user to remove role from- Throws:
InvalidUserException
- if an invalid user is referencedInvalidContentException
- if an invalid content item is referencedInvalidRoleException
- if an invalid role is passed in
-
removeUsersFromRole
void removeUsersFromRole(Long id, String role, String[] username) throws InvalidUserException, InvalidContentException, InvalidRoleException Remove users from content in given role.- Parameters:
id
- content idrole
- from ContentConstants (e.g.ContentConstants.ROLE_READERS
)username
- list of usernames to remove role from- Throws:
InvalidUserException
- if an invalid user is referencedInvalidContentException
- if an invalid content item is referencedInvalidRoleException
- if an invalid role is passed in
-
addGroupInRole
void addGroupInRole(Long id, String role, Long groupId) throws InvalidContentException, InvalidRoleException Add group to content in given role.- Parameters:
id
- content idrole
- from ContentConstants (e.g.ContentConstants.ROLE_READERS
)groupId
- group to add role to- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidRoleException
- if an invalid role is passed in
-
addGroupsInRole
void addGroupsInRole(Long id, String role, Long[] groupId) throws InvalidContentException, InvalidRoleException Add groups to content in given role.- Parameters:
id
- content idrole
- from ContentConstants (e.g.ContentConstants.ROLE_READERS
)groupId
- list of groups to add role to- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidRoleException
- if an invalid role is passed in
-
removeGroupFromRole
void removeGroupFromRole(Long id, String role, Long groupId) throws InvalidContentException, InvalidRoleException Remove group from content in given role.- Parameters:
id
- content idrole
- from ContentConstants (e.g.ContentConstants.ROLE_READERS
)groupId
- group to remove role from- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidRoleException
- if an invalid role is passed in
-
removeGroupsFromRole
void removeGroupsFromRole(Long id, String role, Long[] groupId) throws InvalidContentException, InvalidRoleException Remove groups from content in given role.- Parameters:
id
- content idrole
- from ContentConstants (e.g.ContentConstants.ROLE_READERS
)groupId
- list of groups to remove role from- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidRoleException
- if an invalid role is passed in
-
getViewable
@Deprecated Long[] getViewable(Long root, ContentFilter filter) throws InvalidContentException, InvalidTypeMaskException Deprecated.Get all active, non-expired ids off the root, where view role held by user.- Parameters:
root
- content idfilter
- Only content matching the filter will be returned- Returns:
- content ids
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemask- See Also:
-
getViewableByUser
Long[] getViewableByUser(Long root, ContentFilter filter, String username) throws InvalidUserException, InvalidContentException, InvalidTypeMaskException, DeprecatedException Get all active, non-expired ids off the root, where view role held by user.- Parameters:
root
- content idfilter
- Only content matching the filter will be returnedusername
- user (must match current user, or will throw DeprecatedException)- Returns:
- content ids
- Throws:
InvalidUserException
- if an invalid user is referencedInvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemaskDeprecatedException
-
getEditable
@Deprecated Long[] getEditable(Long root, ContentFilter filter) throws InvalidContentException, InvalidTypeMaskException Deprecated.Get all active, non-expired ids off the root, where editor role held by user.- Parameters:
root
- content idfilter
- Only content matching the filter will be returned- Returns:
- content ids
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemask- See Also:
-
getEditableByUser
Long[] getEditableByUser(Long root_, ContentFilter filter_, String username_) throws InvalidUserException, InvalidContentException, InvalidTypeMaskException, DeprecatedException Get all active, non-expired ids off the root, where editor role held by user.- Parameters:
root_
- content idfilter_
- Only content matching the filter will be returnedusername_
- username (must match current user, or will throw DeprecatedException)- Returns:
- content ids
- Throws:
InvalidUserException
- if an invalid user is referencedInvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemaskDeprecatedException
-
getAdministratable
@Deprecated Long[] getAdministratable(Long root, ContentFilter filter) throws InvalidContentException, InvalidTypeMaskException Deprecated.Get all active, non-expired ids off the root, where administratable role held by user.- Parameters:
root
- content idfilter
- Only content matching the filter will be returned- Returns:
- content ids
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemask- See Also:
-
getAdministratableByUser
Long[] getAdministratableByUser(Long root, ContentFilter filter, String username) throws InvalidUserException, InvalidContentException, InvalidTypeMaskException, DeprecatedException Get all active, non-expired ids off the root, where administratable role held by user.- Parameters:
root
- content idfilter
- only content matching the filter will be returnedusername
- username (must match current user, or will throw DeprecatedException)- Returns:
- content ids
- Throws:
InvalidUserException
- if an invalid user is referencedInvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if the filter contains an invalid typemaskDeprecatedException
-
canAdministrate
Can current user Administrate?- Parameters:
id
- content id- Returns:
- boolean (0 if not, 1 if so)
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
canAdministrate
Can current user Administrate?- Parameters:
ids
- content ids- Returns:
- boolean array (0 if not, 1 if so)
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
canAdministrate
Can current user Administrate?- Parameters:
content
- content array- Returns:
- boolean array (0 if not, 1 if so)
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
canUserAdministrate
Boolean canUserAdministrate(Long id, String username) throws InvalidUserException, InvalidContentException, DeprecatedException Can given User Administrate?- Parameters:
id
- content idusername
- username (must match current user, or will throw DeprecatedException)- Returns:
- boolean (0 if not, 1 if so)
- Throws:
InvalidUserException
- if an invalid user is referencedInvalidContentException
- if an invalid content item is referencedDeprecatedException
-
canUserAdministrate
Boolean[] canUserAdministrate(Long[] ids, String username) throws InvalidUserException, InvalidContentException Can given User Administrate?- Parameters:
ids
- content idsusername
- username (must match current user, or will throw DeprecatedException)- Returns:
- boolean array (0 if not, 1 if so)
- Throws:
InvalidUserException
- if an invalid user is referencedInvalidContentException
- if an invalid content item is referenced
-
canGroupAdministrate
Can given Group Administrate?- Parameters:
id
- content idgroupId
- group id- Returns:
- boolean (0 if not, 1 if so)
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
canGroupAdministrate
Can given Group Administrate?- Parameters:
ids
- content idsgroupId
- group id- Returns:
- boolean array (0 if not, 1 if so)
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
isViewNotRestricted
Is view privilege restricted?- Parameters:
id_
- content id- Returns:
- true if not restricted
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
isEditNotRestricted
Is edit privilege restricted?- Parameters:
id_
- content id- Returns:
- true if not restricted
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
isAdministrateNotRestricted
Is administrate privilege restricted?- Parameters:
id_
- content id- Returns:
- true if not restricted
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
canEdit
Can current user Edit?- Parameters:
id
- content id- Returns:
- boolean (0 if not, 1 if so)
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
canEdit
Can current user Edit?- Parameters:
ids
- content ids- Returns:
- boolean array (0 if not, 1 if so)
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
canEdit
Can current user Edit?- Parameters:
content_
- content list- Returns:
- boolean array (0 if not, 1 if so)
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
canUserEdit
Boolean canUserEdit(Long id, String username) throws InvalidUserException, InvalidContentException, DeprecatedException Can given User Edit?- Parameters:
id
- content idusername
- username (must match current user, or will throw DeprecatedException)- Returns:
- boolean (0 if not, 1 if so)
- Throws:
InvalidUserException
- if an invalid user is referencedInvalidContentException
- if an invalid content item is referencedDeprecatedException
-
canUserEdit
Boolean[] canUserEdit(Long[] ids, String username) throws InvalidUserException, InvalidContentException Can given User Edit?- Parameters:
ids
- content idusername
- username (must match current user, or will throw DeprecatedException)- Returns:
- boolean array (0 if not, 1 if so)
- Throws:
InvalidUserException
- if an invalid user is referencedInvalidContentException
- if an invalid content item is referenced
-
canGroupEdit
Can given Group Edit?- Parameters:
id
- content idgroupId
- group id- Returns:
- boolean (0 if not, 1 if so)
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
canGroupEdit
Can given Group Edit?- Parameters:
ids
- content idsgroupId
- group id- Returns:
- boolean array (0 if not, 1 if so)
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
canView
Can current user View?- Parameters:
id
- content id- Returns:
- boolean (0 if not, 1 if so)
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
canView
Can current user View?- Parameters:
ids
- content ids- Returns:
- boolean array (0 if not, 1 if so)
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
canView
Can current user View?- Parameters:
content
- content list- Returns:
- boolean array (0 if not, 1 if so)
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
canUserView
Boolean canUserView(Long id, String username) throws InvalidUserException, InvalidContentException, DeprecatedException Can given User View?- Parameters:
id
- content idusername
- username (must match current user, or will throw DeprecatedException)- Returns:
- boolean (0 if not, 1 if so)
- Throws:
InvalidUserException
- if an invalid user is referencedInvalidContentException
- if an invalid content item is referencedDeprecatedException
-
canUserView
Boolean[] canUserView(Long[] ids, String username) throws InvalidUserException, InvalidContentException Can given User View?- Parameters:
ids
- content idsusername
- username (must match current user, or will throw DeprecatedException)- Returns:
- boolean array (0 if not, 1 if so)
- Throws:
InvalidUserException
- if an invalid user is referencedInvalidContentException
- if an invalid content item is referenced
-
canGroupView
Can given Group View?- Parameters:
id
- content idgroupId
- group id- Returns:
- boolean (0 if not, 1 if so)
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
canGroupView
Can given Group View?- Parameters:
ids
- content idsgroupId
- group id- Returns:
- boolean array (0 if not, 1 if so)
- Throws:
InvalidContentException
- if an invalid content item is referenced
-
getAccessLevel
Integer getAccessLevel(Long id_, Integer typemask_) throws InvalidContentException, InvalidTypeMaskException Get the Access Level for the current user for a content item.- Parameters:
id_
- content idtypemask_
- specifies the content type- Returns:
- access level. One of
ContentConstants.AL_ADMIN
,ContentConstants.AL_EDITOR
,ContentConstants.AL_INVALID_ID
,ContentConstants.AL_NONE
,ContentConstants.AL_VIEWER
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if an invalid typemask was passed in
-
getAccessLevel
Integer getAccessLevel(Long id_, int typemask_) throws InvalidContentException, InvalidTypeMaskException Get the Access Level for the current user for a content item.- Parameters:
id_
- content idtypemask_
- specifies the content type- Returns:
- access level. One of
ContentConstants.AL_ADMIN
,ContentConstants.AL_EDITOR
,ContentConstants.AL_INVALID_ID
,ContentConstants.AL_NONE
,ContentConstants.AL_VIEWER
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if an invalid typemask was passed in
-
getAccessLevel
Integer[] getAccessLevel(Long[] ids_, Integer typemask_) throws InvalidContentException, InvalidTypeMaskException Get the Access Level for the current user for a list of content items.- Parameters:
ids_
- content idtypemask_
- specifies the content type- Returns:
- access level array. One of
ContentConstants.AL_ADMIN
,ContentConstants.AL_EDITOR
,ContentConstants.AL_INVALID_ID
,ContentConstants.AL_NONE
,ContentConstants.AL_VIEWER
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if an invalid typemask was passed in
-
getAccessLevel
Integer[] getAccessLevel(Long[] ids_, int typemask_) throws InvalidContentException, InvalidTypeMaskException Get the Access Level for the current user for a list of content items.- Parameters:
ids_
- content idtypemask_
- specifies the content type- Returns:
- access level array. One of
ContentConstants.AL_ADMIN
,ContentConstants.AL_EDITOR
,ContentConstants.AL_INVALID_ID
,ContentConstants.AL_NONE
,ContentConstants.AL_VIEWER
- Throws:
InvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if an invalid typemask was passed in
-
getAccessLevelForUser
Integer getAccessLevelForUser(Long id_, Integer typemask_, String username_) throws InvalidUserException, InvalidContentException, InvalidTypeMaskException, DeprecatedException Get the Access Level for the given user for a content item.- Parameters:
id_
- content idtypemask_
- specifies the content typeusername_
- username (must match current user, or will throw DeprecatedException)- Returns:
- access level. One of
ContentConstants.AL_ADMIN
,ContentConstants.AL_EDITOR
,ContentConstants.AL_INVALID_ID
,ContentConstants.AL_NONE
,ContentConstants.AL_VIEWER
- Throws:
InvalidUserException
- if an invalid user is referencedInvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if an invalid typemask was passed inDeprecatedException
-
getAccessLevelForUser
Integer[] getAccessLevelForUser(Long[] ids_, Integer typemask_, String username_) throws InvalidUserException, InvalidContentException, InvalidTypeMaskException, DeprecatedException Get the Access Level for the given user for a list of content items.- Parameters:
ids_
- content idtypemask_
- specifies the content typeusername_
- username (must match current user, or will throw DeprecatedException)- Returns:
- access level array. One of
ContentConstants.AL_ADMIN
,ContentConstants.AL_EDITOR
,ContentConstants.AL_INVALID_ID
,ContentConstants.AL_NONE
,ContentConstants.AL_VIEWER
- Throws:
InvalidUserException
- if an invalid user is referencedInvalidContentException
- if an invalid content item is referencedInvalidTypeMaskException
- if an invalid typemask was passed inDeprecatedException
-
getWhatsNew
@Deprecated Content[] getWhatsNew(Long root_, Integer maxResults_, ContentFilter filter_) throws InvalidTypeMaskException, InvalidContentException Deprecated.Returns list of most recently modified content items within the specified root.- Parameters:
root_
- content idmaxResults_
- max number of content items to returnfilter_
- only content matching the filter will be returned- Returns:
- content list
- Throws:
InvalidTypeMaskException
- if the filter contains an invalid typemaskInvalidContentException
- if an invalid content item is referenced- See Also:
-
getWhatsNewIds
Long[] getWhatsNewIds(Long root_, Integer maxResults_, ContentFilter filter_) throws InvalidTypeMaskException, InvalidContentException Returns id list of most recently modified content items within the specified root.- Parameters:
root_
- content idmaxResults_
- max number of content items to returnfilter_
- only content matching the filter will be returned- Returns:
- id list
- Throws:
InvalidTypeMaskException
- if the filter contains an invalid typemaskInvalidContentException
- if an invalid content item is referenced
-
getWhatsNewPaging
ResultPage getWhatsNewPaging(Long root_, Integer maxResults_, ContentFilter filter_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidTypeMaskException, InvalidContentException Returns list of most recently modified content items within the specified root.- Parameters:
root_
- content idmaxResults_
- max number of content items to returnfilter_
- only content matching the filter will be returnedstartIndex_
- the index into the collection of total results at which to start. Negative numbers are treated as zeros.batchSize_
- the number of results to return. UseConstants.COUNT_ALL
to return the entire collection, but this is STRONGLY discouraged.sortProperty_
- the property by which the results will be sorted. This is one of theCOLUMN_XXX
constants inContentConstants
.sortOrder_
- the order in which to sort the results.This is one ofConstants.SORT_ORDER_ASCENDING
orConstants.SORT_ORDER_DESCENDING
- Returns:
- content list
- Throws:
InvalidTypeMaskException
- if the filter contains an invalid typemaskInvalidContentException
- if an invalid content item is referenced- See Also:
-
setPersonalId
Set the id for your Personal content item. Currently refers to your personal knowledge center.- Parameters:
id_
- of the content object to set as your personal content- Throws:
InvalidContentException
- if an invalid content item is referenced- See Also:
-
getPersonalId
Get the id for your Personal content item. Currently refers to your personal knowledge center. If no personal knowledge center exists it will be created.- Returns:
- the id for your Personal content
- Throws:
InvalidPersonalContentException
- if Personal Content does not exist for this user- See Also:
-
getPersonal
Get your Personal content item. Currently refers to your personal knowledge center. If no personal knowledge center exists it will be created.- Returns:
- your Personal content item
- Throws:
InvalidPersonalContentException
- if Personal Content does not exist for this user
-
getPersonalAndTeamsIds
Get children of 'Personal and Teams'. If no personal knowledge center exists it will be created.- Parameters:
filter_
- only content matching the filter will be returned- Returns:
- content ids
- Throws:
InvalidPersonalContentException
- if Personal Content does not exist for this user
-
getPersonalAndTeams
@Deprecated Content[] getPersonalAndTeams(ContentFilter filter_) throws InvalidPersonalContentException Deprecated.Get children of 'Personal and Teams'. If no personal knowledge center exists it will be created.- Parameters:
filter_
- only content matching the filter will be returned- Returns:
- content list
- Throws:
InvalidPersonalContentException
- if Personal Content does not exist for this user- See Also:
-
getPersonalAndTeamsPaging
ResultPage getPersonalAndTeamsPaging(ContentFilter filter_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidPersonalContentException Get children of 'Personal and Teams'. If no personal knowledge center exists it will be created.- Parameters:
filter_
- only content matching the filter will be returnedstartIndex_
- the index into the collection of total results at which to start. Negative numbers are treated as zeros.batchSize_
- the number of results to return. UseConstants.COUNT_ALL
to return the entire collection, but this is STRONGLY discouraged.sortProperty_
- the property by which the results will be sorted. This is one of theCOLUMN_XXX
constants inContentConstants
.sortOrder_
- the order in which to sort the results.This is one ofConstants.SORT_ORDER_ASCENDING
orConstants.SORT_ORDER_DESCENDING
- Returns:
- content ids
- Throws:
InvalidPersonalContentException
- if Personal Content does not exist for this user- See Also:
-
browse
@Deprecated Content[] browse(Long root, ContentFilter filter) throws InvalidContentException, PrivilegeException Deprecated.Browse includes: what the user may see via group permissions, including favorites, no personal content items, including advertised content items not visible, but not already in favorites. Typically used with Personal Knowledge Centers off of Knowledge Root.- Parameters:
root
- content idfilter
- Only content matching the filter will be returned- Returns:
- list of content items
- Throws:
InvalidContentException
- if an invalid content item is referencedPrivilegeException
- if the user does not have permission to take this action
-
browseIds
Long[] browseIds(Long root, ContentFilter filter) throws InvalidContentException, PrivilegeException Browse includes: what the user may see via group permissions, including favorites, no personal content items, including advertised content items not visible, but not already in favorites. Typically used with Personal Knowledge Centers off of Knowledge Root.- Parameters:
root
- content idfilter
- Only content matching the filter will be returned- Returns:
- list of content item ids
- Throws:
InvalidContentException
- if an invalid content item is referencedPrivilegeException
- if the user does not have permission to take this action
-
browsePaging
ResultPage browsePaging(Long root, ContentFilter filter, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidContentException, PrivilegeException Browse includes: what the user may see via group permissions, including favorites, no personal content items, including advertised content items not visible, but not already in favorites. Typically used with Personal Knowledge Centers off of Knowledge Root.- Parameters:
root
- content idfilter
- Only content matching the filter will be returnedstartIndex_
- the index into the collection of total results at which to start. Negative numbers are treated as zeros.batchSize_
- the number of results to return. UseConstants.COUNT_ALL
to return the entire collection, but this is STRONGLY discouraged.sortProperty_
- the property by which the results will be sorted. This is one of theCOLUMN_XXX
constants inContentConstants
.sortOrder_
- the order in which to sort the results.This is one ofConstants.SORT_ORDER_ASCENDING
orConstants.SORT_ORDER_DESCENDING
- Returns:
- list of content items
- Throws:
InvalidContentException
- if an invalid content item is referencedPrivilegeException
- if the user does not have permission to take this action- See Also:
-
getDownloadLogType
Integer getDownloadLogType()Gets the download log type. Currently always returns TYPE_KC.- Returns:
- download log type
-
updateUsernames
@Deprecated void updateUsernames(String[] oldUsernames_, String[] newUsernames_, long maxExpirationTimeInSeconds_) throws IllegalArgumentException, PrivilegeException, DuplicateNameException Deprecated.DEPRECATED: SeeUserService.renameUsersByUuid(java.lang.String[], java.lang.String[])
Updates a list of old usernames to new usernames.If successful, this method must be followed by
commitUpdateUsernames()
. AftercommitUpdateUsernames
has been called, the old usernames will still be active, but will expire after the interval specified bymaxExpirationTimeInSeconds_
; ifupdateUsernames
is successful butcommitUpdateUsernames
is not called, the new usernames will not become active.If unsuccessful, this method should be followed by
rollbackUpdateUsernames()
. This will simply free memory dedicated to mapping old usernames to new usernames.Note: Only this or the CollaborationService updateUsernames must be called. Do not call both.
- Parameters:
oldUsernames_
- the usernames to be updatednewUsernames_
- the usernames to which the old usernames will be updatedmaxExpirationTimeInSeconds_
- the interval, in seconds, aftercommitUpdateUsernames
has been called, after which the old usernames will expire. If this parameter is zero or a negative value the old usernames will expire instantly. After expiration, the old usernames will no longer be valid.- Throws:
IllegalArgumentException
- if the length ofoldUsernames_
is not the same as the length ofnewUsernames_
.PrivilegeException
- if the current user is not a system administratorDuplicateNameException
- if anyoldUsernames_
ornewUsernames_
contain any duplicates, or if an old username is being updated to a username that already existsServiceException
- if any system-level error occurs
-
rollbackUpdateUsernames
Deprecated.DEPRECATED: SeeUserService.renameUsersByUuid(java.lang.String[], java.lang.String[])
Rolls back an update of usernames.This method should be called if
updateUsernames(String[], String[], long)
is unsuccessful. The rollback will simply free memory dedicated to mapping old usernames to new usernames.- Throws:
ServiceException
- if any system-level error occurs
-
commitUpdateUsernames
Deprecated.DEPRECATED: SeeUserService.renameUsersByUuid(java.lang.String[], java.lang.String[])
Commits an update of usernames.This method should be preceded by a call to
updateUsernames(String[], String[], long)
. After the commit, the old usernames will be temporarily active, and will expire after the interval specified bymaxExpirationTimeInSeconds_
; ifcommitUpdateUsernames
is not called, the new usernames will not become active.- Throws:
ServiceException
- if any system-level error occurs
-
getSystemId
Deprecated.usegetIdByUuid(String)
instead. This method will be removed in a future releaseGet the system id corresponding to the given name K Supplied names include: community (the system default community) kc (the system kc) image_folder_id leader_message_channel_image_folder_id priority_image_folder_id indicator_image_folder_id reports_folder_id.- Parameters:
name_
- this is a known name for a system Content id- Returns:
- system id, or null for unknown
- See Also:
-
getSystemIds
Deprecated.usegetIdsByUuid(String[])
instead. This method will be removed in a future releaseGet the system ids corresponding to the given names.- Parameters:
names_
- these are the known names for a system Content id- Returns:
- list of system ids (-1 for unknown)
- See Also:
-
getSystemNames
Deprecated.Get all system names.- Returns:
- name array (it will be small)
-
setSystemId
Deprecated.Usecreate(Content, Integer)
with a pre-populated UUID and the flagContentConstants.VIS_SYSTEM
.Set a system name to a system id.- Parameters:
name_
- system name, must globally uniqueid_
- content id- Throws:
InvalidContentException
- if an invalid content item is referenced- See Also:
-
setSystemIds
@Deprecated void setSystemIds(String[] names_, Long[] ids_) throws InvalidContentException, IllegalArgumentException Deprecated.Usecreate(Content[], Integer)
with pre-populated UUIDs and the flagContentConstants.VIS_SYSTEM
.Set system names to system ids.- Parameters:
names_
- system names, must globally uniqueids_
- content ids- Throws:
InvalidContentException
- if an invalid content item is referencedIllegalArgumentException
- if the length ofnames_
is different from the length ofids_
- See Also:
-
setRoot
Deprecated.usesetAsRoot(Long)
Sets the given name to be a system id, and its own root, splitting it from its existing hierarchy. Setting as root sets its parent to itself, so it won't traverse further up the tree, and it detaches from the old root. This method also sets the system id; no need for a separate call to call setSystemId().- Parameters:
name_
- root nameid_
- root id- Throws:
InvalidContentException
- if an invalid content item is referenced
-
setAsRoot
Sets the given id as its own root, splitting it from its existing hierarchy. Setting it as root sets its parent to itself, so it won't traverse further up the tree, and it detaches from the old root.- Parameters:
id
- root id- Throws:
InvalidContentException
- if an invalid content item is referenced
-
suggest
Queries for content and returns a JSON formatted string to be used by autocomplete.- Parameters:
query_
- querymaxItems_
- max number of items to returnparams_
- list of information on what is being suggested and what format the results should be in. valid types are rules.groupResults_
- if specifying more than one SuggestParam, would you like to group the results by type, or mixed together and sorted? Default is true. If grouped, order of types matches the order of the suggestParams passed in.- Returns:
- a JSON formatted string
-
suggest
String suggest(String query_, int maxItems_, SuggestParam[] params_, Boolean groupResults_, Long[] allowList) Queries for content and returns a JSON formatted string to be used by autocomplete.- Parameters:
query_
- querymaxItems_
- max number of items to returnparams_
- list of information on what is being suggested and what format the results should be in. valid types are rules.groupResults_
- if specifying more than one SuggestParam, would you like to group the results by type, or mixed together and sorted? Default is true. If grouped, order of types matches the order of the suggestParams passed in.allowList
- list of IDs that will be automatically added to returned results, filtered by query. Ignored if null or empty.- Returns:
- a JSON formatted string
-
adjustCounter
Integer adjustCounter(Long id_, Integer value) throws InvalidContentException, PrivilegeException, InvalidTypeMaskException Adjust a rules based constant (counter) of type integer or double by the given adjustment value. This is useful for atomically incrementing or decrementing global constant counters. Note, that while this is useful for ensuring that read/update/write errors do not occur, the propagation of the update is the same as all constant updates. Also, no new version of the id is created -- it is the same id as before. (This is to prevent a million counter updates from creating a million separate content items.)- Parameters:
id_
- rule id of integer or double constantvalue_
- adjustment value (e.g., 1 to increase by 1, -1 to decrease by 1, etc.)- Returns:
- new value
- Throws:
InvalidContentException
- if an invalid content item is referencedPrivilegeException
- if the user does not have permission to take this actionInvalidTypeMaskException
- for any type error, including adjusting non-rule, non-constant, non-integer or -double.
-
adjustCounter
Double adjustCounter(Long id_, Double value) throws InvalidContentException, PrivilegeException, InvalidTypeMaskException Adjust a rules based constant (counter) of type integer or double by the given adjustment value. This is useful for atomically incrementing or decrementing global constant counters. Note, that while this is useful for ensuring that read/update/write errors do not occur, the propagation of the update is the same as all constant updates. Also, no new version of the id is created -- it is the same id as before. (This is to prevent a million counter updates from creating a million separate content items.)- Parameters:
id_
- rule id of integer or double constantvalue_
- adjustment value (e.g., 1 to increase by 1, -1 to decrease by 1, etc.)- Returns:
- new value
- Throws:
InvalidContentException
- if an invalid content item is referencedPrivilegeException
- if the user does not have permission to take this actionInvalidTypeMaskException
- for any type error, including adjusting non-rule, non-constant, non-integer or -double.
-
moveKnowledgeCenter
void moveKnowledgeCenter(Long kcId_, Long communityId_) throws InvalidContentException, PrivilegeException, IllegalRecursionException, InvalidStateException Move a KC to a community. This method will also update the Content Object to reflect the changes of Type and Quota. If the move succeeds, the KC will be updated to a Community KC.- Parameters:
kcId_
- content id of the Knowledge Center to movecommunityId_
- id of community under which to move the Knowledge Center- Throws:
InvalidContentException
- if an invalid content item is referencedPrivilegeException
- if the user does not have permission to take this actionIllegalRecursionException
- if the destination is a descendant of the item you are movingInvalidStateException
- Deprecated. If the move succeeds, the KC will be updated to a Community KC.
-
moveKnowledgeCenters
void moveKnowledgeCenters(Long[] kcIds_, Long communityId_) throws InvalidContentException, PrivilegeException, IllegalRecursionException, InvalidStateException Moves KCs to a community. This method will also update the Content Objects to reflect the changes to the columns of Type and Quota. If the move succeeds, the KCs will be updated to Community KCs.- Parameters:
kcIds_
- content ids of the Knowledge Centers to movecommunityId_
- id of community under which to move the Knowledge Centers- Throws:
InvalidContentException
- if an invalid content item is referencedPrivilegeException
- if the user does not have permission to take this actionIllegalRecursionException
- if the destination is a descendant of the item you are movingInvalidStateException
- Deprecated. If the move succeeds, the KC will be updated to a Community KC.
-
validateTypedValues
boolean validateTypedValues(TypedValue[] typedValues) throws InvalidDocumentException, InvalidFolderException, InvalidKnowledgeCenterException, InvalidCommunityException Validates given TypedValues. This method is free to throw an exception or to return false if any TypedValue passed is invalid for this engine. This engine supports: AppianType.DOCUMENT AppianType.FOLDER AppianType.KNOWLEDGE_CENTER AppianType.COMMUNITY AppianType.DOCUMENT_OR_FOLDER- Parameters:
typedValues
-- Returns:
- true if valid, false if invalid
- Throws:
InvalidDocumentException
InvalidFolderException
InvalidKnowledgeCenterException
InvalidCommunityException
-
getIdByUuid
Long getIdByUuid(@ConvertWith(com.appiancorp.kougar.mapper.parameters.UuidParameterConverter.class) String uuid) Gets a content id by UUID. The version returned is NOT always the current version (ContentConstants.VERSION_CURRENT
). Consider usinggetVersionId(String, Integer)
instead.- Parameters:
uuid
- content UUID- Returns:
- content id or
null
if the UUID is not found - See Also:
-
constants for System UUIDs
-
getIdsByUuid
Long[] getIdsByUuid(@ConvertWith(com.appiancorp.kougar.mapper.parameters.UuidParameterConverter[][].class) String[] uuids) Gets content ids by UUID. The versions returned are NOT always the current version (ContentConstants.VERSION_CURRENT
).- Parameters:
uuids
- content UUIDs- Returns:
- content ids or
null
items for UUIDs not found - Throws:
NullPointerException
- ifuuids
isnull
- See Also:
-
constants for System UUIDs
-
getDatatypeIds
Gets the datatype ids that content ids map to. For example, a content object withContentConstants.TYPE_RULE
type andContentConstants.SUBTYPE_RULE_QUERY
subtype maps to aAppianType.QUERY_RULE
datatype- Parameters:
contentIds
- content ids- Returns:
- datatype ids mappped to the content objects specified by the given content ids
-
getDocumentInputStream
DocumentInputStream getDocumentInputStream(long id_) throws InvalidContentException, AppianStorageException Opens a stream to a Document allowing for the caller to read its contents.- Parameters:
id_
- the content ID of the version of the document; usegetVersionId(Long, Integer)
to obtain the id of the version of the document- Returns:
- DocumentInputStream containing the content of the document
- Throws:
InvalidContentException
- if an invalid content item is referencedAppianStorageException
- if an error occurs while opening the input stream for the file- See Also:
-
getDocumentInputStream
DocumentInputStream[] getDocumentInputStream(long[] ids_) throws InvalidContentException, AppianStorageException Opens streams to multiple Documents allowing the caller to read their contents.- Parameters:
ids_
- the content IDs of the versions of the documents; usegetVersionIds(Long, Integer[])
to obtain the ids of the versions of the document- Returns:
- DocumentInputStream[] containing the contents of the documents
- Throws:
InvalidContentException
- if an invalid content item is referencedAppianStorageException
- if an error occurs while opening an input stream for a file- See Also:
-
uploadDocument
ContentUploadOutputStream uploadDocument(Document doc, Integer unique) throws InvalidContentException, StorageLimitException, PrivilegeException, InsufficientNameUniquenessException, DuplicateUuidException, AppianStorageException Creates a document and provides an output stream to which the document's content should be written. The document is created using thecreateApproval(Content, Integer)
API. The caller must write the document's data to the returned output stream and complete the upload by callingContentUploadOutputStream.close()
. Invoking the stream's close method will calculate the size of the data written to the stream and save it as metadata for the document.- Parameters:
doc
- The Document to create.unique
- How unique the name must be.- Returns:
- The output stream to which the document's data should be written.
- Throws:
InvalidContentException
StorageLimitException
PrivilegeException
InsufficientNameUniquenessException
DuplicateUuidException
AppianStorageException
-
browsePaging(Long, ContentFilter, int, int, Integer, Integer)
instead