ppap4lmp  0.7.2
sta_copy.h
Go to the documentation of this file.
1 
9 #ifndef STA_COPY_H
10 #define STA_COPY_H
11 
12 #include <starters/starter.h>
13 
25 class StaCopy : public Starter {
26  protected:
28  static const bool do_sorting_by_id = false;
30  virtual void compute_impl(
31  Json &data,
32  JsonToVoidFunc check_required_keys,
33  JsonToBoolFunc check_optional_keys) override;
34  public:
44  StaCopy(
45  const ElPtr &elem);
46  virtual ~StaCopy() = default;
47 };
48 
49 #endif
ShPtr< Element > ElPtr
An alias for a shared pointer of Element class.
Definition: element.h:378
StaCopy(const ElPtr &elem)
Constructor of StaCopy class.
Definition: sta_copy.cpp:16
This file has a definition of Starter class, which is a subclass of Updater class.
std::function< bool(const Json &)> JsonToBoolFunc
An alias for a function accepts a Json object and returns a bool.
Definition: updater.h:20
nlohmann::json Json
Json is an alias for nlohmann::json.
Definition: json.h:22
virtual void compute_impl(Json &data, JsonToVoidFunc check_required_keys, JsonToBoolFunc check_optional_keys) override
This method overrides Updater::compute_impl.
Definition: sta_copy.cpp:24
static const bool do_sorting_by_id
Definition: sta_copy.h:28
Starter sets some properties to an empty Element object.
Definition: starter.h:24
StaCopy copies Element::data of an existing Element object and sets it to a new Element object...
Definition: sta_copy.h:25
std::function< void(const Json &)> JsonToVoidFunc
An alias for a function accepts a Json object.
Definition: updater.h:18