Package org.hippoecm.frontend.model.tree
Class JcrTreeModel
- java.lang.Object
-
- org.hippoecm.frontend.model.tree.JcrTreeModel
-
- All Implemented Interfaces:
Serializable
,EventListener
,TreeModel
,org.apache.wicket.model.IDetachable
,org.apache.wicket.util.io.IClusterable
,IObserver<ObservableTreeModel>
,IJcrTreeModel
public class JcrTreeModel extends Object implements IJcrTreeModel, IObserver<ObservableTreeModel>, org.apache.wicket.model.IDetachable
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description JcrTreeModel(IJcrTreeNode rootModel)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addTreeModelListener(TreeModelListener l)
void
detach()
Object
getChild(Object parent, int index)
int
getChildCount(Object parent)
int
getIndexOfChild(Object parent, Object child)
ObservableTreeModel
getObservable()
The observable that the observer is interested in.Object
getRoot()
boolean
isLeaf(Object node)
TreePath
lookup(JcrNodeModel model)
protected TreeModelEvent
newTreeModelEvent(Event event)
void
onEvent(Iterator<? extends IEvent<ObservableTreeModel>> iter)
Callback that is invoked when the observable sends events.void
removeTreeModelListener(TreeModelListener l)
void
setTreeState(org.apache.wicket.extensions.markup.html.tree.DefaultTreeState state)
void
valueForPathChanged(TreePath path, Object newValue)
-
-
-
Constructor Detail
-
JcrTreeModel
public JcrTreeModel(IJcrTreeNode rootModel)
-
-
Method Detail
-
getObservable
public ObservableTreeModel getObservable()
Description copied from interface:IObserver
The observable that the observer is interested in. This observable may not change, w.r.t. theIObservable.equals(java.lang.Object)
method, while the observer is registered.- Specified by:
getObservable
in interfaceIObserver<ObservableTreeModel>
-
onEvent
public void onEvent(Iterator<? extends IEvent<ObservableTreeModel>> iter)
Description copied from interface:IObserver
Callback that is invoked when the observable sends events. The iterator is guaranteed to be non-empty.- Specified by:
onEvent
in interfaceIObserver<ObservableTreeModel>
-
newTreeModelEvent
protected TreeModelEvent newTreeModelEvent(Event event) throws RepositoryException
- Throws:
RepositoryException
-
addTreeModelListener
public void addTreeModelListener(TreeModelListener l)
- Specified by:
addTreeModelListener
in interfaceTreeModel
-
removeTreeModelListener
public void removeTreeModelListener(TreeModelListener l)
- Specified by:
removeTreeModelListener
in interfaceTreeModel
-
lookup
public TreePath lookup(JcrNodeModel model)
- Specified by:
lookup
in interfaceIJcrTreeModel
-
getChildCount
public int getChildCount(Object parent)
- Specified by:
getChildCount
in interfaceTreeModel
-
getIndexOfChild
public int getIndexOfChild(Object parent, Object child)
- Specified by:
getIndexOfChild
in interfaceTreeModel
-
valueForPathChanged
public void valueForPathChanged(TreePath path, Object newValue)
- Specified by:
valueForPathChanged
in interfaceTreeModel
-
detach
public void detach()
- Specified by:
detach
in interfaceorg.apache.wicket.model.IDetachable
-
setTreeState
public void setTreeState(org.apache.wicket.extensions.markup.html.tree.DefaultTreeState state)
-
-