public class DefaultSQLStatementCompositionContext extends DefaultSQLCompositionContext implements SQLStatementCompositionContext
SQLStatementCompositionContext implementation.SQLStatementCompositionContext.AliasModeSQLCompositionContext.SQLStatementPreparationException| Constructor and Description |
|---|
DefaultSQLStatementCompositionContext(SQLCompositionContext parent,
com.holonplatform.core.datastore.relational.RelationalTarget<?> rootTarget,
SQLStatementCompositionContext.AliasMode aliasMode)
Constructor with parent composition context.
|
DefaultSQLStatementCompositionContext(SQLContext context,
com.holonplatform.core.datastore.relational.RelationalTarget<?> rootTarget,
SQLStatementCompositionContext.AliasMode aliasMode)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
Optional<String> |
getAlias(com.holonplatform.core.Path<?> path,
boolean useParentContext)
Get the given
path alias, if available and alias mode is not SQLStatementCompositionContext.AliasMode.UNSUPPORTED. |
Optional<String> |
getRootAlias()
Get the query root path (target) alias, if available and alias mode is not
SQLStatementCompositionContext.AliasMode.UNSUPPORTED. |
addExpressionResolver, childContext, getDialect, getExpressionResolvers, getNamedParametersHandler, getParent, getValueDeserializer, getValueSerializer, prepareStatement, removeExpressionResolver, resolve, traceequals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitasChild, create, getAliasOrRootaddNamedParameter, childContext, create, getContextSequence, getNamedParametersHandler, getParent, isSQLCompositionContext, isStatementCompositionContext, prepareStatement, resolve, resolveOrFailgetDialect, getTypeConverter, getValueDeserializer, getValueSerializer, traceresolvepublic DefaultSQLStatementCompositionContext(SQLContext context, com.holonplatform.core.datastore.relational.RelationalTarget<?> rootTarget, SQLStatementCompositionContext.AliasMode aliasMode)
context - SQL context (not null)rootTarget - Root query target (not null)aliasMode - Alias handling mode (not null)public DefaultSQLStatementCompositionContext(SQLCompositionContext parent, com.holonplatform.core.datastore.relational.RelationalTarget<?> rootTarget, SQLStatementCompositionContext.AliasMode aliasMode)
parent - Parent composition context (not null)rootTarget - Root query target (not null)aliasMode - Alias handling mode (not null)public Optional<String> getRootAlias()
SQLStatementCompositionContextSQLStatementCompositionContext.AliasMode.UNSUPPORTED.
The alias will be the explicit alias name if the root path is Aliasable, or an auto generated name if
alias mode is SQLStatementCompositionContext.AliasMode.AUTO.
getRootAlias in interface SQLStatementCompositionContextpublic Optional<String> getAlias(com.holonplatform.core.Path<?> path, boolean useParentContext)
SQLStatementCompositionContextpath alias, if available and alias mode is not SQLStatementCompositionContext.AliasMode.UNSUPPORTED.
The alias will be the explicit alias name if the path is Aliasable, or an auto generated name if alias
mode is SQLStatementCompositionContext.AliasMode.AUTO.
getAlias in interface SQLStatementCompositionContextpath - Path for which to get the alias (not null)useParentContext - Whether to check in parent contexts if an alias is available when not available is
current contextCopyright © 2019 The Holon Platform. All rights reserved.