[4dc309] | 1 | /*
|
---|
| 2 | * SetShapeAction.def
|
---|
| 3 | *
|
---|
| 4 | * Created on: Sep 6, 2012
|
---|
| 5 | * Author: ankele
|
---|
| 6 | */
|
---|
| 7 |
|
---|
| 8 | // all includes and forward declarations necessary for non-integral types below
|
---|
| 9 | #include <boost/filesystem.hpp>
|
---|
| 10 |
|
---|
| 11 | #include "Parameters/Validators/DummyValidator.hpp"
|
---|
[98d03b] | 12 | #include "Parameters/Validators/Specific/ShapeNameValidator.hpp"
|
---|
[4dc309] | 13 | #include "Parameters/Validators/Specific/VectorPositiveComponentsValidator.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)(Vector)(Vector)(double)(double)(double)
|
---|
| 19 | #define paramtokens ("shape-type")("translation")("stretch")("angle-x")("angle-y")("angle-z")
|
---|
| 20 | #define paramdescriptions ("type of shape to create")("translation distance")("scaling factors")("rotation x")("rotation y")("rotation z")
|
---|
| 21 | #define paramdefaults (NOPARAM_DEFAULT)(PARAM_DEFAULT(Vector(0.,0.,0.)))(PARAM_DEFAULT(Vector(1.,1.,1.)))(PARAM_DEFAULT(0.))(PARAM_DEFAULT(0.))(PARAM_DEFAULT(0.))
|
---|
| 22 | #define paramreferences (shape_type)(translation)(stretch)(angle_x)(angle_y)(angle_z)
|
---|
| 23 | #define paramvalids \
|
---|
[98d03b] | 24 | (ShapeNameValidator()) \
|
---|
[4dc309] | 25 | (DummyValidator<Vector>()) \
|
---|
| 26 | (VectorPositiveComponentsValidator()) \
|
---|
| 27 | (DummyValidator<double>()) \
|
---|
| 28 | (DummyValidator<double>()) \
|
---|
| 29 | (DummyValidator<double>())
|
---|
| 30 |
|
---|
| 31 | #define statetypes (std::string)(Vector)(Vector)(double)(double)(double)
|
---|
| 32 | #define statereferences (old_type)(old_translation)(old_stretch)(old_angle_x)(old_angle_y)(old_angle_z)
|
---|
| 33 |
|
---|
| 34 | // some defines for all the names, you may use ACTION, STATE and PARAMS
|
---|
| 35 | #define CATEGORY Shape
|
---|
| 36 | #define MENUNAME "shape"
|
---|
| 37 | #define MENUPOSITION 1
|
---|
| 38 | #define ACTIONNAME SetShape
|
---|
| 39 | #define TOKEN "set-shape"
|
---|
| 40 |
|
---|
| 41 |
|
---|
| 42 | // finally the information stored in the ActionTrait specialization
|
---|
| 43 | #define DESCRIPTION "sets the properties for the next shape to be created by the shape factory"
|
---|
| 44 | #undef SHORTFORM
|
---|