Package ch.tocco.nice2.dms.spi.tree
Class DomainNodeImpl
java.lang.Object
ch.tocco.nice2.dms.spi.tree.AbstractContentTreeNode
ch.tocco.nice2.dms.spi.tree.DomainNodeImpl
- All Implemented Interfaces:
ContentTreeNode
,DomainNode
- Direct Known Subclasses:
CmsDomainNodeImpl
-
Field Summary
Fields inherited from class ch.tocco.nice2.dms.spi.tree.AbstractContentTreeNode
ALIAS_FIELD_NAME, ALIAS_SPLITTER, contentTreeContext, contentTreeService, delegate, HASH_FUNCTION, LABEL_FIELD_NAME, log, mode, model, NAME_FIELD_NAME, nodeServicePointHolder, URL_FIELD_NAME
-
Constructor Summary
ConstructorDescriptionDomainNodeImpl
(Entity entity, ContentTreeService contentTreeService, NodeServicePointHolder nodeServicePointHolder) -
Method Summary
Modifier and TypeMethodDescriptionboolean
Is true, if an alias applies to the child nodes, else false.protected EntityTreeNode
decorateTreeNode
(EntityTreeNode treeNode) getName()
Returns this node's name.Get the old path part of this node.getOptimalPathForRequest
(String requestUrl) getPath()
Get the path part of this node.getUrl()
boolean
protected boolean
boolean
Determine if path part has changed (in current transaction).boolean
isRoot()
Determine if the node is a root node.void
moveAbove
(ContentTreeNode referenceNode) move the currentContentTreeNode
to the position beforereferenceNode
void
moveBelow
(ContentTreeNode referenceNode) move the currentContentTreeNode
to the position afterreferenceNode
protected String
normalizeAliases
(String aliases) protected String
normalizeName
(String name) protected String
normalizeUrl
(String url) void
Methods inherited from class ch.tocco.nice2.dms.spi.tree.AbstractContentTreeNode
addAlias, areAliasesChanged, copy, copyChild, copyChildren, copyRelation, decorateCopy, delete, equals, getAdminUrl, getAliases, getAliasesSet, getAvailablePermissions, getBusinessUnit, getBusinessUnitInvoker, getChecksum, getChild, getChildCopyParams, getChildren, getChildren, getChildren, getChildrenCount, getContent, getContentEntity, getContentPublished, getContentRelation, getContentTreeContext, getCopySource, getDefaultPublicContentTreeContext, getDelegate, getLabel, getModel, getNodeRight, getNodeRights, getOldPath, getOldPaths, getOptimalPath, getOrCreateNodeRight, getParent, getPaths, getPermissionsForChildren, getPublishStatus, getRoot, getRoot, getSorting, getTreeNode, hasChild, hasChildren, hasContentReadPermission, hashCode, hasPermissionEditPermission, invokePrivileged, isChildOf, isChildRelationChanged, isCurrentlyPublished, isParentRelationChanged, isPrivileged, isSystemNode, isVisibleInNavigation, moveInto, perform, readString, readStringPrivileged, removeNodeRight, requireParent, resetChildren, setAliases, setContentTreeContext, setLabel, setName, setParent, setPublishStatus, setSorting, setValue, setValue, toString, verifyChecksum, verifyName
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface ch.tocco.nice2.dms.api.tree.ContentTreeNode
addAlias, areAliasesChanged, copy, delete, getAdminUrl, getAliases, getAliasesSet, getAvailablePermissions, getBusinessUnit, getBusinessUnitInvoker, getChecksum, getChild, getChildren, getChildren, getChildren, getChildrenCount, getContent, getContentEntity, getContentPublished, getContentTreeContext, getCopySource, getDefaultPublicContentTreeContext, getDelegate, getLabel, getModel, getNodeRight, getNodeRights, getOldPath, getOldPaths, getOptimalPath, getOrCreateNodeRight, getParent, getPaths, getPermissionsForChildren, getPublishStatus, getRoot, getRoot, getSorting, getTreeNode, hasChild, hasChildren, hasContentReadPermission, hasContentReadPermission, hasPermissionEditPermission, isChildOf, isChildRelationChanged, isCurrentlyPublished, isParentRelationChanged, isSystemNode, isVisibleInNavigation, moveInto, removeNodeRight, requireParent, resetChildren, setAliases, setContentTreeContext, setLabel, setName, setParent, setSorting, verifyChecksum, verifyName
-
Constructor Details
-
DomainNodeImpl
public DomainNodeImpl(Entity entity, ContentTreeService contentTreeService, NodeServicePointHolder nodeServicePointHolder)
-
-
Method Details
-
getName
Description copied from interface:ContentTreeNode
Returns this node's name. The name is a normalized string used in URLs to identify this node.- Specified by:
getName
in interfaceContentTreeNode
- Overrides:
getName
in classAbstractContentTreeNode
-
getUrl
- Specified by:
getUrl
in interfaceDomainNode
-
setUrl
- Specified by:
setUrl
in interfaceDomainNode
-
hasAliases
public boolean hasAliases()- Specified by:
hasAliases
in interfaceContentTreeNode
- Overrides:
hasAliases
in classAbstractContentTreeNode
-
aliasesApplyRecursive
public boolean aliasesApplyRecursive()Description copied from interface:ContentTreeNode
Is true, if an alias applies to the child nodes, else false. This means: If aliases of this node apply recursive and this node has an alias "http://www.example.com" and there is a child node named "child", then "http://www.example.com/child" would resolve the child node.- Specified by:
aliasesApplyRecursive
in interfaceContentTreeNode
- Overrides:
aliasesApplyRecursive
in classAbstractContentTreeNode
-
isRoot
public boolean isRoot()Description copied from interface:ContentTreeNode
Determine if the node is a root node.- Specified by:
isRoot
in interfaceContentTreeNode
- Overrides:
isRoot
in classAbstractContentTreeNode
- Returns:
- true, if the node is a root node, else false.
-
getPath
- Specified by:
getPath
in interfaceContentTreeNode
- Overrides:
getPath
in classAbstractContentTreeNode
- Returns:
- the full path of the current ContentTreeNode
- Throws:
ContentException
-
getOptimalPathForRequest
- Specified by:
getOptimalPathForRequest
in interfaceContentTreeNode
- Overrides:
getOptimalPathForRequest
in classAbstractContentTreeNode
- Returns:
- the optimal path of the current ContentTreeNode which does not contain authority if possible and uses same alias as request if possible
- Throws:
ContentException
-
getPathPart
Description copied from interface:ContentTreeNode
Get the path part of this node. The full path of a node is put together from the path parts of the node and of all parent nodes.- Specified by:
getPathPart
in interfaceContentTreeNode
- Overrides:
getPathPart
in classAbstractContentTreeNode
- Returns:
- the path part of this node.
- Throws:
ContentException
-
getOldPathPart
Description copied from interface:ContentTreeNode
Get the old path part of this node. This is different fromContentTreeNode.getPathPart()
if the path part of this node or of a parent node has changed in the current transaction.- Specified by:
getOldPathPart
in interfaceContentTreeNode
- Overrides:
getOldPathPart
in classAbstractContentTreeNode
- Returns:
- the old path part.
- See Also:
-
decorateTreeNode
- Overrides:
decorateTreeNode
in classAbstractContentTreeNode
- Throws:
ContentException
-
moveBelow
Description copied from interface:ContentTreeNode
move the currentContentTreeNode
to the position afterreferenceNode
- Specified by:
moveBelow
in interfaceContentTreeNode
- Parameters:
referenceNode
- becomes the new left neighbour of thisContentTreeNode
- Throws:
ContentException
-
moveAbove
Description copied from interface:ContentTreeNode
move the currentContentTreeNode
to the position beforereferenceNode
- Specified by:
moveAbove
in interfaceContentTreeNode
- Parameters:
referenceNode
- becomes the new right neighbour of thisContentTreeNode
- Throws:
ContentException
-
isPathPartChanged
public boolean isPathPartChanged()Description copied from interface:ContentTreeNode
Determine if path part has changed (in current transaction).- Specified by:
isPathPartChanged
in interfaceContentTreeNode
- Overrides:
isPathPartChanged
in classAbstractContentTreeNode
- Returns:
- true, if the path part has changed, else false.
- See Also:
-
normalizeName
- Overrides:
normalizeName
in classAbstractContentTreeNode
-
normalizeAliases
- Overrides:
normalizeAliases
in classAbstractContentTreeNode
-
normalizeUrl
-
isEntityDocsNode
protected boolean isEntityDocsNode()- Specified by:
isEntityDocsNode
in classAbstractContentTreeNode
-