TorControlConnection::Command

Send a command, register a handler for the reply. A trailing CRLF is automatically added. Return true on success.

Synopsis

Declared in <torcontrol.h>

bool
Command(
    std::string const& cmd,
    ReplyHandlerCB const& reply_handler);

Return Value

true on success, false on failure.

Parameters

NameDescription
cmdCommand line to send, without the trailing CRLF.
reply_handlerHandler invoked when the reply for this command arrives.