Class CopyToStatement (0.24.0)

public class CopyToStatement extends IntermediatePortalStatement

CopyStatement models a COPY table TO STDOUT statement. The same class is used both as an IntermediatePreparedStatement and IntermediatePortalStatement, as COPY does not support any statement parameters, which means that there is no difference between the two.

Static Fields

COPY_BINARY_HEADER

public static final byte[] COPY_BINARY_HEADER
Field Value
Type Description
byte[]

Constructors

CopyToStatement(ConnectionHandler connectionHandler, OptionsMetadata options, String name, CopyStatement.ParsedCopyStatement parsedCopyStatement)

public CopyToStatement(ConnectionHandler connectionHandler, OptionsMetadata options, String name, CopyStatement.ParsedCopyStatement parsedCopyStatement)
Parameters
Name Description
connectionHandler ConnectionHandler
options OptionsMetadata
name String
parsedCopyStatement com.google.cloud.spanner.pgadapter.statements.CopyStatement.ParsedCopyStatement

Methods

containsResultSet()

public boolean containsResultSet()
Returns
Type Description
boolean
Overrides

createDataRowResponse(Converter converter)

public CopyDataResponse createDataRowResponse(Converter converter)
Parameter
Name Description
converter Converter
Returns
Type Description
CopyDataResponse
Overrides

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
Name Description
name String
parameters byte[][]
parameterFormatCodes List<Short>
resultFormatCodes List<Short>
Returns
Type Description
IntermediatePortalStatement
Overrides

createResultPrefix(ResultSet resultSet)

public WireOutput[] createResultPrefix(ResultSet resultSet)
Parameter
Name Description
resultSet com.google.cloud.spanner.ResultSet
Returns
Type Description
WireOutput[]
Overrides

createResultSuffix()

public WireOutput[] createResultSuffix()
Returns
Type Description
WireOutput[]
Overrides

describeAsync(BackendConnection backendConnection)

public Future<StatementResult> describeAsync(BackendConnection backendConnection)
Parameter
Name Description
backendConnection BackendConnection
Returns
Type Description
Future<StatementResult>
Overrides

executeAsync(BackendConnection backendConnection)

public void executeAsync(BackendConnection backendConnection)
Parameter
Name Description
backendConnection BackendConnection
Overrides

getCommandTag()

public String getCommandTag()
Returns
Type Description
String
Overrides

getStatementType()

public AbstractStatementParser.StatementType getStatementType()
Returns
Type Description
StatementType
Overrides

isBinary()

public boolean isBinary()
Returns
Type Description
boolean