Interface IContainerMechanics
- All Superinterfaces:
IAccessMechanics
,IBasicMechanics
,IClipboardMechanics
,IComponent
,IInitializable
,IMechanics
,ISubscribableMechanics
,ISystemHandler
,IVersionableMechanics
,IViewableContainerMechanics
,IViewableMechanics
- All Known Subinterfaces:
IFolderMechanics
,ITemplateMechanics
,ITopicMechanics
Mechanics for a metadata container.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final String
static final String
Available sort orders for pageing cookiestatic final String
static final String
static final String
static final String
Fields inherited from interface com.webmethods.portal.mech.access.IAccessMechanics
ACCESS_DENIED, ACCESS_GRANTED, ACCESS_RIGHT_ID, ACCESS_RIGHT_LONG_NAME, ACCESS_RIGHT_SHORT_NAME, ACCESS_RIGHTS_CONTAINER, ACCESS_UNSPECIFIED, AUTH_LEVEL_ANONYMOUS, AUTH_LEVEL_BASIC, AUTH_LEVEL_DEFAULT, AUTH_LEVEL_FULL_ACCESS, AUTH_LEVEL_KERBEROS, AUTH_LEVEL_NTLM, AUTH_LEVEL_PROPERTY
Fields inherited from interface com.webmethods.portal.mech.storage.IBasicMechanics
PROP_CUSTOM_FILE_ENCODING, PROP_FILE_ENCODING, TITLEBAR_ACTION_SHOW_ADD_TO_HOME, TITLEBAR_ACTION_SHOW_DISPLAY_OPTIONS, TITLEBAR_ACTION_SHOW_MAXIMIZED, TITLEBAR_ACTION_SHOW_MINIMIZED, TITLEBAR_ACTION_SHOW_NORMAL
Fields inherited from interface com.webmethods.portal.mech.subscription.ISubscribableMechanics
CONTENT_FORMAT_EMAIL, CONTENT_FORMAT_EMAIL_DIGEST, CONTENT_FORMAT_PORTAL_INBOX, CONTENT_FORMAT_PORTAL_INBOX_DIGEST, HEADER_FROM, HEADER_SUBJECT, HEADER_TO
Fields inherited from interface com.webmethods.portal.mech.view.IViewableMechanics
COMMENTS_LINK_TYPE, CONTENT_LINK_TYPE, DEFAULT_ORDER, DEFAULT_PAGE_SIZE, DEFAULT_SORT, DETAILS_LINK_TYPE, LARGE_ICON_TYPE, LINK_TYPE, LINK_TYPE_COMMENTS, LINK_TYPE_CONTENT, LINK_TYPE_DETAILS, LINK_TYPE_EDIT, LINK_TYPE_HELP, LINK_TYPE_HELP_MAXIMIZED, LINK_TYPE_MAXIMIZED, LINK_TYPE_MINIMIZED, LINK_TYPE_PERMISSIONS, LINK_TYPE_PORTAL_CONTENT, LINK_TYPE_PORTLET_STANDALONE, LINK_TYPE_PROPERTIES, LINK_TYPE_RESTORED, LINK_TYPE_SUBSCRIPTIONS, LINK_TYPE_THUMBNAILS, LINK_TYPE_VERSIONS, PERMISSIONS_LINK_TYPE, PORTAL_CONTENT_LINK_TYPE, PROPERTIES_LINK_TYPE, PROPERTY_LINK_TARGET, PROPERTY_OWNER_NAME, PROPERTY_PARENT_NAME, PROPERTY_TOOLTIP, REFERENCE_ICON_TYPE, SUBSCRIPTIONS_LINK_TYPE, THUMBNAIL_ICON_TYPE, THUMBNAILS_LINK_TYPE, VERSIONS_LINK_TYPE
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addReferenceToChild
(IThingID containerId, IThingID childId) Adds a reference to the specified child into the specified container.boolean
canAddChild
(IThingID containerId, IThingID userId, int xtype) Returns true if the specified user can add a child of the specified type can to the specified container.boolean
canAddReference
(IThingID containerId, IThingID user, int xtype) Returns true if the specified user can add a reference to the specified type can to the specified container.boolean
canListChildren
(IThingID containerId, IThingID userId, Map<?, ?> capabilities) Returns true if the specified user has access to view a contents list.boolean
canRemoveChild
(IThingID containerId, IThingID userId, int xtype) Returns true if the specified user can remove a child of the specified type can to the specified container.boolean
canRemoveReference
(IThingID containerId, IThingID user, int xtype) Returns true if the specified user can remove a reference to the specified type can to the specified container.void
checkAddChild
(IThingID containerId, IThingID userId, int xtype) Throws aPortalAccessException
if the specified user cannot add a child of the specified type can to the specified container.void
checkAddReference
(IThingID containerId, IThingID user, int xtype) Throws aPortalAccessException
if the specified user cannot add a reference to the specified type can to the specified container.void
checkHasPrimaryChild
(IThingID containerId, String name) Throws an exception if this container has an active, non-reference child with the specified name.void
checkIsDescendantOrSelf
(IThingID containerId, IThingID descendantId, boolean isCopy) If a call toisDescendantOrSelf(com.webmethods.portal.service.meta2.thing.IThingID, com.webmethods.portal.service.meta2.thing.IThingID)
returns true, throw an exceptionvoid
checkListChildren
(IThingID containerId, IThingID userId, Map<?, ?> capabilities) Throws aPortalAccessException
if the specified user does not have access to view a contents list.void
checkRemoveChild
(IThingID containerId, IThingID userId, int xtype) Throws aPortalAccessException
if the specified user cannot remove a child of the specified type can to the specified container.void
checkRemoveReference
(IThingID containerId, IThingID user, int xtype) Throws aPortalAccessException
if the specified user cannot remove a reference to the specified type can to the specified container.Creates a new copy of the specified child in the specified container.Moves and renames the specified child into the specified container.createChild
(IThingID containerId, IThingID userId, int xtype, Map<String, ? extends Object> properties) Creates a new child of the specified xtype in the specified container.createChild
(IThingID containerId, IThingID userId, int xtype, Map<String, ? extends Object> properties, Locale locale) The same ascreateChild(com.webmethods.portal.service.meta2.thing.IThingID, com.webmethods.portal.service.meta2.thing.IThingID, int, java.util.Map)
but take locale for 'name' and 'description' propertiesvoid
fireAddChildEvent
(IThingID containerId, IThingID userId, int status, IThingID childId) Fires a add child event.void
fireAddReferenceEvent
(IThingID containerId, IThingID userId, int status, IThingID referenceId) Fires a add reference event.void
fireCopyChildEvent
(IThingID dstContainerId, IThingID userId, int status, IThingID dstChildId, IThingID srcContainerId, IThingID srcChildId) Fires a copy child event.void
fireCopyReferenceEvent
(IThingID dstContainerId, IThingID userId, int status, IThingID referenceId, IThingID srcContainerId) Fires a copy reference event.void
fireListChildrenEvent
(IThingID containerId, IThingID userId, int status) Fires a list contents event.void
fireMoveChildEvent
(IThingID dstContainerId, IThingID userId, int status, IThingID childId, IThingID srcContainerId) Fires a move child event.void
fireMoveChildEvent
(IThingID dstContainerId, IThingID userId, int status, IThingID childId, IThingID srcContainerId, String srcName) Fires a move child event.void
fireMoveReferenceEvent
(IThingID dstContainerId, IThingID userId, int status, IThingID referenceId, IThingID srcContainerId) Fires a move reference event.void
fireRemoveReferenceEvent
(IThingID containerId, IThingID userId, int status, IThingID referenceId) Fires a remove reference event.getPrimaryChild
(IThingID containerID, String name) Retrieve a primary child of the given container by name.getPrimaryChildNoCache
(IThingID containerID, String name) Retrieves primary child of given container by name bypassing container cachegetReference
(IThingID containerID, String name) Retrieve a reference in the given container by name.getSelectedListView
(IThingID rootID, IThingID resourceID, IThingID userID, int depth) Given a root, and a current resource, walk down from the rootdepth
levels.getSelectedListView
(IThingID rootID, IThingID resourceID, IThingID userID, int depth, boolean includeItems) Given a root, and a current resource, walk down from the rootdepth
levels.boolean
hasPrimaryChild
(IThingID containerId, String name) Returns true if this container has an active, non-reference child with the specified name.boolean
hasReference
(IThingID containerId, String name) Returns true if this container has a reference child with the specified name.boolean
isDescendantOrSelf
(IThingID containerId, IThingID descendantId) True if the second thing is a descendant of the first, or is the same thing.listChildren
(IThingID containerId) Returns a list of all the children in the specified container.listChildren
(IThingID containerId, IThingID userId, int start, int end) Returns a list of the specified length (or less) from the specified start index in the specified container.listChildren
(IThingID containerId, IThingID userId, int start, int end, int relType) Returns a list of the specified length (or less) from the specified start index in the specified container.listChildren
(IThingID containerId, IThingID userId, IPagingCookie cookie, int action, int rights) Deprecated.listChildren
(IThingID containerId, IThingID userId, IPagingCookie cookie, int action, IRightSet rights) Returns a list of the specified length (or less) from the specified start index filtered for the specified user.listChildren
(IThingID containerId, IPagingCookie cookie, int action, int rights) Deprecated.listChildren
(IThingID containerId, IPagingCookie cookie, int action, IRightSet rights) Returns a list of the specified length (or less) from the specified start index in the specified container.listChildren
(IThingID containerId, String name) Returns the active children and references with the specified name.listChildren
(IThingID containerID, String name, boolean ignoreCase) Returns all children of the given container with the specified namelistDescendants
(IThingID containerId, IThingID userId, IPagingCookie cookie, int action, int rights, int depth, boolean includeItems) Deprecated.listDescendants
(IThingID containerId, IThingID userId, IPagingCookie cookie, int action, IRightSet rights, int depth, boolean includeItems) Returns a list of the specified length (or less) from the specified start index in the specified container.listDescendants
(IThingID containerId, IPagingCookie cookie, int action, int rights, int depth, boolean includeItems) Deprecated.listDescendants
(IThingID containerId, IPagingCookie cookie, int action, IRightSet rights, int depth, boolean includeItems) Returns a list of the specified length (or less) from the specified start index in the specified container.makeUniqueName
(IThingID containerId, String name) Makes a name unique to specified container from the specified name.matchChildren
(IThingID containerId, String regEx, Locale locale) Returns a list of all the children in the specified container which match the regEx.matchChildren
(IThingID containerId, String regEx, Locale locale, IThingID userId, int start, int end) Returns a list of the specified length (or less) from the specified start index in the specified container which match the regEx.matchChildren
(IThingID containerId, String regEx, Locale locale, IThingID userId, IPagingCookie cookie, int action, int rights) Deprecated.matchChildren
(IThingID containerId, String regEx, Locale locale, IThingID userId, IPagingCookie cookie, int action, IRightSet rights) Returns a list of the specified length (or less) from the specified start index filtered for the specified user which match the regEx.matchChildren
(IThingID containerId, String regEx, Locale locale, IPagingCookie cookie, int action, int rights) Deprecated.matchChildren
(IThingID containerId, String regEx, Locale locale, IPagingCookie cookie, int action, IRightSet rights) Returns a list of the specified length (or less) from the specified start index in the specified container which match the regEx.void
Moves the specified child into the specified container.void
Moves and renames the specified child into the specified container.void
removeReferenceToChild
(IThingID containerId, IThingID childId) Removes the reference to the specified child from the specified container.viewPrimaryChild
(IThingID containerId, String name) Returns the active, non-reference child with the specified name, or null if not found.Methods inherited from interface com.webmethods.portal.mech.access.IAccessMechanics
canRemoveSecurityRealm, canSetSecurityRealm, checkAccess, checkAccessEx, checkRemoveSecurityRealm, checkSetSecurityRealm, cloneAces, fireRemoveAcccesEvent, fireRemoveSecurityRealmEvent, fireSetAccessEvent, fireSetAuthenticationEvent, fireSetOwnerEvent, fireSetSecurityRealmEvent, getAccessEx, getAccessList, getAccessListEx, getAclView, getAuthLevelForAuthScheme, getAuthScheme, getAuthSchemeForAuthLevel, getAuthSchemeForResource, getAvailableAuthSchemes, getDefaultAuthScheme, getRightNameForValue, getRightsForType, getRightValueForName, getSecurityRealm, invalidateAcesForThing, invalidateAcesForUser, listSecurityRealmObjects, removeAces, removeSecurityRealm, setAces, setAcesEx, setSecurityRealm, setSecurityRealm
Methods inherited from interface com.webmethods.portal.mech.storage.IBasicMechanics
addNote, addReference, addRelation, canAddNote, canCloneRemote, canCreate, canDelete, canDestroy, canDoTitlebarAction, canListAccess, canListContainers, canListNotes, canRemoveAccess, canRemoveNote, canSetAccess, canSetAuthentication, canSetOwner, canUninstall, canUpdateContent, canUpdateProperties, canVerb, canViewAuthentication, canViewContent, checkAddNote, checkCloneRemote, checkCreate, checkDelete, checkDestroy, checkListAccess, checkListContainers, checkListNotes, checkRemoveAccess, checkRemoveNote, checkSetAccess, checkSetAuthentication, checkSetOwner, checkUninstall, checkUpdateContent, checkUpdateProperties, checkViewAuthentication, checkViewContent, cloneRemote, copy, create, create, delete, destroy, doAfterInstall, doAfterUpgrade, doBeforeUninstall, doBeforeUpgrade, fireAddNoteEvent, fireCacheInvalidateEvent, fireDeleteEvent, fireInsoEvent, fireListAccessEvent, fireListContainersEvent, fireListNotesEvent, firePurgeEvent, fireRemoveAcccesEvent, fireRemoveNoteEvent, fireSetAccessEvent, fireSetAuthenticationEvent, fireSetOwnerEvent, fireUpdateContentEvent, fireUpdatePropertiesEvent, fireViewAuthenticationEvent, fireViewContentEvent, getAccess, getAncestors, getAuthentication, getContent, getContent, getContentStore, getContentStore, getDependencyList, getPrimaryRelatedChild, getPrimaryRelatedContainer, getTimeToLive, isAnonymous, isBaseType, isContainer, isNormal, isReference, isVersionable, isWorkflowEnabled, listAccess, listAccess, listContainers, listContainers, listDependants, listNotes, listRelatedChildren, listRelatedContainers, move, move, prepareForDeletion, removeNote, removeReference, removeRelation, restoreXTypeConfProps, saveXTypeConfProps, setAuthentication, setOwner, setTimeToLive, undeleteAllUndestroyed, updateContent, updateContent, updateProperties, updateProperties
Methods inherited from interface com.webmethods.portal.mech.clipboard.IClipboardMechanics
canCopyToClipboard, canCutToClipboard, checkCopyToClipboard, checkCutToClipboard, copyToClipboard, cutToClipboard, getClipboard, getClipboardInfo, newClipboardItem
Methods inherited from interface com.webmethods.portal.system.IComponent
getComponentData, getComponentName, getComponentProvider, getURI, isInitialized, setComponentData, setComponentProvider
Methods inherited from interface com.webmethods.portal.system.init.IInitializable
init, shutdown
Methods inherited from interface com.webmethods.portal.mech.subscription.ISubscribableMechanics
canDeliverToPrincipal, canEditSubscription, canListSubscriptions, canViewSubscription, checkEditSubscription, checkListSubscriptions, checkViewSubscription, checkViewSubscription, createAppCriteria, createAppCriteriaFolder, createPortletSubscription, createPortletSubscription, disable, disable, disableBySystem, disableBySystem, enable, enable, fireGetAppCriteriaEvent, fireGetSubscriptionEvent, fireSetSubscriptionEvent, fireUnsubscribeEvent, fireViewSubscriptionEvent, generateNotificationContent, generateNotificationHeaders, getAppCriteria, getGroupSubscription, getSubscription, listSubscriptions, listSubscriptions, setGroupSubscription, setGroupSubscription, setSubscription, setSubscription, unsubscribe, unsubscribe, viewSubscription
Methods inherited from interface com.webmethods.portal.mech.storage.IVersionableMechanics
addToVersioning, canAddToVersioning, canCheckIn, canCheckOut, canListVersions, canPublishVersion, canRemoveFromVersioning, canSetCurrentVersion, canUndoCheckOut, canViewVersion, checkAddToVersioning, checkCheckIn, checkCheckOut, checkIn, checkListVersions, checkOut, checkPublishVersion, checkRemoveFromVersioning, checkSetCurrentVersion, checkUndoCheckOut, checkViewVersion, fireAddToVersioningEvent, fireCheckInEvent, fireCheckOutEvent, fireListVersionsEvent, firePublishVersionEvent, fireRemoveFromVersioningEvent, fireSetCurrentVersionEvent, fireUndoCheckOutEvent, fireViewVersionEvent, getCheckedOutBy, getVersion, isCheckedOut, isVersioned, listVersions, publishVersion, removeFromVersioning, setCurrentVersion, undoCheckOut, viewVersion
Methods inherited from interface com.webmethods.portal.mech.view.IViewableContainerMechanics
createPagingCookie
Methods inherited from interface com.webmethods.portal.mech.view.IViewableMechanics
canView, checkView, fireViewEvent, getCss, getCss, getDefaultLinkType, getFormattedProperty, getHierachicalUri, getIcon, getIcon, getLink, getLink, getListProperty, getListPropertyHTML, getListPropertyJS, isEnabled, view, view
-
Field Details
-
SORT_ITEMNAME
Available sort orders for pageing cookie- See Also:
-
SORT_MODIFIED
- See Also:
-
SORT_TYPE
- See Also:
-
SORT_SORTID
- See Also:
-
SORT_NONE_SPECIFIED
- See Also:
-
CREATE_DEFAULT_CONTAINER
- See Also:
-
-
Method Details
-
canListChildren
boolean canListChildren(IThingID containerId, IThingID userId, Map<?, ?> capabilities) throws PortalExceptionReturns true if the specified user has access to view a contents list.- Throws:
PortalException
-
checkListChildren
void checkListChildren(IThingID containerId, IThingID userId, Map<?, ?> capabilities) throws PortalException, PortalAccessExceptionThrows aPortalAccessException
if the specified user does not have access to view a contents list.- Throws:
PortalException
PortalAccessException
-
canAddChild
Returns true if the specified user can add a child of the specified type can to the specified container.- Throws:
PortalException
-
checkAddChild
void checkAddChild(IThingID containerId, IThingID userId, int xtype) throws PortalException, PortalAccessException Throws aPortalAccessException
if the specified user cannot add a child of the specified type can to the specified container.- Throws:
PortalException
PortalAccessException
-
canAddReference
Returns true if the specified user can add a reference to the specified type can to the specified container.- Throws:
PortalException
-
checkAddReference
void checkAddReference(IThingID containerId, IThingID user, int xtype) throws PortalException, PortalAccessException Throws aPortalAccessException
if the specified user cannot add a reference to the specified type can to the specified container.- Throws:
PortalException
PortalAccessException
-
canRemoveChild
Returns true if the specified user can remove a child of the specified type can to the specified container.- Throws:
PortalException
-
checkRemoveChild
void checkRemoveChild(IThingID containerId, IThingID userId, int xtype) throws PortalException, PortalAccessException Throws aPortalAccessException
if the specified user cannot remove a child of the specified type can to the specified container.- Throws:
PortalException
PortalAccessException
-
canRemoveReference
Returns true if the specified user can remove a reference to the specified type can to the specified container.- Throws:
PortalException
-
checkRemoveReference
void checkRemoveReference(IThingID containerId, IThingID user, int xtype) throws PortalException, PortalAccessException Throws aPortalAccessException
if the specified user cannot remove a reference to the specified type can to the specified container.- Throws:
PortalException
PortalAccessException
-
fireListChildrenEvent
void fireListChildrenEvent(IThingID containerId, IThingID userId, int status) throws PortalException Fires a list contents event.- Parameters:
containerId
- Container whose children were listed.userId
- User for whom the children were listed.status
- Status of the event (sucessful, denied, error).- Throws:
PortalException
-
fireAddChildEvent
void fireAddChildEvent(IThingID containerId, IThingID userId, int status, IThingID childId) throws PortalException Fires a add child event.- Parameters:
containerId
- Container to which the child was added.userId
- User on whose behalf the child was added.status
- Status of the event (sucessful, denied, error).childId
- Added child.- Throws:
PortalException
-
fireAddReferenceEvent
void fireAddReferenceEvent(IThingID containerId, IThingID userId, int status, IThingID referenceId) throws PortalException Fires a add reference event.- Parameters:
containerId
- Container to which the reference to the child was added.userId
- User on whose behalf the reference to the child was added.status
- Status of the event (sucessful, denied, error).referenceId
- Referenced child.- Throws:
PortalException
-
fireCopyChildEvent
void fireCopyChildEvent(IThingID dstContainerId, IThingID userId, int status, IThingID dstChildId, IThingID srcContainerId, IThingID srcChildId) throws PortalException Fires a copy child event.- Parameters:
dstContainerId
- Container into which the child was copied.userId
- User on whose behalf the child was copied.status
- Status of the event (sucessful, denied, error).dstChildId
- New copy of the child.srcContainerId
- Container from which the child was copied.srcChildId
- Old copy of the child.- Throws:
PortalException
-
fireCopyReferenceEvent
void fireCopyReferenceEvent(IThingID dstContainerId, IThingID userId, int status, IThingID referenceId, IThingID srcContainerId) throws PortalException Fires a copy reference event.- Parameters:
dstContainerId
- Container into which the reference was copied.userId
- User on whose behalf the reference was copied.status
- Status of the event (sucessful, denied, error).referenceId
- Copied reference.srcContainerId
- Container from which the reference was copied.- Throws:
PortalException
-
fireMoveChildEvent
void fireMoveChildEvent(IThingID dstContainerId, IThingID userId, int status, IThingID childId, IThingID srcContainerId) throws PortalException Fires a move child event.- Parameters:
dstContainerId
- Container into which the child was moved.userId
- User on whose behalf the child was moved.status
- Status of the event (sucessful, denied, error).childId
- Moved child.srcContainerId
- Container from which the child was moved.- Throws:
PortalException
-
fireMoveChildEvent
void fireMoveChildEvent(IThingID dstContainerId, IThingID userId, int status, IThingID childId, IThingID srcContainerId, String srcName) throws PortalException Fires a move child event.- Parameters:
dstContainerId
- Container into which the child was moved.userId
- User on whose behalf the child was moved.status
- Status of the event (sucessful, denied, error).childId
- Moved child.srcContainerId
- Container from which the child was moved.srcName
- the original name of the moved item- Throws:
PortalException
-
fireMoveReferenceEvent
void fireMoveReferenceEvent(IThingID dstContainerId, IThingID userId, int status, IThingID referenceId, IThingID srcContainerId) throws PortalException Fires a move reference event.- Parameters:
dstContainerId
- Container into which the reference was moved.userId
- User on whose behalf the reference was moved.status
- Status of the event (sucessful, denied, error).referenceId
- Moved reference.srcContainerId
- Container from which the reference was moved.- Throws:
PortalException
-
fireRemoveReferenceEvent
void fireRemoveReferenceEvent(IThingID containerId, IThingID userId, int status, IThingID referenceId) throws PortalException Fires a remove reference event.- Parameters:
containerId
- Container from which the reference was removed.userId
- User on whose behalf the reference was removed.status
- Status of the event (sucessful, denied, error).referenceId
- Removed reference.- Throws:
PortalException
-
isDescendantOrSelf
True if the second thing is a descendant of the first, or is the same thing.- Parameters:
containerId
- the target container for the move or copy operationdescendantId
- the thing that will be moved or copied- Throws:
PortalException
-
checkIsDescendantOrSelf
void checkIsDescendantOrSelf(IThingID containerId, IThingID descendantId, boolean isCopy) throws PortalException If a call toisDescendantOrSelf(com.webmethods.portal.service.meta2.thing.IThingID, com.webmethods.portal.service.meta2.thing.IThingID)
returns true, throw an exception- Parameters:
containerId
- the target container for the move or copy operationdescendantId
- the thing that will be moved or copiedisCopy
- whether to throw a move or a copy exception if it fails- Throws:
PortalException
-
makeUniqueName
Makes a name unique to specified container from the specified name. If the name is already unique in this container, returns the unchanged name. Otherwise, some number or text is appended to the name to make it unique.- Throws:
PortalException
-
getPrimaryChild
Retrieve a primary child of the given container by name.- Parameters:
containerID
- the id of the containername
- the (case-insensitive) name of the child to retrieve- Returns:
- the child thingID or null if not found
- Throws:
PortalException
-
getPrimaryChildNoCache
Retrieves primary child of given container by name bypassing container cache- Parameters:
containerID
- the id of the containername
- the (case-insensitive) name of the child to retrieve- Returns:
- the child thingID or null if not found
- Throws:
PortalException
-
hasPrimaryChild
Returns true if this container has an active, non-reference child with the specified name.- Parameters:
containerID
- the id of the containername
- the (case-insensitive) name of the child to retrieve- Returns:
- true if the child was found, false otherwise
- Throws:
PortalException
-
checkHasPrimaryChild
Throws an exception if this container has an active, non-reference child with the specified name.- Parameters:
containerID
- the id of the containername
- the (case-insensitive) name of the child to check- Throws:
PortalException
- if the primary child exists.
-
viewPrimaryChild
Returns the active, non-reference child with the specified name, or null if not found.- Parameters:
containerID
- the id of the containername
- the (case-insensitive) name of the child to retrieve- Returns:
- the view of the child, or null if the child was not found
- Throws:
PortalException
-
getReference
Retrieve a reference in the given container by name.- Parameters:
containerID
- the id of the containername
- the (case-insensitive) name of the reference to retrieve- Returns:
- the thingId, or null if the reference was not found
- Throws:
PortalException
-
hasReference
Returns true if this container has a reference child with the specified name.- Parameters:
containerId
- the container to lookup the child inname
- the (case-insensitive) name of the reference to lookup- Returns:
- true if the container has a child with the given name
- Throws:
PortalException
-
listChildren
Returns the active children and references with the specified name.- Parameters:
containerId
- the container to lookup the child inname
- the (case-insensitive) name of the reference to lookup- Returns:
- an
IThingIDList
ofIThingID
objects - Throws:
PortalException
-
listChildren
IThingIDList listChildren(IThingID containerID, String name, boolean ignoreCase) throws PortalException Returns all children of the given container with the specified name- Parameters:
containerId
- the container to lookup the child inname
- the name of the reference to lookupignoreCase
- whether to use case sensitive matching. If false, case sensitive matching would be done.- Returns:
- an
IThingIDList
ofIThingID
objects - Throws:
PortalException
-
listChildren
Returns a list of all the children in the specified container. May return null to signal no children.- Parameters:
containerId
- Container.- Returns:
- an
IThingIDList
ofIThingID
objects - Throws:
PortalException
-
listChildren
IThingIDList listChildren(IThingID containerId, IThingID userId, int start, int end) throws PortalException Returns a list of the specified length (or less) from the specified start index in the specified container.- Parameters:
containerId
- Container of descendants.userId
- User for which to filter.start
- List starting index (0 for first item).end
- List ending index (<1 for all items).- Returns:
- an
IThingIDList
ofIThingID
objects - Throws:
PortalException
-
listChildren
IThingIDList listChildren(IThingID containerId, IThingID userId, int start, int end, int relType) throws PortalException Returns a list of the specified length (or less) from the specified start index in the specified container.- Parameters:
containerId
- Container of descendants.userId
- User for which to filter.start
- List starting index (0 for first item).end
- List ending index (<1 for all items).relType
- the relation type to include- Returns:
- an
IThingIDList
ofIThingID
objects - Throws:
PortalException
-
listChildren
@Deprecated IListView<? extends IView> listChildren(IThingID containerId, IPagingCookie cookie, int action, int rights) throws PortalException Deprecated.Returns a list of the specified length (or less) from the specified start index in the specified container.- Parameters:
containerId
- Container of children.cookie
- Paging state.action
- Paging action to perform.rights
- User's rights by which to filter.- Returns:
- List of
IView
items, or an empty list. - Throws:
PortalException
-
listChildren
IListView<? extends IView> listChildren(IThingID containerId, IPagingCookie cookie, int action, IRightSet rights) throws PortalException Returns a list of the specified length (or less) from the specified start index in the specified container.- Parameters:
containerId
- Container of children.cookie
- Paging state.action
- Paging action to perform.rights
- User's rights by which to filter.- Returns:
- List of
IView
items, or an empty list. - Throws:
PortalException
-
listChildren
@Deprecated IListView<? extends IView> listChildren(IThingID containerId, IThingID userId, IPagingCookie cookie, int action, int rights) throws PortalException Deprecated.iseinstead
Returns a list of the specified length (or less) from the specified start index filtered for the specified user.- Parameters:
containerId
- Container of children.userId
- User for which to filter.cookie
- Paging state.action
- Paging action to perform.rights
- User's rights by which to filter.- Returns:
- List of
IView
items, or an empty list. - Throws:
PortalException
-
listChildren
IListView<? extends IView> listChildren(IThingID containerId, IThingID userId, IPagingCookie cookie, int action, IRightSet rights) throws PortalException Returns a list of the specified length (or less) from the specified start index filtered for the specified user.- Parameters:
containerId
- Container of children.userId
- User for which to filter.cookie
- Paging state.action
- Paging action to perform.rights
- User's rights by which to filter.- Returns:
- List of
IView
items, or an empty list. - Throws:
PortalException
-
matchChildren
IThingIDList matchChildren(IThingID containerId, String regEx, Locale locale) throws PortalException Returns a list of all the children in the specified container which match the regEx. May return null to signal no children.- Parameters:
containerId
- Container.- Throws:
PortalException
-
matchChildren
IThingIDList matchChildren(IThingID containerId, String regEx, Locale locale, IThingID userId, int start, int end) throws PortalException Returns a list of the specified length (or less) from the specified start index in the specified container which match the regEx.- Parameters:
containerId
- Container of descendants.userId
- User for which to filter.start
- List starting index (0 for first item).end
- List ending index (<1 for all items).- Returns:
- an
IThingIDList
ofIThingID
objects - Throws:
PortalException
-
matchChildren
@Deprecated IListView<? extends IView> matchChildren(IThingID containerId, String regEx, Locale locale, IPagingCookie cookie, int action, int rights) throws PortalException Deprecated.Returns a list of the specified length (or less) from the specified start index in the specified container which match the regEx.- Parameters:
containerId
- Container of children.cookie
- Paging state.action
- Paging action to perform.rights
- User's rights by which to filter.- Returns:
- List of
IView
items, or an empty list. - Throws:
PortalException
-
matchChildren
IListView<? extends IView> matchChildren(IThingID containerId, String regEx, Locale locale, IPagingCookie cookie, int action, IRightSet rights) throws PortalException Returns a list of the specified length (or less) from the specified start index in the specified container which match the regEx.- Parameters:
containerId
- Container of children.cookie
- Paging state.action
- Paging action to perform.rights
- User's rights by which to filter.- Returns:
- List of
IView
items, or an empty list. - Throws:
PortalException
-
matchChildren
@Deprecated IListView<? extends IView> matchChildren(IThingID containerId, String regEx, Locale locale, IThingID userId, IPagingCookie cookie, int action, int rights) throws PortalException Deprecated.Returns a list of the specified length (or less) from the specified start index filtered for the specified user which match the regEx.- Parameters:
containerId
- Container of children.userId
- User for which to filter.cookie
- Paging state.action
- Paging action to perform.rights
- User's rights by which to filter.- Returns:
- List of
IView
items, or an empty list. - Throws:
PortalException
-
matchChildren
IListView<? extends IView> matchChildren(IThingID containerId, String regEx, Locale locale, IThingID userId, IPagingCookie cookie, int action, IRightSet rights) throws PortalException Returns a list of the specified length (or less) from the specified start index filtered for the specified user which match the regEx.- Parameters:
containerId
- Container of children.userId
- User for which to filter.cookie
- Paging state.action
- Paging action to perform.rights
- User's rights by which to filter.- Returns:
- List of
IView
items, or an empty list. - Throws:
PortalException
-
listDescendants
@Deprecated IListView<? extends IView> listDescendants(IThingID containerId, IPagingCookie cookie, int action, int rights, int depth, boolean includeItems) throws PortalException Deprecated.Returns a list of the specified length (or less) from the specified start index in the specified container.- Parameters:
containerId
- Container of descendants.cookie
- Paging state.action
- Paging action to perform.rights
- User's rights by which to filter.depth
- Depth to descend. 0 for all, 1 for children, 2 for children & grandchildren, etc.includeItems
- True to list containers and noncontainers; false to list containers only.- Returns:
- List of
IView
items, or an empty list. - Throws:
PortalException
-
listDescendants
IListView<? extends IView> listDescendants(IThingID containerId, IPagingCookie cookie, int action, IRightSet rights, int depth, boolean includeItems) throws PortalException Returns a list of the specified length (or less) from the specified start index in the specified container.- Parameters:
containerId
- Container of descendants.cookie
- Paging state.action
- Paging action to perform.rights
- User's rights by which to filter.depth
- Depth to descend. 0 for all, 1 for children, 2 for children & grandchildren, etc.includeItems
- True to list containers and noncontainers; false to list containers only.- Returns:
- List of
IView
items, or an empty list. - Throws:
PortalException
-
listDescendants
@Deprecated IListView<? extends IView> listDescendants(IThingID containerId, IThingID userId, IPagingCookie cookie, int action, int rights, int depth, boolean includeItems) throws PortalException Deprecated.Returns a list of the specified length (or less) from the specified start index in the specified container.- Parameters:
containerId
- Container of descendants.userId
- User for which to filter.cookie
- Paging state.action
- Paging action to perform.rights
- User's rights by which to filter.depth
- Depth to descend. 0 for all, 1 for children, 2 for children & grandchildren, etc.includeItems
- True to list containers and noncontainers; false to list containers only.- Returns:
- List of
IView
items, or an empty list. - Throws:
PortalException
-
listDescendants
IListView<? extends IView> listDescendants(IThingID containerId, IThingID userId, IPagingCookie cookie, int action, IRightSet rights, int depth, boolean includeItems) throws PortalException Returns a list of the specified length (or less) from the specified start index in the specified container.- Parameters:
containerId
- Container of descendants.userId
- User for which to filter.cookie
- Paging state.action
- Paging action to perform.rights
- User's rights by which to filter.depth
- Depth to descend. 0 for all, 1 for children, 2 for children & grandchildren, etc.includeItems
- True to list containers and noncontainers; false to list containers only.- Returns:
- List of
IView
items, or an empty list. - Throws:
PortalException
-
getSelectedListView
ISelectedListView getSelectedListView(IThingID rootID, IThingID resourceID, IThingID userID, int depth) throws PortalException Given a root, and a current resource, walk down from the rootdepth
levels. (0 would equal the root). Then return theISelectedListView
that shows the sibling items at that level, including the current item which is selected.
Selected implies that that resource is along the path to the root from the current resource.- Parameters:
rootID
- the root of the depth based list viewresourceID
- the item that helps determine the selected pathdepth
- how many levels to descend from the root (0 = root)- Returns:
- the IListView that contains selected information
- Throws:
PortalException
-
getSelectedListView
ISelectedListView getSelectedListView(IThingID rootID, IThingID resourceID, IThingID userID, int depth, boolean includeItems) throws PortalException Given a root, and a current resource, walk down from the rootdepth
levels. (0 would equal the root). Then return theISelectedListView
that shows the sibling items at that level, including the current item which is selected.
Selected implies that that resource is along the path to the root from the current resource.- Parameters:
rootID
- the root of the depth based list viewresourceID
- the item that helps determine the selected pathdepth
- how many levels to descend from the root (0 = root)includeItems
- True to list containers and noncontainers; false to list containers only.- Returns:
- the IListView that contains selected information
- Throws:
PortalException
-
createChild
IThingID createChild(IThingID containerId, IThingID userId, int xtype, Map<String, ? extends Object> properties) throws PortalExceptionCreates a new child of the specified xtype in the specified container.- Parameters:
containerId
- Container in which to create.userId
- User for which to create.xtype
- Child type to create.properties
- New child's properties. May not be null.- Throws:
PortalException
-
createChild
IThingID createChild(IThingID containerId, IThingID userId, int xtype, Map<String, ? extends Object> properties, Locale locale) throws PortalExceptionThe same ascreateChild(com.webmethods.portal.service.meta2.thing.IThingID, com.webmethods.portal.service.meta2.thing.IThingID, int, java.util.Map)
but take locale for 'name' and 'description' properties- Parameters:
containerId
-userId
-xtype
-properties
-locale
-- Returns:
- Throws:
PortalException
-
copyChild
Creates a new copy of the specified child in the specified container.- Parameters:
containerId
- Container in which to copy.userId
- User for which to copy.childId
- Child to copy.- Throws:
PortalException
-
copyChild
IThingID copyChild(IThingID containerId, IThingID userId, IThingID childId, String newName) throws PortalException Moves and renames the specified child into the specified container.- Parameters:
containerId
- Container in which to copy.userId
- User for which to copy.childId
- Child to copy.newName
- the new name to give the child- Throws:
PortalException
-
moveChild
Moves the specified child into the specified container.- Parameters:
containerId
- Container into which to move.childId
- Child to move.- Throws:
PortalException
-
moveChild
Moves and renames the specified child into the specified container.- Parameters:
containerId
- Container into which to move.childId
- Child to move.newName
- the new name to give the child- Throws:
PortalException
-
addReferenceToChild
Adds a reference to the specified child into the specified container.- Parameters:
containerId
- Container in which to add.childId
- Child to add.- Throws:
PortalException
-
removeReferenceToChild
Removes the reference to the specified child from the specified container.- Parameters:
containerId
- Container from which to remove.childId
- Child to remove.- Throws:
PortalException
-
instead