Package org.zkoss.zul.ext
Interface TreeOpenableModel
-
- All Known Implementing Classes:
AbstractTreeModel,DefaultTreeModel
public interface TreeOpenableModel- Since:
- 6.0.0
- Author:
- jumperchen
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description booleanaddOpenPath(int[] path)Adds path to the current open.booleanaddOpenPaths(int[][] paths)Adds paths to the current Open.voidclearOpen()Empties the current open path.intgetOpenCount()Returns the number of paths that are opened.int[]getOpenPath()Returns the first path in the open.int[][]getOpenPaths()Returns the paths in the open.booleanisOpenEmpty()Returns true if the open is currently empty.booleanisPathOpened(int[] path)Returns true if the path,path, is in the current open.booleanremoveOpenPath(int[] path)Removes path from the open.booleanremoveOpenPaths(int[][] paths)Removes paths from the open.
-
-
-
Method Detail
-
addOpenPath
boolean addOpenPath(int[] path)
Adds path to the current open. If path is not currently in the open the TreeDataListeners are notified. This has no effect ifpathis null.- Parameters:
path- the new path to add to the current open- Returns:
- whether it is added successfully
-
addOpenPaths
boolean addOpenPaths(int[][] paths)
Adds paths to the current Open. If any of the paths in paths are not currently in the Open the TreeDataListeners are notified. This has no effect ifpathsis null.- Parameters:
paths- the new paths to add to the current Open- Returns:
- whether an of the paths is added successfully
-
removeOpenPath
boolean removeOpenPath(int[] path)
Removes path from the open. If path is in the open The TreeDataListeners are notified. This has no effect ifpathis null.- Parameters:
path- the path to remove from the open- Returns:
- true if it was closed successfully
-
removeOpenPaths
boolean removeOpenPaths(int[][] paths)
Removes paths from the open. If any of the paths inpathsare in the open, the TreeDataListeners are notified. This method has no effect ifpathsis null.- Parameters:
paths- the path to remove from the open- Returns:
- true if one of the paths was closed successfully
-
isPathOpened
boolean isPathOpened(int[] path)
Returns true if the path,path, is in the current open.
-
isOpenEmpty
boolean isOpenEmpty()
Returns true if the open is currently empty.
-
clearOpen
void clearOpen()
Empties the current open path. If this represents a change in the current open, theTreeDataListenerlisteners are notified.
-
getOpenCount
int getOpenCount()
Returns the number of paths that are opened.
-
getOpenPath
int[] getOpenPath()
Returns the first path in the open. How first is defined is up to implementors.
-
getOpenPaths
int[][] getOpenPaths()
Returns the paths in the open. This will return null (or an empty array) if nothing is currently opened.
-
-