Class: Google::Apis::SpannerV1::TransactionSelector

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/spanner_v1/classes.rb,
lib/google/apis/spanner_v1/representations.rb,
lib/google/apis/spanner_v1/representations.rb

Overview

This message is used to select the transaction in which a Read or ExecuteSql call runs. See TransactionOptions for more information about transactions.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ TransactionSelector

Returns a new instance of TransactionSelector.



7080
7081
7082
# File 'lib/google/apis/spanner_v1/classes.rb', line 7080

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#beginGoogle::Apis::SpannerV1::TransactionOptions

Options to use for transactions. Corresponds to the JSON property begin



7067
7068
7069
# File 'lib/google/apis/spanner_v1/classes.rb', line 7067

def begin
  @begin
end

#idString

Execute the read or SQL query in a previously-started transaction. Corresponds to the JSON property id NOTE: Values are automatically base64 encoded/decoded in the client library.

Returns:

  • (String)


7073
7074
7075
# File 'lib/google/apis/spanner_v1/classes.rb', line 7073

def id
  @id
end

#single_useGoogle::Apis::SpannerV1::TransactionOptions

Options to use for transactions. Corresponds to the JSON property singleUse



7078
7079
7080
# File 'lib/google/apis/spanner_v1/classes.rb', line 7078

def single_use
  @single_use
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



7085
7086
7087
7088
7089
# File 'lib/google/apis/spanner_v1/classes.rb', line 7085

def update!(**args)
  @begin = args[:begin] if args.key?(:begin)
  @id = args[:id] if args.key?(:id)
  @single_use = args[:single_use] if args.key?(:single_use)
end