Package org.zkoss.zk.ui
Class Path
- java.lang.Object
-
- org.zkoss.zk.ui.Path
-
public class Path extends java.lang.ObjectA representation of a component path.There are three formats: //page-id/comp-id/comp-id
/comp-id/comp-id
comp-id/comp-idAlternatively, you could use
Component.query(java.lang.String)orComponent.queryAll(java.lang.String)instead.- Author:
- tomyeh
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(java.lang.Object o)ComponentgetComponent()Returns the component with this path, or null if no such component.static ComponentgetComponent(java.lang.String path)Returns the component of the specified path, or null if no such component.static ComponentgetComponent(IdSpace is, java.lang.String path)Returns the component of the specified path which is related to the specified ID space, or null if no such component.java.lang.StringgetPath()Returns the path (after normalized).static java.lang.StringgetPath(Component comp)Returns the path of the specified component.inthashCode()java.lang.StringtoString()
-
-
-
Method Detail
-
getPath
public java.lang.String getPath()
Returns the path (after normalized).
-
getPath
public static final java.lang.String getPath(Component comp)
Returns the path of the specified component.
-
getComponent
public Component getComponent()
Returns the component with this path, or null if no such component.
-
getComponent
public static final Component getComponent(java.lang.String path)
Returns the component of the specified path, or null if no such component.
-
getComponent
public static final Component getComponent(IdSpace is, java.lang.String path)
Returns the component of the specified path which is related to the specified ID space, or null if no such component.- Parameters:
is- the current ID space. It is required only if path is related (in other words, not starting with / or //).
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-