class NamedList

A named string container class. More...

Full nameTelEngine::NamedList
Definition#include <telengine.h>
InheritsTelEngine::String [public ]
Inherited byMessage
List of all Methods
Annotated List
Files
Globals
Hierarchy
Index

Public Methods


Detailed Description

This class holds a named list of named strings

 NamedList (const char *name)

NamedList

Creates a new named list.

Parameters:
nameName of the list - must not be NULL or empty

inline unsigned int  length ()

length

[const]

Get the number of parameters

Returns: Count of named strings

Reimplemented from String.

inline unsigned int  count ()

count

[const]

Get the number of non-null parameters

Returns: Count of existing named strings

NamedList & addParam (NamedString *param)

addParam

Add a named string to the parameter list.

Parameters:
paramParameter to add

NamedList & addParam (const char *name, const char *value)

addParam

Add a named string to the parameter list.

Parameters:
nameName of the new string
valueValue of the new string

NamedList & setParam (NamedString *param)

setParam

Set a named string in the parameter list.

Parameters:
paramParameter to set or add

NamedList & setParam (const char *name, const char *value)

setParam

Set a named string in the parameter list.

Parameters:
nameName of the string
valueValue of the string

NamedList & clearParam (const String &name)

clearParam

Clars all instances of a named string in the parameter list.

Parameters:
nameName of the string to remove

NamedString * getParam (const String &name)

getParam

[const]

Locate a named string in the parameter list.

Parameters:
nameName of parameter to locate

Returns: A pointer to the named string or NULL.

NamedString * getParam (unsigned int index)

getParam

[const]

Locate a named string in the parameter list.

Parameters:
indexIndex of the parameter to locate

Returns: A pointer to the named string or NULL.

const char * getValue (const String &name, const char *defvalue = 0)

getValue

[const]

Retrive the value of a named parameter.

Parameters:
nameName of parameter to locate
defvalueDefault value to return if not found

Returns: The string contained in the named parameter or the default


Generated by: kk on nyx on Sat Jun 4 19:29:41 2005, using kdoc 2.0a54.