Google.Cloud.Spanner.Data - Class TransactionId (5.0.0-beta02)

public sealed class TransactionId : IEquatable<TransactionId>

Reference documentation and code samples for the Google.Cloud.Spanner.Data class TransactionId.

A TransactionId holds identifying information about an active transaction in Cloud Spanner. Since it is serializable, it enables you to send this information to another process or machine so it may connect to the same transaction.

Inheritance

object > TransactionId

Namespace

Google.Cloud.Spanner.Data

Assembly

Google.Cloud.Spanner.Data.dll

Properties

ConnectionString

public string ConnectionString { get; }

The connection string this transaction was created in.

Property Value
TypeDescription
string

Methods

FromBase64String(string)

public static TransactionId FromBase64String(string base64String)

Creates an instance of TransactionId given its Base64 encoded string.

Parameter
NameDescription
base64Stringstring

The string provided by ToBase64String().

Returns
TypeDescription
TransactionId

A new instance of TransactionId.

GetHashCode()

public override int GetHashCode()

Serves as the default hash function.

Returns
TypeDescription
int

A hash code for the current object.

Overrides

ToBase64String()

public string ToBase64String()

Returns a Base64 encoded string that can later be serialized back into a TransactionId using FromBase64String(string)

Returns
TypeDescription
string

The base64 encoded string.