controlcommand.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef _CONTROLCOMMAND_H
00018 #define _CONTROLCOMMAND_H
00019
00020 #include <QStringList>
00021
00022
00023 class ControlCommand
00024 {
00025 public:
00026 ControlCommand();
00027 ControlCommand(const QString &keyword);
00028 ControlCommand(const QString &keyword, const QString &arg);
00029 ControlCommand(const QString &keyword, const QStringList &args);
00030
00031
00032 QString keyword() const { return _keyword; }
00033
00034
00035 void setKeyword(const QString &keyword);
00036
00037
00038 void addArgument(const QString &arg);
00039
00040 void addArguments(const QStringList &args);
00041
00042
00043 void appendData(const QString &data);
00044
00045
00046
00047 QString toString() const;
00048
00049 private:
00050
00051 QString escape(const QString &str) const;
00052
00053 QString _keyword;
00054 QStringList _arguments;
00055 QStringList _data;
00056 };
00057
00058 #endif
00059