java.lang.Object
org.springframework.data.jpa.repository.query.JpaEntityGraph
EntityGraph configuration for JPA 2.1
EntityGraphs.- Since:
- 1.6
- Author:
- Thomas Darimont, Mark Paluch, Christoph Strobl
-
Constructor Summary
ConstructorsConstructorDescriptionJpaEntityGraph(String name, EntityGraph.EntityGraphType type, String[] attributePaths) Creates anJpaEntityGraphwith the given name,EntityGraph.EntityGraphTypeand attribute paths.JpaEntityGraph(EntityGraph entityGraph, String nameFallback) Creates anJpaEntityGraph. -
Method Summary
Modifier and TypeMethodDescriptionReturns the attribute node names to be used for thisJpaEntityGraph.getName()Returns the name of theEntityGraphconfiguration to use.getType()Returns theEntityGraph.EntityGraphTypeof theEntityGraphto use.booleanDeprecated, for removal: This API element is subject to removal in a future version.toString()
-
Constructor Details
-
JpaEntityGraph
Creates anJpaEntityGraph.- Parameters:
entityGraph- must not be null.nameFallback- must not be null or empty.
-
JpaEntityGraph
public JpaEntityGraph(String name, EntityGraph.EntityGraphType type, @Nullable String[] attributePaths) Creates anJpaEntityGraphwith the given name,EntityGraph.EntityGraphTypeand attribute paths.- Parameters:
name- must not be null or empty.type- must not be null.attributePaths- may be null.- Since:
- 1.9
-
-
Method Details
-
getName
Returns the name of theEntityGraphconfiguration to use.- Returns:
-
getType
Returns theEntityGraph.EntityGraphTypeof theEntityGraphto use.- Returns:
-
getAttributePaths
Returns the attribute node names to be used for thisJpaEntityGraph.- Returns:
- Since:
- 1.9
-
isAdHocEntityGraph
Deprecated, for removal: This API element is subject to removal in a future version.since 3.5 as the used evaluation does not represent whether aJpaEntityGraphis dynamic or not.Return true if thisJpaEntityGraphneeds to be generated on-the-fly.- Returns:
- true if
attributePathsis not empty. - Since:
- 1.9
-
toString
-
JpaEntityGraphis dynamic or not.