OnixS C++ Eurex T7 Market and Reference Data Interface (EMDI, RDI, EOBI) Handlers  11.0.0
API documentation
InstrumentSnapshot.h
Go to the documentation of this file.
1 /*
2 * Copyright Onix Solutions Limited [OnixS]. All rights reserved.
3 *
4 * This software owned by Onix Solutions Limited [OnixS] and is protected by copyright law
5 * and international copyright treaties.
6 *
7 * Access to and use of the software is governed by the terms of the applicable OnixS Software
8 * Services Agreement (the Agreement) and Customer end user license agreements granting
9 * a non-assignable, non-transferable and non-exclusive license to use the software
10 * for it's own data processing purposes under the terms defined in the Agreement.
11 *
12 * Except as otherwise granted within the terms of the Agreement, copying or reproduction of any part
13 * of this source code or associated reference material to any other location for further reproduction
14 * or redistribution, and any amendments to this copyright notice, are expressly prohibited.
15 *
16 * Any reproduction or redistribution for sale or hiring of the Software not in accordance with
17 * the terms of the Agreement is a violation of copyright law.
18 */
19 
20 #pragma once
21 
27 
28 namespace OnixS
29 {
30  namespace Eurex
31  {
32  namespace MarketData
33  {
34 
35  /// Alternate identifier entry.
36  class ONIXS_EUREX_EMDI_API SecurityAlt : GroupInstance
37  {
38  public:
39 
40  /// Alternate instrument identifier.
42  {
43  StringRef val;
44  return get (Tags::SecurityAltID).toStringRef (val) ? val : StringRef();
45  }
46 
47  /// Security alternate id source.
49  {
50  StringRef val;
51  return get (Tags::SecurityAltIDSource).toStringRef (val) ? val : StringRef();
52  }
53 
54  private:
55  friend class TypedGroup<SecurityAlt>;
56 
57  SecurityAlt (const GroupInstance& groupInstance)
58  : GroupInstance (groupInstance)
59  {
60  }
61  };
62 
63  class SecurityAlts : public TypedGroup<SecurityAlt>
64  {
65  private:
66  explicit
67  SecurityAlts (const Group& group)
68  : TypedGroup<SecurityAlt> (group)
69  {
70  }
71 
72  friend class InstrumentSnapshot;
73  };
74 
75  /// Exposes list of available security types.
76  struct ONIXS_EUREX_EMDI_API SecurityType
77  {
78  enum Enum
79  {
80  /// Used to identify absence of value.
81  Undefined = -1,
82 
83  ///
84  Option = 0,
85 
86  ///
87  Future = 1,
88 
89  ///
90  MultiLegInstrument = 2,
91 
92  ///
93  VarianceFutures = 3,
94 
95  ///
96  TotalReturnFutures = 4,
97 
98  ///
99  CommonStock = 5,
100 
101  ///
102  Bond = 6,
103 
104  ///
105  TradeAtReferencePrice = 7,
106 
107  ///
108  ExchangeTradedFund = 8,
109 
110  ///
111  ExchangeTradedCommodity = 9,
112 
113  ///
114  ExchangeTradedNote = 10,
115 
116  ///
118 
119  ///
121 
122  ///
124 
125  ///
126  InvestmentFunds
127  };
128  };
129 
130  /// Exposes list of Instrument scope operators.
131  struct ONIXS_EUREX_EMDI_API InstrumentScopeOperator
132  {
133  enum Enum
134  {
135  /// Used to identify absence of value.
136  Undefined = -1,
137 
138  ///
139  Include = 0,
140  };
141  };
142 
143 
144  ///
145  struct ONIXS_EUREX_EMDI_API PutOrCall
146  {
147  enum Enum
148  {
149  /// Used to identify absence of value.
150  Undefined = -1,
151 
152  ///
153  Put = 0,
154 
155  ///
156  Call = 1
157  };
158  };
159 
160 
161  ///
162  struct ONIXS_EUREX_EMDI_API ExerciseStyle
163  {
164  enum Enum
165  {
166  /// Used to identify absence of value.
167  Undefined = -1,
168 
169  ///
170  European = 0,
171 
172  ///
173  American = 1
174  };
175  };
176 
177  struct ONIXS_EUREX_EMDI_API MultilegModel
178  {
179  enum Enum
180  {
181  /// Used to identify absence of value.
182  Undefined = -1,
183 
184  ///
185  PredefinedMultilegSecurity = 0,
186 
187  ///
188  UserDefinedMultilegSecurity = 1
189  };
190  };
191 
192  ///
193  struct ONIXS_EUREX_EMDI_API ValuationMethod
194  {
195  enum Enum
196  {
197  /// Used to identify absence of value.
198  Undefined = -1,
199 
200  ///
201  PremiumStyle = 0,
202 
203  ///
204  FuturesStyleMarkToMarket = 1
205  };
206  };
207 
208  ///
209  struct ONIXS_EUREX_EMDI_API WarrantType
210  {
211  enum Enum
212  {
213  /// Used to identify absence of value.
214  Undefined = -1,
215 
216  ///
217  Call = 0,
218  ///
220  ///
222  ///
224  ///
225  Other
226  };
227  };
228 
229 
230  struct ONIXS_EUREX_EMDI_API SettlMethod
231  {
232  enum Enum
233  {
234  /// Used to identify absence of value.
235  Undefined = -1,
236 
237  ///
238  Cash = 0,
239 
240  ///
241  Physical = 1
242  };
243  };
244 
245  struct ONIXS_EUREX_EMDI_API SettlSubMethod
246  {
247  enum Enum
248  {
249  /// Used to identify absence of value.
250  Undefined = -1,
251 
252  ///
253  Shares = 0,
254  Derivatives = 1,
255  PaymentVsPayment = 2,
256  Notional = 3,
257  Cascade = 4,
258  Other = 5
259  };
260  };
261 
262  struct ONIXS_EUREX_EMDI_API InstrumentPartyIDSource
263  {
264  enum Enum
265  {
266  /// Used to identify absence of value.
267  Undefined = -1,
268 
269  ///
270  Proprietary = 0,
271  };
272  };
273 
274  struct ONIXS_EUREX_EMDI_API InstrumentPartyRole
275  {
276  enum Enum
277  {
278  /// Used to identify absence of value.
279  Undefined = -1,
280 
281  ///
282  ClearingOrganization = 0,
283  ///
284  MarketMaker = 1,
285  };
286  };
287 
288  struct ONIXS_EUREX_EMDI_API InstrumentPartyRoleQualifier
289  {
290  enum Enum
291  {
292  /// Used to identify absence of value.
293  Undefined = -1,
294 
295  ///
296  DesignatedSponsor = 0,
297 
298  ///
299  Specialist
300  };
301  };
302 
303  /// Deposit Type
304  struct ONIXS_EUREX_EMDI_API DepositType
305  {
306  enum Enum
307  {
308  /// Used to identify absence of value.
309  Undefined = -1,
310 
311  ///
312  Auslandskassenverein = 0,
313 
314  ///
315  Girosammelverwahrung = 1,
316 
317  ///
318  Streifbandverwahrung = 2,
319 
320  ///
321  Wertpapierrechnung = 3,
322 
323  ///
324  NcsCviaT2S = 4
325  };
326  };
327 
328  /// Accrued interest Calculation Methods
329  struct ONIXS_EUREX_EMDI_API AccruedInterestCalculationMethod
330  {
331  enum Enum
332  {
333  /// Used to identify absence of value.
334  Undefined = -1,
335 
336  ///
337  Basis30360 = 0,
338 
339  ///
341 
342  ///
344 
345  ///
347 
348  ///
350 
351  ///
353 
354  ///
356 
357  ///
359  };
360  };
361 
362  /// Coupon Types
363  struct ONIXS_EUREX_EMDI_API CouponType
364  {
365  enum Enum
366  {
367  /// Used to identify absence of value.
368  Undefined = -1,
369 
370  ///
371  Zero = 0,
372 
373  ///
375 
376  ///
378 
379  ///
381  };
382  };
383 
384  /// Cover Indicator
385  struct ONIXS_EUREX_EMDI_API CoverIndicator
386  {
387  enum Enum
388  {
389  /// Used to identify absence of value.
390  Undefined = -1,
391 
392  ///
393  Intraday = 0,
394 
395  ///
397 
398  ///
400  };
401  };
402 
403  /// Flat Indicators
404  struct ONIXS_EUREX_EMDI_API FlatIndicator
405  {
406  enum Enum
407  {
408  /// Used to identify absence of value.
409  Undefined = -1,
410 
411  ///
412  NoFlat = 0,
413 
414  ///
416 
417  ///
419  };
420  };
421 
422  /// Instrument Party.
423  class ONIXS_EUREX_EMDI_API InstrumentParty : GroupInstance
424  {
425  public:
426 
427  /// Identifies a party associated with an instrument.
428  StringRef id() const
429  {
430  StringRef val;
431  return get (Tags::InstrumentPartyID).toStringRef (val) ? val : StringRef();
432  }
433 
434  ///
436  {
437  return getIntEnumFieldValue<InstrumentPartyIDSource> (*this, Tags::InstrumentPartyIDSource);
438  }
439 
440  ///
442  {
443  return getIntEnumFieldValue<InstrumentPartyRole> (*this, Tags::InstrumentPartyRole);
444  }
445 
446  ///
448  {
449  return getIntEnumFieldValue<InstrumentPartyRoleQualifier> (*this, Tags::InstrumentPartyRoleQualifier);
450  }
451 
452  private:
454 
455  InstrumentParty (const GroupInstance& groupInstance)
456  : GroupInstance (groupInstance)
457  {
458  }
459  };
460 
461  struct ONIXS_EUREX_EMDI_API InstrumentAttributeType
462  {
463  enum Enum
464  {
465  /// Used to identify absence of value.
466  Undefined = -1,
467 
468  ///
469  MinimumReserveOrderQuantity = 0,
470  ///
471  MinimumDisplayQuantity = 1,
472  ///
473  IssuerName = 2,
474  ///
475  IssuerNumber = 3,
476  ///
477  MarketType = 4,
478  ///
479  MarketTypeSupplement = 5,
480  ///
481  ReportingMarket = 6,
482  ///
483  CumExIndicator = 7,
484  ///
485  ProductAssignmentGroup = 8,
486  ///
487  ProductAssignmentGroupDescription = 9,
488  ///
489  PreTradeLISValue = 10,
490  ///
491  VDOMinimumExecutionVolume = 11,
492  ///
493  IlliquidAsDefinedByExchange = 12,
494  ///
495  MarketMakingObligation = 13,
496  ///
497  LiquidAsDefinedByRegulator = 14,
498  ///
499  EligibleForStressedMarketConditions = 15,
500  ///
502  ///
504  ///
506  ///
508  ///
510  ///
512  ///
514  ///
516  ///
518  ///
520  ///
522  ///
524  ///
525  LiquidityClass
526  };
527  };
528 
529  struct ONIXS_EUREX_EMDI_API InstrumentAuctionType
530  {
531  enum Enum
532  {
533  /// Used to identify absence of value.
534  Undefined = -1,
535 
536  ///
537  Default = 0,
538  ///
539  SingleAuction = 1,
540  ///
541  SpecialAuction = 2
542  };
543  };
544 
545  struct ONIXS_EUREX_EMDI_API PostTradeAnonymityType
546  {
547  enum Enum
548  {
549  /// Used to identify absence of value.
550  Undefined = -1,
551 
552  ///
553  Disabled = 0,
554  ///
555  Enabled = 1,
556  ///
557  CentralCounterparty = 2,
558  };
559  };
560 
561  struct ONIXS_EUREX_EMDI_API PriceType
562  {
563  enum Enum
564  {
565  /// Used to identify absence of value.
566  Undefined = -1,
567 
568  ///
569  Percent = 0,
570  ///
571  Shares = 1,
572  ///
573  Points = 2,
574  };
575  };
576 
577  struct ONIXS_EUREX_EMDI_API ContractIdentificationEligibility
578  {
579  enum Enum
580  {
581  /// Used to identify absence of value.
582  Undefined = -1,
583 
584  ///
586 
587  ///
589 
590  ///
592  };
593  };
594 
595 
596  struct ONIXS_EUREX_EMDI_API ContractCycleType
597  {
598  enum Enum
599  {
600  /// Used to identify absence of value.
601  Undefined = -1,
602 
603  ///
604  Dayly = 0,
605 
606  ///
608 
609  ///
611 
612  ///
614 
615  ///
617 
618  ///
620  };
621  };
622 
623  struct ONIXS_EUREX_EMDI_API ContractCycleSubType
624  {
625  enum Enum
626  {
627  /// Used to identify absence of value.
628  Undefined = -1,
629 
630  ///
631  EndOfMonth = 0,
632  };
633  };
634 
635  struct ONIXS_EUREX_EMDI_API ContractFrequency
636  {
637  enum Enum
638  {
639  /// Used to identify absence of value.
640  Undefined = -1,
641 
642  ///
643  Day = 0,
644 
645  ///
647 
648  ///
650 
651  ///
653 
654  ///
655  EndOfMonth
656 
657  };
658  };
659 
660  struct ONIXS_EUREX_EMDI_API ContractDisplayInstruction
661  {
662  enum Enum
663  {
664  /// Used to identify absence of value.
665  Undefined = -1,
666 
667  ///
668  None = 0,
669 
670  ///
672 
673  ///
675 
676  ///
678 
679  ///
681 
682  ///
684 
685  ///
687 
688  ///
690 
691  ///
693 
694  ///
696 
697  ///
699 
700  ///
701  EndOfMonth
702  };
703  };
704 
705  struct ONIXS_EUREX_EMDI_API DisplaySeason
706  {
707  enum Enum
708  {
709  /// Used to identify absence of value.
710  Undefined = -1,
711 
712  ///
713  Summer = 0,
714 
715  ///
717  };
718  };
719 
720  class InstrumentParties : public TypedGroup<InstrumentParty>
721  {
722  private:
723  explicit
724  InstrumentParties (const Group& group)
726  {
727  }
728 
729  friend class InstrumentSnapshot;
730  };
731 
732  /// Instrument Attribute.
733  class ONIXS_EUREX_EMDI_API InstrumentAttribute : GroupInstance
734  {
735  public:
736 
737  ///
739  {
740  return getIntEnumFieldValue<InstrumentAttributeType> (*this, Tags::InstrAttribType);
741  }
742 
743  ///
744  StringRef value() const
745  {
746  StringRef val;
747  return get (Tags::InstrAttribValue).toStringRef (val) ? val : StringRef();
748  }
749 
750  private:
752 
753  InstrumentAttribute (const GroupInstance& groupInstance)
754  : GroupInstance (groupInstance)
755  {
756  }
757  };
758 
759  class InstrumentAttributes : public TypedGroup<InstrumentAttribute>
760  {
761  private:
762  explicit
763  InstrumentAttributes (const Group& group)
765  {
766  }
767 
768  friend class InstrumentSnapshot;
769  };
770 
771 
772  /// Event.
773  class ONIXS_EUREX_EMDI_API Event : GroupInstance
774  {
775  public:
776  /// Event Type
777  bool eventType (UInt32& type) const
778  {
779  return get (Tags::EventType).toNumber (type);
780  }
781 
782  /// Event Date
784  {
785  return getUInt32 (Tags::EventDate);
786  }
787 
788  private:
789  friend class TypedGroup<Event>;
790 
791  Event (const GroupInstance& groupInstance)
792  : GroupInstance (groupInstance)
793  {
794  }
795  };
796 
797  class Events : public TypedGroup<Event>
798  {
799  private:
800  explicit
801  Events (const Group& group)
802  : TypedGroup<Event> (group)
803  {
804  }
805 
806  friend class InstrumentSnapshot;
807  };
808 
809  ///
810  class InstrumentSnapshotLegs : public TypedGroup<InstrumentLeg>
811  {
812  private:
813  explicit
814  InstrumentSnapshotLegs (const Group& group)
815  : TypedGroup<InstrumentLeg> (group)
816  {
817  }
818 
819  friend class InstrumentSnapshot;
820  };
821 
822 
823  /// TradingSessionRules
824  class ONIXS_EUREX_EMDI_API TradingSessionRule : GroupInstance
825  {
826  public:
827 
828  /// Trading Session ID
830  {
831  return 0u;
832  }
833 
834  /// Defines the trading session sub ID.
836  {
837  return getIntEnumFieldValue<TradingSessionSubID> (*this, Tags::TradingSessionSubID);
838  }
839 
840  private:
842 
843  TradingSessionRule (const GroupInstance& groupInstance)
844  : GroupInstance (groupInstance)
845  {
846  }
847  };
848 
849  ///
850  class TradingSessionRules : public TypedGroup<TradingSessionRule>
851  {
852  private:
853  explicit
854  TradingSessionRules (const Group& group)
856  {
857  }
858 
859  friend class InstrumentSnapshot;
860  };
861 
862  /// Instrument snapshot.
863  class ONIXS_EUREX_EMDI_API InstrumentSnapshot : public Message
864  {
865  public:
866  /// Instrument identifier.
868  {
869  return getInt64 (Tags::SecurityID);
870  }
871 
872  /// Entries.
874  {
875  return SecurityAlts ( getGroup (Tags::NoSecurityAltID) );
876  }
877 
878  /// Type of security.
880  {
881  return getIntEnumFieldValue<SecurityType> (*this, Tags::SecurityType);
882  }
883 
884  /// Security Status.
886  {
887  return getIntEnumFieldValue<SecurityStatus> (*this, Tags::SecurityStatus);
888  }
889 
890  /// Security description
891  bool securityDesc(StringRef& desc) const
892  {
893  return get (Tags::SecurityDesc).toStringRef (desc);
894  }
895 
896  /// MIC (ISO 10383), used to identify an instrument of a co-operation partner.
897  bool securityExchange (StringRef& exchange) const
898  {
899  return get (Tags::SecurityExchange).toStringRef (exchange);
900  }
901 
902  /// Type of Market Data update action
904  {
905  return getNonZeroIntEnumFieldValue<InstrumentType>(*this, Tags::ProductComplex);
906  }
907 
908  /// Indicates the type of security using ISO 10962 standard.
909  bool cfiCode(StringRef desc) const
910  {
911  return get (Tags::CFICode).toStringRef (desc);
912  }
913 
914  /// Defines the granularity which suffice to identify a standard e.g. non - flexible contract uniquely within a product.
916  {
917  return getIntEnumFieldValue<ContractIdentificationEligibility>(*this, Tags::ContractIdentificationEligibility);
918  }
919 
920  /// Defines, if this contract based on its contract generation cycle, is considered primary.
921  bool isPrimary() const
922  {
923  UInt32 value;
924  return get(Tags::IsPrimary).toNumber(value) ? (value == 1) : false;
925  }
926 
927  /// Actual contract start date
928  bool contractDate (UInt32& value)
929  {
930  return get (Tags::ContractDate).toNumber (value);
931  }
932 
933  /// Contract start month
934  bool contractMonthYear (UInt32& value)
935  {
936  return get (Tags::ContractMonthYear).toNumber (value);
937  }
938 
939  /// Defines the instrument cycle type
941  {
942  return getIntEnumFieldValue<ContractCycleType>(*this, Tags::ContractCycleType);
943  }
944 
945  /// Indicates the kind of regular expiration pattern, in the context of ContractCycleType(30865).
947  {
948  return getIntEnumFieldValue<ContractCycleSubType>(*this, Tags::ContractCycleSubType);
949  }
950 
951  /// Indicates the kind of regular expiration pattern, in the context of ContractCycleType(30865).
953  {
954  return getIntEnumFieldValue<ContractFrequency>(*this, Tags::ContractFrequency);
955  }
956 
957  /// Defines the instrument display instruction
959  {
960  return getIntEnumFieldValue<ContractDisplayInstruction>(*this, Tags::ContractDisplayInstruction);
961  }
962 
963  /// Display Day
964  bool displayDay(UInt32& value)
965  {
966  return get(Tags::DisplayDay).toNumber(value);
967  }
968 
969  /// Display Relative Day
971  {
972  return get(Tags::DisplayRelativeDay).toNumber(value);
973  }
974 
975  /// Display Week
976  bool displayWeek(UInt32& value)
977  {
978  return get(Tags::DisplayWeek).toNumber(value);
979  }
980 
981  /// Display Month
982  bool displayMonth(UInt32& value)
983  {
984  return get(Tags::DisplayMonth).toNumber(value);
985  }
986 
987  /// The Display Quarter denotes the three-month period inside a year.
988  bool displayQuarter(UInt32& value)
989  {
990  return get(Tags::DisplayQuarter).toNumber(value);
991  }
992 
993  /// Defines the instrument display instruction
995  {
996  return getIntEnumFieldValue<DisplaySeason>(*this, Tags::DisplaySeason);
997  }
998 
999  /// Display Year
1000  bool displayYear(UInt32& value)
1001  {
1002  return get(Tags::DisplayYear).toNumber(value);
1003  }
1004 
1005  /// Display Name
1006  bool displayName(StringRef& val) const
1007  {
1008  return get(Tags::DisplayName).toStringRef(val);
1009  }
1010 
1011  /// Strike Price
1012  bool strikePrice (Decimal& price) const
1013  {
1014  return get (Tags::StrikePrice).toNumber (price);
1015  }
1016 
1017  /// Strike Price Precision
1018  bool strikePricePrecision (UInt32& precision) const
1019  {
1020  return get (Tags::StrikePricePrecision).toNumber (precision);
1021  }
1022 
1023  /// Contract Multiplier
1024  bool contractMultiplier (Decimal& multiplier) const
1025  {
1026  return get (Tags::ContractMultiplier).toNumber (multiplier);
1027  }
1028 
1029  /// Put Or Call
1031  {
1032  return getIntEnumFieldValue<PutOrCall> (*this, Tags::PutOrCall);
1033  }
1034 
1035  /// Version of an option. Version can change as a result of corporate actions or events.
1036  bool optAttribute (UInt32& attribute) const
1037  {
1038  return get (Tags::OptAttribute).toNumber (attribute);
1039  }
1040 
1041  /// Exercise Style
1043  {
1044  return getIntEnumFieldValue<ExerciseStyle> (*this, Tags::ExerciseStyle);
1045  }
1046 
1047  /// Original strike price prior to corporate action, e.g. 5.20.
1048  bool origStrikePrice (Decimal& price) const
1049  {
1050  return get (Tags::OrigStrikePrice).toNumber (price);
1051  }
1052 
1053  /// Contract generation.
1054  bool contractGenerationNumber (UInt32& number) const
1055  {
1056  return get (Tags::ContractGenerationNumber).toNumber (number);
1057  }
1058 
1059  /// Lepo Flag
1061  {
1062  UInt32 value;
1063  return (get (Tags::LowExercisePriceOptionIndicator).toNumber (value) ) ? (value == 1) : false;
1064  }
1065 
1066  /// Traditional or futures margin style.
1068  {
1069  return getIntEnumFieldValue<ValuationMethod> (*this, Tags::ValuationMethod);
1070  }
1071 
1072  ///
1074  {
1075  return getIntEnumFieldValue<SettlMethod> (*this, Tags::SettlMethod);
1076  }
1077 
1078  ///
1080  {
1081  return getIntEnumFieldValue<SettlSubMethod> (*this, Tags::SettlSubMethod);
1082  }
1083 
1084  /// Previous day's settlement price. Converted in trading notation in case of variance futures.
1085  bool priorSettlPrice (Decimal& price) const
1086  {
1087  return get (Tags::PriorSettlPrice).toNumber (price);
1088  }
1089 
1090  /// Common integer multiple of the option legs for Option Volatility Strategies.
1091  bool legRatioMultiplier(UInt32& value) const
1092  {
1093  return get(Tags::LegRatioMultiplier).toNumber(value);
1094  }
1095 
1096  /// Legs
1098  {
1099  return InstrumentSnapshotLegs ( getGroup (Tags::NoLegs) );
1100  }
1101 
1102  /// Refers to MarketSegmentID (1300) from the underlying Product Snapshot.
1104  {
1105  return get(Tags::UnderlyingMarketSegmentID).toNumber(val);
1106  }
1107 
1108  /// Refers to SecurityID (48) from the underlying Instrument Snapshot.
1109  bool underlyingSecurityID(Int64& val) const
1110  {
1111  return get(Tags::UnderlyingSecurityID).toNumber(val);
1112  }
1113 
1114 
1115  /// UnitOfMeasure
1116  bool unitOfMeasure(StringRef& val) const
1117  {
1118  return get(Tags::UnitOfMeasure).toStringRef(val);
1119  }
1120 
1121  /// AssetType
1122  bool assetType(UInt32& val) const
1123  {
1124  return get(Tags::AssetType).toNumber(val);
1125  }
1126 
1127  /// AssetSubType
1128  bool assetSubType(UInt32& val) const
1129  {
1130  return get(Tags::AssetSubType).toNumber(val);
1131  }
1132 
1133  /// Transact Time
1134  bool transactTime (UInt64& time) const
1135  {
1136  return get (Tags::TransactTime).toNumber (time);
1137  }
1138 
1139  /// Reference to tick size table identifier from product level message.
1140  bool refTickTableID (UInt32& time) const
1141  {
1142  return get (Tags::RefTickTableID).toNumber (time);
1143  }
1144 
1145  /// Currency as published in ISO 4217.
1147  {
1148  return getStringRef (Tags::Currency);
1149  }
1150 
1151  /// Settlement currency.
1152  bool settlCurrency(StringRef& desc) const
1153  {
1154  return get (Tags::SettlCurrency).toStringRef (desc);
1155  }
1156 
1157  /// DepositType
1159  {
1160  return getIntEnumFieldValue<DepositType>(*this, Tags::DepositType);
1161  }
1162 
1163  /// Issuer of instrument.
1165  {
1166  return getStringRef(Tags::Issuer);
1167  }
1168 
1169  /// Issue date of instrument.
1170  bool issueDate(UInt32& date) const
1171  {
1172  return get(Tags::IssueDate).toNumber(date);
1173  }
1174 
1175  ///
1176  bool roundLot(Decimal& value) const
1177  {
1178  return get(Tags::RoundLot).toNumber(value);
1179  }
1180 
1181  /// The minimum tradable unit of a bond.
1182  bool minTradeVol(Decimal& value) const
1183  {
1184  return get(Tags::MinTradeVol).toNumber(value);
1185  }
1186 
1187  /// QuotingStartTime
1188  bool quotingStartTime(StringRef value) const
1189  {
1190  return get(Tags::QuotingStartTime).toStringRef(value);
1191  }
1192 
1193  /// QuotingEndTime
1194  bool quotingEndTime(StringRef value) const
1195  {
1196  return get(Tags::QuotingEndTime).toStringRef(value);
1197  }
1198 
1199  /// InstrumentAuctionType
1201  {
1202  return getIntEnumFieldValue<InstrumentAuctionType>(*this, Tags::InstrumentAuctionType);
1203  }
1204 
1205  /// Instrument parties.
1207  {
1208  return InstrumentParties ( getOptionalGroup (Tags::NoInstrumentParties) );
1209  }
1210 
1211  /// Underlying symbol.
1213  {
1214  return getStringRef(Tags::UnderlyingSymbol);
1215  }
1216 
1217  /// Instrument identifier of the leg security.
1218  bool couponRate(Decimal& value) const
1219  {
1220  return get(Tags::CouponRate).toNumber(value);
1221  }
1222 
1223  /// Previous coupon payment date.
1225  {
1226  return get(Tags::PreviousCouponPaymentDate).toNumber(value);
1227  }
1228 
1229  /// Upcoming Coupon payment date.
1230  bool couponPaymentDate(UInt32& value) const
1231  {
1232  return get(Tags::CouponPaymentDate).toNumber(value);
1233  }
1234 
1235  /// Defines the Accrued interest Calculation Method.
1237  {
1238  return getIntEnumFieldValue<AccruedInterestCalculationMethod>(*this, Tags::CouponDayCount);
1239  }
1240 
1241  /// Coupon Type
1243  {
1244  return getIntEnumFieldValue<CouponType>(*this, Tags::CouponType);
1245  }
1246 
1247  /// The accrued interest is rounded to the 12th decimal except for Country(421) = HU, rounded to the 7th decimal.
1249  {
1250  return getStringRef(Tags::CountryOfIssue);
1251  }
1252 
1253  /// The Flat Indicator of a bond.
1255  {
1256  return getIntEnumFieldValue<FlatIndicator>(*this, Tags::FlatIndicator);
1257  }
1258 
1259  /// WarrantType
1261  {
1262  return getIntEnumFieldValue<WarrantType>(*this, Tags::WarrantType);
1263  }
1264 
1265  /// CoverIndicator
1267  {
1268  return getIntEnumFieldValue<CoverIndicator>(*this, Tags::CoverIndicator);
1269  }
1270 
1271  /// Reference to Volatility Corridor Table for Opening Auction
1273  {
1274  return get(Tags::VolatilityCorridorOpeningAuction).toNumber(value);
1275  }
1276 
1277  /// Reference to Volatility Corridor Table for Intraday Auction
1279  {
1280  return get(Tags::VolatilityCorridorIntradayAuction).toNumber(value);
1281  }
1282 
1283  /// Reference to Volatility Corridor Table for Closing Auction
1285  {
1286  return get(Tags::VolatilityCorridorClosingAuction).toNumber(value);
1287  }
1288 
1289  /// Reference to Volatility Corridor Table in Continuous
1291  {
1292  return get(Tags::VolatilityCorridorContinuous).toNumber(value);
1293  }
1294 
1295  /// Instrument attributes
1297  {
1298  return InstrumentAttributes ( getOptionalGroup (Tags::NoInstrAttrib) );
1299  }
1300 
1301  /// Events.
1302  Events events() const
1303  {
1304  return Events ( getGroup (Tags::NoEvents) );
1305  }
1306 
1307  /// Instrument Price Precision
1308  bool instrumentPricePrecision (UInt32& value) const
1309  {
1310  return get (Tags::InstrumentPricePrecision).toNumber (value);
1311  }
1312 
1313  /// Defines the minimum price movement in ticks (tick size).
1314  bool minPriceIncrement (Decimal& increment) const
1315  {
1316  return get (Tags::MinPriceIncrement).toNumber (increment);
1317  }
1318 
1319  /// Defines the minimum increment for trade prices in clearing notation (clearing tick size).
1321  {
1322  return get (Tags::MinPriceIncrementClearing).toNumber (price);
1323  }
1324 
1325  /// Defines the minimum price movement in the respective currency (tick value).
1327  {
1328  return getDecimal (Tags::MinPriceIncrementAmount);
1329  }
1330 
1331  /// Actual expiration day of the instrument (YYYYMMDD).
1332  bool maturityDate(Timestamp& date) const
1333  {
1334  UInt32 tmp;
1335  if (get(Tags::MaturityDate).toNumber(tmp))
1336  {
1338  return true;
1339  }
1340  return false;
1341  }
1342 
1343  /// Expiration month (YYYYMM).
1344  bool maturityMonthYear(UInt32& monthYear) const
1345  {
1346  return get(Tags::MaturityMonthYear).toNumber(monthYear);
1347  }
1348 
1349  /// Standard strategy type for complex instruments.
1350  bool securitySubType(UInt32& type) const
1351  {
1352  return get(Tags::SecuritySubType).toNumber(type);
1353  }
1354 
1355  /// Product identifier.
1357  {
1358  return getGroup (Tags::NoMarketSegments).at (0).getUInt32 (Tags::MarketSegmentID);
1359  }
1360 
1361  /// Implied market indicator
1363  {
1364  return getIntEnumFieldValue<ImpliedMarketIndicator> (getGroup (Tags::NoMarketSegments).at (0), Tags::ImpliedMarketIndicator);
1365  }
1366 
1367  /// Multileg model
1369  {
1370  return getIntEnumFieldValue<MultilegModel> (getGroup (Tags::NoMarketSegments).at (0), Tags::MultilegModel);
1371  }
1372 
1373  /// The unit in which an instrument is quoted/stated when buying or selling. Only for cash.
1375  {
1376  return getIntEnumFieldValue<PriceType> (getGroup (Tags::NoMarketSegments).at (0), Tags::PriceType);
1377  }
1378 
1379  /// Only for cash.
1381  {
1382  return getIntEnumFieldValue<PostTradeAnonymityType> (getGroup (Tags::NoMarketSegments).at (0), Tags::PostTradeAnonymity);
1383  }
1384 
1385  /// Settlment Business Days
1386  bool settlBusinessDays (UInt32& value) const
1387  {
1388  return get (Tags::SettlBusinessDays).toNumber (value);
1389  }
1390 
1391  /// Bid side minimum quote quantity.
1393  {
1394  return getGroup (Tags::NoMarketSegments).at(0).getGroup(Tags::NoQuoteSizeRules).at(0).get(Tags::MinBidSize).toNumber(value);
1395  }
1396 
1397  /// Bid side minimum quote quantity.
1398  bool quoteSizeMinOfferSize(Decimal& value) const
1399  {
1400  return getGroup (Tags::NoMarketSegments).at(0).getGroup(Tags::NoQuoteSizeRules).at(0).get(Tags::MinOfferSize).toNumber(value);
1401  }
1402 
1403  /// Bid side minimum quote quantity.
1405  {
1406  return getGroup (Tags::NoMarketSegments).at(0).getGroup(Tags::NoPriceRangeRules).at(0).getUInt32(Tags::PriceRangeRuleID);
1407  }
1408 
1409  ///
1410  bool symbol(StringRef value) const
1411  {
1412  return get(Tags::Symbol).toStringRef(value);
1413  }
1414 
1415  ///
1417  {
1418  return TradingSessionRules(getOptionalGroup(Tags::NoTradingSessionRules));
1419  }
1420 
1421  private:
1422  friend class InstrumentSnapshotWrapper;
1424 
1425  InstrumentSnapshot (const void* impl)
1426  : Message (impl)
1427  {
1428  }
1429  };
1430  }
1431  }
1432 }
InstrumentAttributes instrumentAttributes() const
Instrument attributes.
bool minTradeVol(Decimal &value) const
The minimum tradable unit of a bond.
const Tag NoInstrumentParties
Definition: Tags.h:210
bool minPriceIncrementClearing(Decimal &price) const
Defines the minimum increment for trade prices in clearing notation (clearing tick size)...
MarketSegmentId marketSegmentId() const
Product identifier.
const Tag MinPriceIncrement
Definition: Tags.h:89
PostTradeAnonymityType::Enum postTradeAnonymity() const
Only for cash.
bool legRatioMultiplier(UInt32 &value) const
Common integer multiple of the option legs for Option Volatility Strategies.
bool displayName(StringRef &val) const
Display Name.
const Tag UnderlyingSecurityID
Definition: Tags.h:157
AccruedInterestCalculationMethod::Enum couponDayCount() const
Defines the Accrued interest Calculation Method.
bool instrumentPricePrecision(UInt32 &value) const
Instrument Price Precision.
const Tag NoTradingSessionRules
Definition: Tags.h:232
bool minPriceIncrement(Decimal &increment) const
Defines the minimum price movement in ticks (tick size).
const Tag LowExercisePriceOptionIndicator
Definition: Tags.h:150
bool quotingStartTime(StringRef value) const
QuotingStartTime.
bool contractMonthYear(UInt32 &value)
Contract start month.
InstrumentType::Enum productComplex() const
Type of Market Data update action.
ContractFrequency::Enum contractFrequency() const
Indicates the kind of regular expiration pattern, in the context of ContractCycleType(30865).
bool contractMultiplier(Decimal &multiplier) const
Contract Multiplier.
InstrumentPartyRole::Enum role() const
const Tag ContractDisplayInstruction
Definition: Tags.h:284
bool quoteSizeRuleMinBidSize(Decimal &value) const
Bid side minimum quote quantity.
const Tag VolatilityCorridorIntradayAuction
Definition: Tags.h:308
ValuationMethod::Enum valuationMethod() const
Traditional or futures margin style.
bool volatilityCorridorContinuous(UInt32 &value) const
Reference to Volatility Corridor Table in Continuous.
StringRef id() const
Identifies a party associated with an instrument.
bool cfiCode(StringRef desc) const
Indicates the type of security using ISO 10962 standard.
MultilegModel::Enum multilegModel() const
Multileg model.
bool couponPaymentDate(UInt32 &value) const
Upcoming Coupon payment date.
InstrumentPartyIDSource::Enum idSource() const
const Tag VolatilityCorridorOpeningAuction
Definition: Tags.h:307
bool previousCouponPaymentDate(UInt32 &value) const
Previous coupon payment date.
const Tag TradingSessionSubID
Definition: Tags.h:77
ContractDisplayInstruction::Enum contractDisplayInstruction() const
Defines the instrument display instruction.
const Tag PostTradeAnonymity
Definition: Tags.h:222
bool couponRate(Decimal &value) const
Instrument identifier of the leg security.
DepositType::Enum depositType() const
DepositType.
const Tag InstrumentPartyRoleQualifier
Definition: Tags.h:216
bool settlCurrency(StringRef &desc) const
Settlement currency.
bool displayRelativeDay(UInt32 &value)
Display Relative Day.
const Tag InstrumentPartyRole
Definition: Tags.h:215
bool displayMonth(UInt32 &value)
Display Month.
StringRef issuer() const
Issuer of instrument.
bool transactTime(UInt64 &time) const
Transact Time.
bool securityDesc(StringRef &desc) const
Security description.
InstrumentAuctionType::Enum instrumentAuctionType() const
InstrumentAuctionType.
PriceType::Enum priceType() const
The unit in which an instrument is quoted/stated when buying or selling. Only for cash...
const Tag InstrumentPartyIDSource
Definition: Tags.h:214
const Tag VolatilityCorridorContinuous
Definition: Tags.h:310
SecurityId securityId() const
Instrument identifier.
bool eventType(UInt32 &type) const
Event Type.
bool optAttribute(UInt32 &attribute) const
Version of an option. Version can change as a result of corporate actions or events.
const Tag MinPriceIncrementAmount
Definition: Tags.h:97
DisplaySeason::Enum displaySeason() const
Defines the instrument display instruction.
unsigned int UInt32
Definition: Numeric.h:41
Definition: Defines.h:30
Decimal type for better precision.
Definition: Numeric.h:63
const Tag LegRatioMultiplier
Definition: Tags.h:287
const Tag InstrumentPricePrecision
Definition: Tags.h:149
TradingSessionSubID::Enum tradingSessionSubID() const
Defines the trading session sub ID.
bool volatilityCorridorIntradayAuction(UInt32 &value) const
Reference to Volatility Corridor Table for Intraday Auction.
Indicates timestamp in "YYYYMMDD" format.
Definition: Timestamp.h:70
bool quotingEndTime(StringRef value) const
QuotingEndTime.
Int64 SecurityId
Alias for Security Id type.
Definition: Defines.h:51
StringRef currency() const
Currency as published in ISO 4217.
const Tag ContractGenerationNumber
Definition: Tags.h:121
InstrumentSnapshotLegs legs() const
Legs.
bool securitySubType(UInt32 &type) const
Standard strategy type for complex instruments.
bool contractGenerationNumber(UInt32 &number) const
Contract generation.
UInt32 tradingSessionID() const
Trading Session ID.
const Tag UnderlyingMarketSegmentID
Definition: Tags.h:289
bool issueDate(UInt32 &date) const
Issue date of instrument.
const Tag StrikePricePrecision
Definition: Tags.h:148
ExerciseStyle::Enum exerciseStyle() const
Exercise Style.
bool quoteSizeMinOfferSize(Decimal &value) const
Bid side minimum quote quantity.
const Tag DisplayRelativeDay
Definition: Tags.h:299
ImpliedMarketIndicator::Enum impliedMarketIndicator() const
Implied market indicator.
bool securityExchange(StringRef &exchange) const
MIC (ISO 10383), used to identify an instrument of a co-operation partner.
bool underlyingMarketSegmentID(UInt32 &val) const
Refers to MarketSegmentID (1300) from the underlying Product Snapshot.
bool underlyingSecurityID(Int64 &val) const
Refers to SecurityID (48) from the underlying Instrument Snapshot.
bool contractDate(UInt32 &value)
Actual contract start date.
FlatIndicator::Enum flatIndicator() const
The Flat Indicator of a bond.
Represents timestamp without time-zone information.
Definition: Timestamp.h:87
bool maturityMonthYear(UInt32 &monthYear) const
Expiration month (YYYYMM).
CoverIndicator::Enum coverIndicator() const
CoverIndicator.
bool displayDay(UInt32 &value)
Display Day.
bool isPrimary() const
Defines, if this contract based on its contract generation cycle, is considered primary.
ContractCycleSubType::Enum contractCycleSubType() const
Indicates the kind of regular expiration pattern, in the context of ContractCycleType(30865).
ContractIdentificationEligibility::Enum contractIdentificationEligibility() const
Defines the granularity which suffice to identify a standard e.g. non - flexible contract uniquely wi...
SecurityType::Enum securityType() const
Type of security.
ContractCycleType::Enum contractCycleType() const
Defines the instrument cycle type.
bool strikePricePrecision(UInt32 &precision) const
Strike Price Precision.
const Tag SecurityAltIDSource
Definition: Tags.h:68
bool settlBusinessDays(UInt32 &value) const
Settlment Business Days.
bool lowExercisePriceOptionIndicator() const
Lepo Flag.
bool assetSubType(UInt32 &val) const
AssetSubType.
StringRef securityAltID() const
Alternate instrument identifier.
bool priorSettlPrice(Decimal &price) const
Previous day&#39;s settlement price. Converted in trading notation in case of variance futures...
CouponType::Enum couponType() const
Coupon Type.
WarrantType::Enum warrantType() const
WarrantType.
InstrumentParties instrumentParties() const
Instrument parties.
StringRef countryOfIssue() const
The accrued interest is rounded to the 12th decimal except for Country(421) = HU, rounded to the 7th ...
const Tag ContractMultiplier
Definition: Tags.h:51
Exposes list of Instrument scope operators.
SecurityStatus::Enum securityStatus() const
Security Status.
const Tag ContractCycleSubType
Definition: Tags.h:295
bool volatilityCorridorClosingAuction(UInt32 &value) const
Reference to Volatility Corridor Table for Closing Auction.
bool volatilityCorridorOpeningAuction(UInt32 &value) const
Reference to Volatility Corridor Table for Opening Auction.
PutOrCall::Enum putOrCall() const
Put Or Call.
InstrumentPartyRoleQualifier::Enum roleQualifier() const
InstrumentAttributeType::Enum type() const
const Tag ImpliedMarketIndicator
Definition: Tags.h:96
Decimal minPriceIncrementAmount() const
Defines the minimum price movement in the respective currency (tick value).
UInt32 eventDate() const
Event Date.
UInt32 MarketSegmentId
Alias for Market Segment ID type.
Definition: Defines.h:40
const Tag ContractIdentificationEligibility
Definition: Tags.h:293
bool origStrikePrice(Decimal &price) const
Original strike price prior to corporate action, e.g. 5.20.
Alternate identifier entry.
const Tag PreviousCouponPaymentDate
Definition: Tags.h:247
bool strikePrice(Decimal &price) const
Strike Price.
const Tag InstrumentAuctionType
Definition: Tags.h:267
StringRef underlyingSymbol() const
Underlying symbol.
const Tag MinPriceIncrementClearing
Definition: Tags.h:220
bool refTickTableID(UInt32 &time) const
Reference to tick size table identifier from product level message.
const Tag MaturityMonthYear
Definition: Tags.h:46
bool unitOfMeasure(StringRef &val) const
UnitOfMeasure.
StringRef securityAltIDSource() const
Security alternate id source.
const Tag VolatilityCorridorClosingAuction
Definition: Tags.h:309
SecurityAlts securityAlts() const
Entries.
bool displayWeek(UInt32 &value)
Display Week.
UInt32 priceRangeRuleID() const
Bid side minimum quote quantity.
static Timestamp parse(const std::string &, TimestampFormat::Enum=TimestampFormat::YYYYMMDDHHMMSSNsec)
bool assetType(UInt32 &val) const
AssetType.
bool displayQuarter(UInt32 &value)
The Display Quarter denotes the three-month period inside a year.
bool displayYear(UInt32 &value)
Display Year.
const Tag SecurityExchange
Definition: Tags.h:50
bool maturityDate(Timestamp &date) const
Actual expiration day of the instrument (YYYYMMDD).
Exposes list of available security types.