mirror of https://github.com/oxen-io/oxen-mq.git
Updated headers and remove dead code
This commit is contained in:
parent
ede91341da
commit
13e7953bd7
|
@ -1,12 +1,10 @@
|
|||
#include <queue>
|
||||
#include "lokimq.h"
|
||||
#include <map>
|
||||
#include <cassert>
|
||||
#include <random>
|
||||
|
||||
extern "C" {
|
||||
#include <sodium.h>
|
||||
}
|
||||
#include "lokimq.h"
|
||||
#include "batch.h"
|
||||
#include "hex.h"
|
||||
|
||||
|
@ -44,14 +42,6 @@ zmq::message_t create_message(string_view data) {
|
|||
return zmq::message_t{data.begin(), data.end()};
|
||||
}
|
||||
|
||||
/*
|
||||
/// Create a message that references the existing data. In order to use this safely you need to be
|
||||
/// sure that the referenced data lasts sufficiently long, which can be tricky.
|
||||
zmq::message_t create_message_reference(string_view data) {
|
||||
return zmq::message_t{const_cast<char*>(&data[0]), data.size(), (zmq::free_fn*) nullptr, nullptr};
|
||||
}
|
||||
*/
|
||||
|
||||
/// Creates a message by bt-serializing the given value (string, number, list, or dict)
|
||||
template <typename T>
|
||||
zmq::message_t create_bt_message(T&& data) { return create_message(bt_serialize(std::forward<T>(data))); }
|
||||
|
|
|
@ -40,6 +40,7 @@
|
|||
#include <iostream>
|
||||
#include <chrono>
|
||||
#include <atomic>
|
||||
#include <cassert>
|
||||
#include <zmq.hpp>
|
||||
#include "bt_serialize.h"
|
||||
#include "string_view.h"
|
||||
|
|
Loading…
Reference in New Issue