OnixS C++ CBOE CFE Binary Order Entry (BOE) Handler 1.12.3
API Documentation
Loading...
Searching...
No Matches
NewComplexInstrument.Leg.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
28
29
30namespace OnixS {
31namespace CboeCFE {
32namespace Trading {
33namespace BOE {
34
36 struct ONIXS_CBOE_CFE_BOE_API Leg
37 {
39 StrRef symbol() const
40 {
41 return symbol_;
42 }
43
45 void symbol(StrRef value)
46 {
47 symbol_ = value;
48 }
49
52 {
53 return ratioQty_;
54 }
55
57 void ratioQty(Binary4 value)
58 {
59 ratioQty_ = value;
60 }
61
64 {
65 return side_;
66 }
67
69 void side(Side::Enum value)
70 {
71 side_ = value;
72 }
73
74
76 std::string toString() const;
77
78 private:
79 size_t serializeTo(unsigned char*) const ONIXS_BATS_BOE_NOEXCEPT;
80
81 Alphanumeric<8> symbol_;
82 Binary4 ratioQty_;
83 Side::Enum side_;
84
85 friend class Serializer;
86 };
87
89 ONIXS_CBOE_CFE_BOE_API void toStr(std::string&, const Leg&);
90
92 inline std::string toStr(const Leg& value)
93 {
94 std::string str;
95 toStr(str, value);
96 return str;
97 }
98
99}
100}
101}
102}
#define ONIXS_BATS_BOE_NOEXCEPT
Definition ABI.h:49
Provides efficient way of accessing text-based field values.
Definition String.h:46
void toStr(std::string &str, const FixedPointDecimal< Mantissa, Exponent > &number)
Serializes fixed-point decimal into a string.
Definition Decimal.h:156
std::string toString() const
Returns the text representation.
void ratioQty(Binary4 value)
Ratio of number of contracts in this leg per order quantity.
void side(Side::Enum value)
Leg Side.
void symbol(StrRef value)
The symbol id for the simple Options on Futures instrument.
Binary4 ratioQty() const
Ratio of number of contracts in this leg per order quantity.
StrRef symbol() const
The symbol id for the simple Options on Futures instrument.