Class: IB::Messages::Incoming::PortfolioValue
- Defined in:
- lib/ib/messages/incoming/portfolio_value.rb
Instance Method Summary collapse
Instance Method Details
#account_name ⇒ Object
39 40 41 |
# File 'lib/ib/messages/incoming/portfolio_value.rb', line 39 def account_name @account_name = @data[:account] end |
#portfolio_value ⇒ Object
30 31 32 33 34 35 36 37 |
# File 'lib/ib/messages/incoming/portfolio_value.rb', line 30 def portfolio_value unless @portfolio_value.present? @portfolio_value = IB::PortfolioValue.new @data[:portfolio_value] @portfolio_value.contract = contract @portfolio_value.account = account end @portfolio_value # return_value end |
#to_human ⇒ Object
25 26 27 28 |
# File 'lib/ib/messages/incoming/portfolio_value.rb', line 25 def to_human # "<PortfolioValue: #{contract.to_human} #{portfolio_value}>" portfolio_value.to_human end |