summaryrefslogtreecommitdiff
path: root/src/dictionary/ICardPack.h
diff options
context:
space:
mode:
authorJedidiah Barber <contact@jedbarber.id.au>2021-07-14 11:49:10 +1200
committerJedidiah Barber <contact@jedbarber.id.au>2021-07-14 11:49:10 +1200
commitd24f813f3f2a05c112e803e4256b53535895fc98 (patch)
tree601e6ae9a1cd44bcfdcf91739a5ca36aedd827c9 /src/dictionary/ICardPack.h
Initial mirror commitHEADmaster
Diffstat (limited to 'src/dictionary/ICardPack.h')
-rw-r--r--src/dictionary/ICardPack.h33
1 files changed, 33 insertions, 0 deletions
diff --git a/src/dictionary/ICardPack.h b/src/dictionary/ICardPack.h
new file mode 100644
index 0000000..9c8e4a2
--- /dev/null
+++ b/src/dictionary/ICardPack.h
@@ -0,0 +1,33 @@
+#ifndef ICARDPACK_H
+#define ICARDPACK_H
+
+#include <QString>
+#include <QList>
+
+#include "../study/StudyRecord.h"
+
+class DicRecord;
+class Field;
+
+class ICardPack
+{
+public:
+ static const QString SynonymDelimiter;
+ static const QString HomonymDelimiter;
+
+public:
+ virtual ~ICardPack() {}
+
+ virtual void addStudyRecord(const QString aCardId,
+ const StudyRecord& aStudyRecord) = 0;
+ virtual QList<StudyRecord> getStudyRecords(QString cardId) const = 0;
+ virtual StudyRecord getStudyRecord(QString cardId) const = 0;
+
+ virtual QList<DicRecord*> getRecords() const = 0;
+ virtual const Field* getQuestionField() const = 0;
+ virtual QList<const Field*> getAnswerFields() const = 0;
+ QString getQuestionFieldName() const;
+ QStringList getAnswerFieldNames() const;
+};
+
+#endif