Lumiera  0.pre.03
»edit your freedom«
steam::control::test::anonymous_namespace{command-argument-test.cpp} Namespace Reference

Classes

struct  Sint5
 Dummy custom memento datatype. More...
 
struct  Tracker
 watching the instance creation of some parameter values More...
 

Functions

Tracker< string > captureState (Tracker< TimeVar >, Tracker< string > xstr, int)
 
void checkSerialisation (CmdClosure &clo)
 
void doIt (Tracker< TimeVar > time, Tracker< string > str, int rand)
 
int dummyC (int u, int o)
 
void dummyU (int, int, int)
 another dummy-UNDO function
 
void prepareEmptyMemento ()
 prepare a (singleton) empty value for the memento. More...
 
void showIt (CmdClosure &clo)
 
int twoRandomDigits ()
 
void undoIt (Tracker< TimeVar > time, Tracker< string >, int, Tracker< string > memento)
 

Variables

ostringstream protocol
 used to verify the test function calls
 

Function Documentation

◆ prepareEmptyMemento()

void steam::control::test::anonymous_namespace{command-argument-test.cpp}::prepareEmptyMemento ( )

prepare a (singleton) empty value for the memento.

Remarks
This is done prior to observing the Tracker instanceCnt, because this empty value obviously remains allocated forever. The memento is stored within a special holder to allow capturing memento state even from immutable values, which only can be copy constructed. This mechanism uses lib::NullValue to retrieve an empty placeholder value when the memento has not yet been captured.

Definition at line 104 of file command-argument-test.cpp.