Package org.hibernate.spi
Class NavigablePath
java.lang.Object
org.hibernate.spi.NavigablePath
- All Implemented Interfaces:
Serializable,DotIdentifierSequence
- Direct Known Subclasses:
EntityIdentifierNavigablePath,TreatedNavigablePath
@Incubating
public class NavigablePath
extends Object
implements DotIdentifierSequence, Serializable
A compound name where the root path element is an entity name or a collection role
and each the path sub-path from the root references a domain or mapping model part
relative to a root path.
- See Also:
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionNavigablePath(String localName) NavigablePath(String rootName, @Nullable String alias) NavigablePath(@Nullable NavigablePath parent, String localName, @Nullable String alias, String identifierForTableGroup, int hashCode) NavigablePath(NavigablePath parent, String navigableName) NavigablePath(NavigablePath parent, String localName, @Nullable String alias) -
Method Summary
Modifier and TypeMethodDescriptionAppend a new part to the end of this sequence, returning the new representation.boolean@Nullable StringgetAlias()The full sequence text.The name of this leaf sequence part.@Nullable NavigablePathThe parent sequence part.@Nullable NavigablePathinthashCode()booleanbooleanisParent(@Nullable NavigablePath navigablePath) Determine whether this path is part of the given path's parentbooleanisParentOrEqual(@Nullable NavigablePath navigablePath) Determine whether this path is part of the given path's parentbooleanisSuffix(@Nullable DotIdentifierSequence dotIdentifierSequence) Determine whether the given path is a suffix of this pathprotected booleanprotected booleanbooleanpathsMatch(@Nullable NavigablePath path) @Nullable Stringrelativize(NavigablePath base) Ignores aliases in the resulting Stringprotected voidrelativize(NavigablePath base, NavigablePath.RelativePathCollector collector) toString()@Nullable NavigablePathtrimSuffix(@Nullable DotIdentifierSequence suffix) Removes the suffix part from the NavigablePath, when the NavigablePath does not contain the suffix it returns null;Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.hibernate.spi.DotIdentifierSequence
getParts, isRoot
-
Field Details
-
IDENTIFIER_MAPPER_PROPERTY
- See Also:
-
-
Constructor Details
-
NavigablePath
-
NavigablePath
-
-
Method Details
-
getParent
Description copied from interface:DotIdentifierSequenceThe parent sequence part.Given the sequence
a.b.c, returns the sequencea.b.- Specified by:
getParentin interfaceDotIdentifierSequence
-
getLocalName
Description copied from interface:DotIdentifierSequenceThe name of this leaf sequence part.Given the sequence
a.b.c, returns the string"c".- Specified by:
getLocalNamein interfaceDotIdentifierSequence
-
getAlias
-
isAliased
public boolean isAliased() -
getIdentifierForTableGroup
-
hashCode
public int hashCode() -
equals
-
localNamesMatch
-
append
Description copied from interface:DotIdentifierSequenceAppend a new part to the end of this sequence, returning the new representation.Given the sequence
a.b.c, appendingdresults in the new sequencea.b.c.d.- Specified by:
appendin interfaceDotIdentifierSequence
-
append
-
treatAs
-
treatAs
-
getRealParent
-
isSuffix
Determine whether the given path is a suffix of this path -
trimSuffix
Removes the suffix part from the NavigablePath, when the NavigablePath does not contain the suffix it returns null;- Parameters:
suffix- the part to remove from the NavigablePath- Returns:
- the NavigablePath stripped of the suffix part or null if the NavigablePath does not contain the suffix.
-
getFullPath
Description copied from interface:DotIdentifierSequenceThe full sequence text.Given the sequence
a.b.c, returns the string"a.b.c".- Specified by:
getFullPathin interfaceDotIdentifierSequence
-
toString
-