public class BindValueInfo
extends java.lang.Object
Modifier and Type | Method and Description |
---|---|
static BindValueInfo |
getBindValueInfo()
Factory method for getting a BindValueInfo instance
|
oracle.pgql.lang.ir.QueryExpression.ExpressionType |
getBindVarType(oracle.pgql.lang.ir.QueryExpression.BindVariable bv)
Returns the value type for this bind variable determined from the set method previously used for this bind variable's parameter index.
|
static java.lang.String |
getBvEncoding(oracle.pgql.lang.ir.QueryExpression.BindVariable bv)
Generates a string encoding of a bind variable for easy replacement in the generated SQL.
|
java.util.List<java.lang.Object> |
getSqlBvList(int idx)
Returns the SQL bind value list for this processed query
|
java.lang.String |
processBindVariables(java.lang.String pgqlToSqlString, int bvListIdx)
Returns a new String that is the result of replacing all encoded bind variables in pgqlToSqlString with "?".
|
void |
setBoolean(int parameterIndex, boolean x)
Sets the designated parameter to the given Java boolean value.
|
void |
setDouble(int parameterIndex, double x)
Sets the designated parameter to the given Java double value.
|
void |
setFloat(int parameterIndex, float x)
Sets the designated parameter to the given Java float value.
|
void |
setInt(int parameterIndex, int x)
Sets the designated parameter to the given Java int value.
|
void |
setLong(int parameterIndex, long x)
Sets the designated parameter to the given Java long value.
|
void |
setString(int parameterIndex, java.lang.String x)
Sets the designated parameter to the given Java String value.
|
void |
setTimestamp(int parameterIndex, java.sql.Timestamp x)
Sets the designated parameter to the given Java Timestamp value.
|
public static BindValueInfo getBindValueInfo()
public oracle.pgql.lang.ir.QueryExpression.ExpressionType getBindVarType(oracle.pgql.lang.ir.QueryExpression.BindVariable bv) throws PgqlToSqlException
bv
- the bind variable to return the type forPgqlToSqlException
public static java.lang.String getBvEncoding(oracle.pgql.lang.ir.QueryExpression.BindVariable bv)
bv
- the BindVariable instance to encodepublic java.util.List<java.lang.Object> getSqlBvList(int idx)
idx
- the index of the SQL bind value listpublic java.lang.String processBindVariables(java.lang.String pgqlToSqlString, int bvListIdx)
pgqlToSqlString
- a SQL string that contains encoded bind variablesbvListIdx
- index of list/mapping where bind value info should be storedpublic void setBoolean(int parameterIndex, boolean x)
parameterIndex
- the first parameter is 1, the second is 2, ...x
- the parameter valuepublic void setDouble(int parameterIndex, double x)
parameterIndex
- the first parameter is 1, the second is 2, ...x
- the parameter valuepublic void setFloat(int parameterIndex, float x)
parameterIndex
- the first parameter is 1, the second is 2, ...x
- the parameter valuepublic void setInt(int parameterIndex, int x)
parameterIndex
- the first parameter is 1, the second is 2, ...x
- the parameter valuepublic void setLong(int parameterIndex, long x)
parameterIndex
- the first parameter is 1, the second is 2, ...x
- the parameter valuepublic void setString(int parameterIndex, java.lang.String x)
parameterIndex
- the first parameter is 1, the second is 2, ...x
- the parameter valuepublic void setTimestamp(int parameterIndex, java.sql.Timestamp x)
parameterIndex
- the first parameter is 1, the second is 2, ...x
- the parameter value