Cockatrice 2026-09-01-Development-3.1.0-beta.10
A virtual tabletop for multiplayer card games
Loading...
Searching...
No Matches
PendingCommand Class Reference

#include <pending_command.h>

Inheritance diagram for PendingCommand:
[legend]
Collaboration diagram for PendingCommand:
[legend]

Signals

void finished (const Response &response, const CommandContainer &commandContainer, const QVariant &extraData)

Public Member Functions

 PendingCommand (const CommandContainer &_commandContainer, QVariant _extraData=QVariant())
CommandContainergetCommandContainer ()
void setExtraData (const QVariant &_extraData)
QVariant getExtraData () const
void processResponse (const Response &response)
int tick ()
void startTiming ()
 Starts the round-trip timer. Called by the client thread right before the command container is handed to the transport layer.
qint64 elapsedMs () const

Private Attributes

CommandContainer commandContainer
QVariant extraData
int ticks
QElapsedTimer startTime

Detailed Description

Todo
Document this file.

Constructor & Destructor Documentation

◆ PendingCommand()

PendingCommand::PendingCommand ( const CommandContainer & _commandContainer,
QVariant _extraData = QVariant() )
explicit

Member Function Documentation

◆ elapsedMs()

qint64 PendingCommand::elapsedMs ( ) const
Returns
Milliseconds elapsed since startTiming(), or -1 if the timer was never started.
Here is the caller graph for this function:

◆ finished

void PendingCommand::finished ( const Response & response,
const CommandContainer & commandContainer,
const QVariant & extraData )
signal

◆ getCommandContainer()

CommandContainer & PendingCommand::getCommandContainer ( )
Here is the caller graph for this function:

◆ getExtraData()

QVariant PendingCommand::getExtraData ( ) const

◆ processResponse()

void PendingCommand::processResponse ( const Response & response)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ setExtraData()

void PendingCommand::setExtraData ( const QVariant & _extraData)
Here is the caller graph for this function:

◆ startTiming()

void PendingCommand::startTiming ( )

Starts the round-trip timer. Called by the client thread right before the command container is handed to the transport layer.

Here is the caller graph for this function:

◆ tick()

int PendingCommand::tick ( )
Here is the caller graph for this function:

Member Data Documentation

◆ commandContainer

CommandContainer PendingCommand::commandContainer
private

◆ extraData

QVariant PendingCommand::extraData
private

◆ startTime

QElapsedTimer PendingCommand::startTime
private

◆ ticks

int PendingCommand::ticks
private

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