public class JdbcDefaultType extends SqlMetaType
| Modifier and Type | Field and Description |
|---|---|
(package private) static Map<Class<?>,Object> |
jdbcTypes
The map between the Java types and the META types.
|
logger| Constructor and Description |
|---|
JdbcDefaultType() |
| Modifier and Type | Method and Description |
|---|---|
void |
addScalar(SqlQuery query,
String dbName,
Class<?> attributeType)
Declares a scalar query result, which is an SQL query execution output value.
|
void |
setParameter(SqlRuntimeContext runtimeCtx,
SqlQuery query,
String paramName,
Object inputValue,
Class<?> inputType,
boolean ingoreError)
Binds an input value to a named query parameter.
|
void |
setResult(SqlRuntimeContext runtimeCtx,
Object resultInstance,
String attributeName,
Object resultValue,
boolean ingoreError)
Initializes the attribute of the result class with output value from the SQL query execution.
|
public void addScalar(SqlQuery query, String dbName, Class<?> attributeType)
addScalar in class SqlMetaTypequery - the SQL Engine query, an adapter or proxy to the internal JDBC or ORM staffdbName - the name of a database query output, it can be the column name or the alias nameattributeType - the Java type of of the attribute in the result classpublic void setResult(SqlRuntimeContext runtimeCtx, Object resultInstance, String attributeName, Object resultValue, boolean ingoreError) throws SqlRuntimeException
setResult in class SqlMetaTyperuntimeCtx - the public runtimeCtx contextresultInstance - the instance of the result classattributeName - the name of the attribute in the result classresultValue - the query execution output valueingoreError - ignore improper output value handlingSqlRuntimeException - in the case of any problem with the output values handlingpublic void setParameter(SqlRuntimeContext runtimeCtx, SqlQuery query, String paramName, Object inputValue, Class<?> inputType, boolean ingoreError) throws SqlRuntimeException
setParameter in class SqlMetaTyperuntimeCtx - the public runtimeCtx contextquery - the SQL Engine query, an adapter or proxy to the internal JDBC or ORM staffparamName - the name of the parameterinputValue - the possibly-null parameter value, a dynamic input valueingoreError - ignore improper input value handlingSqlRuntimeException - in the case of any problem with the input values handlingCopyright © 2016. All rights reserved.