|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.bval.jsr303.util.PathImpl
public class PathImpl
Description: object holding the property path as a list of nodes.
(Implementation based on reference implementation)
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface javax.validation.Path |
|---|
Path.Node |
| Method Summary | |
|---|---|
void |
addNode(Path.Node node)
Add a node to this PathImpl. |
static PathImpl |
copy(Path path)
Copy another Path. |
static PathImpl |
create(String name)
Create a PathImpl instance representing the specified path. |
static PathImpl |
createPathFromString(String propertyPath)
Returns a Path instance representing the path described by the given string. |
boolean |
equals(Object o)
|
NodeImpl |
getLeafNode()
Get the leaf node (if any) from this PathImpl |
PathImpl |
getPathWithoutLeafNode()
Return a new PathImpl that represents this minus its leaf node (if present). |
int |
hashCode()
|
boolean |
isRootPath()
Learn whether this PathImpl points to the root of its graph. |
boolean |
isSubPathOf(Path path)
Learn whether path is a parent to this. |
Iterator<Path.Node> |
iterator()
|
Path.Node |
removeLeafNode()
Trim the leaf node from this PathImpl. |
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Method Detail |
|---|
public static PathImpl createPathFromString(String propertyPath)
Path instance representing the path described by the given string. To create a root node the empty string should be passed.
Note: This signature is to maintain pluggability with the RI impl.
propertyPath - the path as string representation.
Path instance representing the path described by the given string.public static PathImpl create(String name)
PathImpl instance representing the specified path.
name -
public static PathImpl copy(Path path)
path -
PathImplpublic boolean isRootPath()
PathImpl points to the root of its graph.
public PathImpl getPathWithoutLeafNode()
PathImpl that represents this minus its leaf node (if present).
public void addNode(Path.Node node)
PathImpl.
node - to addpublic Path.Node removeLeafNode()
PathImpl.
IllegalStateException - if no nodes are foundpublic NodeImpl getLeafNode()
PathImpl
NodeImplpublic Iterator<Path.Node> iterator()
iterator in interface Iterable<Path.Node>public boolean isSubPathOf(Path path)
path is a parent to this.
path -
true if our nodes begin with nodes equal to those found in pathpublic String toString()
toString in class Objectpublic boolean equals(Object o)
equals in class Objectpublic int hashCode()
hashCode in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||