org.apache.slide.common
Class UriPath
java.lang.Object
org.apache.slide.common.UriPath
- public final class UriPath
- extends java.lang.Object
An URI path.
- Version:
- $Revision: 1.8 $
|
Constructor Summary |
UriPath(java.lang.String uri)
|
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
UriPath
public UriPath(java.lang.String uri)
tokens
public java.lang.String[] tokens()
lastSegment
public java.lang.String lastSegment()
parent
public UriPath parent()
child
public UriPath child(java.lang.String segment)
subUriPath
public UriPath subUriPath(int start,
int end)
subUriPathString
public java.lang.String subUriPathString(int start,
int end)
isParentOf
public boolean isParentOf(java.lang.String child)
- Tests whether a given uri is a child of this uri path.
- Parameters:
child - uri of the possible child
- Returns:
true if child is a child of this path
equals
public boolean equals(java.lang.Object o)
hashCode
public int hashCode()
toString
public java.lang.String toString()
segmentCount
public static int segmentCount(java.lang.String uri)
getParentUri
public static java.lang.String getParentUri(java.lang.String uri)
getLastSegment
public static java.lang.String getLastSegment(java.lang.String uri)
main
public static void main(java.lang.String[] args)