MAK RTIspy API Documentation for HLA 1.3
List of all members | Classes | Public Slots | Signals | Public Member Functions | Protected Types | Protected Member Functions | Protected Attributes | Static Protected Attributes

Dialog which displays the results of network latency testing for a particular initiating federate. More...

+ Inheritance diagram for DtLatencyTestDialog:
+ Collaboration diagram for DtLatencyTestDialog:

Classes

struct  DtDetailedInfo
 Structure to store detailed information. More...

Public Slots

virtual void processRun ()
 Process the pressing of the run button.
virtual void processContinuous ()
 Process the pressing of the continuous button.
virtual void processStop ()
 Process the pressing of the stop button.
virtual void processSave ()
 Process the pressing of the save button.
virtual void processSelectionChange ()
 Process the selection of a new item in the table.
virtual void setTestConfig (unsigned int interactionPeriod, unsigned int numInteractions, unsigned int payloadBytes)
 Set test configuration values.

Signals

void run ()
 Signal emitted when run button is pressed.
void runContinuous ()
 Signal emitted when run button is pressed in continuous mode.
void stopRunning ()
 Signal emitted when stop button is pressed.
void dismiss ()
 Signal emitted when the dialog is closed or dismissed.
void updateTestConfig (unsigned int interactionPeriod, unsigned int numInteractions, unsigned int payloadBytes)
 Signal emitted when test configuration is updated.
void observing ()
 Signal emitted when the dialog is ready to receive test reports.

Public Member Functions

 DtLatencyTestDialog (QWidget *parent=0, Qt::WindowFlags f=0)
 Constructor.
virtual ~DtLatencyTestDialog ()
 Destructor.
virtual void clearResults ()
 Clears the displayed results.
virtual void addResult (const QString &recipName, unsigned int recipHandle, DtRIDParameters::DtAsynchronousIOModeEnum initProcModel, DtRIDParameters::DtAsynchronousIOModeEnum recipProcModel, unsigned int initTickTime, unsigned int recipTickTime, unsigned int bestEffortRoundTripTime, unsigned int reliableRoundTripTime, int initBestEffortQTime, int recipBestEffortQTime, int initReliableQTime, int recipReliableQTime)
 Adds a new test result.
virtual void addTimeoutResult (const QString &recipName, unsigned int recipHandle)
 Adds a new timeout test result.
virtual void setName (const QString &name)
 Renames the component.
virtual void updateStatus (bool enabled, bool capable, bool continuous, bool inProgress)
 Updates the testing status.
virtual void indicateFederateResigned ()
 Indicate on the dialog that federate has resigned.
virtual void indicateRtiexecShutdown ()
 Indicate on the dialog that rtiexec has shutdown.
virtual bool isTestInProgress ()
 Returns true if a test is currently in progress.
virtual void closeWithoutPrompt ()
 Closes the dialog without displaying a prompt, even if a test is in progress.

Protected Types

enum  DtResultsTableCol { RecipientCol, TransitTimeCol, TimeWaitingCol, TotalTimeCol }
 Enumeration for the table columns. More...
typedef std::map< int,
DtDetailedInfo * > 
DtHandleToDetailedInfoMap
 Typedef for map of recipient handle to detailed info.

Protected Member Functions

virtual void getWidgetsToUpdate (unsigned int recipHandle, QTableWidgetItem *&recipItem, QTableWidgetItem *&timeWaitingItem, QTableWidgetItem *&transitTimeItem, QTableWidgetItem *&totalTimeItem, DtDetailedInfo *&details)
 Gets the widgets in the dialog that should be updated to display the test results for the given recipient name.
virtual QString federateNameToDisplay (unsigned int handle, const QString &name=QString::null)
 Creates the string to be used in the GUI display for the given federate.
virtual unsigned int handleFromDisplayName (const QString &name)
 Returns the handle from the displayed federate name.
virtual QString procModelString (DtRIDParameters::DtAsynchronousIOModeEnum procModel)
 Converts the processing model value to a string.
virtual void clearDetailsDisplay ()
 Clears the detailed information display.
virtual void setTitle ()
 Updates the title of the dialog.
virtual void closeEvent (QCloseEvent *event)
 Handles the closing of the window.
virtual void showEvent (QShowEvent *event)
 Prepare the dialog to be shown.
virtual void convertToMsString (unsigned int usec, QString &result, const QString &notAvailableString=theLongNAString, bool zeroIsNotAvailable=true)
 Converts from usec to a string displaying msec.
virtual void convertToMsString (int usec, QString &result, const QString &notAvailableString=theLongNAString, bool zeroIsNotAvailable=true)
 Converts from usec to a string displaying msec.

Protected Attributes

Ui::LatencyTestDialog myUiImpl
QString myName
 Name of the initiating federate.
QString myStatusText
 Text which displays the current status.
DtHandleToDetailedInfoMap myDetailedInfo
 Map of recipient handles to more detailed information.
DtLatencyTestConfigWidgetmyConfigWidget
 The widget which configures latency test parameters.
bool myTestingEnabled
 Stores whether or not testing is enabled.
bool myTestCapable
 Stores whether or not the LRC is currently capable of running a test.
bool myTestInProgress
 Stores whether or not a test is in progress.
bool myContinuous
 Stores whether or not the current test is continuous.
QIcon myContinuousIcon
 Icon for the continuous button when it is not depressed.
QString mySavedFile
 The previously saved file.
bool myCloseWithoutPrompt
 Indicates that no prompt should be displayed when the dialog is closed.

Static Protected Attributes

static const QString theShortNAString = "--"
 Short string used to indicate metric is not available.
static const QString theLongNAString = "Not available"
 Longer string used to indicate metric is not available.
static const QString theInitiatorToolTip = "The federate initiating test messages."
 Tool tip text for the displayed information.
static const QString theRecipientToolTip = "The remote federate the initiator is sending messages to."
 Tool tip text for the displayed information.
static const QString theTimeWaitingToolTip = "Shown as Best Effort Time / Reliable Time"
 Tool tip text for the displayed information.
static const QString theTransitTimeToolTip = "Shown as Best Effort Time / Reliable Time"
 Tool tip text for the displayed information.
static const QString theTotalTimeToolTip = "Shown as Best Effort Time / Reliable Time"
 Tool tip text for the displayed information.
static const QString theTimestampToolTip = "The time at which this test result was received."
 Tool tip text for the displayed information.
static const QString theProcModelToolTip = "Some metrics are not available in all modes."
 Tool tip text for the displayed information.
static const QString theTickTimeToolTip = "The average time between ticks on this federate."
 Tool tip text for the displayed information.
static const QString theQTimeToolTip = "Callbacks processing modes."
 Tool tip text for the displayed information.
static const QString theRunButtonToolTip = "Run a test"
 Tool tip text for the dialog buttons.
static const QString theStopButtonToolTip = "Stop the current test"
 Tool tip text for the dialog buttons.
static const QString theContinuousButtonToolTip = "Run test continuously"
 Tool tip text for the dialog buttons.
static const QString theConfigureButtonToolTip = "Configure test preferences"
 Tool tip text for the dialog buttons.
static const QString theSaveButtonToolTip = "Save the results to a file"
 Tool tip text for the dialog buttons.

Detailed Description

Dialog which displays the results of network latency testing for a particular initiating federate.

Member Typedef Documentation

Typedef for map of recipient handle to detailed info.

Member Enumeration Documentation

Enumeration for the table columns.

Enumerator:
RecipientCol 
TransitTimeCol 
TimeWaitingCol 
TotalTimeCol 

Constructor & Destructor Documentation

DtLatencyTestDialog::DtLatencyTestDialog ( QWidget parent = 0,
Qt::WindowFlags  f = 0 
)
DtLatencyTestDialog::~DtLatencyTestDialog ( )
virtual

Destructor.

References myConfigWidget.

Member Function Documentation

void DtLatencyTestDialog::addResult ( const QString &  recipName,
unsigned int  recipHandle,
DtRIDParameters::DtAsynchronousIOModeEnum  initProcModel,
DtRIDParameters::DtAsynchronousIOModeEnum  recipProcModel,
unsigned int  initTickTime,
unsigned int  recipTickTime,
unsigned int  bestEffortRoundTripTime,
unsigned int  reliableRoundTripTime,
int  initBestEffortQTime,
int  recipBestEffortQTime,
int  initReliableQTime,
int  recipReliableQTime 
)
virtual
void DtLatencyTestDialog::addTimeoutResult ( const QString &  recipName,
unsigned int  recipHandle 
)
virtual
void DtLatencyTestDialog::clearDetailsDisplay ( )
protectedvirtual

Clears the detailed information display.

References myUiImpl.

Referenced by clearResults(), and processSelectionChange().

void DtLatencyTestDialog::clearResults ( )
virtual

Clears the displayed results.

References clearDetailsDisplay(), myDetailedInfo, and myUiImpl.

Referenced by closeEvent().

void DtLatencyTestDialog::closeEvent ( QCloseEvent *  event)
protectedvirtual

Handles the closing of the window.

References clearResults(), dismiss(), myCloseWithoutPrompt, myContinuous, myTestInProgress, and updateStatus().

void DtLatencyTestDialog::closeWithoutPrompt ( )
virtual

Closes the dialog without displaying a prompt, even if a test is in progress.

References myCloseWithoutPrompt.

Referenced by DtAssistantLatencyTestMgr::verifyNewTestCanBeRun().

void DtLatencyTestDialog::convertToMsString ( unsigned int  usec,
QString &  result,
const QString &  notAvailableString = theLongNAString,
bool  zeroIsNotAvailable = true 
)
protectedvirtual

Converts from usec to a string displaying msec.

Referenced by addResult(), and convertToMsString().

void DtLatencyTestDialog::convertToMsString ( int  usec,
QString &  result,
const QString &  notAvailableString = theLongNAString,
bool  zeroIsNotAvailable = true 
)
protectedvirtual

Converts from usec to a string displaying msec.

References convertToMsString().

void DtLatencyTestDialog::dismiss ( )
signal

Signal emitted when the dialog is closed or dismissed.

Referenced by closeEvent().

QString DtLatencyTestDialog::federateNameToDisplay ( unsigned int  handle,
const QString &  name = QString::null 
)
protectedvirtual

Creates the string to be used in the GUI display for the given federate.

Referenced by addResult(), addTimeoutResult(), and getWidgetsToUpdate().

void DtLatencyTestDialog::getWidgetsToUpdate ( unsigned int  recipHandle,
QTableWidgetItem *&  recipItem,
QTableWidgetItem *&  timeWaitingItem,
QTableWidgetItem *&  transitTimeItem,
QTableWidgetItem *&  totalTimeItem,
DtDetailedInfo *&  details 
)
protectedvirtual

Gets the widgets in the dialog that should be updated to display the test results for the given recipient name.

References federateNameToDisplay(), myDetailedInfo, myUiImpl, RecipientCol, theRecipientToolTip, theTimeWaitingToolTip, theTotalTimeToolTip, theTransitTimeToolTip, TimeWaitingCol, TotalTimeCol, and TransitTimeCol.

Referenced by addResult(), and addTimeoutResult().

unsigned int DtLatencyTestDialog::handleFromDisplayName ( const QString &  name)
protectedvirtual

Returns the handle from the displayed federate name.

Referenced by processSave(), and processSelectionChange().

void DtLatencyTestDialog::indicateFederateResigned ( )
virtual

Indicate on the dialog that federate has resigned.

References myStatusText, myTestCapable, myTestInProgress, myUiImpl, and setTitle().

Referenced by DtAssistantLatencyTestMgr::removeLrcComponent().

void DtLatencyTestDialog::indicateRtiexecShutdown ( )
virtual
bool DtLatencyTestDialog::isTestInProgress ( )
virtual

Returns true if a test is currently in progress.

References myTestInProgress.

Referenced by DtAssistantLatencyTestMgr::verifyNewTestCanBeRun().

void DtLatencyTestDialog::observing ( )
signal

Signal emitted when the dialog is ready to receive test reports.

Referenced by showEvent().

void DtLatencyTestDialog::processContinuous ( )
virtualslot

Process the pressing of the continuous button.

References myUiImpl, and runContinuous().

Referenced by DtLatencyTestDialog().

void DtLatencyTestDialog::processRun ( )
virtualslot

Process the pressing of the run button.

References myStatusText, myUiImpl, run(), runContinuous(), and setTitle().

Referenced by DtLatencyTestDialog(), and showEvent().

void DtLatencyTestDialog::processSave ( )
virtualslot

Process the pressing of the save button.

References handleFromDisplayName(), myDetailedInfo, myName, mySavedFile, and myUiImpl.

Referenced by DtLatencyTestDialog().

void DtLatencyTestDialog::processSelectionChange ( )
virtualslot
void DtLatencyTestDialog::processStop ( )
virtualslot

Process the pressing of the stop button.

References myStatusText, myTestInProgress, myUiImpl, setTitle(), and stopRunning().

Referenced by DtLatencyTestDialog().

QString DtLatencyTestDialog::procModelString ( DtRIDParameters::DtAsynchronousIOModeEnum  procModel)
protectedvirtual
void DtLatencyTestDialog::run ( )
signal

Signal emitted when run button is pressed.

Referenced by processRun().

void DtLatencyTestDialog::runContinuous ( )
signal

Signal emitted when run button is pressed in continuous mode.

Referenced by processContinuous(), and processRun().

void DtLatencyTestDialog::setName ( const QString &  name)
virtual
void DtLatencyTestDialog::setTestConfig ( unsigned int  interactionPeriod,
unsigned int  numInteractions,
unsigned int  payloadBytes 
)
virtualslot
void DtLatencyTestDialog::setTitle ( )
protectedvirtual

Updates the title of the dialog.

References myName, and myStatusText.

Referenced by indicateFederateResigned(), indicateRtiexecShutdown(), processRun(), processStop(), setName(), and updateStatus().

void DtLatencyTestDialog::showEvent ( QShowEvent *  event)
protectedvirtual

Prepare the dialog to be shown.

References myUiImpl, observing(), and processRun().

void DtLatencyTestDialog::stopRunning ( )
signal

Signal emitted when stop button is pressed.

Referenced by processStop().

void DtLatencyTestDialog::updateStatus ( bool  enabled,
bool  capable,
bool  continuous,
bool  inProgress 
)
virtual
void DtLatencyTestDialog::updateTestConfig ( unsigned int  interactionPeriod,
unsigned int  numInteractions,
unsigned int  payloadBytes 
)
signal

Signal emitted when test configuration is updated.

Referenced by setTestConfig().

Member Data Documentation

bool DtLatencyTestDialog::myCloseWithoutPrompt
protected

Indicates that no prompt should be displayed when the dialog is closed.

Referenced by closeEvent(), and closeWithoutPrompt().

DtLatencyTestConfigWidget* DtLatencyTestDialog::myConfigWidget
protected

The widget which configures latency test parameters.

Referenced by setTestConfig(), and ~DtLatencyTestDialog().

bool DtLatencyTestDialog::myContinuous
protected

Stores whether or not the current test is continuous.

Referenced by closeEvent(), and updateStatus().

QIcon DtLatencyTestDialog::myContinuousIcon
protected

Icon for the continuous button when it is not depressed.

Referenced by DtLatencyTestDialog().

DtHandleToDetailedInfoMap DtLatencyTestDialog::myDetailedInfo
protected

Map of recipient handles to more detailed information.

Referenced by clearResults(), getWidgetsToUpdate(), processSave(), and processSelectionChange().

QString DtLatencyTestDialog::myName
protected

Name of the initiating federate.

Referenced by processSave(), setName(), and setTitle().

QString DtLatencyTestDialog::mySavedFile
protected

The previously saved file.

Referenced by processSave().

QString DtLatencyTestDialog::myStatusText
protected

Text which displays the current status.

Referenced by indicateFederateResigned(), indicateRtiexecShutdown(), processRun(), processStop(), setTitle(), and updateStatus().

bool DtLatencyTestDialog::myTestCapable
protected

Stores whether or not the LRC is currently capable of running a test.

Referenced by indicateFederateResigned(), indicateRtiexecShutdown(), and updateStatus().

bool DtLatencyTestDialog::myTestingEnabled
protected

Stores whether or not testing is enabled.

Referenced by updateStatus().

bool DtLatencyTestDialog::myTestInProgress
protected

Stores whether or not a test is in progress.

Referenced by closeEvent(), indicateFederateResigned(), indicateRtiexecShutdown(), isTestInProgress(), processStop(), and updateStatus().

Ui::LatencyTestDialog DtLatencyTestDialog::myUiImpl
protected
const QString DtLatencyTestDialog::theConfigureButtonToolTip = "Configure test preferences"
staticprotected

Tool tip text for the dialog buttons.

Referenced by DtLatencyTestDialog().

const QString DtLatencyTestDialog::theContinuousButtonToolTip = "Run test continuously"
staticprotected

Tool tip text for the dialog buttons.

Referenced by DtLatencyTestDialog().

const QString DtLatencyTestDialog::theInitiatorToolTip = "The federate initiating test messages."
staticprotected

Tool tip text for the displayed information.

Referenced by DtLatencyTestDialog().

const QString DtLatencyTestDialog::theLongNAString = "Not available"
staticprotected

Longer string used to indicate metric is not available.

Referenced by addResult().

const QString DtLatencyTestDialog::theProcModelToolTip = "Some metrics are not available in all modes."
staticprotected

Tool tip text for the displayed information.

Referenced by DtLatencyTestDialog().

const QString DtLatencyTestDialog::theQTimeToolTip = "Callbacks processing modes."
staticprotected

Tool tip text for the displayed information.

Referenced by DtLatencyTestDialog().

const QString DtLatencyTestDialog::theRecipientToolTip = "The remote federate the initiator is sending messages to."
staticprotected

Tool tip text for the displayed information.

Referenced by DtLatencyTestDialog(), and getWidgetsToUpdate().

const QString DtLatencyTestDialog::theRunButtonToolTip = "Run a test"
staticprotected

Tool tip text for the dialog buttons.

Referenced by DtLatencyTestDialog().

const QString DtLatencyTestDialog::theSaveButtonToolTip = "Save the results to a file"
staticprotected

Tool tip text for the dialog buttons.

Referenced by DtLatencyTestDialog().

const QString DtLatencyTestDialog::theShortNAString = "--"
staticprotected

Short string used to indicate metric is not available.

Referenced by addResult().

const QString DtLatencyTestDialog::theStopButtonToolTip = "Stop the current test"
staticprotected

Tool tip text for the dialog buttons.

Referenced by DtLatencyTestDialog().

const QString DtLatencyTestDialog::theTickTimeToolTip = "The average time between ticks on this federate."
staticprotected

Tool tip text for the displayed information.

Referenced by DtLatencyTestDialog().

const QString DtLatencyTestDialog::theTimestampToolTip = "The time at which this test result was received."
staticprotected

Tool tip text for the displayed information.

Referenced by DtLatencyTestDialog().

const QString DtLatencyTestDialog::theTimeWaitingToolTip = "Shown as Best Effort Time / Reliable Time"
staticprotected

Tool tip text for the displayed information.

Referenced by DtLatencyTestDialog(), and getWidgetsToUpdate().

const QString DtLatencyTestDialog::theTotalTimeToolTip = "Shown as Best Effort Time / Reliable Time"
staticprotected

Tool tip text for the displayed information.

Referenced by DtLatencyTestDialog(), and getWidgetsToUpdate().

const QString DtLatencyTestDialog::theTransitTimeToolTip = "Shown as Best Effort Time / Reliable Time"
staticprotected

Tool tip text for the displayed information.

Referenced by DtLatencyTestDialog(), and getWidgetsToUpdate().


The documentation for this class was generated from the following files:

Document ID: Generated on Tue May 7 16:26:47 EDT 2013 from SVN revision 126903
Copyright © 2005-2013 VT MÄK Inc. All Rights Reserved (www.mak.com)