ExecutionReport.h 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307
  1. #ifndef FIX43_EXECUTIONREPORT_H
  2. #define FIX43_EXECUTIONREPORT_H
  3. #include "Message.h"
  4. namespace FIX43
  5. {
  6. class ExecutionReport : public Message
  7. {
  8. public:
  9. ExecutionReport() : Message(MsgType()) {}
  10. ExecutionReport(const FIX::Message& m) : Message(m) {}
  11. ExecutionReport(const Message& m) : Message(m) {}
  12. ExecutionReport(const ExecutionReport& m) : Message(m) {}
  13. static FIX::MsgType MsgType() { return FIX::MsgType("8"); }
  14. ExecutionReport(
  15. const FIX::OrderID& aOrderID,
  16. const FIX::ExecID& aExecID,
  17. const FIX::ExecType& aExecType,
  18. const FIX::OrdStatus& aOrdStatus,
  19. const FIX::Side& aSide,
  20. const FIX::LeavesQty& aLeavesQty,
  21. const FIX::CumQty& aCumQty,
  22. const FIX::AvgPx& aAvgPx )
  23. : Message(MsgType())
  24. {
  25. set(aOrderID);
  26. set(aExecID);
  27. set(aExecType);
  28. set(aOrdStatus);
  29. set(aSide);
  30. set(aLeavesQty);
  31. set(aCumQty);
  32. set(aAvgPx);
  33. }
  34. FIELD_SET(*this, FIX::OrderID);
  35. FIELD_SET(*this, FIX::SecondaryOrderID);
  36. FIELD_SET(*this, FIX::SecondaryClOrdID);
  37. FIELD_SET(*this, FIX::SecondaryExecID);
  38. FIELD_SET(*this, FIX::ClOrdID);
  39. FIELD_SET(*this, FIX::OrigClOrdID);
  40. FIELD_SET(*this, FIX::ClOrdLinkID);
  41. FIELD_SET(*this, FIX::NoPartyIDs);
  42. class NoPartyIDs: public FIX::Group
  43. {
  44. public:
  45. NoPartyIDs() : FIX::Group(453,448,FIX::message_order(448,447,452,523,0)) {}
  46. FIELD_SET(*this, FIX::PartyID);
  47. FIELD_SET(*this, FIX::PartyIDSource);
  48. FIELD_SET(*this, FIX::PartyRole);
  49. FIELD_SET(*this, FIX::PartySubID);
  50. };
  51. FIELD_SET(*this, FIX::TradeOriginationDate);
  52. FIELD_SET(*this, FIX::ListID);
  53. FIELD_SET(*this, FIX::CrossID);
  54. FIELD_SET(*this, FIX::OrigCrossID);
  55. FIELD_SET(*this, FIX::CrossType);
  56. FIELD_SET(*this, FIX::ExecID);
  57. FIELD_SET(*this, FIX::ExecRefID);
  58. FIELD_SET(*this, FIX::ExecType);
  59. FIELD_SET(*this, FIX::OrdStatus);
  60. FIELD_SET(*this, FIX::WorkingIndicator);
  61. FIELD_SET(*this, FIX::OrdRejReason);
  62. FIELD_SET(*this, FIX::ExecRestatementReason);
  63. FIELD_SET(*this, FIX::Account);
  64. FIELD_SET(*this, FIX::AccountType);
  65. FIELD_SET(*this, FIX::DayBookingInst);
  66. FIELD_SET(*this, FIX::BookingUnit);
  67. FIELD_SET(*this, FIX::PreallocMethod);
  68. FIELD_SET(*this, FIX::SettlmntTyp);
  69. FIELD_SET(*this, FIX::FutSettDate);
  70. FIELD_SET(*this, FIX::CashMargin);
  71. FIELD_SET(*this, FIX::ClearingFeeIndicator);
  72. FIELD_SET(*this, FIX::Symbol);
  73. FIELD_SET(*this, FIX::SymbolSfx);
  74. FIELD_SET(*this, FIX::SecurityID);
  75. FIELD_SET(*this, FIX::SecurityIDSource);
  76. FIELD_SET(*this, FIX::Product);
  77. FIELD_SET(*this, FIX::CFICode);
  78. FIELD_SET(*this, FIX::SecurityType);
  79. FIELD_SET(*this, FIX::MaturityMonthYear);
  80. FIELD_SET(*this, FIX::MaturityDate);
  81. FIELD_SET(*this, FIX::CouponPaymentDate);
  82. FIELD_SET(*this, FIX::IssueDate);
  83. FIELD_SET(*this, FIX::RepoCollateralSecurityType);
  84. FIELD_SET(*this, FIX::RepurchaseTerm);
  85. FIELD_SET(*this, FIX::RepurchaseRate);
  86. FIELD_SET(*this, FIX::Factor);
  87. FIELD_SET(*this, FIX::CreditRating);
  88. FIELD_SET(*this, FIX::InstrRegistry);
  89. FIELD_SET(*this, FIX::CountryOfIssue);
  90. FIELD_SET(*this, FIX::StateOrProvinceOfIssue);
  91. FIELD_SET(*this, FIX::LocaleOfIssue);
  92. FIELD_SET(*this, FIX::RedemptionDate);
  93. FIELD_SET(*this, FIX::StrikePrice);
  94. FIELD_SET(*this, FIX::OptAttribute);
  95. FIELD_SET(*this, FIX::ContractMultiplier);
  96. FIELD_SET(*this, FIX::CouponRate);
  97. FIELD_SET(*this, FIX::SecurityExchange);
  98. FIELD_SET(*this, FIX::Issuer);
  99. FIELD_SET(*this, FIX::EncodedIssuerLen);
  100. FIELD_SET(*this, FIX::EncodedIssuer);
  101. FIELD_SET(*this, FIX::SecurityDesc);
  102. FIELD_SET(*this, FIX::EncodedSecurityDescLen);
  103. FIELD_SET(*this, FIX::EncodedSecurityDesc);
  104. FIELD_SET(*this, FIX::NoSecurityAltID);
  105. class NoSecurityAltID: public FIX::Group
  106. {
  107. public:
  108. NoSecurityAltID() : FIX::Group(454,455,FIX::message_order(455,456,0)) {}
  109. FIELD_SET(*this, FIX::SecurityAltID);
  110. FIELD_SET(*this, FIX::SecurityAltIDSource);
  111. };
  112. FIELD_SET(*this, FIX::Side);
  113. FIELD_SET(*this, FIX::NoStipulations);
  114. class NoStipulations: public FIX::Group
  115. {
  116. public:
  117. NoStipulations() : FIX::Group(232,233,FIX::message_order(233,234,0)) {}
  118. FIELD_SET(*this, FIX::StipulationType);
  119. FIELD_SET(*this, FIX::StipulationValue);
  120. };
  121. FIELD_SET(*this, FIX::QuantityType);
  122. FIELD_SET(*this, FIX::OrderQty);
  123. FIELD_SET(*this, FIX::CashOrderQty);
  124. FIELD_SET(*this, FIX::OrderPercent);
  125. FIELD_SET(*this, FIX::RoundingDirection);
  126. FIELD_SET(*this, FIX::RoundingModulus);
  127. FIELD_SET(*this, FIX::OrdType);
  128. FIELD_SET(*this, FIX::PriceType);
  129. FIELD_SET(*this, FIX::Price);
  130. FIELD_SET(*this, FIX::StopPx);
  131. FIELD_SET(*this, FIX::PegDifference);
  132. FIELD_SET(*this, FIX::DiscretionInst);
  133. FIELD_SET(*this, FIX::DiscretionOffset);
  134. FIELD_SET(*this, FIX::Currency);
  135. FIELD_SET(*this, FIX::ComplianceID);
  136. FIELD_SET(*this, FIX::SolicitedFlag);
  137. FIELD_SET(*this, FIX::TimeInForce);
  138. FIELD_SET(*this, FIX::EffectiveTime);
  139. FIELD_SET(*this, FIX::ExpireDate);
  140. FIELD_SET(*this, FIX::ExpireTime);
  141. FIELD_SET(*this, FIX::ExecInst);
  142. FIELD_SET(*this, FIX::OrderCapacity);
  143. FIELD_SET(*this, FIX::OrderRestrictions);
  144. FIELD_SET(*this, FIX::CustOrderCapacity);
  145. FIELD_SET(*this, FIX::Rule80A);
  146. FIELD_SET(*this, FIX::LastQty);
  147. FIELD_SET(*this, FIX::UnderlyingLastQty);
  148. FIELD_SET(*this, FIX::LastPx);
  149. FIELD_SET(*this, FIX::UnderlyingLastPx);
  150. FIELD_SET(*this, FIX::LastSpotRate);
  151. FIELD_SET(*this, FIX::LastForwardPoints);
  152. FIELD_SET(*this, FIX::LastMkt);
  153. FIELD_SET(*this, FIX::TradingSessionID);
  154. FIELD_SET(*this, FIX::TradingSessionSubID);
  155. FIELD_SET(*this, FIX::LastCapacity);
  156. FIELD_SET(*this, FIX::LeavesQty);
  157. FIELD_SET(*this, FIX::CumQty);
  158. FIELD_SET(*this, FIX::AvgPx);
  159. FIELD_SET(*this, FIX::DayOrderQty);
  160. FIELD_SET(*this, FIX::DayCumQty);
  161. FIELD_SET(*this, FIX::DayAvgPx);
  162. FIELD_SET(*this, FIX::GTBookingInst);
  163. FIELD_SET(*this, FIX::TradeDate);
  164. FIELD_SET(*this, FIX::TransactTime);
  165. FIELD_SET(*this, FIX::ReportToExch);
  166. FIELD_SET(*this, FIX::Commission);
  167. FIELD_SET(*this, FIX::CommType);
  168. FIELD_SET(*this, FIX::CommCurrency);
  169. FIELD_SET(*this, FIX::FundRenewWaiv);
  170. FIELD_SET(*this, FIX::Spread);
  171. FIELD_SET(*this, FIX::BenchmarkCurveCurrency);
  172. FIELD_SET(*this, FIX::BenchmarkCurveName);
  173. FIELD_SET(*this, FIX::BenchmarkCurvePoint);
  174. FIELD_SET(*this, FIX::YieldType);
  175. FIELD_SET(*this, FIX::Yield);
  176. FIELD_SET(*this, FIX::GrossTradeAmt);
  177. FIELD_SET(*this, FIX::NumDaysInterest);
  178. FIELD_SET(*this, FIX::ExDate);
  179. FIELD_SET(*this, FIX::AccruedInterestRate);
  180. FIELD_SET(*this, FIX::AccruedInterestAmt);
  181. FIELD_SET(*this, FIX::TradedFlatSwitch);
  182. FIELD_SET(*this, FIX::BasisFeatureDate);
  183. FIELD_SET(*this, FIX::BasisFeaturePrice);
  184. FIELD_SET(*this, FIX::Concession);
  185. FIELD_SET(*this, FIX::TotalTakedown);
  186. FIELD_SET(*this, FIX::NetMoney);
  187. FIELD_SET(*this, FIX::SettlCurrAmt);
  188. FIELD_SET(*this, FIX::SettlCurrency);
  189. FIELD_SET(*this, FIX::SettlCurrFxRate);
  190. FIELD_SET(*this, FIX::SettlCurrFxRateCalc);
  191. FIELD_SET(*this, FIX::HandlInst);
  192. FIELD_SET(*this, FIX::MinQty);
  193. FIELD_SET(*this, FIX::MaxFloor);
  194. FIELD_SET(*this, FIX::PositionEffect);
  195. FIELD_SET(*this, FIX::MaxShow);
  196. FIELD_SET(*this, FIX::Text);
  197. FIELD_SET(*this, FIX::EncodedTextLen);
  198. FIELD_SET(*this, FIX::EncodedText);
  199. FIELD_SET(*this, FIX::FutSettDate2);
  200. FIELD_SET(*this, FIX::OrderQty2);
  201. FIELD_SET(*this, FIX::LastForwardPoints2);
  202. FIELD_SET(*this, FIX::MultiLegReportingType);
  203. FIELD_SET(*this, FIX::CancellationRights);
  204. FIELD_SET(*this, FIX::MoneyLaunderingStatus);
  205. FIELD_SET(*this, FIX::RegistID);
  206. FIELD_SET(*this, FIX::Designation);
  207. FIELD_SET(*this, FIX::TransBkdTime);
  208. FIELD_SET(*this, FIX::ExecValuationPoint);
  209. FIELD_SET(*this, FIX::ExecPriceType);
  210. FIELD_SET(*this, FIX::ExecPriceAdjustment);
  211. FIELD_SET(*this, FIX::PriorityIndicator);
  212. FIELD_SET(*this, FIX::PriceImprovement);
  213. FIELD_SET(*this, FIX::NoContraBrokers);
  214. class NoContraBrokers: public FIX::Group
  215. {
  216. public:
  217. NoContraBrokers() : FIX::Group(382,375,FIX::message_order(375,337,437,438,655,0)) {}
  218. FIELD_SET(*this, FIX::ContraBroker);
  219. FIELD_SET(*this, FIX::ContraTrader);
  220. FIELD_SET(*this, FIX::ContraTradeQty);
  221. FIELD_SET(*this, FIX::ContraTradeTime);
  222. FIELD_SET(*this, FIX::ContraLegRefID);
  223. };
  224. FIELD_SET(*this, FIX::NoContAmts);
  225. class NoContAmts: public FIX::Group
  226. {
  227. public:
  228. NoContAmts() : FIX::Group(518,519,FIX::message_order(519,520,521,0)) {}
  229. FIELD_SET(*this, FIX::ContAmtType);
  230. FIELD_SET(*this, FIX::ContAmtValue);
  231. FIELD_SET(*this, FIX::ContAmtCurr);
  232. };
  233. FIELD_SET(*this, FIX::NoLegs);
  234. class NoLegs: public FIX::Group
  235. {
  236. public:
  237. NoLegs() : FIX::Group(555,600,FIX::message_order(600,601,602,603,604,607,608,609,610,611,248,249,250,251,252,253,257,599,596,597,598,254,612,613,614,615,616,617,618,619,620,621,622,623,624,564,565,539,654,566,587,588,637,0)) {}
  238. FIELD_SET(*this, FIX::LegSymbol);
  239. FIELD_SET(*this, FIX::LegSymbolSfx);
  240. FIELD_SET(*this, FIX::LegSecurityID);
  241. FIELD_SET(*this, FIX::LegSecurityIDSource);
  242. FIELD_SET(*this, FIX::LegProduct);
  243. FIELD_SET(*this, FIX::LegCFICode);
  244. FIELD_SET(*this, FIX::LegSecurityType);
  245. FIELD_SET(*this, FIX::LegMaturityMonthYear);
  246. FIELD_SET(*this, FIX::LegMaturityDate);
  247. FIELD_SET(*this, FIX::LegCouponPaymentDate);
  248. FIELD_SET(*this, FIX::LegIssueDate);
  249. FIELD_SET(*this, FIX::LegRepoCollateralSecurityType);
  250. FIELD_SET(*this, FIX::LegRepurchaseTerm);
  251. FIELD_SET(*this, FIX::LegRepurchaseRate);
  252. FIELD_SET(*this, FIX::LegFactor);
  253. FIELD_SET(*this, FIX::LegCreditRating);
  254. FIELD_SET(*this, FIX::LegInstrRegistry);
  255. FIELD_SET(*this, FIX::LegCountryOfIssue);
  256. FIELD_SET(*this, FIX::LegStateOrProvinceOfIssue);
  257. FIELD_SET(*this, FIX::LegLocaleOfIssue);
  258. FIELD_SET(*this, FIX::LegRedemptionDate);
  259. FIELD_SET(*this, FIX::LegStrikePrice);
  260. FIELD_SET(*this, FIX::LegOptAttribute);
  261. FIELD_SET(*this, FIX::LegContractMultiplier);
  262. FIELD_SET(*this, FIX::LegCouponRate);
  263. FIELD_SET(*this, FIX::LegSecurityExchange);
  264. FIELD_SET(*this, FIX::LegIssuer);
  265. FIELD_SET(*this, FIX::EncodedLegIssuerLen);
  266. FIELD_SET(*this, FIX::EncodedLegIssuer);
  267. FIELD_SET(*this, FIX::LegSecurityDesc);
  268. FIELD_SET(*this, FIX::EncodedLegSecurityDescLen);
  269. FIELD_SET(*this, FIX::EncodedLegSecurityDesc);
  270. FIELD_SET(*this, FIX::LegRatioQty);
  271. FIELD_SET(*this, FIX::LegSide);
  272. FIELD_SET(*this, FIX::NoLegSecurityAltID);
  273. class NoLegSecurityAltID: public FIX::Group
  274. {
  275. public:
  276. NoLegSecurityAltID() : FIX::Group(604,605,FIX::message_order(605,606,0)) {}
  277. FIELD_SET(*this, FIX::LegSecurityAltID);
  278. FIELD_SET(*this, FIX::LegSecurityAltIDSource);
  279. };
  280. FIELD_SET(*this, FIX::LegPositionEffect);
  281. FIELD_SET(*this, FIX::LegCoveredOrUncovered);
  282. FIELD_SET(*this, FIX::NoNestedPartyIDs);
  283. class NoNestedPartyIDs: public FIX::Group
  284. {
  285. public:
  286. NoNestedPartyIDs() : FIX::Group(539,524,FIX::message_order(524,525,538,545,0)) {}
  287. FIELD_SET(*this, FIX::NestedPartyID);
  288. FIELD_SET(*this, FIX::NestedPartyIDSource);
  289. FIELD_SET(*this, FIX::NestedPartyRole);
  290. FIELD_SET(*this, FIX::NestedPartySubID);
  291. };
  292. FIELD_SET(*this, FIX::LegRefID);
  293. FIELD_SET(*this, FIX::LegPrice);
  294. FIELD_SET(*this, FIX::LegSettlmntTyp);
  295. FIELD_SET(*this, FIX::LegFutSettDate);
  296. FIELD_SET(*this, FIX::LegLastPx);
  297. };
  298. };
  299. }
  300. #endif