Public interface of class OrdGroups. More...
#include <OrdGroups.h>
Related Functions | |
(Note that these are not member functions.) | |
void | OrdGroups_add_variable (OrdGroups_ptr self, node_ptr name, int group) |
Adds a new variable to the groups set. | |
void | OrdGroups_add_variables (OrdGroups_ptr self, NodeList_ptr vars, int group) |
Adds a list of variable to the groups set. | |
OrdGroups_ptr | OrdGroups_copy (const OrdGroups_ptr self) |
Class copy constructor. | |
OrdGroups_ptr | OrdGroups_create (void) |
Class constructor. | |
int | OrdGroups_create_group (OrdGroups_ptr self) |
Creates a new group, and returns the group ID for future reference. | |
void | OrdGroups_destroy (OrdGroups_ptr self) |
Class destructor. | |
int | OrdGroups_get_size (const OrdGroups_ptr self) |
Returns the number of available groups. | |
int | OrdGroups_get_var_group (const OrdGroups_ptr self, node_ptr name) |
Given a var name, it returns the group that variable belongs to. | |
NodeList_ptr | OrdGroups_get_vars_in_group (const OrdGroups_ptr self, int group) |
Returns the set of variables that belong to a given group. |
Public interface of class OrdGroups.
Set of groups of vars. Variables can be organized in groups, and the class provides methods that allow for searching the group one variable belongs to, and the set of variables that a group contains.
void OrdGroups_add_variable | ( | OrdGroups_ptr | self, | |
node_ptr | name, | |||
int | group | |||
) | [related] |
Adds a new variable to the groups set.
The addition is performed only if the variable has not been already added to the same group. If the variable has been already added but to a different group, an error occurs. The group must be already existing.
void OrdGroups_add_variables | ( | OrdGroups_ptr | self, | |
NodeList_ptr | vars, | |||
int | group | |||
) | [related] |
Adds a list of variable to the groups set.
The addition of each variable is performed only if the variable has not been already added to the same group. If the variable has been already added but to a different group, an error occurs. The group must be already existing.
OrdGroups_ptr OrdGroups_copy | ( | const OrdGroups_ptr | self | ) | [related] |
Class copy constructor.
Returned instance is a copy of self
OrdGroups_ptr OrdGroups_create | ( | void | ) | [related] |
Class constructor.
int OrdGroups_create_group | ( | OrdGroups_ptr | self | ) | [related] |
Creates a new group, and returns the group ID for future reference.
void OrdGroups_destroy | ( | OrdGroups_ptr | self | ) | [related] |
Class destructor.
int OrdGroups_get_size | ( | const OrdGroups_ptr | self | ) | [related] |
Returns the number of available groups.
int OrdGroups_get_var_group | ( | const OrdGroups_ptr | self, | |
node_ptr | name | |||
) | [related] |
Given a var name, it returns the group that variable belongs to.
-1 is returned if the variable does not belong to any group.
NodeList_ptr OrdGroups_get_vars_in_group | ( | const OrdGroups_ptr | self, | |
int | group | |||
) | [related] |
Returns the set of variables that belong to a given group.
Returned list instance still belongs to self.