Class PartitionId
java.lang.Object
com.google.cloud.spanner.connection.PartitionId
- All Implemented Interfaces:
Serializable
Contains a reference to a
BatchTransactionId and a Partition. The combination of
these two are needed to execute a partition of a partitioned query on a Connection. A
PartitionId can safely be given to a different connection and/or host to be executed
there.- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionstatic PartitionIdDeserializes a string representation of aPartitionId.static StringencodeToString(BatchTransactionId transactionId, Partition partition) booleaninthashCode()
-
Method Details
-
decodeFromString
Deserializes a string representation of aPartitionId. The string must have been created with theencodeToString(BatchTransactionId, Partition)method. -
encodeToString
- Returns:
- A string-encoded version of this
PartitionId. This encoded version can be sent to any otherConnectionto be executed there, including connections on different hosts than the current host.
-
equals
-
hashCode
public int hashCode() -
getTransactionId
-
getPartition
-