ppap4lmp  0.7.2
add_special_bonds.h
Go to the documentation of this file.
1 
9 #ifndef ADD_SPECIAL_BONDS_H
10 #define ADD_SPECIAL_BONDS_H
11 
12 #include <adders/adder.h>
13 
32 class AddSpecialBonds : public Adder {
42  protected:
53  virtual void compute_impl(
54  Json &data,
55  JsonToVoidFunc check_required_keys,
56  JsonToBoolFunc check_optional_keys) override;
57  public:
88  const ElPtr &el_mols,
89  const Vec<Vec<int>> &scheme);
119  const ElPtr &el_mols,
120  const Map<int,Vec<Vec<int>>> &type_to_scheme);
121  virtual ~AddSpecialBonds() = default;
122 };
123 
124 #endif
ShPtr< Element > ElPtr
An alias for a shared pointer of Element class.
Definition: element.h:378
Adder adds new properties to a non-empty Element object.
Definition: adder.h:24
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
Map< int, Vec< Vec< int > > > mol_type_to_sbonds_list_in_mol
std::vector< T > Vec
Vec is an alias for vector (same as list in Python).
Definition: std.h:27
AddSpecialBonds(const ElPtr &el_mols, const Vec< Vec< int >> &scheme)
Constructor of AddSpecialBonds class for molecules all of whose type property are 1...
virtual void compute_impl(Json &data, JsonToVoidFunc check_required_keys, JsonToBoolFunc check_optional_keys) override
This method overrides Updater::compute_impl.
This file has a definition of Adder class, which is a subclass of Updater class.
std::function< void(const Json &)> JsonToVoidFunc
An alias for a function accepts a Json object.
Definition: updater.h:18
AddSpecialBonds adds special bonds.
std::unordered_map< T, U > Map
Map is an alias for unordered map (same as dict in Python).
Definition: std.h:38