![]() |
Developer Application Interface (ARC API) v4.5.8
ARC, Inc. GenIV Application Interface
|
#include <CArcStatusPacket.h>
Public Member Functions | |
CArcStatusPacket (void)=default | |
virtual | ~CArcStatusPacket (void)=default |
void | assign (std::uint8_t *pData, const std::uint32_t uiSize) |
bool | headerValid (void) const noexcept override |
constexpr std::uint32_t | command (void) noexcept |
std::uint32_t | value (const std::uint32_t uiIndex=0) const |
const std::uint32_t * | valueData (void) |
std::uint8_t | valueCount (void) |
bool | compare (const std::uint32_t uiValue=static_cast< std::uint32_t >(cmds_e::DONE)) noexcept |
template<typename... Args> | |
std::enable_if_t< std::conjunction_v< std::is_same< std::uint32_t, Args >... >, bool > | compare (Args... args) |
bool | success (void) noexcept |
bool | containsError (void) noexcept |
errorCodes_e | errorCode (void) noexcept |
const std::string | errorCodeDescription (void) |
const std::string | getName (void) const override |
![]() | |
virtual | ~CArcPacket (void)=default |
constexpr std::uint32_t | headerLength (void) const noexcept |
constexpr std::uint32_t | headerByteLength (void) const noexcept |
std::uint8_t | packetId (void) const |
bool | checkPacketId (std::uint32_t uiHeader, std::uint8_t uiPacketId) const noexcept |
std::uint8_t | payloadId (void) const |
std::uint8_t | payloadLength (void) const |
std::uint32_t | payloadByteLength (void) const |
std::uint32_t * | payload (void) const noexcept |
void | add (const std::uint32_t uiValue) |
std::uint32_t | length (void) const noexcept |
std::uint32_t | byteLength (void) const noexcept |
std::uint32_t | maxByteLength (void) const noexcept |
std::uint32_t | maxLength (void) const noexcept |
std::uint32_t | at (const std::uint32_t uiIndex) const |
std::uint32_t & | operator[] (const std::uint32_t uiIndex) |
std::uint8_t * | data (void) const noexcept |
virtual const std::string | toString (void) const |
virtual const std::string | toLogString (void) const |
![]() | |
virtual | ~CArcBase (void) |
Static Public Attributes | |
static constexpr std::uint32_t | STATUS_START_INDEX = 1 |
Static Protected Attributes | |
static constexpr std::uint8_t | PAYLOAD_ID = 0xAF |
![]() | |
static constexpr auto | MAX_PACKET_SIZE = static_cast< std::uint32_t >( 1024 ) |
![]() | |
static const std::string | m_sVersion |
Additional Inherited Members | |
![]() | |
static const std::string | version (void) |
static void | zeroMemory (void *pDest, std::size_t uiSize) |
static void | copyMemory (void *pDest, void *pSrc, std::size_t uiSize) |
template<typename T > | |
static std::tuple< T *, T * > | copyAndIncrement (void *pDest, void *pSrc, const std::size_t uiSize) |
template<typename ErrCode > requires std::is_integral_v<ErrCode> | |
static const std::string | getSystemErrorMessage (ErrCode iErrCode) |
static const std::string | getSystemErrorMessage (void) |
static std::uint32_t | getSystemError (void) noexcept |
static pStringList_t | splitString (const std::string &sString, const char &zDelim=' ') |
static std::string | formatString (const char *pszFmt,...) |
static const std::filesystem::path | incrementFileName (const std::filesystem::path &tFilePath="", const std::int32_t iStartValue=-1) |
static std::string | convertWideToAnsi (const wchar_t wzString[]) noexcept |
static std::string | convertWideToAnsi (const std::wstring &wsString) |
static std::wstring | convertAnsiToWide (const char *pszString) |
static std::string | cmdToString (const std::uint32_t uiCmd) |
template<typename T > | |
static std::string | iterToString (T *begin, T *end, const char zSeperator=' ') |
static std::string | setDots (const std::string &sText, const std::size_t uiMaxLength, const char szDot='.') |
static std::string | trim (const std::string &sText) noexcept |
static const std::chrono::time_point< std::chrono::high_resolution_clock > | startCodeTime (void) noexcept |
template<typename T > | |
static constexpr auto | endCodeTime (const std::chrono::time_point< std::chrono::high_resolution_clock > tStartTimePoint) noexcept |
![]() | |
CArcPacket (const std::uint32_t uiSize=MAX_PACKET_SIZE) | |
void | incrementLength (const std::uint8_t uiIncr=1) noexcept |
![]() | |
CArcBase (void)=default | |
CArcBase (const CArcBase &)=delete | |
CArcBase (CArcBase &&)=delete | |
CArcBase & | operator= (const CArcBase &)=delete |
CArcBase & | operator= (CArcBase &&)=delete |
![]() | |
packetHeader_t * | m_pHeader |
std::uint32_t * | m_pPayload |
std::unique_ptr< std::uint8_t[]> | m_pData |
std::uint32_t | m_uiSize |
ARC GenIV status packet class. The command reply packet type.
Definition at line 31 of file CArcStatusPacket.h.
|
default |
|
virtualdefault |
void arc::gen4::CArcStatusPacket::assign | ( | std::uint8_t * | pData, |
const std::uint32_t | uiSize | ||
) |
Assign data to the packet.
pData | - The byte data to assign as the packet data. |
uiSize | - The number of bytes in the data buffer parameter. |
std::runtime_error | See specific packet types to details. |
std::out_of_range | error if data too large for packet type. |
|
overridevirtualnoexcept |
Determines if the packet contains a valid header. The implementation may change; thus no details are given.
Implements arc::gen4::CArcPacket.
|
inlineconstexprnoexcept |
std::uint32_t arc::gen4::CArcStatusPacket::value | ( | const std::uint32_t | uiIndex = 0 | ) | const |
Returns the status value at the specified index.
uiIndex | - The value index ( default = 0 ). |
std::out_of_range | error if index is out of range. |
const std::uint32_t * arc::gen4::CArcStatusPacket::valueData | ( | void | ) |
Returns a pointer to the start of the status value(s).
std::runtime_error | error if there is no valid value. |
std::uint8_t arc::gen4::CArcStatusPacket::valueCount | ( | void | ) |
Returns the number of status values.
std::runtime_error |
|
noexcept |
Compares the specified parameter against the first status value.
uiValue | - The expected status value ( default = DONE ). |
|
inline |
Compares all the values in the list against the first status value.
rList | - The list of expected status values. |
Definition at line 93 of file CArcStatusPacket.h.
|
noexcept |
Alias for the default compare() method, which verifies that the status value is a 'DONE'.
|
noexcept |
Returns true if the first status value contains a standard error code ( 'ERR', etc ); false otherwise.
|
noexcept |
Returns the error code returned by the controller.
const std::string arc::gen4::CArcStatusPacket::errorCodeDescription | ( | void | ) |
Returns a text description for the error code returned by the controller.
std::runtime_error |
|
overridevirtual |
Returns the packet name.
Any | exception thrown by std::string |
Implements arc::gen4::CArcPacket.
|
staticconstexpr |
The index of the first status value
Definition at line 130 of file CArcStatusPacket.h.
|
staticconstexprprotected |
Definition at line 135 of file CArcStatusPacket.h.