OnixS ICE iMpact Multicast Price Feed Handler C++ library  8.11.0
API documentation
FuturesProductDefinition.h
Go to the documentation of this file.
1 /**
2  * \file
3  * \brief Declare `OnixS::ICE::iMpact::MarketData::FuturesProductDefinition` message structure
4  */
5 /*
6  * Copyright (c) Onix Solutions Limited. All rights reserved.
7  *
8  * This software owned by Onix Solutions Limited and is protected by copyright law
9  * and international copyright treaties.
10  *
11  * Access to and use of the software is governed by the terms of the applicable ONIXS Software
12  * Services Agreement (the Agreement) and Customer end user license agreements granting
13  * a non-assignable, non-transferable and non-exclusive license to use the software
14  * for it's own data processing purposes under the terms defined in the Agreement.
15  *
16  * Except as otherwise granted within the terms of the Agreement, copying or reproduction of any part
17  * of this source code or associated reference material to any other location for further reproduction
18  * or redistribution, and any amendments to this copyright notice, are expressly prohibited.
19  *
20  * Any reproduction or redistribution for sale or hiring of the Software not in accordance with
21  * the terms of the Agreement is a violation of copyright law.
22  */
23 
24 #pragma once
25 
26 #include "../Export.h"
27 #include "../Types.h"
28 #include "../Enumerations.h"
29 #include "../Time.h"
30 #include "../Optional.h"
31 
32 #include <iosfwd>
33 #include <string>
34 #include <vector>
35 
36 namespace OnixS { namespace ICE { namespace iMpact { namespace MarketData {
37 
38 /// This class represents the Futures/OTC Product Definition Response Message.
39 struct ONIXS_ICEMDH_EXPORT FuturesProductDefinition
40 {
41  /// Message type constant
42  enum { messageType = 'B' };
43 
44  /// The original request sequence ID assigned by client, unique per
45  /// session.
47 
48  /// See Appendix C for the list of market types and IDs.
50 
51  /// Unique identifier of the market.
53 
54  /// See Naming Convention on Appendix D.
55  std::string contractSymbol;
56 
57  /// See Appendix A on trading status codes.
59 
60  /// Denominator for the order price fields in this market.
62 
63  /// Minimum increment price for this market.
65 
66  /// Minimum increment quantity for this market.
68 
69  /// The lot size is minimum size of contracts in lots. It is multiplier to
70  /// determine the total lots.
71  int lotSize;
72 
73  /// Description of the market.
74  std::string marketDesc;
75 
76  /// 4 digit year. Last date that the market can be traded and should be
77  /// removed from the system.
78  short maturityYear;
79 
80  /// Month range 1-12. Last date that the market can be traded and should
81  /// be removed from the system.
83 
84  /// Day of the month. Last date that the market can be traded and should
85  /// be removed from the system.
86  short maturityDay;
87 
88  /// Indicate if the market is a spread.
89  bool isSpread;
90 
91  /// Indicate if the market is crack spread.
93 
94  /// Ignored when it is not spread.
96 
97  /// Ignored when it is not spread.
99 
100  /// Denominator for the deal price fields in the market. For most markets,
101  /// this is the same as OrderPriceDenominator. However, it could be
102  /// different for some crack or spread markets.
104 
105  /// Minimum quantity for this market.
106  int minQty;
107 
108  /// The quantity in unit of measurement per lot. For example, it is 1000
109  /// barrels per lot for Brent.
111 
112  /// The currency that the market is traded on.
113  std::string currency;
114 
115  /// Only used for `OffExchangeIncrementOptionPrice`.
117 
118  /// Use `ScreentickValue` and `BlockTickValue` instead of this field.
119  /// `OrderPriceDenominator` should be applied to get the real value.
120  /// Please take note that this value can be different for the same markets
121  /// with different expiry and that this value can change over time for a
122  /// given market (i.e. `MarketID`).
123  long long oldTickValue;
124 
125  /// Indicate if the market supports option markets.
127 
128  /// Clearing limit admin related.
129  std::string clearedAlias;
130 
131  /// Indicate if implication is done for a given spread market and its
132  /// given outright leg markets.
134 
135  /// 4 digit year.
137 
138  /// Month range 1-12.
140 
141  /// Day of the month.
143 
144  /// Minimum Price.
146 
147  /// Maximum Price.
149 
150  /// Name of the product that the contract/market is under.
151  std::string productName;
152 
153  /// Alias of the hub for the contract/market.
154  std::string hubAlias;
155 
156  /// Name of the strip for the contract/market.
157  std::string stripName;
158 
159  /// Indicate if serial options is supported.
161 
162  /// Indicate if the contract is tradable.
164 
165  /// Denominator for the settlement price fields in the market. For most
166  /// markets, this is the same as DealPriceDenominator.
168 
169  /// Market Identifier Code for the market.
170  std::string micCode;
171 
172  /// Denominator for UnitQuantity. Clients should also apply
173  /// UnitQtyDenominator when calculating LotSize. This field will be `0`
174  /// for most of the markets.
176 
177  /// Contains the Strategy Code for defined market where applicable. See
178  /// Appendix E for list of codes.
180 
181  /// Indicate if the contract is for hedge only.
182  bool hedgeOnly;
183 
184  /// Exchange silo code for the market.
186 
187  /// Denominator for `OffExchangeIncrementQty`.
189 
190  /// Off exchange increment qty. `OffExchangeIncrementQtyDenominator`
191  /// should be applied to this field.
193 
194  /// Off exchange increment price. `OrderPriceDenominator` should be
195  /// applied to this field.
197 
198  /// Off exchange options increment price. `NumDecimalsOptionsPrice` should
199  /// be applied to this field.
201 
202  /// ID of the product that the contract/market is under.
204 
205  /// ID of the hub for the contract/market.
206  int hubId;
207 
208  /// ID of the strip for the contract/market.
209  int stripId;
210 
211  /// The ISIN of the security this market is associated with. This is
212  /// currently only populated for Liffe Equity markets.
213  std::string underlyingISIN;
214 
215  /// This nested class represents block details definition.
216  struct ONIXS_ICEMDH_EXPORT BlockDetail
217  {
218  /// Block Type.
220 
221  /// Trade Type.
223 
224  /// Minimum Quantity. `OffExchangeIncrementQtyDenominator` should be
225  /// applied to this field.
226  long long minQty;
227 
228  /// Returns string representation.
229  std::string toString() const;
230  };
231 
232  /// Alias for collection of BlockDetails.
233  typedef std::vector<BlockDetail> BlockDetails;
234 
235  /// Collection of BlockDetails.
237 
238  /// Denominator for the alternate deal price fields in the market.
240 
241  /// Fixed Rate: The fixed rate for an instrument.
243 
244  /// Fixed Rate: The fixed rate Denominator for an instrument.
246 
247  /// Cash Flow Alignment Date: The cash flow alignment date is a date not
248  /// adjusted for holidays used to derive interest payment dates. Any
249  /// calendar day.
251 
252  /// Effective Date: The effective date of the swap future. Any business
253  /// day.
255 
256  /// First Fixing Date: The first Fixing Date is the date at which the
257  /// float rate is set during the first float period. Any acceptable
258  /// business day.
260 
261  /// Previous Fixing Rate: The rate set on the last reset date. Sent for
262  /// float leg on aged or spot starting swap futures. Not sent for forward
263  /// starting swap futures. Number of decimal places for RepurchaseRate is
264  /// 5. `0` is valid for this field up until the First Fixing Date
265  /// (IssueDate).
267 
268  /// Previous Fixing Date: The date the floating rate was set for the next
269  /// floating payment. Milliseconds since Jan 1st, 1970, 00:00:00 GMT. `0`
270  /// is valid for this field up until the First Fixing Date (IssueDate).
272 
273  /// Index Factor: Percentage of the original index that is still accruing
274  /// interest. Number of decimal places for Factor is 2.
276 
277  /// Interpolation Factor: Multiplier that when applied to the longer rate
278  /// in the CreditRating (Rate Descriptor) field results in RepurchaseRate
279  /// (Previous Fixing Rate). Not sent for forward starting interest rate
280  /// swap futures.
282 
283  /// Denominator value for ContractMultiplier.
285 
286  /// Payment Frequency: The interest rate swap future payment frequency.
287  /// Supported values: `6M` = 6 months, `1Y` = 1 year.
289 
290  /// Rate Descriptor: The description of Float Rate. Sent for float leg on
291  /// aged or spot starting swap futures.
293 
294  /// Total Premium Accrual: Premium that has accrued during the current
295  /// quarterly payment period. Based on 100 Notional and will be applied to
296  /// the `A` value. Number of decimal places for AccruedPremiumAmt is 10.
298 
299  /// CDS - Premium & Credit Event Payments (B): This value represents
300  /// historical premium and credit event payments for 100 notional, and is
301  /// one of the primary inputs needed for calculating a futures price for a
302  /// swap future. IRS - Accrued Coupons (B Value): This value represents
303  /// historical fixed and floating payments for 100 notional, and is one of
304  /// the primary inputs needed for calculating a futures price for an
305  /// interest rate swap future. Number of decimal places for
306  /// EventPaymentAmt is 10. This value can be negative.
308 
309  /// Price Alignment Interest (C): Eris PAI is the cumulative daily
310  /// interest on variation margin adjustment for 100 notional. Eris PAI is
311  /// one of the primary inputs needed for calculating a futures price for a
312  /// swap future. IRS - Accrued Coupons (B Value): This value represents
313  /// historical fixed and floating payments for 100 notional, and is one of
314  /// the primary inputs needed for calculating a futures price for a swap
315  /// future. Denominator value for AlignmentInterestRate is 10.
317 
318  /// Settlement Type.
320 
321  /// Indicates if Market is only tradable via ICE Block Trade. This also
322  /// means the screen trading is not allowed for the market.
324 
325  /// Indicates if flexible strikes can be created for the option market.
327 
328  /// Market ID for the corresponding hedge market. It will be set to `-1`
329  /// when not applicable.
331 
332  /// The number of markets for the given market type.
334 
335  /// Only sent if contract symbol is greater than 35. Client should use
336  /// this field if sent else use existing contract symbol field.
338 
339  /// Unit Of Measure.
341 
342  /// Indicates if GTC is allowed in the market.
344 
345  /// Indicates if Cross order is supported in the market.
347 
348  /// Indicates if AON order is supported in the market.
350 
351  /// Indicates MIFID-II market.
353 
354  /// Indicates this is a test market.
356 
357  /// Product ID to use when requesting new spread.
359 
360  /// This ISIN is only supported for MiFID Regulated Markets. Of the MiFID
361  /// markets, only Futures and Options markets will support ISINs; some
362  /// strategies will have an ISIN.
364 
365  /// This field can be used to identify if a market is Platts or not.
367 
368  /// ScreenLastTradeDate is the last date, by Exchange rule, that the
369  /// market is available for trading on the Central Order Book. It applies
370  /// to all cleared instruments on the trading platform.
372 
373  /// Indicates if dividend is adjusted.
375 
376  /// Indicates whether the Block Minimum can be overridden for the market.
378 
379  /// The deliverable quantity of a stock, commodity, or other financial
380  /// instrument that underlies a futures or options contract.
382 
383  /// Identifies the monetary amount per tick move when calculated from the
384  /// Central Limit Order Book.
386 
387  /// Identifies the monetary amount per tick move when calculated for Off-
388  /// Exchange trades.
390 
391  /// Denominator for ScreenTickValue and BlockTickValue.
393 
394  /// Denominator for ContractSize.
396 
397  /// Number of cycles (days, hours, MWh, etc) for a contract. Replaces
398  /// OldNumOfCycles (id=38).
400 
401  /// Default constructor.
403 
404  /// Initialize from raw message data.
405  FuturesProductDefinition(const char* data, size_t dataSize);
406 
407  /// Deserialize from raw data.
408  void deserialize(const char* data, size_t dataSize);
409 
410  /// Reset all fields to default values.
411  void reset();
412 
413  /// Returns string representation.
414  std::string toString() const;
415 };
416 
417 /// Make it printable using C++ I/O streams.
418 ONIXS_ICEMDH_EXPORT std::ostream& operator<<(std::ostream&, const FuturesProductDefinition&);
419 
420 }}}} // namespace MarketData, iMpact, ICE, OnixS
std::string productName
Name of the product that the contract/market is under.
Optional< bool > miFIDRegulatedMarket
Indicates MIFID-II market.
Optional< bool > gtAllowed
Indicates if GTC is allowed in the market.
short MarketType
Alias for market types.
Definition: Types.h:36
std::vector< BlockDetail > BlockDetails
Alias for collection of BlockDetails.
This nested class represents block details definition.
bool hedgeOnly
Indicate if the contract is for hedge only.
long long Price
Alias for order identifiers type.
Definition: Types.h:54
Optional< bool > testMarketIndicator
Indicates this is a test market.
Optional< MarketTransparencyType::Enum > marketTransparencyType
This field can be used to identify if a market is Platts or not.
std::string contractSymbol
See Naming Convention on Appendix D.
Optional< bool > crossOrderSupported
Indicates if Cross order is supported in the market.
Optional< char > couponRateDenominator
Fixed Rate: The fixed rate Denominator for an instrument.
ExchangeSilo::Enum exchangeSilo
Exchange silo code for the market.
int incrementPrice
Minimum increment price for this market.
int MarketId
Alias for market identifiers type.
Definition: Types.h:39
char numDecimalsOptionsPrice
Only used for OffExchangeIncrementOptionPrice.
std::ostream & operator<<(std::ostream &, const Error &)
Make it printable to formatted C++ I/O streams.
Optional< char > tickValueDenominator
Denominator for ScreenTickValue and BlockTickValue.
TradingStatus::Enum tradingStatus
See Appendix A on trading status codes.
bool isCrackSpread
Indicate if the market is crack spread.
Optional< int > refSpreadProductId
Product ID to use when requesting new spread.
Optional< bool > overrideBlockMin
Indicates whether the Block Minimum can be overridden for the market.
Optional< SettlementType::Enum > settlementType
Settlement Type.
int productId
ID of the product that the contract/market is under.
char orderPriceDenominator
Denominator for the order price fields in this market.
MarketType requestMarketType
See Appendix C for the list of market types and IDs.
char offExchangeIncrementQtyDenominator
Denominator for OffExchangeIncrementQty.
Enum
Exchange silo code for the market.
Definition: Enumerations.h:828
Optional< bool > flexAllowed
Indicates if flexible strikes can be created for the option market.
int incrementQty
Minimum increment quantity for this market.
This class represents the Futures/OTC Product Definition Response Message.
Optional< char > interpolationFactorDenominator
Denominator value for ContractMultiplier.
std::string hubAlias
Alias of the hub for the contract/market.
Optional< bool > aonAllowed
Indicates if AON order is supported in the market.
std::string stripName
Name of the strip for the contract/market.
std::string micCode
Market Identifier Code for the market.
Optional< int > numOfMarkets
The number of markets for the given market type.
bool allowOptions
Indicate if the market supports option markets.
int stripId
ID of the strip for the contract/market.
Optional< long long > couponRate
Fixed Rate: The fixed rate for an instrument.
Optional< BlockDetails > blockDetails
Collection of BlockDetails.
Optional< bool > isDividendAdjusted
Indicates if dividend is adjusted.
bool isSerialOptionsSupported
Indicate if serial options is supported.
std::string currency
The currency that the market is traded on.
Optional< char > contractSizeDenominator
Denominator for ContractSize.
Optional< char > altPriceDenominator
Denominator for the alternate deal price fields in the market.