Class: WalletException

Inherits:
Thrift::Exception
  • Object
show all
Includes:
Thrift::Struct, Thrift::Struct_Union
Defined in:
lib/linerb/gen-rb/takagi_chan_types.rb,
lib/linerb/gen-rb/takagi_chan_types.rb

Constant Summary collapse

CODE =
1
REASON =
2
ATTRIBUTES =
3
FIELDS =
{
  CODE => {:type => ::Thrift::Types::I32, :name => 'code', :enum_class => ::G_a_m_a0_k0},
  REASON => {:type => ::Thrift::Types::STRING, :name => 'reason'},
  ATTRIBUTES => {:type => ::Thrift::Types::MAP, :name => 'attributes', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::STRING}}
}

Instance Method Summary collapse

Instance Method Details

#struct_fieldsObject



12362
# File 'lib/linerb/gen-rb/takagi_chan_types.rb', line 12362

def struct_fields; FIELDS; end

#validateObject



12364
12365
12366
12367
12368
# File 'lib/linerb/gen-rb/takagi_chan_types.rb', line 12364

def validate
  unless @code.nil? || ::G_a_m_a0_k0::VALID_VALUES.include?(@code)
    raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field code!')
  end
end