Home
Base module

AsyncDiagnostic

Asynchronous diagnostic information collector.

AsyncDiagnostic

#include <icy/diagnosticmanager.h>
class AsyncDiagnostic

Defined in src/base/include/icy/diagnosticmanager.h:124

Inherits: IDiagnostic, Runnable

Asynchronous diagnostic information collector.

List of all members

NameKindOwner
~AsyncDiagnosticfunctionDeclared here
runfunctionDeclared here
checkfunctionDeclared here
_threadvariableDeclared here
namevariableInherited from IDiagnostic
descriptionvariableInherited from IDiagnostic
summaryvariableInherited from IDiagnostic
SummaryUpdatedvariableInherited from IDiagnostic
IDiagnosticfunctionInherited from IDiagnostic
~IDiagnosticfunctionInherited from IDiagnostic
checkfunctionInherited from IDiagnostic
resetfunctionInherited from IDiagnostic
completefunctionInherited from IDiagnostic
passedfunctionInherited from IDiagnostic
failedfunctionInherited from IDiagnostic
runfunctionInherited from IDiagnostic
passfunctionInherited from IDiagnostic
failfunctionInherited from IDiagnostic
addSummaryfunctionInherited from IDiagnostic
StateChangevariableInherited from Stateful
StatefulfunctionInherited from Stateful
~StatefulfunctionInherited from Stateful
stateEqualsfunctionInherited from Stateful
stateBetweenfunctionInherited from Stateful
statefunctionInherited from Stateful
statefunctionInherited from Stateful
_statevariableInherited from Stateful
beforeStateChangefunctionInherited from Stateful
onStateChangefunctionInherited from Stateful
setStatefunctionInherited from Stateful
setStatefunctionInherited from Stateful
RunnablefunctionInherited from Runnable
~RunnablefunctionInherited from Runnable
runfunctionInherited from Runnable
cancelfunctionInherited from Runnable
cancelledfunctionInherited from Runnable
exitvariableInherited from Runnable

Inherited from IDiagnostic

KindNameDescription
variablenameThe name of the diagnostic.
variabledescriptionThe diagnostic description.
variablesummaryThe diagnostic summary, maybe including troubleshooting information on failure.
variableSummaryUpdatedSignals when a new text item is added to the summary.
functionIDiagnostic
function~IDiagnostic virtual
functioncheck virtualResets state to None and invokes run() to perform the diagnostic check.
functionreset virtualClears the summary and resets state to None.
functioncomplete virtual constReturns true if the diagnostic has reached a terminal state (Passed or Failed).
functionpassed virtual constReturns true if the diagnostic state is Passed.
functionfailed virtual constReturns true if the diagnostic state is Failed.
functionrun virtualOverride to implement diagnostic logic.
functionpass virtualTransitions the state to Passed.
functionfail virtualTransitions the state to Failed.
functionaddSummary virtualAppends text to the summary list and emits SummaryUpdated.

Inherited from Stateful

KindNameDescription
variableStateChangeSignals when the state changes.
functionStateful inline
function~Stateful virtual inline
functionstateEquals virtual const inlineReturns true if the current state ID equals the given ID.
functionstateBetween virtual const inlineReturns true if the current state ID is in the inclusive range [lid, rid].
functionstate virtual inlineReturns a mutable reference to the current state.
functionstate virtual const inlineReturns a copy of the current state.
variable_state
functionbeforeStateChange virtual inlineOverride to handle pre state change logic. Return false to prevent state change.
functiononStateChange virtual inlineOverride to handle post state change logic.
functionsetState virtual inlineSets the state and sends the state signal if the state change was successful.
functionsetState virtual inlineSets the state and sends the state signal if the state change was successful.

Inherited from Runnable

KindNameDescription
functionRunnable inline
function~Runnable virtualDefaulted destructor.
functionrun virtualThe run method will be called by the asynchronous context.
functioncancel virtual inlineCancel the current task. The run() method should return ASAP.
functioncancelled virtual const inlineReturns true when the task has been cancelled.
variableexit

Public Methods

ReturnNameDescription
voidrun virtual overrideOverride to implement diagnostic logic.
voidcheck virtual inline overrideResets the diagnostic and launches run() on a background thread.

run

virtual override

virtual void run() override

Defined in src/base/include/icy/diagnosticmanager.h:130

Override to implement diagnostic logic.

The StateChange signal will dispatch diagnostic test results to delegates.

Reimplements

check

virtual inline override

virtual inline void check() override

Defined in src/base/include/icy/diagnosticmanager.h:133

Resets the diagnostic and launches run() on a background thread.

Reimplements

Protected Attributes

ReturnNameDescription
Thread_thread

_thread

Thread _thread

Defined in src/base/include/icy/diagnosticmanager.h:140