constants.h File Reference Detailed DescriptionDefinition of a table of constants that are pairs (identifier,value) used when processing input files (for instance .cuik files). The definition of constants are useful to facilitate the writting of the equations.
Definition in file constants.h.
Macro Definition Documentation
Initial room for constants.It will be enlarged if necessary.
Definition at line 26 of file constants.h. Referenced by InitConstants(). Function Documentation
Creates a new set of constants.
Definition at line 21 of file constants.c. References Tconstants::cts, INIT_NUM_CONSTANTS, Tconstants::max_constants, Tconstants::n, and NEW. Referenced by InitCuikSystem().
Initializes a set of constant with data from another set.
Definition at line 30 of file constants.c. References AddConstant(), Tconstants::cts, Tconstants::max_constants, Tconstants::n, Tconstant::name, NEW, and Tconstant::vs. Referenced by CopyCuikSystem(), and MergeConstants().
Merges the constats in to sets into a new set.
Definition at line 42 of file constants.c. References AddConstant(), CopyConstants(), Tconstants::cts, Tconstants::n, Tconstant::name, and Tconstant::vs. Referenced by CuikSystemMerge().
Returns the number of constants currently in the set.
Definition at line 55 of file constants.c. References Tconstants::n.
Adds a new constnat to the set. It does not test whether or not there is another constant with the same name. This must be tested before using AddConstant calling the function 'GetConstantWithName'
Definition at line 65 of file constants.c. References Tconstants::cts, Tconstants::max_constants, MEM_DUP, Tconstants::n, Tconstant::name, NEW, and Tconstant::vs. Referenced by CopyConstants(), and MergeConstants().
Determines the numerical identifier for a constant with a given name. It can be used also to check if a constant is included in the set or not.
Definition at line 88 of file constants.c. References Tconstants::cts, FALSE, Tconstant::name, NO_UINT, and TRUE.
Returns the value of a constant, given the numerical identifier of this constant.
Definition at line 113 of file constants.c. References Tconstants::cts, Error(), and Tconstant::vs.
Prints a set of constants into a stream, that can be stdout.
Definition at line 126 of file constants.c. References Tconstants::cts, Tconstants::n, Tconstant::name, and Tconstant::vs.
Deletes a set of constants.
Definition at line 137 of file constants.c. References Tconstants::cts, Tconstants::n, and Tconstant::name. Referenced by DeleteCuikSystem(). |
Follow us!