Class: IB::Models::Execution

Inherits:
Model
  • Object
show all
Defined in:
lib/ib-ruby/models/execution.rb

Overview

This is IB Order execution report. Instantiate with a Hash of attributes, to be auto-set via initialize in Model.

Constant Summary collapse

DEFAULT_PROPS =
{:order_id => 0,
:client_id => 0,
:shares => 0,
:price => 0,
:perm_id => 0,
:liquidation => 0, }

Instance Attribute Summary

Attributes inherited from Model

#created_at

Instance Method Summary collapse

Methods inherited from Model

#[], #[]=, #initialize

Methods included from ModelProperties

#define_property, #define_property_methods, #prop

Constructor Details

This class inherits a constructor from IB::Models::Model

Instance Method Details

#to_sObject



35
36
37
38
39
# File 'lib/ib-ruby/models/execution.rb', line 35

def to_s
  "<Execution #{time}: #{side} #{shares} @ #{price} on #{exchange}, " +
      "cumulative: #{cumulative_quantity} @ #{average_price}, " +
      "ids: #{exec_id} exec #{perm_id} perm #{order_id} order #{order_ref} ref>"
end