Class: Banker::Account

Inherits:
Base
  • Object
show all
Defined in:
lib/banker/account.rb

Instance Attribute Summary collapse

Attributes inherited from Base

#agent, #keys

Instance Method Summary collapse

Methods inherited from Base

#class_name, #cleaner, #get, #get_letter, #memorable_required, #params, #parse_ofx

Constructor Details

#initialize(args = {}) ⇒ Account

Returns a new instance of Account.



4
5
6
7
8
9
10
11
12
# File 'lib/banker/account.rb', line 4

def initialize(args = {})
  @keys = %w(name uid amount)
  params(args)
  @transactions = []

  args.each do |attribute, value|
    send(:"#{attribute}=", value)
  end
end

Instance Attribute Details

#amountObject

Returns the value of attribute amount.



3
4
5
# File 'lib/banker/account.rb', line 3

def amount
  @amount
end

#currencyObject

Returns the value of attribute currency.



3
4
5
# File 'lib/banker/account.rb', line 3

def currency
  @currency
end

#limitObject

Returns the value of attribute limit.



3
4
5
# File 'lib/banker/account.rb', line 3

def limit
  @limit
end

#nameObject

Returns the value of attribute name.



3
4
5
# File 'lib/banker/account.rb', line 3

def name
  @name
end

#transactionsObject

Returns the value of attribute transactions.



3
4
5
# File 'lib/banker/account.rb', line 3

def transactions
  @transactions
end

#uidObject

Returns the value of attribute uid.



3
4
5
# File 'lib/banker/account.rb', line 3

def uid
  @uid
end