Interface AttributeNode<J>
- Type Parameters:
J- The type of the attribute
- All Superinterfaces:
AttributeNode<J>,GraphNode<J>
- All Known Subinterfaces:
AttributeNodeImplementor<J,E, K>
- All Known Implementing Classes:
AttributeNodeImpl
An AttributeNode representing an attribute whose type is a managed type or collection
of some managed type may have an associated value subgraph, which is represented by
an instance of SubGraph.
- For a singular attribute, the value type is the type of the attribute.
- For a plural attribute, the value type is the collection element type.
Or, if the represented attribute is a Map, the AttributeNode maye have an
associated key subgraph, similarly represented by a SubGraph.
Not every attribute node has a subgraph.
Extends the JPA-defined AttributeNode with additional operations.
- API Note:
- Historically, this interface declared operations with incorrect generic types, leading to unsound code. This was in Hibernate 7, with possible breakage to older code.
-
Method Summary
Modifier and TypeMethodDescriptionThePersistentAttributerepresented by this node.All key subgraphs rooted at this node.All key subgraphs rooted at this node.All value subgraphs rooted at this node.All value subgraphs rooted at this node.SubGraph<?> Deprecated.This operation is not properly type safe.<S> SubGraph<S> makeKeySubGraph(Class<S> subtype) Deprecated.This operation is not properly type safe.SubGraph<?> Deprecated.This operation is not properly type safe.<S> SubGraph<S> makeSubGraph(Class<S> subtype) Deprecated.This operation is not properly type safe.Methods inherited from interface jakarta.persistence.AttributeNode
getAttributeName
-
Method Details
-
getAttributeDescriptor
PersistentAttribute<?,J> getAttributeDescriptor()ThePersistentAttributerepresented by this node. -
getSubGraphs
All value subgraphs rooted at this node.Includes treated subgraphs.
- See Also:
-
getKeySubGraphs
All key subgraphs rooted at this node.Includes treated subgraphs.
- See Also:
-
getSubgraphs
All value subgraphs rooted at this node.Includes treated subgraphs.
- Specified by:
getSubgraphsin interfaceAttributeNode<J>- See Also:
- API Note:
- This operation is declared with raw types by JPA
-
getKeySubgraphs
All key subgraphs rooted at this node.Includes treated subgraphs.
- Specified by:
getKeySubgraphsin interfaceAttributeNode<J>- See Also:
- API Note:
- This operation is declared with raw types by JPA
-
makeSubGraph
Deprecated.This operation is not properly type safe. Note thatgraph.addAttributeNode(att).makeSubGraph()is a synonym forgraph.addSubgraph(att).Create and return a new valueSubGraphrooted at this node, or return an existing suchSubGraphif there is one.- See Also:
-
makeKeySubGraph
Deprecated.This operation is not properly type safe. Note thatgraph.addAttributeNode(att).makeKeySubGraph()is a synonym forgraph.addMapKeySubgraph(att).Create and return a new keySubGraphrooted at this node, or return an existing suchSubGraphif there is one.- See Also:
-
makeSubGraph
Deprecated.This operation is not properly type safe. Note thatgraph.addAttributeNode(att).makeSubGraph(cl)is a synonym forgraph.addTreatedSubgraph(att,cl).Create and return a new valueSubGraphrooted at this node, with the given type, which may be a subtype of the value type, or return an existing suchSubGraphif there is one.If the given type is a proper subtype of the value type, the result is a treated subgraph.
- Parameters:
subtype- The type or treated type of the value type- See Also:
-
makeKeySubGraph
Deprecated.This operation is not properly type safe. Note thatgraph.addAttributeNode(att).makeKeySubGraph(cl)is a synonym forgraph.addTreatedMapKeySubgraph(att,cl).Create and return a new valueSubGraphrooted at this node, with the given type, which may be a subtype of the key type, or return an existing suchSubGraphif there is one.If the given type is a proper subtype of the key type, the result is a treated subgraph.
- Parameters:
subtype- The type or treated type of the key type- See Also:
-