OnixS C++ Tradeweb Approved Publication Arrangement (APA) Handler  1.2.2.18
API documentation
ExecutionReportWithIsin.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 
22 #include <vector>
23 
29 
30 
31 namespace OnixS {
32 namespace Tradeweb {
33 namespace MarketData {
34 namespace Apa {
35 
36  /// An execution report with ISIN is sent when an execution is made public and the execution was reported with an ISIN.
38  {
39  /// Date and time when the transaction was executed.
41  {
42  return ordinary<Integer8>(24);
43  }
44 
45  /// Code used to identify the financial instrument.
47  {
48  return fixedStr<12>(32);
49  }
50 
51  /// Number of transactions represented by this report.
53  {
54  return ordinary<Integer8>(44);
55  }
56 
57  /// Price represented as described in the PrcFormat field.
58  bool price(Decimal& value) const
59  {
60  return Decimal::tryParse(&ordinary<Char>(52), 20, value);
61  }
62 
63  /// Format of the subsequent price field.
65  {
66  return fixedStr<4>(72);
67  }
68 
69  /// Currency in which the price is expressed.
71  {
72  return fixedStr<3>(76);
73  }
74 
75  /// Identification of the venue where the transaction was executed.
77  {
78  return fixedStr<4>(79);
79  }
80 
81  /// Indication of the measurement units in which the quantity in measurement unit is expressed.
83  {
84  return fixedStr<25>(83);
85  }
86 
87  /// The equivalent amount of commodity traded expressed in measurement unit.
88  bool qtyInMeasurementUnit(Decimal& value) const
89  {
90  return Decimal::tryParse(&ordinary<Char>(108), 20, value);
91  }
92 
93  /// The number of units of the financial instrument, or the number of derivative contracts in the transaction.
94  bool qty(Decimal& value) const
95  {
96  return Decimal::tryParse(&ordinary<Char>(128), 20, value);
97  }
98 
99  /// Nominal amount or notional amount.
100  bool notionalAmount(Decimal& value) const
101  {
102  return Decimal::tryParse(&ordinary<Char>(148), 20, value);
103  }
104 
105  /// Currency in which the notional is denominated.
107  {
108  return fixedStr<3>(168);
109  }
110 
111  /// For emission allowances and emission allowance derivatives only.
112  StrRef type() const
113  {
114  return fixedStr<4>(171);
115  }
116 
117  /// Date and time when the transaction was published by a trading venue or APA.
119  {
120  return ordinary<Integer8>(175);
121  }
122 
123  /// Code assigned by trading venues.
125  {
126  return fixedStr<52>(183);
127  }
128 
129  /// For derivatives. Code to identify whether the transaction will be cleared.
131  {
132  return enumeration<TransactionToBeCleared>(235);
133  }
134 
135  ///
136  Integer4 flags() const
137  {
138  return ordinary<Integer4>(236);
139  }
140 
141  ///
143  {
144  return ordinary<Integer2>(240);
145  }
146 
147  ///
149  {
150  return enumeration<PublicationType>(242);
151  }
152 
153  /// Code assigned by trading venues.
155  {
156  return fixedStr<52>(243);
157  }
158 
159  /// Initializes instance over given memory block.
160  ExecutionReportWithIsinMsg(const void* data, MessageSize size)
161  : BinaryMessage(data, size)
162  {
163  }
164  };
165 
166  /// Serializes object into string.
167  ONIXS_TRADEWEB_APA_API void toStr(std::string&, const ExecutionReportWithIsinMsg&);
168 
169  /// Serializes object into string.
170  inline std::string toStr(const ExecutionReportWithIsinMsg& msg)
171  {
172  std::string str;
173  toStr(str, msg);
174  return str;
175  }
176 
177 }
178 }
179 }
180 }
bool price(Decimal &value) const
Price represented as described in the PrcFormat field.
StrRef prcCurrency() const
Currency in which the price is expressed.
An execution report with ISIN is sent when an execution is made public and the execution was reported...
StrRef qtyNotation() const
Indication of the measurement units in which the quantity in measurement unit is expressed.
Integer8 transactionCount() const
Number of transactions represented by this report.
bool notionalAmount(Decimal &value) const
Nominal amount or notional amount.
StrRef instrumentId() const
Code used to identify the financial instrument.
StrRef transactionIdentificationCode() const
Code assigned by trading venues.
static bool tryParse(const char *buffer, size_t bufferSize, Decimal &)
Encapsulates services for manipulating little endian encoded messages.
bool qtyInMeasurementUnit(Decimal &value) const
The equivalent amount of commodity traded expressed in measurement unit.
Integer2 MessageSize
Aliases message length type.
Integer8 publicationDateTime() const
Date and time when the transaction was published by a trading venue or APA.
Provides efficient way of accessing text-based FIX field values.
Definition: String.h:43
bool qty(Decimal &value) const
The number of units of the financial instrument, or the number of derivative contracts in the transac...
StrRef originalTransactionIdentificationCode() const
Code assigned by trading venues.
StrRef prcNotation() const
Format of the subsequent price field.
ExecutionReportWithIsinMsg(const void *data, MessageSize size)
Initializes instance over given memory block.
Integer8 tradingDate() const
Date and time when the transaction was executed.
void toStr(std::string &str, const Decimal &value)
Definition: Decimal.h:251
StrRef executionVenue() const
Identification of the venue where the transaction was executed.
StrRef notionalCurrency() const
Currency in which the notional is denominated.
StrRef type() const
For emission allowances and emission allowance derivatives only.
TransactionToBeCleared::Enum transactionToBeCleared() const
For derivatives. Code to identify whether the transaction will be cleared.