Package org.exoplatform.wiki.tree
Class TreeNode
- java.lang.Object
-
- org.exoplatform.wiki.tree.TreeNode
-
- Direct Known Subclasses:
PageTreeNode,RootTreeNode,SpaceTreeNode,WikiHomeTreeNode,WikiTreeNode
public class TreeNode extends Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classTreeNode.TREETYPE
-
Field Summary
Fields Modifier and Type Field Description static StringCAN_EDITprotected List<TreeNode>childrenstatic StringCHILDREN_NUMBERstatic StringCURRENT_PAGEstatic StringCURRENT_PATHThe current path that's used in move pagestatic StringDEPTHprotected booleanhasChildprotected Stringidprotected booleanisRetrictedprotected booleanisSelectedprotected Stringnameprotected TreeNodeTypenodeTypeprotected Stringpathstatic StringPATHstatic StringSELECTED_PAGEstatic StringSHOW_DESCENDANTstatic StringSHOW_EXCERPTstatic StringSTACK_PARAMSstatic StringWITH_DRAFTS
-
Constructor Summary
Constructors Constructor Description TreeNode()TreeNode(String name, TreeNodeType nodeType)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidaddChildren(HashMap<String,Object> context, String userId)StringbuildPath()booleanequals(Object obj)List<TreeNode>getChildren()StringgetId()StringgetName()TreeNodeTypegetNodeType()protected intgetNumberOfChildren(HashMap<String,Object> context, int size)StringgetPath()inthashCode()booleanisHasChild()booleanisRetricted()booleanisSelected()voidpushDescendants(HashMap<String,Object> context, String userId)voidsetChildren(List<TreeNode> children)voidsetHasChild(boolean hasChild)voidsetId(String id)voidsetName(String name)voidsetNodeType(TreeNodeType nodeType)voidsetRetricted(boolean isRetricted)voidsetSelected(boolean isSelected)
-
-
-
Field Detail
-
name
protected String name
-
id
protected String id
-
path
protected String path
-
isRetricted
protected boolean isRetricted
-
hasChild
protected boolean hasChild
-
nodeType
protected TreeNodeType nodeType
-
STACK_PARAMS
public static final String STACK_PARAMS
- See Also:
- Constant Field Values
-
PATH
public static final String PATH
- See Also:
- Constant Field Values
-
WITH_DRAFTS
public static final String WITH_DRAFTS
- See Also:
- Constant Field Values
-
SELECTED_PAGE
public static final String SELECTED_PAGE
- See Also:
- Constant Field Values
-
CURRENT_PATH
public static final String CURRENT_PATH
The current path that's used in move page- See Also:
- Constant Field Values
-
CURRENT_PAGE
public static final String CURRENT_PAGE
- See Also:
- Constant Field Values
-
CAN_EDIT
public static final String CAN_EDIT
- See Also:
- Constant Field Values
-
SHOW_EXCERPT
public static final String SHOW_EXCERPT
- See Also:
- Constant Field Values
-
SHOW_DESCENDANT
public static final String SHOW_DESCENDANT
- See Also:
- Constant Field Values
-
CHILDREN_NUMBER
public static final String CHILDREN_NUMBER
- See Also:
- Constant Field Values
-
DEPTH
public static final String DEPTH
- See Also:
- Constant Field Values
-
isSelected
protected boolean isSelected
-
-
Constructor Detail
-
TreeNode
public TreeNode()
-
TreeNode
public TreeNode(String name, TreeNodeType nodeType)
-
-
Method Detail
-
getId
public String getId()
-
setId
public void setId(String id)
-
getNodeType
public TreeNodeType getNodeType()
-
setNodeType
public void setNodeType(TreeNodeType nodeType)
-
isHasChild
public boolean isHasChild()
-
setHasChild
public void setHasChild(boolean hasChild)
-
getName
public String getName()
-
setName
public void setName(String name)
-
isSelected
public boolean isSelected()
-
setSelected
public void setSelected(boolean isSelected)
-
getPath
public String getPath()
-
isRetricted
public boolean isRetricted()
-
setRetricted
public void setRetricted(boolean isRetricted)
-
pushDescendants
public void pushDescendants(HashMap<String,Object> context, String userId) throws Exception
- Throws:
Exception
-
addChildren
protected void addChildren(HashMap<String,Object> context, String userId) throws Exception
- Throws:
Exception
-
buildPath
public String buildPath()
-
-