Package org.hibernate.graph
Enum Class GraphSemantic
- All Implemented Interfaces:
Serializable,Comparable<GraphSemantic>,Constable
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extendsEnum<E>>Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionIndicates that anEntityGraphshould be interpreted as a JPA "fetch graph".Indicates that anEntityGraphshould be interpreted as a JPA "load graph".Method Summary
Modifier and TypeMethodDescriptionstaticGraphSemanticfromHintName(String hintName) The corresponding Jakarta Persistence hint name.Deprecated.UsegetJakartaHintName()insteadstaticGraphSemanticReturns the enum constant of this class with the specified name.staticGraphSemantic[]values()Returns an array containing the constants of this enum class, inthe order they are declared.
Enum Constant Details
FETCH
Indicates that anEntityGraphshould be interpreted as a JPA "fetch graph".- Attributes explicitly specified using an
AttributeNodes are treated asFetchType.EAGERand fetched via a join or subsequent select. - Attributes not explicitly specified are treated as
FetchType.LAZYand are not fetched.
- Attributes explicitly specified using an
LOAD
Indicates that anEntityGraphshould be interpreted as a JPA "load graph".- Attributes explicitly specified using an
AttributeNodes are treated asFetchType.EAGERand fetched via a join or subsequent select. - Attributes not explicitly specified are treated as
FetchType.LAZYorFetchType.EAGERdepending on the mapping of the attribute, instead of forcingFetchType.LAZY.
- Attributes explicitly specified using an
Method Details
values
Returns an array containing the constants of this enum class, inthe order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
valueOf
Returns the enum constant of this class with the specified name.The string must matchexactly an identifier used to declare anenum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
getJakartaHintName
The corresponding Jakarta Persistence hint name.getJpaHintName
Deprecated.UsegetJakartaHintName()insteadThe hint name that should be used with Java Persistence.fromHintName