JayBeams  0.1
Another project to have fun coding.
feed_id.hpp
Go to the documentation of this file.
1 #ifndef jb_mktdata_feed_id_hpp
2 #define jb_mktdata_feed_id_hpp
3 
4 #include <boost/endian/buffers.hpp>
5 
6 namespace jb {
7 namespace mktdata {
8 
9 /**
10  * Identifiers for market feeds.
11  *
12  * Each feed in JayBeams receives a unique identifier, for example,
13  * the Nasdaq OMX feed over ITCH-5.x will have a different name than
14  * the PSX feed over ITCH-5.x. This is useful for applications that
15  * want to detect bad feeds and name them, or simply for
16  * debugability.
17  */
18 struct feed_id {
19  /// The JayBeams internal identifier for the feed
20  boost::endian::little_uint32_buf_t id;
21 
22  /// The size for a feed name, in bytes
23  static constexpr std::size_t feed_name_size = 16;
24 };
25 
26 } // namespace mktdata
27 } // namespace jb
28 
29 #endif // jb_mktdata_feed_id_hpp
Identifiers for market feeds.
Definition: feed_id.hpp:18
static constexpr std::size_t feed_name_size
The size for a feed name, in bytes.
Definition: feed_id.hpp:23
boost::endian::little_uint32_buf_t id
The JayBeams internal identifier for the feed.
Definition: feed_id.hpp:20
The top-level namespace for the JayBeams library.
Definition: as_hhmmss.hpp:7