#include <controlreply.h>
Public Member Functions | |
ControlReply () | |
void | appendLine (ReplyLine line) |
ReplyLine | getLine (int idx=0) const |
QList< ReplyLine > | getLines () const |
QString | getStatus () const |
QString | getMessage () const |
QStringList | getData () const |
QString | toString () const |
Private Attributes | |
QList< ReplyLine > | _lines |
Definition at line 35 of file controlreply.h.
ControlReply::ControlReply | ( | ) |
Default constructor
Definition at line 31 of file controlreply.cpp.
void ControlReply::appendLine | ( | ReplyLine | line | ) |
Add a line associated with this reply
Definition at line 37 of file controlreply.cpp.
References _lines.
Referenced by ControlSocket::readReply().
ReplyLine ControlReply::getLine | ( | int | idx = 0 |
) | const |
Returns a single line from this reply
Returns the requested line from this reply
Definition at line 44 of file controlreply.cpp.
References _lines.
Referenced by getData(), getMessage(), and getStatus().
QList< ReplyLine > ControlReply::getLines | ( | ) | const |
Returns all lines for this reply
Definition at line 51 of file controlreply.cpp.
References _lines.
Referenced by TorControl::getConf(), TorControl::getDescriptorListById(), TorControl::getDescriptorListByName(), TorControl::getInfo(), TorEvents::handleEvent(), and TorControl::protocolInfo().
QString ControlReply::getStatus | ( | ) | const |
Returns the status of the first line in the reply
Definition at line 58 of file controlreply.cpp.
References getLine(), and ReplyLine::getStatus().
Referenced by ControlConnection::onReadyRead(), and TorControl::send().
QString ControlReply::getMessage | ( | ) | const |
Returns the messasge of the first line in the reply
Returns the message of the first line in the reply
Definition at line 65 of file controlreply.cpp.
References getLine(), and ReplyLine::getMessage().
Referenced by TorControl::getCircuits(), TorControl::getRouterIDList(), TorControl::getStreams(), and TorControl::send().
QStringList ControlReply::getData | ( | ) | const |
Returns the data for the first line in the reply.
Definition at line 72 of file controlreply.cpp.
References ReplyLine::getData(), and getLine().
Referenced by TorControl::getAddressMap(), TorControl::getCircuits(), and TorControl::getStreams().
QString ControlReply::toString | ( | ) | const |
Returns the entire contents of the control reply.
Definition at line 79 of file controlreply.cpp.
References _lines, and ReplyLine::toString().
Referenced by ControlConnection::onReadyRead().
QList<ReplyLine> ControlReply::_lines [private] |
Definition at line 59 of file controlreply.h.
Referenced by appendLine(), getLine(), getLines(), and toString().