Package com.googlecode.objectify.impl
Class Path
- java.lang.Object
-
- com.googlecode.objectify.impl.Path
-
public class Path extends Object
Path represents the individual steps from the root object to the current property.- Author:
- Jeff Schnitzer
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description intdepth()ROOT is 0, top level Entity properties are 1, embedded things are higher.booleanequals(Object obj)Compares on complete pathPathextend(String name)PathgetPrevious()Get the previous path; for root this will be nullStringgetSegment()Get this segment of the path.inthashCode()Generates hash code for complete pathbooleanisRoot()static Pathroot()ObjectthrowIllegalState(String message)Convenient way to include path location in the exception message.ObjectthrowIllegalState(String message, Throwable cause)Convenient way to include path location in the exception message.ObjectthrowNullPointer(String message)Convenient way to include path location in the exception message.StringtoPathString()Create the full x.y.z stringStringtoString()
-
-
-
Method Detail
-
root
public static Path root()
-
toPathString
public String toPathString()
Create the full x.y.z string
-
getSegment
public String getSegment()
Get this segment of the path. For root this will be null.
-
getPrevious
public Path getPrevious()
Get the previous path; for root this will be null
-
isRoot
public boolean isRoot()
-
equals
public boolean equals(Object obj)
Compares on complete path
-
hashCode
public int hashCode()
Generates hash code for complete path
-
throwIllegalState
public Object throwIllegalState(String message)
Convenient way to include path location in the exception message. Never returns.
-
throwIllegalState
public Object throwIllegalState(String message, Throwable cause)
Convenient way to include path location in the exception message. Never returns.
-
throwNullPointer
public Object throwNullPointer(String message)
Convenient way to include path location in the exception message. Never returns.
-
depth
public int depth()
ROOT is 0, top level Entity properties are 1, embedded things are higher.
-
-