Vidalia 0.2.10
|
#include <BootstrapStatus.h>
Definition at line 26 of file BootstrapStatus.h.
Actions the Tor software might recommend controllers take in response to a bootstrap status problem event.
Definition at line 48 of file BootstrapStatus.h.
Currently enumerated bootstrapping states defined by Tor's control protocol (Tor >= 0.2.1.0-alpha-dev.
Definition at line 31 of file BootstrapStatus.h.
BootstrapStatus::BootstrapStatus | ( | ) |
Default constructor.
Definition at line 20 of file BootstrapStatus.cpp.
References _action, _percentComplete, _reason, _severity, _status, tc::UnrecognizedReason, UnrecognizedRecommendation, tc::UnrecognizedSeverity, and UnrecognizedStatus.
BootstrapStatus::BootstrapStatus | ( | tc::Severity | severity, |
Status | status, | ||
int | percentComplete, | ||
const QString & | description, | ||
const QString & | warning = QString() , |
||
tc::ConnectionStatusReason | reason = tc::UnrecognizedReason , |
||
Recommendation | action = UnrecognizedRecommendation |
||
) |
Constructor.
Definition at line 30 of file BootstrapStatus.cpp.
References _action, _description, _percentComplete, _reason, _severity, _status, _warning, description(), reason(), severity(), status(), and warning().
BootstrapStatus::Recommendation BootstrapStatus::actionFromString | ( | const QString & | str | ) | [static] |
Converts a string RECOMMENDATION value to a RecommendAction enum value.
Returns the action that the Tor software recommended be taken in response to this bootstrap status.
Definition at line 80 of file BootstrapStatus.cpp.
References RecommendIgnore, RecommendWarn, and UnrecognizedRecommendation.
Referenced by TorControl::bootstrapStatus(), and TorEvents::handleClientStatusEvent().
QString BootstrapStatus::description | ( | ) | const [inline] |
Returns a description of Tor's current bootstrapping status.
Definition at line 77 of file BootstrapStatus.h.
References _description.
Referenced by BootstrapStatus().
bool BootstrapStatus::isValid | ( | ) | const |
Returns true if this object represents a valid bootstrap status phase.
Definition at line 91 of file BootstrapStatus.cpp.
References _percentComplete, _severity, _status, tc::UnrecognizedSeverity, and UnrecognizedStatus.
Referenced by MainWindow::authenticated().
int BootstrapStatus::percentComplete | ( | ) | const [inline] |
Returns an integer between 0 and 100 representing an estimate of how much of Tor's bootstrapping process it has completed.
Definition at line 74 of file BootstrapStatus.h.
References _percentComplete.
Referenced by MainWindow::bootstrapStatusChanged().
tc::ConnectionStatusReason BootstrapStatus::reason | ( | ) | const [inline] |
Returns a ConnectionStatusReason enum value describing the most recent error Tor encountered while attempting to bootstrap, if this event's severity is 'warn'. Otherwise, this simply returns tc::UnrecognizedReason.
Definition at line 88 of file BootstrapStatus.h.
References _reason.
Referenced by BootstrapStatus(), and MainWindow::bootstrapStatusChanged().
Recommendation BootstrapStatus::recommendedAction | ( | ) | const [inline] |
Returns the action that the Tor software recommended be taken in response to this bootstrap status event.
Definition at line 92 of file BootstrapStatus.h.
References _action.
Referenced by MainWindow::bootstrapStatusChanged().
tc::Severity BootstrapStatus::severity | ( | ) | const [inline] |
Returns the severity of this bootstrap status event.
Definition at line 66 of file BootstrapStatus.h.
References _severity.
Referenced by BootstrapStatus(), and MainWindow::bootstrapStatusChanged().
Status BootstrapStatus::status | ( | ) | const [inline] |
Returns the BootstrapStatus enum value indicated by this bootstrap status event.
Definition at line 70 of file BootstrapStatus.h.
References _status.
Referenced by BootstrapStatus(), and MainWindow::bootstrapStatusChanged().
BootstrapStatus::Status BootstrapStatus::statusFromString | ( | const QString & | str | ) | [static] |
Converts a string TAG value to a BootstrapStatus enum value.
Definition at line 48 of file BootstrapStatus.cpp.
References BootstrappingDone, ConnectingToDirMirror, ConnectingToEntryGuard, CreatingOneHopCircuit, EstablishingCircuit, HandshakingWithDirMirror, HandshakingWithEntryGuard, LoadingAuthorityCertificates, LoadingDescriptors, LoadingNetworkStatus, RequestingDescriptors, RequestingNetworkStatus, and UnrecognizedStatus.
Referenced by TorControl::bootstrapStatus(), and TorEvents::handleClientStatusEvent().
QString BootstrapStatus::warning | ( | ) | const [inline] |
Returns a description of the most recent error Tor encountered while attempting to bootstrap, if this event's severity is 'warn'. Otherwise, this returns a default-constructed QString.
Definition at line 82 of file BootstrapStatus.h.
References _warning.
Referenced by BootstrapStatus().
Recommendation BootstrapStatus::_action [private] |
Recommendation enum value describing Tor's suggested response to this bootstrap status event.
Definition at line 141 of file BootstrapStatus.h.
Referenced by BootstrapStatus(), and recommendedAction().
QString BootstrapStatus::_description [private] |
Description of Tor's current bootstrapping status.
Definition at line 123 of file BootstrapStatus.h.
Referenced by BootstrapStatus(), and description().
int BootstrapStatus::_percentComplete [private] |
Approximate percentage of Tor's bootstrapping process that is complete.
Definition at line 118 of file BootstrapStatus.h.
Referenced by BootstrapStatus(), isValid(), and percentComplete().
ConnectionStatusReason enum value describing the most recent error Tor encountered while attempting to bootstrap.
Definition at line 135 of file BootstrapStatus.h.
Referenced by BootstrapStatus(), and reason().
tc::Severity BootstrapStatus::_severity [private] |
Severity of the current bootstrap status.
Definition at line 108 of file BootstrapStatus.h.
Referenced by BootstrapStatus(), isValid(), and severity().
Status BootstrapStatus::_status [private] |
Current bootstrapping status value.
Definition at line 113 of file BootstrapStatus.h.
Referenced by BootstrapStatus(), isValid(), and status().
QString BootstrapStatus::_warning [private] |
Description of the most recent error Tor encountered while attempting to bootstrap.
Definition at line 129 of file BootstrapStatus.h.
Referenced by BootstrapStatus(), and warning().