@Deprecated
public interface PageService
extends com.appiancorp.services.ContextSensitiveService
Portal pages have a "zone count" attribute which specifies the number of zones the page has for placing portlets. The portlets contained in a portal page can be Deactivated or Deleted; deactivating a portlet just hides it from the page, while deleting a portlet removes it permanently along with all its content (for shared portlets, all instances of the portlet on other pages will also be removed).
Pages can be private or public. The security for private pages is defined as follows:
Portlets within portal pages have an additional separate security map defined as follows:
When a user edits a page, the page is locked and a draft is created. Unless a user has the privileges to break the lock on the page, he/she will not be able to edit the page. If the page options are set such that modifications to the page require approval, the draft first has to be approved at which point it is published. Once a draft is published, it will be visible to page viewers.
Contributions are a way to log and keep track of all the content additions
made by users. When a user submits new/updated content, or removes content,
addContribution(com.appiancorp.suiteapi.portal.Contribution)
/updateContribution(com.appiancorp.suiteapi.portal.Contribution)
or
deleteContribution(com.appiancorp.suiteapi.portal.Contribution)
should be called to log the event. This should
be done for modifications of all content (not just pages but all Appian Type
objects such as forums, documents, etc). The
getContributionsForTypePaging(com.appiancorp.suiteapi.portal.Contribution, int, int, java.lang.Integer, java.lang.Integer)
method can then be used later to
retrieve the logged user content modifications.
Methods of service classes can all throw the unchecked exception
ServiceException
if any
system-level error (for example, server failure) occurs, and will in general
throw a checked exception (InvalidXXXException
) when an entity
to be retrieved is inaccessible, instead of returning null
.
Exceptions to this paradigm (including the use of ResultList
as
described below) are noted. All checked exceptions extend
AppianException
.
It may be necessary to retrieve a subset of results as opposed to an entire
collection, and also to sort the subset by some property of the returned
object. "Paging" methods which return a
ResultPage
are provided in certain
instances for this purpose. The ResultPage
will contain the
sorted subset of results
(via Result.getResults()
), and the
total number of items in the available result set
(via ResultPage.getAvailableItems()
).
It may also be necessary to retrieve some results, even if all results
cannot be retrieved (for instance, some of the entities corresponding
to a list of entity IDs may no longer exist). Methods which return a
ResultList
are provided for this
purpose. The Result.getResults()
method in this case will return all results which can be retrieved. In
addition, there will be a list of result codes
(ResultList.getResultCodes()
) that
represent the successful retrieval of an entity, or, if the entity could
not be retrieved, the reason for the failure. See the CODE_XXX
constants in ResultList
for details.
Page
,
PageInfo
,
PageRoleMap
,
PageNavigationService
,
Contribution
Modifier and Type | Field and Description |
---|---|
static boolean |
addContribution$UPDATES
Deprecated.
|
static boolean |
addPortlet$UPDATES
Deprecated.
|
static boolean |
addPortlets$UPDATES
Deprecated.
|
static boolean |
approveDraft$UPDATES
Deprecated.
|
static boolean |
changePageDescription$UPDATES
Deprecated.
|
static boolean |
changePageTemplate$UPDATES
Deprecated.
|
static boolean |
createPage$UPDATES
Deprecated.
|
static boolean |
createPages$UPDATES
Deprecated.
|
static java.lang.Integer |
DEACTIVATE_PORTLET
Deprecated.
A constant representing the deactivation of a portlet
|
static java.lang.Integer |
DELETE_PORTLET
Deprecated.
A constant representing the deletion of a portlet
|
static boolean |
deleteContribution$UPDATES
Deprecated.
|
static boolean |
deleteDraft$UPDATES
Deprecated.
|
static boolean |
deletePage$UPDATES
Deprecated.
|
static boolean |
getAccessLevelForPage$UPDATES
Deprecated.
|
static boolean |
getAccessLevelForPages$UPDATES
Deprecated.
|
static boolean |
getContributions$UPDATES
Deprecated.
|
static boolean |
getContributionsForType$UPDATES
Deprecated.
|
static boolean |
getContributionsForTypePaging$UPDATES
Deprecated.
|
static boolean |
getDraft$UPDATES
Deprecated.
|
static boolean |
getMaximumContributions$UPDATES
Deprecated.
|
static boolean |
getPage$UPDATES
Deprecated.
|
static boolean |
getPages$UPDATES
Deprecated.
|
static boolean |
getPagesList$UPDATES
Deprecated.
|
static boolean |
getPagesPaging$UPDATES
Deprecated.
|
static boolean |
getRoleMapForPage$UPDATES
Deprecated.
|
static boolean |
movePortlet$UPDATES
Deprecated.
|
static boolean |
peekDraft$UPDATES
Deprecated.
|
static boolean |
publishDraft$UPDATES
Deprecated.
|
static boolean |
publishDrafts$UPDATES
Deprecated.
|
static boolean |
removePortlet$UPDATES
Deprecated.
|
static boolean |
renamePage$UPDATES
Deprecated.
|
static boolean |
returnDraft$UPDATES
Deprecated.
|
static boolean |
setIsPagePublic$UPDATES
Deprecated.
|
static boolean |
setMaximumContributions$UPDATES
Deprecated.
|
static boolean |
setPageApproval$UPDATES
Deprecated.
|
static boolean |
setPageCategory$UPDATES
Deprecated.
|
static boolean |
setPageDataContextType$UPDATES
Deprecated.
|
static boolean |
setPageUrl$UPDATES
Deprecated.
|
static boolean |
setRoleMapForPage$UPDATES
Deprecated.
|
static boolean |
takeDraft$UPDATES
Deprecated.
|
static boolean |
unlockDraft$UPDATES
Deprecated.
|
static boolean |
updateContribution$UPDATES
Deprecated.
|
static boolean |
updatePage$UPDATES
Deprecated.
|
static boolean |
updatePages$UPDATES
Deprecated.
|
static boolean |
validateTypedValues$UPDATES
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
void |
addContribution(Contribution contribution_)
Deprecated.
This functionality is no longer supported and will be removed in the next release.
|
void |
addPortlet(java.lang.Long pageId_,
java.lang.Long portletId_,
java.lang.Integer zone_,
int index_)
Deprecated.
Attempts to lock the current draft of the specified page and add a portlet.
|
void |
addPortlets(java.lang.Long pageId_,
java.lang.Long[] portletIds_,
java.lang.Integer[] zones_,
int[] indices_)
Deprecated.
Attempts to lock the current draft of the specified page and add portlets.
|
void |
approveDraft(java.lang.Long pageId_)
Deprecated.
Applies the changes made to the draft of the specified page, and clears the draft.
|
void |
changePageDescription(java.lang.Long pageId_,
java.lang.String newDescription_)
Deprecated.
Changes the description of the specified page.
|
void |
changePageTemplate(java.lang.Long pageId_,
java.lang.String newTemplateName_,
int newZoneCount_)
Deprecated.
Attempts to lock the current draft for the specified page (i.e., put the page
into draft state) and changes the template in the draft.
|
java.lang.Long |
createPage(Page page_)
Deprecated.
Creates a page using the attributes specified in the passed object.
|
java.lang.Long[] |
createPages(Page[] pages_)
Deprecated.
Creates pages in bulk using the attributes specified in the passed objects.
|
void |
deleteContribution(Contribution contribution_)
Deprecated.
This functionality is no longer supported and will be removed in the next release.
|
void |
deleteDraft(java.lang.Long pageId_)
Deprecated.
Cancels the changes made to the draft for the specified page, and clears
the draft.
|
void |
deletePage(java.lang.Long pageId_)
Deprecated.
Deletes the specified page.
|
int |
getAccessLevelForPage(java.lang.Long pageId_)
Deprecated.
Gets the current user's access level for the given page.
|
int[] |
getAccessLevelForPages(java.lang.Long[] pageIds_)
Deprecated.
Gets the current user's access levels for the given pages.
|
Contribution[] |
getContributions()
Deprecated.
This functionality is no longer supported and will be removed in the next release.
|
Contribution[] |
getContributionsForType(Contribution contribution_)
Deprecated.
This functionality is no longer supported and will be removed in the next release.
|
ResultPage |
getContributionsForTypePaging(Contribution contribution_,
int startIndex_,
int batchSize_,
java.lang.Integer sortProperty_,
java.lang.Integer sortOrder_)
Deprecated.
This functionality is no longer supported and will be removed in the next release.
|
Page |
getDraft(java.lang.Long pageId_)
Deprecated.
Retrieves the draft version of the specified page.
|
int |
getMaximumContributions()
Deprecated.
This functionality is no longer supported and will be removed in the next release.
|
Page |
getPage(java.lang.Long pageId_)
Deprecated.
Gets the specified portal page.
|
Page[] |
getPages(java.lang.Long[] pageIds_)
|
ResultList |
getPagesList(java.lang.Long[] pageIds_)
Deprecated.
Gets the specified portal pages, returning the valid results even if all
the results cannot be retrieved (for instance, if some of the pages
corresponding to the IDs no longer exist).
|
ResultPage |
getPagesPaging(java.lang.Long[] pageIds_,
int startIndex_,
int batchSize_,
java.lang.Integer sortProperty_,
java.lang.Integer sortOrder_)
Deprecated.
Gets the specified portal pages as an array of
Page
objects in a ResultPage . |
PageRoleMap |
getRoleMapForPage(java.lang.Long pageId_)
Deprecated.
Get the role map of a page, specifiying the administrators, editors and
viewers of the page.
|
void |
movePortlet(java.lang.Long pageId_,
java.lang.Long portletId_,
java.lang.Integer zone_,
int index_)
Deprecated.
Attempts to lock the current draft of the specified page and move a
portlet within the page.
|
Page |
peekDraft(java.lang.Long pageId_)
Deprecated.
Retrieves the pending draft if present or the published page, without setting the draft owner.
|
void |
publishDraft(java.lang.Long pageId_)
Deprecated.
Submits the current draft of the specified page for publication, and
releases any lock on the draft.
|
void |
publishDrafts(java.lang.Long[] pageIds_)
Deprecated.
Submits the current drafts of the specified pages for publication, and
releases any lock on the drafts.
|
void |
removePortlet(java.lang.Long pageId_,
java.lang.Long portletId_,
java.lang.Integer action_)
Deprecated.
Attempts to lock the current draft of the specified page and remove a
portlet.
|
void |
renamePage(java.lang.Long pageId_,
java.lang.String newName_)
Deprecated.
Renames the specified page to the specified name.
|
void |
returnDraft(java.lang.Long pageId_)
Deprecated.
Returns a submitted page back to a draft state
(
Page.STATE_NEW_DRAFT or Page.STATE_DRAFT ). |
void |
setIsPagePublic(java.lang.Long pageId_,
boolean isPublic_)
Deprecated.
Changes whether the page is publicly viewable.
|
void |
setMaximumContributions(int size_)
Deprecated.
This functionality is no longer supported and will be removed in the next release.
|
void |
setPageApproval(java.lang.Long pageId_,
boolean approvalRequired_)
Deprecated.
Sets whether approval is required for page modifications.
|
void |
setPageCategory(java.lang.Long pageId_,
java.lang.Long categoryId_)
Deprecated.
Changes the category for the specified page.
|
void |
setPageDataContextType(java.lang.Long pageId,
java.lang.Long dataContextType)
Deprecated.
Sets the type of data that will be sent to the page when it is requested.
|
void |
setPageUrl(java.lang.Long pageId_,
java.lang.String url_)
Deprecated.
Changes the URL for the specified custom page.
|
void |
setRoleMapForPage(java.lang.Long pageId_,
PageRoleMap map_)
Deprecated.
Set the role map for a page
|
Page |
takeDraft(java.lang.Long pageId_)
Deprecated.
Retrieves the draft version of the specified page and locks it for editing.
|
void |
unlockDraft(java.lang.Long pageId_)
Deprecated.
Releases the lock on the draft for the specified page, if the current user
owns the draft.
|
void |
updateContribution(Contribution contribution_)
Deprecated.
This functionality is no longer supported and will be removed in the next release.
|
void |
updatePage(Page page_)
Deprecated.
Updates a page using the attributes specified in the passed object.
|
void |
updatePages(Page[] pages_)
Deprecated.
Updates pages in bulk using the attributes specified in the passed objects.
|
boolean |
validateTypedValues(TypedValue[] typedValues)
Deprecated.
Validates given TypedValues.
|
static final java.lang.Integer DELETE_PORTLET
static final java.lang.Integer DEACTIVATE_PORTLET
static final boolean getPage$UPDATES
static final boolean getPages$UPDATES
static final boolean createPage$UPDATES
static final boolean createPages$UPDATES
static final boolean updatePage$UPDATES
static final boolean updatePages$UPDATES
static final boolean deletePage$UPDATES
static final boolean getAccessLevelForPage$UPDATES
static final boolean renamePage$UPDATES
static final boolean changePageDescription$UPDATES
static final boolean getDraft$UPDATES
static final boolean peekDraft$UPDATES
static final boolean takeDraft$UPDATES
static final boolean approveDraft$UPDATES
static final boolean deleteDraft$UPDATES
static final boolean publishDraft$UPDATES
static final boolean publishDrafts$UPDATES
static final boolean returnDraft$UPDATES
static final boolean unlockDraft$UPDATES
static final boolean changePageTemplate$UPDATES
static final boolean setPageCategory$UPDATES
static final boolean setPageUrl$UPDATES
static final boolean setPageApproval$UPDATES
static final boolean setIsPagePublic$UPDATES
static final boolean addPortlet$UPDATES
static final boolean removePortlet$UPDATES
static final boolean movePortlet$UPDATES
static final boolean getRoleMapForPage$UPDATES
static final boolean setRoleMapForPage$UPDATES
static final boolean addContribution$UPDATES
static final boolean updateContribution$UPDATES
static final boolean deleteContribution$UPDATES
static final boolean getContributions$UPDATES
static final boolean getContributionsForType$UPDATES
static final boolean getContributionsForTypePaging$UPDATES
static final boolean setMaximumContributions$UPDATES
static final boolean getMaximumContributions$UPDATES
static final boolean getAccessLevelForPages$UPDATES
static final boolean addPortlets$UPDATES
static final boolean getPagesPaging$UPDATES
static final boolean getPagesList$UPDATES
static final boolean validateTypedValues$UPDATES
static final boolean setPageDataContextType$UPDATES
Page getPage(java.lang.Long pageId_) throws PrivilegeException, InvalidPageException, InvalidAnonymousUserException, InvalidUserException
Page.STATE_DRAFT
.
If a published version exists for the page, the published version is returned.pageId_
- The ID of the page to retrieve.PrivilegeException
- if the current user is not authorized to
view the pageInvalidAnonymousUserException
- if the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- if the user calling this method is invalid;
this exception is not thrown if the user is deactivated, so the caller
should validate that the user is active before calling (known issue)InvalidPageException
- if the specified page does not existServiceException
- if any system-level error occurs@Deprecated Page[] getPages(java.lang.Long[] pageIds_) throws PrivilegeException, InvalidPageException, InvalidAnonymousUserException, InvalidUserException, java.lang.NullPointerException
null
is returned for each
page that does not exist, or that the user is not authorized to view. Also see
getPage(Long)
pageIds_
- the IDs of the portal pages to retrieve.null
for each page that does not exist, or that the current user does not have
permission to view.PrivilegeException
- if the current user is anonymous and tries to
view pages that anonymous users have no permission to accessInvalidAnonymousUserException
- if the current user is anonymous, but
anonymous access has not been enabledInvalidUserException
- if the user calling this method is invalidInvalidPageException
- if any of the specified pages do not existServiceException
- if any system-level error occursjava.lang.NullPointerException
- if the passed pageIds_
array
or any of its elements is null
java.lang.Long createPage(Page page_) throws PrivilegeException, InvalidAnonymousUserException, InvalidUserException, InvalidCategoryException, DuplicateUuidException
group
attribute is specified, the current user must
be an administrator of that group; creates the two way association between the group
and the new page. The new page's state will be Page.STATE_NEW_DRAFT
;
only the creator and a portal administrator will be able to view/modify the page.
The user making this call becomes the creator of the page.page_
- The page to create. The following fields
are the minimum required attributes that must not be null
to
successfully create the page: name
, template
(a tiles reference for the template JSP), zoneCount
(see
Page.setZoneCount(int)
). The following attributes are optional:
description
, category
, approvalRequired
,
group
, public
, type
, and url
(note: url is applicable only for page type PageInfo.TYPE_CUSTOM
).
For the allowed values for type
see PageInfo.TYPE_XXX
constants.
All other attributes are ignored. This is the same whether or not the page is a
custom page - attributes that don't make sense for a custom page (such as
zoneCount
) should just be given valid dummy values.PrivilegeException
- if the current user is not allowed to create
the specified pageInvalidAnonymousUserException
- if the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- if the user calling this method is invalidjava.lang.IllegalArgumentException
- if an invalid name or
template was specified; this exception is not thrown if an invalid zoneCount
is given, therefore the caller should validate that zoneCount
> 0 and < 255InvalidCategoryException
- if the category ID was specified (is
non-null
), but does not correspond to a valid categoryjava.lang.NullPointerException
- if the passed page_
object is
null
ServiceException
- if any system-level error occursDuplicateUuidException
- if the UUID of the page already existsjava.lang.Long[] createPages(Page[] pages_) throws PrivilegeException, InvalidAnonymousUserException, InvalidUserException, InvalidCategoryException, DuplicateUuidException
createPage(Page)
.pages_
- List of the pages to create. See createPage(Page)
InvalidAnonymousUserException
- If the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- If the user calling this method is invalidjava.lang.IllegalArgumentException
- if an invalid zone count, name or
template was specified for any of the pagesPrivilegeException
- If the current user is not allowed to create
any of the pagesInvalidCategoryException
- If the category ID was specified (is
non-null
) for any of the pages, but does not correspond to a
valid categoryjava.lang.NullPointerException
- If the passed pages_
array or
any of its elements is null
DuplicateUuidException
- if the UUID of any of the pages already
exists or if the same UUID is passed in for several pagesServiceException
- If any system-level error occursvoid updatePage(Page page_) throws InvalidAnonymousUserException, InvalidUserException, PrivilegeException, InvalidCategoryException, InvalidPageException
Updates a page using the attributes specified in the passed object.
This method does not create a new draft. It requires the current user to be an administrator of
the group, if a group
attribute is specified. This creates a two way association
between the group and the page. A null
value for group dissociates an existing two
way association.
To update some of the ignored attributes of the page use the following:
url
- use setPageUrl(Long, String)
instead.template
and zoneCount
- use
changePageTemplate(Long, String, int)
instead.rolemap
- use setRoleMapForPage(Long, PageRoleMap)
instead.portlets
- use addPortlets(Long, Long[], Integer[], int[])
and
removePortlet(Long, Long, Integer)
instead.page_
- the page to update. The following fields
are the minimum required attributes that must not be null
to
successfully update the page: id
, name
and
template
(a tiles reference for the template JSP, although it's ignored). description
, category
,
group
, public
. All other attributes are ignored. This is the same
whether or not the page is a custom page - attributes that don't make
sense for a custom page (such as zoneCount
) should just be
given valid dummy values.InvalidAnonymousUserException
- If an anonymous User
attempts to make this call.InvalidUserException
- If the current User
does not exist.PrivilegeException
- If the current User
is not an
administrator of the Group
specified in the
group
field of the Page
or if the current user
does not have sufficient privileges to update the Page
.InvalidCategoryException
- not thrown, instead the category
is reset to null if an invalid category is given (known issue)java.lang.NullPointerException
- If the given page_
is null.java.lang.IllegalArgumentException
- if either the name
or
template
field is null.InvalidPageException
- If the Page
given by the
id
field does not exist.void updatePages(Page[] pages_) throws InvalidAnonymousUserException, InvalidUserException, PrivilegeException, InvalidCategoryException, InvalidPageException
updatePage(Page)
.pages_
- The attributes of each page to update. See updatePage(Page)
InvalidAnonymousUserException
- If an anonymous User
attempts to make this call.InvalidUserException
- If the current User
does not exist.PrivilegeException
- If the current User
is not an
administrator of any one of the Group
objects specified in
the group
field of the Page
or if the current
user does not have sufficient privileges to update any one of the
Page
objects.InvalidCategoryException
- If at least one of the given
category
fields is invalid.java.lang.NullPointerException
- If any of the Page
objects is
null.java.lang.IllegalArgumentException
- If either the name
or
template field in any of the given Page
objects is null.InvalidPageException
- If any of the Page
objects given
by the id
field does not exist.void deletePage(java.lang.Long pageId_) throws InvalidAnonymousUserException, InvalidUserException, PrivilegeException, InvalidPageException
pageId_
- the ID of the page to delete.InvalidAnonymousUserException
- if the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- if the user calling this method is invalid;
this exception is not thrown if a deactivated user is used to call this
method, so the caller should validate that the user is not deactivated
before calling (known issue)PrivilegeException
- if the current user is not allowed to delete
the pageInvalidPageException
- if the page with the specified ID does not
existServiceException
- if any system-level error occursint getAccessLevelForPage(java.lang.Long pageId_) throws InvalidAnonymousUserException, InvalidUserException, InvalidPageException
pageId_
- the ID of the page for which the user's access level is to
be returned.PAGE_ACCESS_LEVEL_XXX
constants in
PageInfo
InvalidAnonymousUserException
- if the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- if the user calling this method is invalidInvalidPageException
- if the page with the specified ID does not
existServiceException
- if any system-level error occursvoid renamePage(java.lang.Long pageId_, java.lang.String newName_) throws InvalidAnonymousUserException, InvalidUserException, PrivilegeException, InvalidPageException
pageId_
- the ID of the page to rename.newName_
- the new name of the page.InvalidAnonymousUserException
- if the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- if the user calling this method is invalidPrivilegeException
- if the current user is not allowed to rename
the pageInvalidPageException
- if the page with the specified ID does not
existServiceException
- if any system-level error occursvoid changePageDescription(java.lang.Long pageId_, java.lang.String newDescription_) throws InvalidAnonymousUserException, InvalidUserException, PrivilegeException, InvalidPageException
pageId_
- the ID of the page whose description should be changed.newDescription_
- the new description for the page.InvalidAnonymousUserException
- if the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- if the user calling this method is invalidPrivilegeException
- if the current user is not allowed to change
the page descriptionInvalidPageException
- if the page with the specified ID does not
existServiceException
- if any system-level error occursPage getDraft(java.lang.Long pageId_) throws PrivilegeException, InvalidPageException, InvalidAnonymousUserException, InvalidUserException
Page.STATE_LOCKED
).pageId_
- the ID of the page whose draft should be returned.InvalidAnonymousUserException
- if the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- if the user calling this method is invalidPrivilegeException
- if the current user is not allowed to view
the page draftInvalidPageException
- if the page with the specified ID does not
existServiceException
- if any system-level error occurstakeDraft(java.lang.Long)
Page peekDraft(java.lang.Long pageId_) throws PrivilegeException, InvalidPageException, InvalidAnonymousUserException, InvalidUserException
Page.STATE_LOCKED
).pageId_
- the ID of the page whose draft should be returned.InvalidAnonymousUserException
- if the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- if the user calling this method is invalidPrivilegeException
- if the current user is not allowed to view
the page draftInvalidPageException
- if the page with the specified ID does not
existPage takeDraft(java.lang.Long pageId_) throws PrivilegeException, InvalidPageException, InvalidAnonymousUserException, InvalidUserException
pageId_
- the ID of the page whose draft should be returned.InvalidAnonymousUserException
- if the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- if the user calling this method is invalidPrivilegeException
- if the current user is not allowed to view and
lock the draftInvalidPageException
- if the page with the specified ID does not
existServiceException
- if any system-level error occursgetDraft(java.lang.Long)
void approveDraft(java.lang.Long pageId_) throws InvalidAnonymousUserException, InvalidUserException, PrivilegeException, InvalidStateException, InvalidPageException
pageId_
- the ID of the page for which the draft should be approved.InvalidAnonymousUserException
- if the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- if the user calling this method is invalidPrivilegeException
- if the current user is not allowed to approve
the pageInvalidStateException
- if a draft does not exist for the specified
pageInvalidPageException
- if the page with the specified ID does not
existServiceException
- if any system-level error occursvoid deleteDraft(java.lang.Long pageId_) throws InvalidAnonymousUserException, InvalidUserException, PrivilegeException, LockException, InvalidPageException, java.lang.NullPointerException, InvalidStateException
Page.STATE_NEW_DRAFT
state. Only page admins
and the user who originally created the draft can delete the draft.pageId_
- the id of the page for which the draft should be deleted.InvalidAnonymousUserException
- if the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- if the user calling this method is invalidPrivilegeException
- if the current user is not allowed to delete
the draftLockException
- if the draft is locked by another userInvalidPageException
- if the page with the specified ID does not
existInvalidStateException
- if the page has no draftjava.lang.NullPointerException
- if the argument is null
ServiceException
- if any system-level error occursvoid publishDraft(java.lang.Long pageId_) throws InvalidAnonymousUserException, InvalidUserException, InvalidStateException, PrivilegeException, InvalidPageException
approveDraft(java.lang.Long)
is called, otherwise the
page is published immediately. It associates the page with the group
(group->page) if there was a group associated with the page (page->group).
If a System Administrator user calls this method on a page that requires
approval, the Page
will enter the
Page.STATE_PUBLISHED
state even if that user is not a member of Portal Administrators.
pageId_
- the ID of the page for which the draft should be published.InvalidAnonymousUserException
- if the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- if the user calling this method is invalidInvalidStateException
- if a draft does not exist for the specified
pagePrivilegeException
- if the current user is not allowed to publish
the pageInvalidPageException
- if the page with the specified ID does not
existServiceException
- if any system-level error occursvoid publishDrafts(java.lang.Long[] pageIds_) throws InvalidAnonymousUserException, InvalidUserException, InvalidStateException, PrivilegeException, InvalidPageException
updatePage(Page)
.pageIds_
- the IDs of the pages for which the drafts should be
published.InvalidAnonymousUserException
- if the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- if the user calling this method is invalidInvalidStateException
- if a draft does not exist for any of the
specified pagesPrivilegeException
- if the current user is not allowed publish
the pagesInvalidPageException
- if any of the IDs does not correspond to a
valid pageServiceException
- if any system-level error occursvoid returnDraft(java.lang.Long pageId_) throws InvalidAnonymousUserException, InvalidUserException, PrivilegeException, InvalidStateException, InvalidPageException, java.lang.NullPointerException
Page.STATE_NEW_DRAFT
or Page.STATE_DRAFT
).pageId_
- the id of the page which should be returned to a draft.InvalidStateException
- if the page state is not
Page.STATE_NEW_SUBMITTED
or Page.STATE_SUBMITTED
InvalidAnonymousUserException
- if the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- if the user calling this method is invalidPrivilegeException
- if the current user is not an approver of the
pageInvalidPageException
- if the page with the specified ID does not
existServiceException
- if any system-level error occursjava.lang.NullPointerException
- if the passed page id is null
void unlockDraft(java.lang.Long pageId_) throws LockException, InvalidPageException
pageId_
- the id of the page for which the draft lock should be
released.LockException
- if the current user does not own the draftInvalidPageException
- if the page with the specified ID does not
existServiceException
- if any system-level error occursvoid changePageTemplate(java.lang.Long pageId_, java.lang.String newTemplateName_, int newZoneCount_) throws InvalidAnonymousUserException, InvalidUserException, PrivilegeException, LockException, java.lang.IllegalArgumentException, InvalidPageException, java.lang.NullPointerException
pageId_
- The ID of the page for which the template should be changed.newTemplateName_
- The name of the new template, which should be a
tiles reference.newZoneCount_
- The number of zones that can contain portlets.
See Page.getZoneCount()
.InvalidAnonymousUserException
- if the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- If the user calling this method is invalidPrivilegeException
- If the current user is not allowed to modify
the pageLockException
- If the draft is locked and the current user does not
own the draftjava.lang.IllegalArgumentException
- If an invalid zone count is usedInvalidPageException
- If the page with the specified ID does not
existjava.lang.NullPointerException
- If any argument is null
.ServiceException
- If any system-level error occursgetDraft(java.lang.Long)
void setPageCategory(java.lang.Long pageId_, java.lang.Long categoryId_) throws InvalidAnonymousUserException, InvalidUserException, PrivilegeException, InvalidCategoryException, InvalidPageException
pageId_
- the ID of the page for which the category should be set.categoryId_
- the ID of the category to which to add the page.InvalidAnonymousUserException
- if the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- if the user calling this method is invalidPrivilegeException
- if the current user is not allowed to set
the category for the pageInvalidPageException
- if the page with the specified ID does not
existInvalidCategoryException
- if no category with the specified ID
existsServiceException
- if any system-level error occursvoid setPageUrl(java.lang.Long pageId_, java.lang.String url_) throws InvalidPageException, InvalidOperationException, PrivilegeException
pageId_
- the ID of the page for which the URL should be set.url_
- the new URL for the page.InvalidPageException
- if no page with the specified ID existsInvalidOperationException
- if the page is not a custom pagePrivilegeException
- if the current user is not allowed to change
the URL for the pagevoid setPageApproval(java.lang.Long pageId_, boolean approvalRequired_) throws InvalidAnonymousUserException, InvalidUserException, PrivilegeException, InvalidPageException
true
to false
.pageId_
- the ID of the page for which the approval should be set.approvalRequired_
- specifies whether approval will be required for
page modifications.InvalidAnonymousUserException
- if the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- if the user calling this method is invalidPrivilegeException
- if the current user is not allowed to change
the approval setting for the pageInvalidPageException
- if no page with the specified ID existsServiceException
- if any system-level error occursvoid setIsPagePublic(java.lang.Long pageId_, boolean isPublic_) throws InvalidAnonymousUserException, InvalidUserException, PrivilegeException, InvalidPageException
pageId_
- the ID of the page for which the viewable setting should
be changed.isPublic_
- specifies whether the page will be publicly viewable.InvalidAnonymousUserException
- if the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- if the user calling this method is invalidPrivilegeException
- if the current user is not allowed to change
the viewable setting for the pageInvalidPageException
- if no page with the specified ID existsServiceException
- if any system-level error occursvoid addPortlet(java.lang.Long pageId_, java.lang.Long portletId_, java.lang.Integer zone_, int index_) throws InvalidAnonymousUserException, InvalidUserException, PrivilegeException, PortletSharingException, DuplicatePortletException, InvalidPageException, InvalidPortletException, InvalidZoneException, LockException, java.lang.NullPointerException
pageId_
- the ID of the page to which the portlet should be added.portletId_
- the ID of the portlet to add to the page.zone_
- Specifies which zone will contain the portlet. The zone
identifies which column the portlet should be placed into, with the
indexing starting at 0 (left-most column).index_
- Specifies the position of the portlet within the zone, with
the indexing starting at 0 (top-most position).InvalidAnonymousUserException
- if the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- if the user calling this method is invalidPrivilegeException
- if the current user is not allowed to modify
the pagePortletSharingException
- if the specified portlet is non-shareable,
and is already on another pageDuplicatePortletException
- if the specified portlet already exists
on the draftInvalidPageException
- if no page with the specified ID existsInvalidPortletException
- if no portlet with the specified ID existsInvalidZoneException
- if the specified zone does not existLockException
- if the current user does not own the draftServiceException
- if any system-level error occursjava.lang.NullPointerException
- if any argument is nullvoid removePortlet(java.lang.Long pageId_, java.lang.Long portletId_, java.lang.Integer action_) throws InvalidAnonymousUserException, InvalidUserException, PrivilegeException, LockException, InvalidPageException, InvalidPortletException
pageId_
- the ID of the page from which the portlet should be
removed.portletId_
- the ID of the portlet to remove.action_
- The action to take (DELETE_PORTLET
or DEACTIVATE_PORTLET
).InvalidAnonymousUserException
- if the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- if the user calling this method is invalidPrivilegeException
- if the current user is not allowed to remove
the portletLockException
- if the current user does not own the page draftInvalidPageException
- if no page with the specified ID existsInvalidPortletException
- if no portlet with the specified ID existsServiceException
- if any system-level error occursvoid movePortlet(java.lang.Long pageId_, java.lang.Long portletId_, java.lang.Integer zone_, int index_) throws InvalidAnonymousUserException, InvalidUserException, PrivilegeException, LockException, InvalidZoneException, InvalidPageException, InvalidPortletException, java.lang.NullPointerException
pageId_
- the ID of the page in which the portlet should be moved.portletId_
- the ID of the portlet to move.zone_
- specifies the new zone that will contain the portlet. The
zone identifies which column the portlet should be placed into, with the
indexing starting at 0 (left-most column).index_
- specifies the position of the portlet within the zone, with
the indexing starting at 0 (top-most position).InvalidAnonymousUserException
- if the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- if the user calling this method is invalidPrivilegeException
- if the current user is not allowed to modify
the pageLockException
- if the current user does not own the page draftInvalidZoneException
- if the specified zone does not existInvalidPageException
- if no page with the specified ID existsInvalidPortletException
- if no portlet with the specified ID existsServiceException
- if any system-level error occursjava.lang.NullPointerException
- if any argument is nullPageRoleMap getRoleMapForPage(java.lang.Long pageId_) throws InvalidPageException, PrivilegeException
pageId_
- the ID of the page.PrivilegeException
- if the current user is not allowed to view
the page rolemapInvalidPageException
- if no page with the specified ID existsServiceException
- if any system-level error occursPageRoleMap
void setRoleMapForPage(java.lang.Long pageId_, PageRoleMap map_) throws InvalidAnonymousUserException, InvalidUserException, PrivilegeException, InvalidPageException, java.lang.NullPointerException
pageId_
- the ID of the page.map_
- the new rolemap of the page.InvalidAnonymousUserException
- if the current user is anonymous
or the anonymous user is in the rolemap, but anonymous access has not
been enabled.InvalidUserException
- if the user calling this method is invalidPrivilegeException
- if the current user is not allowed to set the
rolemap for the pageInvalidPageException
- if no page with the specified ID existsjava.lang.NullPointerException
- if any argument is nullServiceException
- if any system-level error occursPageRoleMap
@Deprecated void addContribution(Contribution contribution_)
LocalObject
. Currently contributions are logged when a user
creates or edits a message, thread or page and when the user uploads a
document.contribution_
- the contribution to add. The type
,
id
, and author
fields should be set. The
timestamp
will be set by the system.ServiceException
- if any system-level error occursjava.lang.NullPointerException
- if contribution_
is nullLocalObject
@Deprecated void updateContribution(Contribution contribution_)
LocalObject
. Currently contributions are logged when a
user creates or edits a message, thread or page and when the user
uploads a document.contribution_
- the contribution to update. The
type
, id
, and author
fields
should be set. The timestamp
will be set by the system.ServiceException
- if any system-level error occursjava.lang.NullPointerException
- if contribution_
is nullLocalObject
@Deprecated void deleteContribution(Contribution contribution_)
contribution_
- the contribution to delete. The
type
and id
fields
should be set.java.lang.NullPointerException
- if contribution_
is nullServiceException
- if any system-level error occurs@Deprecated Contribution[] getContributions()
ServiceException
- if any system-level error occurs@Deprecated Contribution[] getContributionsForType(Contribution contribution_)
getMaximumContributions()
and set to a new value
using setMaximumContributions(int)
.
To retrieve the current user's authored threads set the
author
field of the passed contribution_
to
Contribution.AUTHOR_ON
. To retrieve the threads in which
the current user has participated set the author
field of
the passed contribution_
to
Contribution.AUTHOR_OFF
. For contributions other than
threads, the author
field reflects whether the user created
(Contribution.AUTHOR_ON
) or updated
(Contribution.AUTHOR_OFF
) the contribution.contribution_
- a Contribution
object whose
type
and author
should be set to determine the
type and author of the retrieved contributions.ServiceException
- if any system-level error occurs@Deprecated ResultPage getContributionsForTypePaging(Contribution contribution_, int startIndex_, int batchSize_, java.lang.Integer sortProperty_, java.lang.Integer sortOrder_)
author
field of the passed contribution_
to
Contribution.AUTHOR_ON
. To retrive the threads in which the
current user has participated set the author
field of the
passed contribution_
to Contribution.AUTHOR_OFF
.
For contributions other than threads, the author
field
reflects whether the user created (Contribution.AUTHOR_ON
)
or updated (Contribution.AUTHOR_OFF
) the contribution.contribution_
- a Contribution
object whose
type
and author
should be set to determine the
type and author of the retrieved contributions.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. Negative numbers will
result in the entire collection being returned, but this is
STRONGLY discouraged.sortProperty_
- the property by which the results should be sorted.
This should be one of the SORT_BY_XXX
constants defined
in Contribution
.sortOrder_
- the order in which to sort the results. This should be
either
Constants.SORT_ORDER_ASCENDING
or
Constants.SORT_ORDER_DESCENDING
.ResultPage
containing a list of
Contribution
objects of the passed type.java.lang.NullPointerException
- if contribution_
is nullServiceException
- if any system-level error occurs@Deprecated void setMaximumContributions(int size_)
getContributionsForType(Contribution)
.size_
- The maximum number of contributions to be returned by
getContributionsForType(Contribution)
.ServiceException
- if any system-level error occursContribution
@Deprecated int getMaximumContributions()
getContributionsForType(Contribution)
.getContributionsForType(Contribution)
.ServiceException
- if any system-level error occursContribution
int[] getAccessLevelForPages(java.lang.Long[] pageIds_) throws InvalidAnonymousUserException, InvalidUserException, InvalidPageException, java.lang.NullPointerException
pageIds_
- the IDs of the pages for which the user's access levels
should be returned.PAGE_ACCESS_LEVEL_XXX
constants in PageInfo
.InvalidAnonymousUserException
- if the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- if the user calling this method is invalidInvalidPageException
- if any of the specified pages does not existjava.lang.NullPointerException
- if pageIds_
is nullServiceException
- if any system-level error occursvoid addPortlets(java.lang.Long pageId_, java.lang.Long[] portletIds_, java.lang.Integer[] zones_, int[] indices_) throws InvalidAnonymousUserException, InvalidUserException, PrivilegeException, PortletSharingException, DuplicatePortletException, InvalidPageException, InvalidPortletException, InvalidZoneException, LockException, java.lang.NullPointerException
pageId_
- the ID of the page to which the portlets should be added.portletIds_
- the IDs of the portlets to add to the page.zones_
- specifies which zone will contain the portlet with
the same array index. The zone identifies which column the portlet should
be placed into, with the indexing starting at 0 (left-most column).indices_
- specifies the position within the zone of the
portlet with the same array index. The position indexing starts at 0
(top-most position).InvalidAnonymousUserException
- if the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- if the user calling this method is invalidPrivilegeException
- if the current user is not allowed to modify
the pagePortletSharingException
- if any portlet is non-shareable, and is
already on another pageDuplicatePortletException
- if any specified portlet already exists
on the draftInvalidPageException
- if no page with the specified ID existsInvalidPortletException
- if any of the portlet IDs does not
correspond to a valid portletInvalidZoneException
- if any specified zone does not existLockException
- if the current user does not own the draftjava.lang.NullPointerException
- if any argument is nullServiceException
- if any system-level error occursaddPortlet(java.lang.Long, java.lang.Long, java.lang.Integer, int)
ResultPage getPagesPaging(java.lang.Long[] pageIds_, int startIndex_, int batchSize_, java.lang.Integer sortProperty_, java.lang.Integer sortOrder_) throws PrivilegeException, InvalidPageException, InvalidAnonymousUserException, InvalidUserException, java.lang.NullPointerException
Page
objects in a ResultPage
. null
is returned for
each page that does not exist, or that the user is not allowed to view.pageIds_
- the IDs of the portal pages to retrieve.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. Negative numbers will
result in the entire collection being returned, but this is
STRONGLY discouraged.sortProperty_
- the property by which the results should be sorted.
This should be one of the SORT_BY_XXX
constants defined
in Page
.sortOrder_
- the order in which to sort the results. This should be
either
Constants.SORT_ORDER_ASCENDING
or
Constants.SORT_ORDER_DESCENDING
.ResultPage
containing an array of Page
objects. The array may contain null
items if the current user
does not have permission to view particular pages, or of particular pages
do not existPrivilegeException
- if the current user is anonymous and anonymous
users cannot view any of the given pagesInvalidPageException
- if any of the IDs does not correspond to a
valid pageInvalidAnonymousUserException
- if the current user is anonymous,
but anonymous access has not been enabledInvalidUserException
- if the user calling this method is invalidjava.lang.NullPointerException
- if the passed pageIds_
array
or any of its elements is null
ServiceException
- if any system-level error occursPage
ResultList getPagesList(java.lang.Long[] pageIds_)
pageIds_
- the IDs of the pages that should be retrieved.ResultList
containing pages and error codes. The
Result.getResults()
method should be
used to get all the pages that were successfully retrieved. In addition,
ResultList.getResultCodes()
can be
used to get the list of result codes corresponding to each of the
specified page IDs. Each code represents the successful retrieval of a
page, or, if the page could not be retrieved, the reason for the failure;
this is one of the CODE_XXX
or PORTAL_CODE_XXX
constants defined in ResultList
.ServiceException
- if any system-level error occursboolean validateTypedValues(TypedValue[] typedValues)
typedValues
- void setPageDataContextType(java.lang.Long pageId, java.lang.Long dataContextType)
null
clear its value.pageId
- the ID of the page whose data context should be changed.dataContextType
- id of data context type; null
if clearing the context.Copyright © 2003-2024 Appian Corporation. All Rights Reserved.