diff options
author | Yaroslav Brustinov <ybrustin@cisco.com> | 2016-08-03 16:21:12 +0300 |
---|---|---|
committer | Yaroslav Brustinov <ybrustin@cisco.com> | 2016-08-03 16:21:12 +0300 |
commit | 0f863b48e742ecd6b6dd522803e95a528024bbc9 (patch) | |
tree | 81798d3fb9d40ee41efbb41d69170c752a5c3a5f /src/publisher/trex_publisher.h | |
parent | 3159743120d9e1033c5ed809c1031b814204fd8f (diff) | |
parent | 0ccbb8ff779d4e905fc4fea5d2570f6e72821b0e (diff) |
Merge remote-tracking branch 'origin/master'
Diffstat (limited to 'src/publisher/trex_publisher.h')
-rw-r--r-- | src/publisher/trex_publisher.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/publisher/trex_publisher.h b/src/publisher/trex_publisher.h index 1d283478..fb7226c4 100644 --- a/src/publisher/trex_publisher.h +++ b/src/publisher/trex_publisher.h @@ -38,7 +38,7 @@ public: virtual bool Create(uint16_t port, bool disable); virtual void Delete(); - virtual void publish_json(const std::string &s); + virtual void publish_json(const std::string &s, uint32_t zip_threshold = MSG_COMPRESS_THRESHOLD); enum event_type_e { EVENT_PORT_STARTED = 0, @@ -71,9 +71,14 @@ public: private: void show_zmq_last_error(const std::string &err); + void publish_zipped_json(const std::string &s); + void publish_raw_json(const std::string &s); + private: void * m_context; void * m_publisher; + + static const int MSG_COMPRESS_THRESHOLD = 256; }; #endif /* __TREX_PUBLISHER_H__ */ |