Class: Tradier::Account
Instance Attribute Summary collapse
-
#account_number ⇒ Object
readonly
Returns the value of attribute account_number.
-
#type ⇒ Object
readonly
Returns the value of attribute type.
Instance Method Summary collapse
- #cash? ⇒ Boolean
- #gainloss ⇒ Object
- #history ⇒ Object
- #margin? ⇒ Boolean
- #orders ⇒ Object
- #positions ⇒ Object
Methods inherited from Base
#[], #attr_equal, attr_reader, #attrs, #attrs_equal, from_response, #initialize, #update
Constructor Details
This class inherits a constructor from Tradier::Base
Instance Attribute Details
#account_number ⇒ Object (readonly)
Returns the value of attribute account_number.
5 6 7 |
# File 'lib/tradier/account.rb', line 5 def account_number @account_number end |
#type ⇒ Object (readonly)
Returns the value of attribute type.
5 6 7 |
# File 'lib/tradier/account.rb', line 5 def type @type end |
Instance Method Details
#cash? ⇒ Boolean
11 12 13 |
# File 'lib/tradier/account.rb', line 11 def cash? type.downcase == 'cash' end |
#gainloss ⇒ Object
23 24 |
# File 'lib/tradier/account.rb', line 23 def gainloss end |
#history ⇒ Object
26 27 |
# File 'lib/tradier/account.rb', line 26 def history end |
#margin? ⇒ Boolean
7 8 9 |
# File 'lib/tradier/account.rb', line 7 def margin? type.downcase == 'margin' end |