Package org.teiid.translator.jpa
Class JPA2ExecutionFactory
- java.lang.Object
-
- org.teiid.translator.ExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
- org.teiid.translator.jpa.JPA2ExecutionFactory
-
@Translator(name="jpa2", description="A translator for JPA2 based entities") public class JPA2ExecutionFactory extends ExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.teiid.translator.ExecutionFactory
ExecutionFactory.Format, ExecutionFactory.NullOrder, ExecutionFactory.SupportedJoinCriteria, ExecutionFactory.TransactionSupport
-
-
Field Summary
-
Fields inherited from class org.teiid.translator.ExecutionFactory
DEFAULT_MAX_FROM_GROUPS, DEFAULT_MAX_IN_CRITERIA_SIZE, DEFAULT_MAX_PROJECTED_COLUMNS
-
-
Constructor Summary
Constructors Constructor Description JPA2ExecutionFactory()
-
Method Summary
-
Methods inherited from class org.teiid.translator.ExecutionFactory
addPushDownFunction, areLobsUsableAfterClose, createExecution, getCacheDirective, getCollationLocale, getConnection, getDefaultNullOrder, getDirectQueryProcedureName, getExcludedCommonTableExpressionName, getInstance, getLanguageFactory, getMaxDependentInPredicates, getMaxFromGroups, getMaxInCriteriaSize, getMaxProjectedColumns, getMetadata, getNativeQueryProcedureName, getPushDownFunctions, getRequiredLikeEscape, getSupportedJoinCriteria, getTransactionSupport, getTypeFacility, initCapabilities, isCopyLobs, isForkable, isImmutable, isSourceRequired, isSourceRequiredForCapabilities, isSourceRequiredForMetadata, isThreadBound, requiresCriteria, returnsSingleUpdateCount, setCollationLocale, setCopyLobs, setDirectQueryProcedureName, setExcludedCommonTableExpressionName, setImmutable, setMaxDependentInPredicates, setMaxInCriteriaSize, setNativeQueryProcedureName, setRequiresCriteria, setSourceRequired, setSourceRequiredForMetadata, setSupportedJoinCriteria, setSupportsDirectQueryProcedure, setSupportsFullOuterJoins, setSupportsInnerJoins, setSupportsNativeQueries, setSupportsOrderBy, setSupportsOuterJoins, setSupportsSelectDistinct, setThreadBound, setTransactionSupport, supportsAdvancedOlapOperations, supportsAggregatesCountBig, supportsAggregatesEnhancedNumeric, supportsArrayAgg, supportsArrayType, supportsBatchedUpdates, supportsBulkUpdate, supportsCommonTableExpressions, supportsCompareCriteriaOrderedExclusive, supportsConvert, supportsCorrelatedSubqueries, supportsCorrelatedSubqueryLimit, supportsDirectQueryProcedure, supportsElementaryOlapOperations, supportsExcept, supportsFormatLiteral, supportsFullDependentJoins, supportsFullOuterJoins, supportsFunctionsInGroupBy, supportsGeographyType, supportsGroupByMultipleDistinctAggregates, supportsGroupByRollup, supportsInnerJoins, supportsInsertWithQueryExpression, supportsIntersect, supportsIsDistinctCriteria, supportsLateralJoin, supportsLateralJoinCondition, supportsLikeCriteriaEscapeCharacter, supportsLikeRegex, supportsListAgg, supportsMultipleOpenExecutions, supportsNativeQueries, supportsOnlyCorrelatedSubqueries, supportsOnlyFormatLiterals, supportsOnlyLateralJoinProcedure, supportsOnlyLiteralComparison, supportsOnlyRelationshipStyleJoins, supportsOnlySingleTableGroupBy, supportsOnlyTimestampAddLiteral, supportsOrderBy, supportsOrderByNullOrdering, supportsOrderByUnrelated, supportsOrderByWithExtendedGrouping, supportsOuterJoins, supportsPartialFiltering, supportsProcedureParameterExpression, supportsProcedureTable, supportsQuantifiedCompareCriteriaAll, supportsQuantifiedCompareCriteriaSome, supportsRecursiveCommonTableExpressions, supportsScalarSubqueryProjection, supportsSearchedCaseExpressions, supportsSelectDistinct, supportsSelectExpressionArrayType, supportsSelectWithoutFrom, supportsSetQueryLimitOffset, supportsSetQueryOrderBy, supportsSimilarTo, supportsStringAgg, supportsSubqueryCommonTableExpressions, supportsSubqueryInOn, supportsUnions, supportsUpsert, supportsWindowDistinctAggregates, supportsWindowFrameClause, supportsWindowFunctionCumeDist, supportsWindowFunctionNthValue, supportsWindowFunctionNtile, supportsWindowFunctionPercentRank, supportsWindowOrderByWithAggregates, useBindingsForDependentJoin
-
-
-
-
Method Detail
-
start
public void start() throws TranslatorException- Overrides:
startin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>- Throws:
TranslatorException
-
getConnection
public javax.persistence.EntityManager getConnection(javax.persistence.EntityManagerFactory factory, ExecutionContext executionContext) throws TranslatorException- Overrides:
getConnectionin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>- Throws:
TranslatorException
-
closeConnection
public void closeConnection(javax.persistence.EntityManager connection, javax.persistence.EntityManagerFactory factory)- Overrides:
closeConnectionin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
createResultSetExecution
public ResultSetExecution createResultSetExecution(QueryExpression command, ExecutionContext executionContext, RuntimeMetadata metadata, javax.persistence.EntityManager connection) throws TranslatorException
- Overrides:
createResultSetExecutionin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>- Throws:
TranslatorException
-
createProcedureExecution
public ProcedureExecution createProcedureExecution(Call command, ExecutionContext executionContext, RuntimeMetadata metadata, javax.persistence.EntityManager connection) throws TranslatorException
- Overrides:
createProcedureExecutionin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>- Throws:
TranslatorException
-
createUpdateExecution
public UpdateExecution createUpdateExecution(Command command, ExecutionContext executionContext, RuntimeMetadata metadata, javax.persistence.EntityManager connection) throws TranslatorException
- Overrides:
createUpdateExecutionin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>- Throws:
TranslatorException
-
createDirectExecution
public ProcedureExecution createDirectExecution(List<Argument> arguments, Command command, ExecutionContext executionContext, RuntimeMetadata metadata, javax.persistence.EntityManager connection) throws TranslatorException
- Overrides:
createDirectExecutionin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>- Throws:
TranslatorException
-
getMetadataProcessor
public MetadataProcessor<javax.persistence.EntityManager> getMetadataProcessor()
- Overrides:
getMetadataProcessorin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsSelectExpression
public boolean supportsSelectExpression()
- Overrides:
supportsSelectExpressionin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsAliasedTable
public boolean supportsAliasedTable()
- Overrides:
supportsAliasedTablein classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsInlineViews
public boolean supportsInlineViews()
- Overrides:
supportsInlineViewsin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsCompareCriteriaEquals
public boolean supportsCompareCriteriaEquals()
- Overrides:
supportsCompareCriteriaEqualsin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsCompareCriteriaOrdered
public boolean supportsCompareCriteriaOrdered()
- Overrides:
supportsCompareCriteriaOrderedin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsLikeCriteria
public boolean supportsLikeCriteria()
- Overrides:
supportsLikeCriteriain classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsInCriteria
public boolean supportsInCriteria()
- Overrides:
supportsInCriteriain classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsInCriteriaSubquery
public boolean supportsInCriteriaSubquery()
- Overrides:
supportsInCriteriaSubqueryin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsIsNullCriteria
public boolean supportsIsNullCriteria()
- Overrides:
supportsIsNullCriteriain classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsOrCriteria
public boolean supportsOrCriteria()
- Overrides:
supportsOrCriteriain classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsNotCriteria
public boolean supportsNotCriteria()
- Overrides:
supportsNotCriteriain classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsExistsCriteria
public boolean supportsExistsCriteria()
- Overrides:
supportsExistsCriteriain classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsGroupBy
public boolean supportsGroupBy()
- Overrides:
supportsGroupByin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsHaving
public boolean supportsHaving()
- Overrides:
supportsHavingin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsAggregatesSum
public boolean supportsAggregatesSum()
- Overrides:
supportsAggregatesSumin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsAggregatesAvg
public boolean supportsAggregatesAvg()
- Overrides:
supportsAggregatesAvgin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsAggregatesMin
public boolean supportsAggregatesMin()
- Overrides:
supportsAggregatesMinin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsAggregatesMax
public boolean supportsAggregatesMax()
- Overrides:
supportsAggregatesMaxin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsAggregatesCount
public boolean supportsAggregatesCount()
- Overrides:
supportsAggregatesCountin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsAggregatesCountStar
public boolean supportsAggregatesCountStar()
- Overrides:
supportsAggregatesCountStarin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsAggregatesDistinct
public boolean supportsAggregatesDistinct()
- Overrides:
supportsAggregatesDistinctin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsScalarSubqueries
public boolean supportsScalarSubqueries()
- Overrides:
supportsScalarSubqueriesin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
useAnsiJoin
public boolean useAnsiJoin()
- Overrides:
useAnsiJoinin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsDependentJoins
public boolean supportsDependentJoins()
- Overrides:
supportsDependentJoinsin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsSelfJoins
public boolean supportsSelfJoins()
- Overrides:
supportsSelfJoinsin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsRowLimit
public boolean supportsRowLimit()
- Overrides:
supportsRowLimitin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
supportsRowOffset
public boolean supportsRowOffset()
- Overrides:
supportsRowOffsetin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
getSupportedFunctions
public List<String> getSupportedFunctions()
- Overrides:
getSupportedFunctionsin classExecutionFactory<javax.persistence.EntityManagerFactory,javax.persistence.EntityManager>
-
getFunctionModifiers
public Map<String,FunctionModifier> getFunctionModifiers()
Return a map of function name to FunctionModifier.- Returns:
- Map of function name to FunctionModifier.
-
registerFunctionModifier
public void registerFunctionModifier(String name, FunctionModifier modifier)
Add theFunctionModifierto the set of known modifiers.- Parameters:
name-modifier-
-
-