Class: Tarantool::Model::StaleObjectError
- Defined in:
- tarantool-model/lib/tarantool/model/errors.rb
Overview
The row's locking column changed since the record was loaded.
Instance Attribute Summary collapse
-
#attempted_action ⇒ Object
readonly
Returns the value of attribute attempted_action.
-
#record ⇒ Object
readonly
Returns the value of attribute record.
Instance Method Summary collapse
-
#initialize(record, attempted_action) ⇒ StaleObjectError
constructor
A new instance of StaleObjectError.
Constructor Details
#initialize(record, attempted_action) ⇒ StaleObjectError
Returns a new instance of StaleObjectError.
42 43 44 45 46 |
# File 'tarantool-model/lib/tarantool/model/errors.rb', line 42 def initialize(record, attempted_action) @record = record @attempted_action = attempted_action super("Attempted to #{attempted_action} a stale #{record.class.name} with key #{record.to_key.inspect}") end |
Instance Attribute Details
#attempted_action ⇒ Object (readonly)
Returns the value of attribute attempted_action.
40 41 42 |
# File 'tarantool-model/lib/tarantool/model/errors.rb', line 40 def attempted_action @attempted_action end |
#record ⇒ Object (readonly)
Returns the value of attribute record.
40 41 42 |
# File 'tarantool-model/lib/tarantool/model/errors.rb', line 40 def record @record end |