JayBeams  0.1
Another project to have fun coding.
modify_message.cpp
Go to the documentation of this file.
2 
3 #include <ostream>
4 
5 namespace jb {
6 namespace pitch2 {
7 
8 template <typename quantity_t, typename price_t>
9 std::ostream& stream_modify_message(
10  std::ostream& os, modify_message<quantity_t, price_t> const& x) {
11  return os << "length=" << static_cast<int>(x.length.value())
12  << ",message_type=" << static_cast<int>(x.message_type.value())
13  << ",time_offset=" << x.time_offset.value()
14  << ",order_id=" << x.order_id.value()
15  << ",quantity=" << x.quantity.value()
16  << ",price=" << x.price.value()
17  << ",modify_flags=" << static_cast<int>(x.modify_flags.value());
18 }
19 
20 std::ostream& operator<<(std::ostream& os, modify_long_message const& x) {
21  return stream_modify_message(os, x);
22 }
23 
24 std::ostream& operator<<(std::ostream& os, modify_short_message const& x) {
25  return stream_modify_message(os, x);
26 }
27 
28 } // namespace pitch2
29 } // namespace jb
std::ostream & operator<<(std::ostream &os, add_order_message const &x)
Streaming operator for jb::pitch2::add_order_message.
boost::endian::little_uint32_buf_t time_offset
boost::endian::little_uint8_buf_t modify_flags
std::ostream & stream_modify_message(std::ostream &os, modify_message< quantity_t, price_t > const &x)
Represent the &#39;Modify (short)&#39; messages in the PITCH-2.X protocol.
boost::endian::little_uint8_buf_t length
boost::endian::little_uint8_buf_t message_type
Represent the &#39;Modify&#39; messages in the PITCH-2.X protocol.
boost::endian::little_uint64_buf_t order_id
Represent the &#39;Modify (long)&#39; messages in the PITCH-2.X protocol.
The top-level namespace for the JayBeams library.
Definition: as_hhmmss.hpp:7