|
|
@ -1,6 +1,7 @@ |
|
|
|
#ifndef JSON_ADAPTER_HH
|
|
|
|
#define JSON_ADAPTER_HH
|
|
|
|
|
|
|
|
#include <thread>
|
|
|
|
#include <pEp/message.h>
|
|
|
|
#include <pEp/sync_api.h>
|
|
|
|
#include "registry.hh"
|
|
|
@ -36,8 +37,8 @@ public: |
|
|
|
JsonAdapter& ignore_session_errors(bool _ig); |
|
|
|
|
|
|
|
// if called with "false" the JSON Adpapter would no longer deliver HTML and JavaScript files, only handle JSON-RPC requests
|
|
|
|
JsonAdapter& deliver_html(bool _deliver_html); |
|
|
|
|
|
|
|
JsonAdapter& deliver_html(bool _deliver_html); |
|
|
|
|
|
|
|
// look for a free port to listen on and set the given configuration
|
|
|
|
void prepare_run(const std::string& address, unsigned start_port, unsigned end_port, ::messageToSend_t messageToSend); |
|
|
|
|
|
|
@ -69,6 +70,8 @@ public: |
|
|
|
|
|
|
|
unsigned request_count() const; |
|
|
|
|
|
|
|
virtual std::thread::id get_sync_thread_id() const = 0; |
|
|
|
|
|
|
|
// returns 'true' if 's' is the security token created by the function above.
|
|
|
|
virtual bool verify_security_token(const std::string& s) const override; |
|
|
|
|
|
|
|