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 int
depth()
ROOT is 0, top level Entity properties are 1, embedded things are higher.boolean
equals(Object obj)
Compares on complete pathPath
extend(String name)
Path
getPrevious()
Get the previous path; for root this will be nullString
getSegment()
Get this segment of the path.int
hashCode()
Generates hash code for complete pathboolean
isRoot()
static Path
root()
Object
throwIllegalState(String message)
Convenient way to include path location in the exception message.Object
throwIllegalState(String message, Throwable cause)
Convenient way to include path location in the exception message.Object
throwNullPointer(String message)
Convenient way to include path location in the exception message.String
toPathString()
Create the full x.y.z stringString
toString()
-
-
-
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.
-
-