You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

28 lines
663 B

3 years ago
#ifndef COMMANDDECODER_H
#define COMMANDDECODER_H
#include <QList>
#include "CommandsType.h"
#include "BaseDecoder.h"
3 years ago
class CommandDecoder : public BaseDecoder
3 years ago
{
private:
2 years ago
QList<CommandsType> _decodedList;
bool _isNextItemValue = true;
int _argc;
bool isCommand(char* argv);
void checkIfEnoughArgsAreProvided(int argc);
QList<CommandsType> CommandValueDecoder(char* argv[]);
void initCommandStrcut(char* argv, CommandsType& sample);
void checkIfNextItemShallBeValue(char* argv);
3 years ago
public:
CommandDecoder();
QList<CommandsType> decoderString() override;
QList<CommandsType> decoderString(int argc, char* argv[]) override;
3 years ago
};
#endif //COMMANDDECODER_H