Class: Bakong::OpenApi::Resources::Base

Inherits:
Object
  • Object
show all
Defined in:
lib/bakong/open_api/resources/base.rb

Overview

Shared behavior for resource modules. Each resource gets a ‘client` accessor (so `connection` and `config` are reachable) and helpers for turning a Bakong envelope `errorCode, responseMessage, data` into either snake_cased data or a raised domain-specific Error.

Direct Known Subclasses

Accounts, Deeplinks, Tokens, Transactions

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(client) ⇒ Base

Returns a new instance of Base.



14
15
16
# File 'lib/bakong/open_api/resources/base.rb', line 14

def initialize(client)
  @client = client
end

Instance Attribute Details

#clientObject (readonly)

Returns the value of attribute client.



18
19
20
# File 'lib/bakong/open_api/resources/base.rb', line 18

def client
  @client
end