Exception: Tarantool::StatusCode

Inherits:
TarantoolError show all
Defined in:
lib/tarantool/exceptions.rb

Direct Known Subclasses

BadReturnCode, TryAgain

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(code, msg) ⇒ StatusCode

Returns a new instance of StatusCode.



13
14
15
16
# File 'lib/tarantool/exceptions.rb', line 13

def initialize(code, msg)
  super(msg)
  @code = code
end

Instance Attribute Details

#codeObject (readonly)

Returns the value of attribute code.



12
13
14
# File 'lib/tarantool/exceptions.rb', line 12

def code
  @code
end

Instance Method Details

#to_sObject



17
18
19
# File 'lib/tarantool/exceptions.rb', line 17

def to_s
  "#{super} [#{code}]"
end