Class: RuBittrex::Account

Inherits:
Object
  • Object
show all
Extended by:
ClientHelper
Includes:
Helpers
Defined in:
lib/ru_bittrex/account.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Methods included from Helpers

#extract_timestamp

Constructor Details

#initialize(attrs = {}) ⇒ Account

Returns a new instance of Account.



9
10
11
12
13
14
# File 'lib/ru_bittrex/account.rb', line 9

def initialize(attrs = {})
  @id             = attrs["accountId"]
  @updated_at     = extract_timestamp(attrs["updated"])
  @volume_30_days = attrs["volume30days"]
  @raw            = attrs
end

Instance Attribute Details

#idObject (readonly)

Returns the value of attribute id.



6
7
8
# File 'lib/ru_bittrex/account.rb', line 6

def id
  @id
end

#rawObject (readonly)

Returns the value of attribute raw.



6
7
8
# File 'lib/ru_bittrex/account.rb', line 6

def raw
  @raw
end

#updated_atObject (readonly)

Returns the value of attribute updated_at.



6
7
8
# File 'lib/ru_bittrex/account.rb', line 6

def updated_at
  @updated_at
end

#volume_30_daysObject (readonly) Also known as: volume

Returns the value of attribute volume_30_days.



6
7
8
# File 'lib/ru_bittrex/account.rb', line 6

def volume_30_days
  @volume_30_days
end

Class Method Details

.get(params = {}) ⇒ Object



16
17
18
# File 'lib/ru_bittrex/account.rb', line 16

def self.get(params = {})
  new _get('account', params)
end

.volume(params = {}) ⇒ Object



20
21
22
# File 'lib/ru_bittrex/account.rb', line 20

def self.volume(params = {})
  new _get('account/volume', params)
end