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.
Inheritance
java.lang.Object > IntermediateStatement > IntermediatePreparedStatement > IntermediatePortalStatement > CopyToStatementStatic Fields
COPY_BINARY_HEADER
public static final byte[] COPY_BINARY_HEADER
Type | Description |
byte[] |
Constructors
CopyToStatement(ConnectionHandler connectionHandler, OptionsMetadata options, String name, CopyTreeParser.CopyOptions copyOptions)
public CopyToStatement(ConnectionHandler connectionHandler, OptionsMetadata options, String name, CopyTreeParser.CopyOptions copyOptions)
Name | Description |
connectionHandler | ConnectionHandler |
options | OptionsMetadata |
name | String |
copyOptions | CopyTreeParser.CopyOptions |
Methods
bind(String name, byte[][] parameters, List<Short> parameterFormatCodes, List<Short> resultFormatCodes)
public IntermediatePortalStatement bind(String name, byte[][] parameters, List<Short> parameterFormatCodes, List<Short> resultFormatCodes)
Bind this statement (that is to say, transform it into a portal by giving it the data items to complete the statement.
Name | Description |
name | String |
parameters | byte[][] |
parameterFormatCodes | List<Short> |
resultFormatCodes | List<Short> |
Type | Description |
IntermediatePortalStatement |
containsResultSet()
public boolean containsResultSet()
Type | Description |
boolean |
createDataRowResponse(ResultSet resultSet, ConnectionHandler.QueryMode mode)
public CopyDataResponse createDataRowResponse(ResultSet resultSet, ConnectionHandler.QueryMode mode)
Name | Description |
resultSet | com.google.cloud.spanner.ResultSet |
mode | ConnectionHandler.QueryMode |
Type | Description |
CopyDataResponse |
createResultPrefix(ResultSet resultSet)
public WireOutput[] createResultPrefix(ResultSet resultSet)
Name | Description |
resultSet | com.google.cloud.spanner.ResultSet |
Type | Description |
WireOutput[] |
createResultSuffix()
public WireOutput[] createResultSuffix()
Type | Description |
WireOutput[] |
describeAsync(BackendConnection backendConnection)
public Future<DescribePortalMetadata> describeAsync(BackendConnection backendConnection)
Name | Description |
backendConnection | BackendConnection |
Type | Description |
Future<DescribePortalMetadata> |
executeAsync(BackendConnection backendConnection)
public void executeAsync(BackendConnection backendConnection)
Name | Description |
backendConnection | BackendConnection |
getCommandTag()
public String getCommandTag()
Type | Description |
String |
getStatementType()
public AbstractStatementParser.StatementType getStatementType()
Type | Description |
StatementType |