PixelLightAPI  .
Public Member Functions
PLCore::ParamsParser Class Reference

Class for parsing parameters. More...

#include <ParamsParser.h>

List of all members.

Public Member Functions

 ParamsParser ()
 Constructor.
 ~ParamsParser ()
 Destructor.
PLCORE_API bool ParseString (const String &sParameters)
 Parse parameter string.
PLCORE_API bool Next ()
 Parse next parameter.
bool HasParam () const
 Check if the current (last parsed) parameter is valid.
String GetName () const
 Get name of currently parsed parameter.
String GetValue () const
 Get value of currently parsed parameter.

Detailed Description

Class for parsing parameters.

Remarks:
This class can parse parameter lists given as strings (e.g. "param1=\"hello" param2=10")

Constructor & Destructor Documentation

Destructor.


Member Function Documentation

PLCORE_API bool PLCore::ParamsParser::ParseString ( const String sParameters)

Parse parameter string.

Parameters:
[in]sParametersString containing parameters (e.g. "Param0=\"Hello" Param1=10)
Returns:
'true' if the string could be parsed, else 'false'
Remarks:
This will first check if the string is a valid parameter string and then parse the first parameter and value. If the string is not valid or empty, the function will return 'false'.
PLCORE_API bool PLCore::ParamsParser::Next ( )

Parse next parameter.

Returns:
'true' if the next name/value pair could be parsed, else 'false'
bool PLCore::ParamsParser::HasParam ( ) const [inline]

Check if the current (last parsed) parameter is valid.

Returns:
'true' if there is a current parameter, else 'false'

Get name of currently parsed parameter.

Returns:
Parameter name

Get value of currently parsed parameter.

Returns:
Parameter name

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


PixelLight PixelLight 0.9.11-R1
Copyright (C) 2002-2012 by The PixelLight Team
Last modified Thu Feb 23 2012 14:09:23
The content of this PixelLight document is published under the
Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported