The Set Class
[The Classes]

tbd More...


Modules

 The Set Interface

Typedefs

typedef Cmaid_Container Cmaid_Set
 Type definition of the Set Class.

Functions

CMAID_INLINE void * cmaid_set_add (Cmaid_Set *s, void *data)
 Adds an item to the set.
CMAID_INLINE void cmaid_set_remove (Cmaid_Set *s, const void *data)
 Removes the given item from the set.
CMAID_INLINE void * cmaid_set_get (Cmaid_Set *s, const void *data)


Detailed Description

tbd

XXX TBD


Function Documentation

CMAID_INLINE void* cmaid_set_add ( Cmaid_Set s,
void *  data 
)

Adds an item to the set.

Parameters:
s the set to add an item
data; the data to add
Returns:
Returns the adress of the element This function adds an item to the set given by the passed data. If there is already an item equal to the given data, no item is added. No matter if there was added a new item or not, the address returned points to the item which is now or has been in the set. If the container allocates the data for you, the pointer to the allocated address will be returned,

CMAID_INLINE void* cmaid_set_get ( Cmaid_Set s,
const void *  data 
)

Parameters:
s the set to find the item
data the item to be find
Returns:
The found data, or NULL
This function returns the address of the data belgonging to the found node this doesn't have to be the same like the data passed to the function, if the container creates a copy of it.

CMAID_INLINE void cmaid_set_remove ( Cmaid_Set s,
const void *  data 
)

Removes the given item from the set.

Parameters:
s the set to remove the item
data the item to remove
Returns:
Returns no value Rempves the item from the set if the container has allocated the memory the memory of the item is afterwards not safe to read.


Generated on Wed Aug 5 00:20:50 2009 for Cmaid by  doxygen 1.5.8