cbp2make
Makefile generation tool for Code::Blocks IDE
Public Member Functions | Private Attributes | List of all members
CGlobalVariableConfig Class Reference

Manages global compiler variables configuration. More...

#include <cbglobalvar.h>

Public Member Functions

void Clear (void)
 Resets the configuration to the initial state. More...
 
size_t Count (void) const
 Returns the number of variable sets in configuration. More...
 
CGlobalVariableSetGet (const size_t Index)
 Returns a set of variables by index. More...
 
CGlobalVariableSetFind (const CString &Name)
 Returns a set of variables by name. More...
 
CGlobalVariableSetAdd (const CString &Name)
 Adds new set of global compiler variables. More...
 
void AddDefault (void)
 Adds the 'default' set of variables. More...
 
void Remove (const CString &Name)
 Removes a set of variables. More...
 
void Read (const TiXmlElement *GlobalVariableConfigRoot)
 Reads the global compiler variable configuration from an XML document. More...
 
void Write (TiXmlElement *GlobalVariableConfigRoot)
 Writes the global compiler variable configuration to an XML document. More...
 
void Show (void)
 Prints the global compiler variable configuration contents to standard output. More...
 
 CGlobalVariableConfig (void)
 Creates global compiler variable configuration. More...
 
 ~CGlobalVariableConfig (void)
 Destroys global compiler variable configuration. More...
 

Private Attributes

std::vector< CGlobalVariableSet * > m_VariableSets
 List of variable sets. More...
 

Detailed Description

Manages global compiler variables configuration.

Configuration consists of a number of sets of variables.

Constructor & Destructor Documentation

◆ CGlobalVariableConfig()

CGlobalVariableConfig::CGlobalVariableConfig ( void  )

Creates global compiler variable configuration.

◆ ~CGlobalVariableConfig()

CGlobalVariableConfig::~CGlobalVariableConfig ( void  )

Destroys global compiler variable configuration.

Member Function Documentation

◆ Add()

CGlobalVariableConfig::Add ( const CString Name)

Adds new set of global compiler variables.

Parameters
Namename of the set.
Returns
pointer to the set of variables.

If a variable set with name Name already exists, new variable set will not be created.

◆ AddDefault()

CGlobalVariableConfig::AddDefault ( void  )

Adds the 'default' set of variables.

The default set cannot be removed. However, it can be cleared by a call Remove("default") which removes the existing default set and creates an empty default set again right away.

◆ Clear()

CGlobalVariableConfig::Clear ( void  )

Resets the configuration to the initial state.

◆ Count()

CGlobalVariableConfig::Count ( void  ) const
inline

Returns the number of variable sets in configuration.

Returns
number of sets.

◆ Find()

CGlobalVariableConfig::Find ( const CString Name)

Returns a set of variables by name.

Parameters
Namename of a set of variables.
Returns
pointer to a set of variables or NULL if a set with name Name does not exist.

◆ Get()

CGlobalVariableConfig::Get ( const size_t  Index)

Returns a set of variables by index.

Parameters
Indexindex of a set of variables.
Returns
pointer to a set of variables or NULL if a set with index Index does not exist.

◆ Read()

CGlobalVariableConfig::Read ( const TiXmlElement *  GlobalVariableConfigRoot)

Reads the global compiler variable configuration from an XML document.

Parameters
GlobalVariableConfigRootan element of XML document.

◆ Remove()

CGlobalVariableConfig::Remove ( const CString Name)

Removes a set of variables.

Parameters
Namename of set of global compiler variables.

◆ Show()

CGlobalVariableConfig::Show ( void  )

Prints the global compiler variable configuration contents to standard output.

◆ Write()

CGlobalVariableConfig::Write ( TiXmlElement *  GlobalVariableConfigRoot)

Writes the global compiler variable configuration to an XML document.

Parameters
GlobalVariableConfigRootan element of XML document.

Member Data Documentation

◆ m_VariableSets

CGlobalVariableConfig::m_VariableSets
private

List of variable sets.


The documentation for this class was generated from the following files: