public final class TransactionSelector extends GeneratedMessageV3 implements TransactionSelectorOrBuilder
This message is used to select the transaction in which a Read or ExecuteSql call runs.
See TransactionOptions for more information about transactions.
Protobuf type google.spanner.v1.TransactionSelector
Inheritance
Object > AbstractMessageLite<MessageType,BuilderType> > AbstractMessage > GeneratedMessageV3 > TransactionSelectorImplements
TransactionSelectorOrBuilderStatic Fields
BEGIN_FIELD_NUMBER
public static final int BEGIN_FIELD_NUMBER
Field Value | |
---|---|
Type | Description |
int |
ID_FIELD_NUMBER
public static final int ID_FIELD_NUMBER
Field Value | |
---|---|
Type | Description |
int |
SINGLE_USE_FIELD_NUMBER
public static final int SINGLE_USE_FIELD_NUMBER
Field Value | |
---|---|
Type | Description |
int |
Static Methods
getDefaultInstance()
public static TransactionSelector getDefaultInstance()
Returns | |
---|---|
Type | Description |
TransactionSelector |
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Returns | |
---|---|
Type | Description |
Descriptor |
newBuilder()
public static TransactionSelector.Builder newBuilder()
Returns | |
---|---|
Type | Description |
TransactionSelector.Builder |
newBuilder(TransactionSelector prototype)
public static TransactionSelector.Builder newBuilder(TransactionSelector prototype)
Parameter | |
---|---|
Name | Description |
prototype |
TransactionSelector |
Returns | |
---|---|
Type | Description |
TransactionSelector.Builder |
parseDelimitedFrom(InputStream input)
public static TransactionSelector parseDelimitedFrom(InputStream input)
Parameter | |
---|---|
Name | Description |
input |
InputStream |
Returns | |
---|---|
Type | Description |
TransactionSelector |
Exceptions | |
---|---|
Type | Description |
IOException |
parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
public static TransactionSelector parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters | |
---|---|
Name | Description |
input |
InputStream |
extensionRegistry |
ExtensionRegistryLite |
Returns | |
---|---|
Type | Description |
TransactionSelector |
Exceptions | |
---|---|
Type | Description |
IOException |
parseFrom(byte[] data)
public static TransactionSelector parseFrom(byte[] data)
Parameter | |
---|---|
Name | Description |
data |
byte[] |
Returns | |
---|---|
Type | Description |
TransactionSelector |
Exceptions | |
---|---|
Type | Description |
InvalidProtocolBufferException |
parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
public static TransactionSelector parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters | |
---|---|
Name | Description |
data |
byte[] |
extensionRegistry |
ExtensionRegistryLite |
Returns | |
---|---|
Type | Description |
TransactionSelector |
Exceptions | |
---|---|
Type | Description |
InvalidProtocolBufferException |
parseFrom(ByteString data)
public static TransactionSelector parseFrom(ByteString data)
Parameter | |
---|---|
Name | Description |
data |
ByteString |
Returns | |
---|---|
Type | Description |
TransactionSelector |
Exceptions | |
---|---|
Type | Description |
InvalidProtocolBufferException |
parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static TransactionSelector parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters | |
---|---|
Name | Description |
data |
ByteString |
extensionRegistry |
ExtensionRegistryLite |
Returns | |
---|---|
Type | Description |
TransactionSelector |
Exceptions | |
---|---|
Type | Description |
InvalidProtocolBufferException |
parseFrom(CodedInputStream input)
public static TransactionSelector parseFrom(CodedInputStream input)
Parameter | |
---|---|
Name | Description |
input |
CodedInputStream |
Returns | |
---|---|
Type | Description |
TransactionSelector |
Exceptions | |
---|---|
Type | Description |
IOException |
parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public static TransactionSelector parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters | |
---|---|
Name | Description |
input |
CodedInputStream |
extensionRegistry |
ExtensionRegistryLite |
Returns | |
---|---|
Type | Description |
TransactionSelector |
Exceptions | |
---|---|
Type | Description |
IOException |
parseFrom(InputStream input)
public static TransactionSelector parseFrom(InputStream input)
Parameter | |
---|---|
Name | Description |
input |
InputStream |
Returns | |
---|---|
Type | Description |
TransactionSelector |
Exceptions | |
---|---|
Type | Description |
IOException |
parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
public static TransactionSelector parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters | |
---|---|
Name | Description |
input |
InputStream |
extensionRegistry |
ExtensionRegistryLite |
Returns | |
---|---|
Type | Description |
TransactionSelector |
Exceptions | |
---|---|
Type | Description |
IOException |
parseFrom(ByteBuffer data)
public static TransactionSelector parseFrom(ByteBuffer data)
Parameter | |
---|---|
Name | Description |
data |
ByteBuffer |
Returns | |
---|---|
Type | Description |
TransactionSelector |
Exceptions | |
---|---|
Type | Description |
InvalidProtocolBufferException |
parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
public static TransactionSelector parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters | |
---|---|
Name | Description |
data |
ByteBuffer |
extensionRegistry |
ExtensionRegistryLite |
Returns | |
---|---|
Type | Description |
TransactionSelector |
Exceptions | |
---|---|
Type | Description |
InvalidProtocolBufferException |
parser()
public static Parser<TransactionSelector> parser()
Returns | |
---|---|
Type | Description |
Parser<TransactionSelector> |
Methods
equals(Object obj)
public boolean equals(Object obj)
Parameter | |
---|---|
Name | Description |
obj |
Object |
Returns | |
---|---|
Type | Description |
boolean |
getBegin()
public TransactionOptions getBegin()
Begin a new transaction and execute this read or SQL query in it. The transaction ID of the new transaction is returned in ResultSetMetadata.transaction, which is a Transaction.
.google.spanner.v1.TransactionOptions begin = 3;
Returns | |
---|---|
Type | Description |
TransactionOptions |
The begin. |
getBeginOrBuilder()
public TransactionOptionsOrBuilder getBeginOrBuilder()
Begin a new transaction and execute this read or SQL query in it. The transaction ID of the new transaction is returned in ResultSetMetadata.transaction, which is a Transaction.
.google.spanner.v1.TransactionOptions begin = 3;
Returns | |
---|---|
Type | Description |
TransactionOptionsOrBuilder |
getDefaultInstanceForType()
public TransactionSelector getDefaultInstanceForType()
Returns | |
---|---|
Type | Description |
TransactionSelector |
getId()
public ByteString getId()
Execute the read or SQL query in a previously-started transaction.
bytes id = 2;
Returns | |
---|---|
Type | Description |
ByteString |
The id. |
getParserForType()
public Parser<TransactionSelector> getParserForType()
Returns | |
---|---|
Type | Description |
Parser<TransactionSelector> |
getSelectorCase()
public TransactionSelector.SelectorCase getSelectorCase()
Returns | |
---|---|
Type | Description |
TransactionSelector.SelectorCase |
getSerializedSize()
public int getSerializedSize()
Returns | |
---|---|
Type | Description |
int |
getSingleUse()
public TransactionOptions getSingleUse()
Execute the read or SQL query in a temporary transaction. This is the most efficient way to execute a transaction that consists of a single SQL query.
.google.spanner.v1.TransactionOptions single_use = 1;
Returns | |
---|---|
Type | Description |
TransactionOptions |
The singleUse. |
getSingleUseOrBuilder()
public TransactionOptionsOrBuilder getSingleUseOrBuilder()
Execute the read or SQL query in a temporary transaction. This is the most efficient way to execute a transaction that consists of a single SQL query.
.google.spanner.v1.TransactionOptions single_use = 1;
Returns | |
---|---|
Type | Description |
TransactionOptionsOrBuilder |
hasBegin()
public boolean hasBegin()
Begin a new transaction and execute this read or SQL query in it. The transaction ID of the new transaction is returned in ResultSetMetadata.transaction, which is a Transaction.
.google.spanner.v1.TransactionOptions begin = 3;
Returns | |
---|---|
Type | Description |
boolean |
Whether the begin field is set. |
hasId()
public boolean hasId()
Execute the read or SQL query in a previously-started transaction.
bytes id = 2;
Returns | |
---|---|
Type | Description |
boolean |
Whether the id field is set. |
hasSingleUse()
public boolean hasSingleUse()
Execute the read or SQL query in a temporary transaction. This is the most efficient way to execute a transaction that consists of a single SQL query.
.google.spanner.v1.TransactionOptions single_use = 1;
Returns | |
---|---|
Type | Description |
boolean |
Whether the singleUse field is set. |
hashCode()
public int hashCode()
Returns | |
---|---|
Type | Description |
int |
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns | |
---|---|
Type | Description |
FieldAccessorTable |
isInitialized()
public final boolean isInitialized()
Returns | |
---|---|
Type | Description |
boolean |
newBuilderForType()
public TransactionSelector.Builder newBuilderForType()
Returns | |
---|---|
Type | Description |
TransactionSelector.Builder |
newBuilderForType(GeneratedMessageV3.BuilderParent parent)
protected TransactionSelector.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter | |
---|---|
Name | Description |
parent |
BuilderParent |
Returns | |
---|---|
Type | Description |
TransactionSelector.Builder |
newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter | |
---|---|
Name | Description |
unused |
UnusedPrivateParameter |
Returns | |
---|---|
Type | Description |
Object |
toBuilder()
public TransactionSelector.Builder toBuilder()
Returns | |
---|---|
Type | Description |
TransactionSelector.Builder |
writeTo(CodedOutputStream output)
public void writeTo(CodedOutputStream output)
Parameter | |
---|---|
Name | Description |
output |
CodedOutputStream |
Exceptions | |
---|---|
Type | Description |
IOException |