aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/dicealias.h
diff options
context:
space:
mode:
Diffstat (limited to 'dicealias.h')
-rw-r--r--dicealias.h29
1 files changed, 29 insertions, 0 deletions
diff --git a/dicealias.h b/dicealias.h
new file mode 100644
index 0000000..565b903
--- /dev/null
+++ b/dicealias.h
@@ -0,0 +1,29 @@
+#ifndef DICEALIAS_H
+#define DICEALIAS_H
+
+#include <QString>
+
+class DiceAlias
+{
+public:
+ enum RESOLUTION_TYPE { REPLACE,REGEXP};
+ DiceAlias(QString cmd, QString key, bool isReplace = true);
+ ~DiceAlias();
+
+ bool resolved(QString & str);
+
+ void setCommand(QString key);
+ void setValue(QString value);
+ void setType(RESOLUTION_TYPE );
+
+ QString getCommand();
+ QString getValue();
+ bool isReplace();
+private:
+ QString m_command;
+ QString m_value;
+ RESOLUTION_TYPE m_type;
+
+};
+
+#endif // DICEALIAS_H