Skip to content

Commit

Permalink
final override
Browse files Browse the repository at this point in the history
  • Loading branch information
taehyounpark committed Apr 10, 2024
1 parent e126b61 commit 0fb0fd8
Show file tree
Hide file tree
Showing 8 changed files with 40 additions and 40 deletions.
6 changes: 3 additions & 3 deletions extensions/queryosity/csv.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,14 +22,14 @@ class csv : public dataset::reader<csv> {
* @brief Parallelize the dataset for parallel processing.
* @param[in] nslots Requested concurrency.
*/
virtual void parallelize(unsigned int nslots) override;
virtual void parallelize(unsigned int nslots) final override;

/**
* @brief Partition the dataset for parallel processing.
* @returns Dataset partition.
*/
virtual std::vector<std::pair<unsigned long long, unsigned long long>>
partition() override;
partition() final override;

/**
* @brief Read a column.
Expand Down Expand Up @@ -58,7 +58,7 @@ template <typename T> class csv::cell : public column::reader<T> {
: m_value(), m_document(document), m_column_name(column_name) {};
virtual ~cell() = default;

virtual T const &read(unsigned int, unsigned long long) const override;
virtual T const &read(unsigned int, unsigned long long) const final override;

protected:
mutable T m_value;
Expand Down
6 changes: 3 additions & 3 deletions extensions/queryosity/hist.h
Original file line number Diff line number Diff line change
Expand Up @@ -64,21 +64,21 @@ class hist
* @param weight Selection weight value.
*/
virtual void fill(queryosity::column::observable<Vals>... columns,
double weight) override;
double weight) final override;

/**
* @brief Retrieve the result.
* @return The (smart pointer to) histogram.
*/
virtual std::shared_ptr<hist_t> result() const override;
virtual std::shared_ptr<hist_t> result() const final override;

/**
* @brief Merge results from multithreaded runs.
* @param[in] results Result from each multithreaded slot.
* @return Merged histogram.
*/
virtual std::shared_ptr<hist_t>
merge(std::vector<std::shared_ptr<hist_t>> const &results) const override;
merge(std::vector<std::shared_ptr<hist_t>> const &results) const final override;

protected:
std::shared_ptr<hist_t> m_hist;
Expand Down
6 changes: 3 additions & 3 deletions extensions/queryosity/json.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,14 @@ class json : public queryosity::dataset::reader<json> {
* @brief Parallelize the dataset for parallel processing.
* @param[in] nslots Requested concurrency.
*/
virtual void parallelize(unsigned int nslots) override;
virtual void parallelize(unsigned int nslots) final override;

/**
* @brief Partition the dataset for parallel processing.
* @returns Dataset partition.
*/
virtual std::vector<std::pair<unsigned long long, unsigned long long>>
partition() override;
partition() final override;

/**
* @brief Read a column.
Expand Down Expand Up @@ -70,7 +70,7 @@ template <typename T> class json::item : public queryosity::column::reader<T> {
* @param[in] entry Entry number.
*/
virtual const T &read(unsigned int slot,
unsigned long long entry) const override;
unsigned long long entry) const final override;

protected:
mutable T m_value;
Expand Down
16 changes: 8 additions & 8 deletions include/queryosity/lazy.h
Original file line number Diff line number Diff line change
Expand Up @@ -54,17 +54,17 @@ class lazy : public dataflow::node,

virtual ~lazy() = default;

virtual std::vector<Action *> const &get_slots() const override;
virtual std::vector<Action *> const &get_slots() const final override;

virtual void set_variation(const std::string &var_name, lazy var) override;
virtual void set_variation(const std::string &var_name, lazy var) final override;

virtual lazy &nominal() override;
virtual lazy &variation(const std::string &var_name) override;
virtual lazy const &nominal() const override;
virtual lazy const &variation(const std::string &var_name) const override;
virtual lazy &nominal() final override;
virtual lazy &variation(const std::string &var_name) final override;
virtual lazy const &nominal() const final override;
virtual lazy const &variation(const std::string &var_name) const final override;

virtual bool has_variation(const std::string &var_name) const override;
virtual std::set<std::string> get_variation_names() const override;
virtual bool has_variation(const std::string &var_name) const final override;
virtual std::set<std::string> get_variation_names() const final override;

template <typename To, typename V = Action,
std::enable_if_t<queryosity::is_column_v<V>, bool> = false>
Expand Down
14 changes: 7 additions & 7 deletions include/queryosity/lazy_varied.h
Original file line number Diff line number Diff line change
Expand Up @@ -41,15 +41,15 @@ class lazy<Act>::varied : public dataflow::node,
template <typename Derived>
varied &operator=(typename lazy<Derived>::varied const &);

virtual void set_variation(const std::string &var_name, lazy var) override;
virtual void set_variation(const std::string &var_name, lazy var) final override;

virtual lazy &nominal() override;
virtual lazy &variation(const std::string &var_name) override;
virtual lazy const &nominal() const override;
virtual lazy const &variation(const std::string &var_name) const override;
virtual lazy &nominal() final override;
virtual lazy &variation(const std::string &var_name) final override;
virtual lazy const &nominal() const final override;
virtual lazy const &variation(const std::string &var_name) const final override;

virtual bool has_variation(const std::string &var_name) const override;
virtual std::set<std::string> get_variation_names() const override;
virtual bool has_variation(const std::string &var_name) const final override;
virtual std::set<std::string> get_variation_names() const final override;

/**
* @brief Compound a cut to this selection.
Expand Down
2 changes: 1 addition & 1 deletion include/queryosity/query.h
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ class node : public action {

virtual void initialize(unsigned int slot, unsigned long long begin,
unsigned long long end) override;
virtual void execute(unsigned int slot, unsigned long long entry) override;
virtual void execute(unsigned int slot, unsigned long long entry) final override;
virtual void finalize(unsigned int slot) override;

virtual void count(double w) = 0;
Expand Down
16 changes: 8 additions & 8 deletions include/queryosity/todo.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,17 +32,17 @@ class todo : public dataflow::node,
todo(todo &&) = default;
todo &operator=(todo &&) = default;

virtual std::vector<Helper *> const &get_slots() const override;
virtual std::vector<Helper *> const &get_slots() const final override;

virtual void set_variation(const std::string &var_name, todo var) override;
virtual void set_variation(const std::string &var_name, todo var) final override;

virtual todo &nominal() override;
virtual todo &variation(const std::string &var_name) override;
virtual todo const &nominal() const override;
virtual todo const &variation(const std::string &var_name) const override;
virtual todo &nominal() final override;
virtual todo &variation(const std::string &var_name) final override;
virtual todo const &nominal() const final override;
virtual todo const &variation(const std::string &var_name) const final override;

virtual bool has_variation(const std::string &var_name) const override;
virtual std::set<std::string> get_variation_names() const override;
virtual bool has_variation(const std::string &var_name) const final override;
virtual std::set<std::string> get_variation_names() const final override;

/**
* @brief Evaluate the column definition with input columns.
Expand Down
14 changes: 7 additions & 7 deletions include/queryosity/todo_varied.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,15 @@ class todo<Helper>::varied : public dataflow::node,
varied(varied &&) = default;
varied &operator=(varied &&) = default;

virtual void set_variation(const std::string &var_name, todo var) override;
virtual void set_variation(const std::string &var_name, todo var) final override;

virtual todo &nominal() override;
virtual todo &variation(const std::string &var_name) override;
virtual todo const &nominal() const override;
virtual todo const &variation(const std::string &var_name) const override;
virtual todo &nominal() final override;
virtual todo &variation(const std::string &var_name) final override;
virtual todo const &nominal() const final override;
virtual todo const &variation(const std::string &var_name) const final override;

virtual bool has_variation(const std::string &var_name) const override;
virtual std::set<std::string> get_variation_names() const override;
virtual bool has_variation(const std::string &var_name) const final override;
virtual std::set<std::string> get_variation_names() const final override;

public:
template <
Expand Down

0 comments on commit 0fb0fd8

Please sign in to comment.