Abstract singleton that provides interface to the container of GTPin configuration arguments (KNOBs)
More...
#include <igt_knob_registry.h>
Detailed Description
Abstract singleton that provides interface to the container of GTPin configuration arguments (KNOBs)
Member Function Documentation
| virtual GTPinKnob gtpin::IGtKnobRegistry::CreateArg |
( |
const char * |
name, |
|
|
const char * |
message, |
|
|
uint32_t |
flags, |
|
|
char |
symId, |
|
|
KNOB_TYPE |
knobType |
|
) |
| [pure virtual] |
Create a new Knob argument
- Parameters:
-
| [in] | name | Unique identifier of the Knob |
| [in] | message | Description of the Knob to be printed in the help message |
| [in] | flags | Combination of KNOB_FLAG properties |
| [in] | symId | Single-symbol identifier of the Knob in the command line, or \0 character if such identifier does not exist |
| [in] | knobType | Type of the Knob value(s) |
- Returns:
- Handle to the new Knob, or NULL if requested Knob cannot be created (e.g. due to name duplication) In case of error, the IGtCore::LastError() function provides the specific failure reason
| virtual GTPinKnob gtpin::IGtKnobRegistry::FindArg |
( |
const char * |
name | ) |
const [pure virtual] |
Find an existing Knob argument with the specified name
- Parameters:
-
| [in] | name | Identifier of the requested Knob |
- Returns:
- Handle to the requested Knob, or NULL if a Knob with the specified name does not exist
| virtual GTPinKnob gtpin::IGtKnobRegistry::GetArg |
( |
uint32_t |
argOrdinal | ) |
const [pure virtual] |
Get Knob argument with the specified ordinal number. This function can be used to iterate elements of this Knob registry.
- Parameters:
-
| [in] | argOrdinal | Ordinal number of a Knob argument - any integer in the [0, NumArgs()) range |
- Returns:
- Handle to the requested Knob
| bool gtpin::IGtKnobRegistry::GetArgValue |
( |
KnobValue & |
value, |
|
|
const char * |
name, |
|
|
uint32_t |
index = 0 |
|
) |
| const [inline] |
Get value of the Knob specified by its name
- Parameters:
-
| [out] | value | Structure that receives the requested Knob value and its type |
| [in] | name | The name of the Knob argument |
| [in] | index | Index of the requested element in the vector of values |
- Returns:
- true - success; false - the requested Knob is not found
| virtual uint32_t gtpin::IGtKnobRegistry::NumArgs |
( |
| ) |
const [pure virtual] |
- Returns:
- Total number of Knob arguments in the registry
| bool gtpin::IGtKnobRegistry::SetArgValue |
( |
const KnobValue & |
value, |
|
|
const char * |
name |
|
) |
| [inline] |
Set value of the Knob specified by its name
- Parameters:
-
| [in] | value | The Knob value to be set/added |
| [in] | name | The name of the Knob argument |
- Returns:
- true - success; false - the requested Knob is not found