OnixS C++ FMX UST BIMP Market Data Handler 1.2.0
API documentation
Loading...
Searching...
No Matches
Defines.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
26
27#include <string>
28#include <ostream>
29#include <set>
30
31
32namespace OnixS
33{
34 namespace FmxUST
35 {
36 namespace MarketData
37 {
38 namespace Bimp
39 {
41 struct ONIXS_FMXUST_BIMP_API DataSource
42 {
45
46 enum Origin
47 {
49 Replay = 1,
50 Spin = 2
51 };
52
55
58
61
64
67
69 bool cached;
70
71 std::string toString () const;
72 };
73
74 typedef UInt8 Integer1;
75 typedef UInt16 Integer2;
76 typedef UInt32 Integer4;
77 typedef UInt64 Integer8;
78
79 typedef UInt8 SignedInteger1;
80 typedef UInt16 SignedInteger2;
81 typedef UInt32 SignedInteger4;
82 typedef UInt64 SignedInteger8;
83
86
89
92
95
98
101
102 typedef UInt8 BitField;
103
104 ONIXS_FMXUST_BIMP_API std::ostream& operator << (std::ostream& stream, const DataSource& ds);
105
107 typedef size_t CpuIndex;
108
110 class ONIXS_FMXUST_BIMP_API ThreadAffinity
111 {
112 typedef std::set<CpuIndex> CpuIndexes;
113
114 public:
117
120
123
125 bool empty() const;
126
128 void copyTo(CpuIndexes&) const;
129
131 bool insert(CpuIndex index);
132
134 bool erase(CpuIndex index);
135
137 void clear();
138
140 ThreadAffinity& operator = (const ThreadAffinity&);
141
143 std::string toString() const;
144
145 private:
146
148 CpuIndexes* indices_;
149 };
150 }
151 }
152 }
153}
std::string toString() const
Returns the string representation.
ThreadAffinity(const ThreadAffinity &)
Initializes as copy of other set.
bool empty() const
Indicates whether is empty.
~ThreadAffinity()
Utilizes all the resources.
bool erase(CpuIndex index)
Removes CPU index from the set.
bool insert(CpuIndex index)
Adds CPU index into set.
void copyTo(CpuIndexes &) const
Copies set into another set.
Represents time point without time-zone information.
Definition Time.h:483
Integer2 MessageSize
Aliases message length type.
Definition Defines.h:100
size_t CpuIndex
Zero-based index of CPU.
Definition Defines.h:107
Integer8 SequenceNumber
Alias for Sequence Number type.
Definition Defines.h:85
Integer8 Quantity
Alias for Quantity type.
Definition Defines.h:97
SignedInteger8 Price
Alias for Order Id type.
Definition Defines.h:94
Integer8 OrderId
Alias for Order Id type.
Definition Defines.h:91
Integer8 InstrumentId
Alias for Instrument Id type.
Definition Defines.h:88
ONIXS_FMXUST_BIMP_API std::ostream & operator<<(std::ostream &stream, const ServiceDescriptor &descriptor)
Origin origin
the way data received
Definition Defines.h:66
UInt16 packetMessageCount
Message sequence number.
Definition Defines.h:57
UInt8 packetMessageNumber
Number of message in packet.
Definition Defines.h:60
bool cached
The packet was cached due to incorrect sequence.
Definition Defines.h:69
Timestamp packetReceptionTime
Time when the packet was received by Handler from UDP, in system ticks,.
Definition Defines.h:54
UInt64 messageSeqNum
Message sequence number.
Definition Defines.h:63