Package org.zkoss.zuti.zul
Interface NavigationLevel<T>
- Type Parameters:
T- The data type
public interface NavigationLevel<T>
An object that represents the navigation level.
- Since:
- 8.6.0
- Author:
- rudyhuang
-
Method Summary
Modifier and TypeMethodDescriptiongetChild()Gets the child navigation level if any.Gets the context of this level if any.Gets the data associated with the current key if any.Gets the current key.Gets the item iterator in this level.getItems()Gets the list of items in this level.intgetLevel()Gets the level number.navigateTo(String key) Navigates to the specified key in the current level.setContext(Map<String, Object> context) Sets the context of this level.
-
Method Details
-
getLevel
int getLevel()Gets the level number. The first level is 1.- Returns:
- the level number
-
getContext
Gets the context of this level if any.- Returns:
- the context map. Might be
null
-
setContext
Sets the context of this level.- Parameters:
context- the context map- Returns:
- this object
-
getCurrentKey
String getCurrentKey()Gets the current key. If no data exists in this level, the result isnull.- Returns:
- the current key. Might be
null
-
getCurrent
T getCurrent()Gets the data associated with the current key if any.- Returns:
- the data object. Might be
null
-
getChild
NavigationLevel<T> getChild()Gets the child navigation level if any.- Returns:
- the child navigation level. Might be
null
-
getItemIterator
Gets the item iterator in this level. ThePair.getX()is the key, andPair.getY()is the data.- Returns:
- the item iterator
-
getItems
Gets the list of items in this level. Note: The performance is no good.- Returns:
- the list of items
-