Class IntermediatePreparedStatement (0.25.0)

public class IntermediatePreparedStatement extends IntermediateStatement

Intermediate representation for prepared statements (i.e.: statements before they become portals)

Inheritance

java.lang.Object > IntermediateStatement > IntermediatePreparedStatement

Constructors

IntermediatePreparedStatement(ConnectionHandler connectionHandler, OptionsMetadata options, String name, int[] givenParameterDataTypes, AbstractStatementParser.ParsedStatement parsedStatement, Statement originalStatement)

public IntermediatePreparedStatement(ConnectionHandler connectionHandler, OptionsMetadata options, String name, int[] givenParameterDataTypes, AbstractStatementParser.ParsedStatement parsedStatement, Statement originalStatement)
Parameters
NameDescription
connectionHandlerConnectionHandler
optionsOptionsMetadata
nameString
givenParameterDataTypesint[]
parsedStatementParsedStatement
originalStatementcom.google.cloud.spanner.Statement

Fields

givenParameterDataTypes

protected final int[] givenParameterDataTypes
Field Value
TypeDescription
int[]

statement

protected Statement statement
Field Value
TypeDescription
com.google.cloud.spanner.Statement

Methods

autoDescribeParameters(byte[][] parameterValues, BackendConnection backendConnection)

public void autoDescribeParameters(byte[][] parameterValues, BackendConnection backendConnection)

Describe the parameters of this statement.

Parameters
NameDescription
parameterValuesbyte[][]
backendConnectionBackendConnection

createPortal(String name, byte[][] parameters, List<Short> parameterFormatCodes, List<Short> resultFormatCodes)

public IntermediatePortalStatement createPortal(String name, byte[][] parameters, List<Short> parameterFormatCodes, List<Short> resultFormatCodes)

Creates a portal from this statement.

Parameters
NameDescription
nameString
parametersbyte[][]
parameterFormatCodesList<Short>

A list of the format of each parameter.

resultFormatCodesList<Short>

A list of the desired format of each result.

Returns
TypeDescription
IntermediatePortalStatement

An Intermediate Portal Statement (or rather a bound version of this statement)

describe()

public DescribeResult describe()

Moreso meant for inherited classes, allows one to call describe on a statement. Since raw statements cannot be described, throw an error.

Returns
TypeDescription
DescribeResult
Overrides

describeAsync(BackendConnection backendConnection)

public Future<StatementResult> describeAsync(BackendConnection backendConnection)
Parameter
NameDescription
backendConnectionBackendConnection
Returns
TypeDescription
Future<StatementResult>
Overrides

getGivenParameterDataTypes()

public int[] getGivenParameterDataTypes()
Returns
TypeDescription
int[]