Class JPAMethodContext
java.lang.Object
org.apache.olingo.odata2.jpa.processor.api.access.JPAMethodContext
- All Implemented Interfaces:
JPAMethodContextView
The abstract class is a compilation of objects required for building specific
instances of JPA Method Context. Extend this class to implement specific
implementations of JPQL context types (Create,Update,Function). A JPA method
Context is constructed from an OData request. Depending on OData
CUD/FunctionImport operation performed on an Entity, a corresponding JPA
method context object is built. The object thus built can be used for
executing operations on JPA Entity/Custom processor objects.
A default implementation is provided by the library.
A default implementation is provided by the library.
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classThe abstract class is extended by specific JPA Method Context Builder to build JPA Method Context types. -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic final JPAMethodContext.JPAMethodContextBuildercreateBuilder(JPQLContextType contextType, Object resultsView) the method instantiates an instance of type JPAMethodContextBuilder.The method returns an instance of Object on which the methods/custom operations can be executed.The method returns list of JPA functions that can be executed on the enclosing object.protected voidsetEnclosingObject(Object enclosingObject) protected voidsetJpaFunction(List<JPAFunction> jpaFunctionList)
-
Field Details
-
enclosingObject
-
jpaFunction
-
-
Constructor Details
-
JPAMethodContext
public JPAMethodContext()
-
-
Method Details
-
getEnclosingObject
Description copied from interface:JPAMethodContextViewThe method returns an instance of Object on which the methods/custom operations can be executed.- Specified by:
getEnclosingObjectin interfaceJPAMethodContextView- Returns:
- instance of enclosing object for the method
-
getJPAFunctionList
Description copied from interface:JPAMethodContextViewThe method returns list of JPA functions that can be executed on the enclosing object.- Specified by:
getJPAFunctionListin interfaceJPAMethodContextView- Returns:
- an instance of list of JPA Function
-
setEnclosingObject
-
setJpaFunction
-
createBuilder
public static final JPAMethodContext.JPAMethodContextBuilder createBuilder(JPQLContextType contextType, Object resultsView) throws ODataJPARuntimeException the method instantiates an instance of type JPAMethodContextBuilder.- Parameters:
contextType- indicates the type of JPQLContextBuilder to instantiate.resultsView- is the OData request view- Returns:
JPAMethodContext.JPAMethodContextBuilder- Throws:
ODataJPARuntimeException- Caso ocorra exceção
-