Castor3D  ..
Public Member Functions | List of all members
Castor3D::Parameters Class Reference

Configuration parameters. More...

Public Member Functions

C3D_API Parameters ()
 Constructor. More...
 
C3D_API ~Parameters ()
 Destructor. More...
 
template<typename T >
bool Add (Castor::String const &p_name, T *p_values, uint32_t p_count)
 Adds a parameter. More...
 
template<typename T , uint32_t N>
bool Add (Castor::String const &p_name, T const(&p_values)[N])
 Adds a parameter. More...
 
template<typename T >
bool Add (Castor::String const &p_name, T const &p_value)
 Adds a parameter. More...
 
bool Add (Castor::String const &p_name, Castor::String const &p_value)
 Adds a string parameter. More...
 
template<typename T >
bool Set (Castor::String const &p_name, T const &p_value)
 Sets a parameter value. More...
 
template<typename T >
bool Get (Castor::String const &p_name, T *p_values, uint32_t p_count) const
 Retrieves a parameter value. More...
 
template<typename T >
bool Get (Castor::String const &p_name, T &p_value) const
 Retrieves a parameter value. More...
 
template<typename T , uint32_t N>
bool Get (Castor::String const &p_name, T(&p_values)[N]) const
 Retrieves a parameter value. More...
 
bool Get (Castor::String const &p_name, Castor::String &p_value) const
 Retrieves a parameter value. More...
 

Detailed Description

Configuration parameters.

Author
Sylvain DOREMUS
Version
0.7.0.0
Date
12/11/2012
Remarks
Pair of a name and binary data

Constructor & Destructor Documentation

◆ Parameters()

C3D_API Castor3D::Parameters::Parameters ( )
inline

Constructor.

◆ ~Parameters()

C3D_API Castor3D::Parameters::~Parameters ( )
inline

Destructor.

Member Function Documentation

◆ Add() [1/4]

template<typename T >
bool Castor3D::Parameters::Add ( Castor::String const &  p_name,
T *  p_values,
uint32_t  p_count 
)
inline

Adds a parameter.

Remarks
If a parameter with the given name already exists, nothing is done
Parameters
[in]p_nameThe parameter name
[in]p_valuesThe parameter values
[in]p_countThe values count
Returns
false if a parameter with the given name already exists

Referenced by Add().

+ Here is the caller graph for this function:

◆ Add() [2/4]

template<typename T , uint32_t N>
bool Castor3D::Parameters::Add ( Castor::String const &  p_name,
T const(&)  p_values[N] 
)
inline

Adds a parameter.

Remarks
If a parameter with the given name already exists, nothing is done
Parameters
[in]p_nameThe parameter name
[in]p_valuesThe parameter values
Returns
false if a parameter with the given name already exists

References Add().

+ Here is the call graph for this function:

◆ Add() [3/4]

template<typename T >
bool Castor3D::Parameters::Add ( Castor::String const &  p_name,
T const &  p_value 
)
inline

Adds a parameter.

Remarks
If a parameter with the given name already exists, nothing is done
Parameters
[in]p_nameThe parameter name
[in]p_valueThe parameter value
Returns
false if a parameter with the given name already exists

References Add().

+ Here is the call graph for this function:

◆ Add() [4/4]

bool Castor3D::Parameters::Add ( Castor::String const &  p_name,
Castor::String const &  p_value 
)
inline

Adds a string parameter.

Remarks
If a parameter with the given name already exists, nothing is done
Parameters
[in]p_nameThe parameter name
[in]p_valueThe parameter value
Returns
false if a parameter with the given name already exists

◆ Get() [1/4]

template<typename T >
bool Castor3D::Parameters::Get ( Castor::String const &  p_name,
T *  p_values,
uint32_t  p_count 
) const
inline

Retrieves a parameter value.

Parameters
[in]p_nameThe parameter name
[out]p_valuesThe parameter values
[in]p_countThe values available count
Returns
false if there is no parameter with the given name

Referenced by Get().

+ Here is the caller graph for this function:

◆ Get() [2/4]

template<typename T >
bool Castor3D::Parameters::Get ( Castor::String const &  p_name,
T &  p_value 
) const
inline

Retrieves a parameter value.

Parameters
[in]p_nameThe parameter name
[out]p_valueThe parameter value
Returns
false if there is no parameter with the given name

References Get().

+ Here is the call graph for this function:

◆ Get() [3/4]

template<typename T , uint32_t N>
bool Castor3D::Parameters::Get ( Castor::String const &  p_name,
T(&)  p_values[N] 
) const
inline

Retrieves a parameter value.

Parameters
[in]p_nameThe parameter name
[out]p_valuesThe parameter values
Returns
false if there is no parameter with the given name

References Get().

+ Here is the call graph for this function:

◆ Get() [4/4]

bool Castor3D::Parameters::Get ( Castor::String const &  p_name,
Castor::String &  p_value 
) const
inline

Retrieves a parameter value.

Parameters
[in]p_nameThe parameter name
[out]p_valueThe parameter value
Returns
false if there is no parameter with the given name

◆ Set()

template<typename T >
bool Castor3D::Parameters::Set ( Castor::String const &  p_name,
T const &  p_value 
)
inline

Sets a parameter value.

Parameters
[in]p_nameThe parameter name
[in]p_valueThe parameter value
Returns
false if there is no parameter with the given name

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