source: src/Actions/PotentialAction/RemovePotentialAction.def

stable v1.7.0
Last change on this file was a4b917, checked in by Frederik Heber <frederik.heber@…>, 6 weeks ago

Adds add and remove potential actions.

  • DOC: Adds missing actions to userguide.
  • TESTS: added actions test case with undo, redo and various cases.
  • Property mode set to 100644
File size: 1.7 KB
Line 
1/*
2 * RemovePotentialAction.def
3 *
4 * Created on: Aug 17, 2025
5 * Author: heber
6 */
7
8// all includes and forward declarations necessary for non-integral types below
9#include "FunctionApproximation/FunctionModel.hpp"
10#include "Parameters/Validators/Specific/ElementValidator.hpp"
11#include "Parameters/Validators/Specific/PotentialTypeValidator.hpp"
12#include "Parameters/Validators/STLVectorValidator.hpp"
13#include "Potentials/SerializablePotential.hpp"
14
15// i.e. there is an integer with variable name Z that can be found in
16// ValueStorage by the token "Z" -> first column: int, Z, "Z"
17// "undefine" if no parameters are required, use (NOPARAM_DEFAULT) for each (undefined) default value
18#define paramtypes (std::string)(std::vector<const element *>)
19#define paramtokens ("remove-potential")("potential-charges")
20#define paramdescriptions ("potential type to remove")("charges specifying the potential")
21#define paramdefaults (NOPARAM_DEFAULT)(NOPARAM_DEFAULT)
22#define paramreferences (potential_type)(charges)
23#define paramvalids \
24(PotentialTypeValidator()) \
25(STLVectorValidator< std::vector<const element *> >(0,99, ElementValidator()))
26
27#define statetypes (std::string)(SerializablePotential::ParticleTypes_t)(FunctionModel::parameters_t)
28#define statereferences (potential_name)(chargenumbers)(potential_params)
29
30// some defines for all the names, you may use ACTION, STATE and PARAMS
31#define CATEGORY Potential
32#define MENUNAME "potential"
33#define MENUPOSITION 2
34#define ACTIONNAME RemovePotential
35#define TOKEN "remove-potential"
36
37
38// finally the information stored in the ActionTrait specialization
39#define DESCRIPTION "remove a present potential from the internal registry"
40#undef SHORTFORM
Note: See TracBrowser for help on using the repository browser.