Package org.hibernate.graph.internal
Class AbstractGraph<J>
java.lang.Object
org.hibernate.graph.internal.AbstractGraphNode<J>
org.hibernate.graph.internal.AbstractGraph<J>
- All Implemented Interfaces:
Graph<J>
,GraphNode<J>
,GraphImplementor<J>
,GraphNodeImplementor<J>
- Direct Known Subclasses:
RootGraphImpl
,SubGraphImpl
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
AbstractGraph
(GraphImplementor<J> original, boolean mutable) AbstractGraph
(ManagedDomainType<J> managedType, boolean mutable) -
Method Summary
Modifier and TypeMethodDescription<AJ> AttributeNodeImplementor<AJ>
addAttributeNode
(String attributeName) Add anAttributeNode
(with no associatedSubGraph
) to this container by attribute name.addAttributeNode
(AttributeNodeImplementor<?> incomingAttributeNode) <AJ> AttributeNodeImplementor<AJ>
addAttributeNode
(PersistentAttribute<? extends J, AJ> attribute) Add anAttributeNode
(with no associatedSubGraph
) to this container by attribute reference.<AJ> AttributeNodeImplementor<AJ>
findAttributeNode
(String attributeName) Find an already existing AttributeNode by attributeName within this container<AJ> AttributeNodeImplementor<AJ>
findAttributeNode
(PersistentAttribute<? extends J, AJ> attribute) Find an already existing AttributeNode by corresponding attribute reference, within this container.<AJ> AttributeNodeImplementor<AJ>
findOrCreateAttributeNode
(PersistentAttribute<? extends J, AJ> attribute) List<AttributeNode<?>>
Ultimately only needed for implementingEntityGraph.getAttributeNodes()
andSubgraph.getAttributeNodes()
Graphs apply only toManagedType
s.makeRootGraph
(String name, boolean mutable) Create a named rootGraph
if the given name is not null.void
merge
(GraphImplementor<? extends J> other) Methods inherited from class org.hibernate.graph.internal.AbstractGraphNode
isMutable, verifyMutability
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.hibernate.graph.Graph
addPluralSubgraph
Methods inherited from interface org.hibernate.graph.spi.GraphImplementor
addKeySubGraph, addKeySubGraph, addKeySubGraph, addKeySubGraph, addSubGraph, addSubGraph, addSubGraph, addSubGraph, findOrCreateAttributeNode, getAttributeNodeList, makeCopy, makeSubGraph, visitAttributeNodes
Methods inherited from interface org.hibernate.graph.spi.GraphNodeImplementor
makeCopy
-
Constructor Details
-
AbstractGraph
-
AbstractGraph
-
-
Method Details
-
getGraphedType
Description copied from interface:Graph
Graphs apply only toManagedType
s.- Specified by:
getGraphedType
in interfaceGraph<J>
- Returns:
- the
ManagedType
being graphed here.
-
makeRootGraph
Description copied from interface:Graph
Create a named rootGraph
if the given name is not null.- Specified by:
makeRootGraph
in interfaceGraph<J>
- Specified by:
makeRootGraph
in interfaceGraphImplementor<J>
mutable
- controls whether the resultingGraph
is mutable
-
merge
- Specified by:
merge
in interfaceGraphImplementor<J>
-
addAttributeNode
public AttributeNodeImplementor<?> addAttributeNode(AttributeNodeImplementor<?> incomingAttributeNode) - Specified by:
addAttributeNode
in interfaceGraphImplementor<J>
-
findAttributeNode
Description copied from interface:Graph
Find an already existing AttributeNode by attributeName within this container- Specified by:
findAttributeNode
in interfaceGraph<J>
- Specified by:
findAttributeNode
in interfaceGraphImplementor<J>
-
findAttributeNode
public <AJ> AttributeNodeImplementor<AJ> findAttributeNode(PersistentAttribute<? extends J, AJ> attribute) Description copied from interface:Graph
Find an already existing AttributeNode by corresponding attribute reference, within this container.- Specified by:
findAttributeNode
in interfaceGraph<J>
- Specified by:
findAttributeNode
in interfaceGraphImplementor<J>
-
getGraphAttributeNodes
Description copied from interface:Graph
Ultimately only needed for implementingEntityGraph.getAttributeNodes()
andSubgraph.getAttributeNodes()
- Specified by:
getGraphAttributeNodes
in interfaceGraph<J>
-
getAttributeNodeImplementors
- Specified by:
getAttributeNodeImplementors
in interfaceGraphImplementor<J>
-
addAttributeNode
public <AJ> AttributeNodeImplementor<AJ> addAttributeNode(String attributeName) throws CannotContainSubGraphException Description copied from interface:Graph
Add anAttributeNode
(with no associatedSubGraph
) to this container by attribute name.- Specified by:
addAttributeNode
in interfaceGraph<J>
- Specified by:
addAttributeNode
in interfaceGraphImplementor<J>
- Throws:
CannotContainSubGraphException
-
addAttributeNode
public <AJ> AttributeNodeImplementor<AJ> addAttributeNode(PersistentAttribute<? extends J, AJ> attribute) throws CannotContainSubGraphExceptionDescription copied from interface:Graph
Add anAttributeNode
(with no associatedSubGraph
) to this container by attribute reference.- Specified by:
addAttributeNode
in interfaceGraph<J>
- Specified by:
addAttributeNode
in interfaceGraphImplementor<J>
- Throws:
CannotContainSubGraphException
-
findOrCreateAttributeNode
public <AJ> AttributeNodeImplementor<AJ> findOrCreateAttributeNode(PersistentAttribute<? extends J, AJ> attribute) - Specified by:
findOrCreateAttributeNode
in interfaceGraphImplementor<J>
-