aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/result/diceresult.h
diff options
context:
space:
mode:
authorRenaud G <renaud@rolisteam.org>2020-04-01 00:48:15 +0200
committerRenaud G <renaud@rolisteam.org>2020-04-01 00:48:15 +0200
commit4418146f8553c670be2548ad4e5c1d024e91e2ad (patch)
tree89807162cc56575f8560655da8e614995dc39417 /result/diceresult.h
parent14b2b264097cebb05237164f7320ad4b4fbbfba0 (diff)
downloadOneRoll-4418146f8553c670be2548ad4e5c1d024e91e2ad.tar.gz
OneRoll-4418146f8553c670be2548ad4e5c1d024e91e2ad.zip
New Api for string result subclass dice result.
Diffstat (limited to 'result/diceresult.h')
-rw-r--r--result/diceresult.h26
1 files changed, 13 insertions, 13 deletions
diff --git a/result/diceresult.h b/result/diceresult.h
index 8f30340..0ee622c 100644
--- a/result/diceresult.h
+++ b/result/diceresult.h
@@ -39,58 +39,58 @@ public:
/**
* @brief ~DiceResult
*/
- virtual ~DiceResult();
+ virtual ~DiceResult() override;
/**
* @brief getResultList
* @return
*/
- QList<Die*>& getResultList();
+ virtual QList<Die*>& getResultList();
/**
* @brief insertResult
*/
- void insertResult(Die*);
+ virtual void insertResult(Die*);
/**
* @brief setResultList
* @param list
*/
- void setResultList(QList<Die*> list);
+ virtual void setResultList(QList<Die*> list);
/**
* @brief getScalar
* @return
*/
- virtual QVariant getResult(Dice::RESULT_TYPE);
+ virtual QVariant getResult(Dice::RESULT_TYPE) override;
/**
* @brief toString
* @return
*/
- virtual QString toString(bool wl);
+ virtual QString toString(bool wl) override;
/**
* @brief isHomogeneous
*/
- bool isHomogeneous() const;
+ virtual bool isHomogeneous() const;
/**
* @brief setHomogeneous
*/
- void setHomogeneous(bool);
+ virtual void setHomogeneous(bool);
Die::ArithmeticOperator getOperator() const;
void setOperator(const Die::ArithmeticOperator& dieOperator);
bool contains(Die* die, const std::function<bool(const Die*, const Die*)> equal);
- void clear();
+ void clear() override;
- virtual Result* getCopy() const;
+ virtual Result* getCopy() const override;
-private:
+protected:
qreal getScalarResult();
-private:
+protected:
QList<Die*> m_diceValues;
bool m_homogeneous;
- Die::ArithmeticOperator m_operator;
+ Die::ArithmeticOperator m_operator= Die::ArithmeticOperator::PLUS;
};
Q_DECLARE_METATYPE(QList<Die*>)
#endif // DICERESULT_H