Class: IbRubyProxy::Client::Ib::ContractDetails

Inherits:
Struct
  • Object
show all
Defined in:
lib/ib_ruby_proxy/client/ib/contract_details.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(contract: nil, market_name: nil, min_tick: 0, price_magnifier: 0, order_types: nil, valid_exchanges: nil, under_conid: 0, long_name: nil, contract_month: nil, industry: nil, category: nil, subcategory: nil, time_zone_id: nil, trading_hours: nil, liquid_hours: nil, ev_rule: nil, ev_multiplier: 0, md_size_multiplier: 0, sec_id_list: nil, agg_group: 0, under_symbol: nil, under_sec_type: nil, market_rule_ids: nil, real_expiration_date: nil, last_trade_time: nil, cusip: nil, ratings: nil, desc_append: nil, bond_type: nil, coupon_type: nil, callable: false, putable: false, coupon: 0, convertible: false, maturity: nil, issue_date: nil, next_option_date: nil, next_option_type: nil, next_option_partial: false, notes: nil) ⇒ ContractDetails

Returns a new instance of ContractDetails.



9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 9

def initialize(contract: nil, market_name: nil, min_tick: 0, price_magnifier: 0, order_types: nil, valid_exchanges: nil, under_conid: 0, long_name: nil, contract_month: nil, industry: nil, category: nil, subcategory: nil, time_zone_id: nil, trading_hours: nil, liquid_hours: nil, ev_rule: nil, ev_multiplier: 0, md_size_multiplier: 0, sec_id_list: nil, agg_group: 0, under_symbol: nil, under_sec_type: nil, market_rule_ids: nil, real_expiration_date: nil, last_trade_time: nil, cusip: nil, ratings: nil, desc_append: nil, bond_type: nil, coupon_type: nil, callable: false, putable: false, coupon: 0, convertible: false, maturity: nil, issue_date: nil, next_option_date: nil, next_option_type: nil, next_option_partial: false, notes: nil)
  self.contract = contract
  self.market_name = market_name
  self.min_tick = min_tick
  self.price_magnifier = price_magnifier
  self.order_types = order_types
  self.valid_exchanges = valid_exchanges
  self.under_conid = under_conid
  self.long_name = long_name
  self.contract_month = contract_month
  self.industry = industry
  self.category = category
  self.subcategory = subcategory
  self.time_zone_id = time_zone_id
  self.trading_hours = trading_hours
  self.liquid_hours = liquid_hours
  self.ev_rule = ev_rule
  self.ev_multiplier = ev_multiplier
  self.md_size_multiplier = md_size_multiplier
  self.sec_id_list = sec_id_list
  self.agg_group = agg_group
  self.under_symbol = under_symbol
  self.under_sec_type = under_sec_type
  self.market_rule_ids = market_rule_ids
  self.real_expiration_date = real_expiration_date
  self.last_trade_time = last_trade_time
  self.cusip = cusip
  self.ratings = ratings
  self.desc_append = desc_append
  self.bond_type = bond_type
  self.coupon_type = coupon_type
  self.callable = callable
  self.putable = putable
  self.coupon = coupon
  self.convertible = convertible
  self.maturity = maturity
  self.issue_date = issue_date
  self.next_option_date = next_option_date
  self.next_option_type = next_option_type
  self.next_option_partial = next_option_partial
  self.notes = notes
end

Instance Attribute Details

#agg_groupObject

Returns the value of attribute agg_group

Returns:

  • (Object)

    the current value of agg_group



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def agg_group
  @agg_group
end

#bond_typeObject

Returns the value of attribute bond_type

Returns:

  • (Object)

    the current value of bond_type



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def bond_type
  @bond_type
end

#callableObject

Returns the value of attribute callable

Returns:

  • (Object)

    the current value of callable



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def callable
  @callable
end

#categoryObject

Returns the value of attribute category

Returns:

  • (Object)

    the current value of category



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def category
  @category
end

#contractObject

Returns the value of attribute contract

Returns:

  • (Object)

    the current value of contract



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def contract
  @contract
end

#contract_monthObject

Returns the value of attribute contract_month

Returns:

  • (Object)

    the current value of contract_month



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def contract_month
  @contract_month
end

#convertibleObject

Returns the value of attribute convertible

Returns:

  • (Object)

    the current value of convertible



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def convertible
  @convertible
end

#couponObject

Returns the value of attribute coupon

Returns:

  • (Object)

    the current value of coupon



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def coupon
  @coupon
end

#coupon_typeObject

Returns the value of attribute coupon_type

Returns:

  • (Object)

    the current value of coupon_type



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def coupon_type
  @coupon_type
end

#cusipObject

Returns the value of attribute cusip

Returns:

  • (Object)

    the current value of cusip



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def cusip
  @cusip
end

#desc_appendObject

Returns the value of attribute desc_append

Returns:

  • (Object)

    the current value of desc_append



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def desc_append
  @desc_append
end

#ev_multiplierObject

Returns the value of attribute ev_multiplier

Returns:

  • (Object)

    the current value of ev_multiplier



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def ev_multiplier
  @ev_multiplier
end

#ev_ruleObject

Returns the value of attribute ev_rule

Returns:

  • (Object)

    the current value of ev_rule



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def ev_rule
  @ev_rule
end

#industryObject

Returns the value of attribute industry

Returns:

  • (Object)

    the current value of industry



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def industry
  @industry
end

#issue_dateObject

Returns the value of attribute issue_date

Returns:

  • (Object)

    the current value of issue_date



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def issue_date
  @issue_date
end

#last_trade_timeObject

Returns the value of attribute last_trade_time

Returns:

  • (Object)

    the current value of last_trade_time



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def last_trade_time
  @last_trade_time
end

#liquid_hoursObject

Returns the value of attribute liquid_hours

Returns:

  • (Object)

    the current value of liquid_hours



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def liquid_hours
  @liquid_hours
end

#long_nameObject

Returns the value of attribute long_name

Returns:

  • (Object)

    the current value of long_name



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def long_name
  @long_name
end

#market_nameObject

Returns the value of attribute market_name

Returns:

  • (Object)

    the current value of market_name



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def market_name
  @market_name
end

#market_rule_idsObject

Returns the value of attribute market_rule_ids

Returns:

  • (Object)

    the current value of market_rule_ids



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def market_rule_ids
  @market_rule_ids
end

#maturityObject

Returns the value of attribute maturity

Returns:

  • (Object)

    the current value of maturity



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def maturity
  @maturity
end

#md_size_multiplierObject

Returns the value of attribute md_size_multiplier

Returns:

  • (Object)

    the current value of md_size_multiplier



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def md_size_multiplier
  @md_size_multiplier
end

#min_tickObject

Returns the value of attribute min_tick

Returns:

  • (Object)

    the current value of min_tick



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def min_tick
  @min_tick
end

#next_option_dateObject

Returns the value of attribute next_option_date

Returns:

  • (Object)

    the current value of next_option_date



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def next_option_date
  @next_option_date
end

#next_option_partialObject

Returns the value of attribute next_option_partial

Returns:

  • (Object)

    the current value of next_option_partial



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def next_option_partial
  @next_option_partial
end

#next_option_typeObject

Returns the value of attribute next_option_type

Returns:

  • (Object)

    the current value of next_option_type



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def next_option_type
  @next_option_type
end

#notesObject

Returns the value of attribute notes

Returns:

  • (Object)

    the current value of notes



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def notes
  @notes
end

#order_typesObject

Returns the value of attribute order_types

Returns:

  • (Object)

    the current value of order_types



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def order_types
  @order_types
end

#price_magnifierObject

Returns the value of attribute price_magnifier

Returns:

  • (Object)

    the current value of price_magnifier



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def price_magnifier
  @price_magnifier
end

#putableObject

Returns the value of attribute putable

Returns:

  • (Object)

    the current value of putable



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def putable
  @putable
end

#ratingsObject

Returns the value of attribute ratings

Returns:

  • (Object)

    the current value of ratings



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def ratings
  @ratings
end

#real_expiration_dateObject

Returns the value of attribute real_expiration_date

Returns:

  • (Object)

    the current value of real_expiration_date



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def real_expiration_date
  @real_expiration_date
end

#sec_id_listObject

Returns the value of attribute sec_id_list

Returns:

  • (Object)

    the current value of sec_id_list



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def sec_id_list
  @sec_id_list
end

#subcategoryObject

Returns the value of attribute subcategory

Returns:

  • (Object)

    the current value of subcategory



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def subcategory
  @subcategory
end

#time_zone_idObject

Returns the value of attribute time_zone_id

Returns:

  • (Object)

    the current value of time_zone_id



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def time_zone_id
  @time_zone_id
end

#trading_hoursObject

Returns the value of attribute trading_hours

Returns:

  • (Object)

    the current value of trading_hours



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def trading_hours
  @trading_hours
end

#under_conidObject

Returns the value of attribute under_conid

Returns:

  • (Object)

    the current value of under_conid



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def under_conid
  @under_conid
end

#under_sec_typeObject

Returns the value of attribute under_sec_type

Returns:

  • (Object)

    the current value of under_sec_type



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def under_sec_type
  @under_sec_type
end

#under_symbolObject

Returns the value of attribute under_symbol

Returns:

  • (Object)

    the current value of under_symbol



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def under_symbol
  @under_symbol
end

#valid_exchangesObject

Returns the value of attribute valid_exchanges

Returns:

  • (Object)

    the current value of valid_exchanges



8
9
10
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 8

def valid_exchanges
  @valid_exchanges
end

Instance Method Details

#to_ibObject



52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
# File 'lib/ib_ruby_proxy/client/ib/contract_details.rb', line 52

def to_ib
  ib_object = Java::ComIbClient::ContractDetails.new
  ib_object.contract(contract).to_java
  ib_object.marketName(market_name).to_java
  ib_object.minTick(min_tick).to_java
  ib_object.priceMagnifier(price_magnifier).to_java
  ib_object.orderTypes(order_types).to_java
  ib_object.validExchanges(valid_exchanges).to_java
  ib_object.underConid(under_conid).to_java
  ib_object.longName(long_name).to_java
  ib_object.contractMonth(contract_month).to_java
  ib_object.industry(industry).to_java
  ib_object.category(category).to_java
  ib_object.subcategory(subcategory).to_java
  ib_object.timeZoneId(time_zone_id).to_java
  ib_object.tradingHours(trading_hours).to_java
  ib_object.liquidHours(liquid_hours).to_java
  ib_object.evRule(ev_rule).to_java
  ib_object.evMultiplier(ev_multiplier).to_java
  ib_object.mdSizeMultiplier(md_size_multiplier).to_java
  ib_object.secIdList(sec_id_list).to_java
  ib_object.aggGroup(agg_group).to_java
  ib_object.underSymbol(under_symbol).to_java
  ib_object.underSecType(under_sec_type).to_java
  ib_object.marketRuleIds(market_rule_ids).to_java
  ib_object.realExpirationDate(real_expiration_date).to_java
  ib_object.lastTradeTime(last_trade_time).to_java
  ib_object.cusip(cusip).to_java
  ib_object.ratings(ratings).to_java
  ib_object.descAppend(desc_append).to_java
  ib_object.bondType(bond_type).to_java
  ib_object.couponType(coupon_type).to_java
  ib_object.callable(callable).to_java
  ib_object.putable(putable).to_java
  ib_object.coupon(coupon).to_java
  ib_object.convertible(convertible).to_java
  ib_object.maturity(maturity).to_java
  ib_object.issueDate(issue_date).to_java
  ib_object.nextOptionDate(next_option_date).to_java
  ib_object.nextOptionType(next_option_type).to_java
  ib_object.nextOptionPartial(next_option_partial).to_java
  ib_object.notes(notes).to_java

  ib_object
end