GenericInertialCommandResponse
public
InertialCmdResponse
GenericInertialCommandResponse

Represents the response to a GenericInertialCommand.

See Also

InertialCmdResponse

Functions
GenericInertialCommandResponse
GenericInertialCommandResponse()

Creates a GenericInertialCommandResponse with default values.

GenericInertialCommandResponse
GenericInertialCommandResponse(
ResponsePattern::State state,
bool success,
InertialPacket::MipAckNack errorCode,
std::string cmdName,
ByteStream data
)

Creates a GenericInertialCommandResponse with the given parameters.

Parameters
state
ResponsePattern::State

The state of the response.

success
bool

Whether or not the command was a success.

errorCode
InertialPacket::MipAckNack

The MIP Ack/Nack error code received.

cmdName
std::string

The name of the command.

data

The <ByteStream that holds the result data from the response (if any).

ResponseSuccess
static GenericInertialCommandResponse ResponseSuccess(
std::string cmdName,
ByteStream data ByteStream()
)

Creates a GenericInertialCommandResponse with a successful response.

Parameters
cmdName
std::string

The name of the command.

data

The <ByteStream that holds the data from the response (if any).

Returns

A GenericInertialCommandResponse representing a success response from the command.

ResponseFail
static GenericInertialCommandResponse ResponseFail(
ResponsePattern::State errorState,
InertialPacket::MipAckNack errorCode,
std::string cmdName
)

Creates a GenericInertialCommandResponse with a fail response.

Parameters
errorState
ResponsePattern::State

The state that caused the ResponseFail.

errorCode
InertialPacket::MipAckNack

The MIP Ack/Nack error code to set with the ResponseFail.

cmdName
std::string

The name of the command.

Returns

A GenericInertialCommandResponse representing a failed response from the command.

Variables
m_data
ByteStream m_data

The <ByteStream that holds the data received from the response, if any.

Functions
data
ByteStream data() const

Gets the data that was received from the response, if any.

Returns

A ByteStream that contains the data received from the response, if any.