![]() |
GM6000 Digital Heater Controller Build: 16 (Branch = develop)
SDX-1330
|
This class implements a TShell command that is used to provision a GM6000 unit at production. More...
This class implements a TShell command that is used to provision a GM6000 unit at production.
This class assumes that the following MP exists: mp::serialNumber mp::modelNumber TODO: mp::XYZ - Algorithm stuffs....
#include <Provision.h>
Public Member Functions | |
const char * | getUsage () const noexcept |
See Cpl::TShell::Command `. | |
const char * | getHelp () const noexcept |
See Cpl::TShell::Command. | |
Provision (Cpl::Container::SList< Cpl::TShell::Command > &commandList, Ajax::Main::PersonalityRecord &personalityRecord, Cpl::Persistent::RecordServer &recordServer, Driver::Crypto::Hash &sha512HashFunction, Cpl::TShell::Security::Permission_T minPermLevel=OPTION_TSHELL_CMD_COMMAND_DEFAULT_PERMISSION_LEVEL) noexcept | |
Constructor. | |
Cpl::TShell::Command::Result_T | execute (Cpl::TShell::Context_ &context, char *cmdString, Cpl::Io::Output &outfd) noexcept |
See Cpl::TShell::Command. | |
![]() | |
const char * | getVerb () const noexcept |
See Cpl::TShell::Command. | |
Security::Permission_T | getMinPermissionRequired () const noexcept |
See Cpl::TShell::Command. | |
![]() | |
virtual | ~Command () |
Virtual destructor. | |
![]() | |
bool | insert_ (void *newContainerPtr) |
Helper method to trap when inserting an item in multiple containers. | |
bool | isInContainer_ (const void *containerPtr) const noexcept |
Returns 'true' if the instance is in the specified container. | |
Static Public Attributes | |
static constexpr const char * | verb = "prov" |
The command verb/identifier. | |
static constexpr const char * | usage = "prov <modelNumber> <serialNumber> <consolePwd> <h-outS> <h-maxY> <h-errS> <h-dErrS> <h-outK0> <h-outK1> <h-outK2> <h-outK3> <h-outK4> <fanLow> <fanMed> <fanHi> <maxCap>" |
The command usage string. | |
static constexpr const char * | detailedHelp = " Provisions the GM6000 with its 'personality'" |
The command detailed help string (recommended that lines do not exceed 80 chars) 1 2 3 4 5 6 7 8 12345678901234567890123456789012345678901234567890123456789012345678901234567890. | |
Protected Member Functions | |
bool | hashPassword (const char *plaintext, Cpl::Text::String &workBufferMem, Cpl::Text::String &workDigestMem, Cpl::Text::String &outputBufferMemory) noexcept |
Helper function. | |
![]() | |
Command (Cpl::Container::SList< Cpl::TShell::Command > &commandList, const char *verb, Security::Permission_T minPermLevel=OPTION_TSHELL_CMD_COMMAND_DEFAULT_PERMISSION_LEVEL) noexcept | |
Constructor. | |
![]() | |
Command () | |
Constructor. | |
![]() | |
Item () | |
Constructor. | |
Item (const char *) | |
Constructor used ONLY with the child class MapItem: -->special constructor to allow a Map to be statically allocated. | |
Protected Attributes | |
Cpl::Persistent::RecordServer & | m_recordServer |
Persistent Storage Server. | |
Ajax::Main::PersonalityRecord & | m_personalityRec |
Personality record that I write to. | |
Driver::Crypto::Hash & | m_sha512 |
Hash function to use. The expectation is this a SHA512 has function. | |
![]() | |
const char * | m_verb |
Command verb. | |
Security::Permission_T | m_minPermissionLevel |
Minimum required user permission need to execute me. | |
Additional Inherited Members | |
![]() | |
enum | Result_T { eSUCCESS = 0 , eERROR_BAD_SYNTAX = 1 , eERROR_INVALID_CMD = 2 , eERROR_IO = 3 , eERROR_MISSING_ARGS = 4 , eERROR_EXTRA_ARGS = 5 , eERROR_INVALID_ARGS = 6 , eERROR_FAILED = 7 } |
Possible result codes when executing a command. More... | |
![]() | |
static void | remove_ (Item *itemPtr) noexcept |
Helper method to do the proper 'clean-up' for the multiple-containers-error-trap when removing an item from a container. | |
![]() | |
void * | m_nextPtr_ |
The link field. | |
void * | m_inListPtr_ |
Debug field. | |
![]() | |
enum | CondResult_T { eFALSE , eTRUE , eERROR } |
Result when processing a conditional statement. More... | |
|
noexcept |
Constructor.
|
virtualnoexcept |
See Cpl::TShell::Command.
Implements Cpl::TShell::Command.
|
inlinevirtualnoexcept |
See Cpl::TShell::Command.
Implements Cpl::TShell::Command.
|
inlinevirtualnoexcept |
See Cpl::TShell::Command `.
Implements Cpl::TShell::Command.
|
protectednoexcept |
Helper function.
|
staticconstexpr |
The command detailed help string (recommended that lines do not exceed 80 chars) 1 2 3 4 5 6 7 8 12345678901234567890123456789012345678901234567890123456789012345678901234567890.
|
protected |
Personality record that I write to.
|
protected |
Persistent Storage Server.
|
protected |
Hash function to use. The expectation is this a SHA512 has function.
|
staticconstexpr |
The command usage string.
|
staticconstexpr |
The command verb/identifier.