Home | Index | universal Index | gsp Index | Examples | Tutorial

SIniFileComposite Class Reference

#include "ini__SIniFile.h"

Composite class for SIniFile. More...


Deriving Class(es)


Public Functions

SIniFileComposite ( ) 
~SIniFileComposite ( ) 
  • void 
addComponent SIniFile * pComponent 
  • void 
addComponent SIniFile * pComponent , unsigned long uIterLevel , ... ) 
  • void 
destroyAllComponents ( ) 
  • void 
destroyComponentAt ( unsigned long uIterLevel , ... ) 
  • void 
detachAllComponents ( ) 
getComponent ( unsigned long uIndex 
getComponentAt ( unsigned long uIterLevel , ... ) 
  • unsigned long 
getNbComponents ( ) const 
lastComponent ( ) 
operator ()( unsigned int uIterLevel , ... ) 
ptr ( unsigned int uIterLevel , ... ) 
  • void 
setComponent SIniFile * pComponent , unsigned long uIndex 
  • void 
setComponentAt SIniFile * pComponent , unsigned long uIterLevel , ... ) 

Protected Functions

  • void 
ensureComponentCapacity ( unsigned long uMinCapacity 
getComponentAt ( unsigned long uIterLevel , va_list arg 

Protected Variables

m_apComponents 
  • unsigned long 
m_uCapacity 
  • unsigned long 
m_uNbComponents 

Private Variables

  • bool 
m_bComponentsDetached 

Detailed Description

Composite class for SIniFile. Used to store instances of symbol iterations.


Files Included

#include <stdarg.h>
#include "gsp__Symbol.h"

Functions Documentation

SIniFileComposite ( ) 

Constructor. By default the composite is empty.

See also:

Back to index

~SIniFileComposite ( )   [  virtual  ] 

Destructor. By default the composite is empty.

See also:

Back to index

void ensureComponentCapacity ( unsigned long uMinCapacity   [  protected  ] 

Components-related management function.

Manages the memory slots used to store pointers to sub components (symbols) (when the symbol is iterative). Re-allocates the memory slots if necessary to ensure that at least uMinCapacity pointers can be stored. If the slots must be increased, the new slot capacity is at least doubled if this is sufficient.

See also:

Back to index

void addComponent SIniFile * pComponent 

Adds a sub component for this symbol.

See also:

Back to index

void addComponent SIniFile * pComponent , unsigned long uIterLevel , ... ) 

Adds a sub component to a composite of a given hierarchy, creating missing intermediate composites. uIterLevel gives the depth of the hierarchy. ... gives the indexes of the sub composites for each hierarchy level.

Note: uIterLevel can't be zero. If so this function does nothing.

See also:

Back to index

SIniFile * lastComponent ( ) 

Returns the last sub component.

See also:

Back to index

SIniFile * getComponent ( unsigned long uIndex 

Returns the sub component of the specified index.

See also:

Back to index

SIniFile * getComponentAt ( unsigned long uIterLevel , ... ) 

Equivalent to the function referred to below, except that a various number of parameter can be given to the function.

See also:

SIniFile * SIniFileComposite::getComponentAt ( unsigned long uIterLevel , va_list arg 
Back to index

SIniFile * getComponentAt ( unsigned long uIterLevel , va_list arg   [  protected  ] 

Returns the sub component of the specified index. Allows to get a random sub component from the composite hierarchy.

uIterLevel gives the depth of the hierarchy. ... gives the indexes of the sub composites for each hierarchy level.

See also:

Back to index

SIniFile & operator ()( unsigned int uIterLevel , ... ) 

Does the same as the function referred to below, except a reference to the object is returned.

See also:

SIniFile * SIniFileComposite::getComponentAt ( unsigned long uIterLevel , va_list arg 
Back to index

SIniFile * ptr ( unsigned int uIterLevel , ... ) 

Does the same as the function referred to below, except that a pointer to the object is returned and that no parse error is raised if the pointer is NULL. Any by-pointer reference (e.g. &1) in reduction codes is replaced by a call to this operator.

See also:

SIniFile & operator ()( unsigned int uIterLevel , ... ) 
Back to index

void setComponentAt SIniFile * pComponent , unsigned long uIterLevel , ... ) 

Sets pComponent as the sub component of the specified index uIterLevel. Allows to set a random sub component into the composite hierarchy.

uIterLevel gives the depth of the hierarchy. ... gives the indexes of the sub composites for each hierarchy level.

Note: uIterLevel can't be zero. If so this function does nothing.

See also:

Back to index

void setComponent SIniFile * pComponent , unsigned long uIndex 

Sets pComponent as the component of the specified index uIndex.

This is a no-op if uIndex >= the number of components.

See also:

Back to index

void detachAllComponents ( ) 

Detaches all components from this composite. This means that components are not destroyed when this composite is.

See also:

Back to index

void destroyComponentAt ( unsigned long uIterLevel , ... ) 

Destroys the sub component of the specified index.

uIterLevel gives the depth of the hierarchy. ... gives the indexes of the sub composites for each hierarchy level.

See also:

Back to index

void destroyAllComponents ( ) 

Destroys all sub components and resets any reference to them.

See also:

Back to index

unsigned long getNbComponents ( ) const 

Returns the number of components contained by this composite. Note that these components may themselves be composites.

See also:

Back to index


This file is part of the LLOOP LL Object-Oriented Parser Generator and Object Expander Generator. Copyright (c) 2005-2006 Michel MEHL, France. All rights reserved. LLOOP is distributed by the company ERSA SaRL.


Copyright (c) 2005-2006 Michel MEHL, Haguenau, France
LLOOP version 1.1


Generated with makedoc.