GTPin

- Main Page
- Related Pages
- Modules
- Data Structures

- Data Structures
- Data Structure Index
- Class Hierarchy
- Data Fields

Public Member Functions
gtpin::IGtKnobArg Class Reference
GTPin: Configuration

Abstract class that represents GTPin configuration argument (KNOB) More...

`#include <igt_knob_arg.h>`

## Public Member Functions
virtual bool | AddValue (const KnobValue &value)=0
virtual bool | GetValue (KnobValue &value, uint32_t index) const =0
virtual uint32_t | NumValues () const =0
virtual void | GetDescriptor (KnobDescriptor &dsc) const =0
virtual void | Reset ()=0

## Detailed Description

Abstract class that represents GTPin configuration argument (KNOB)

## Member Function Documentation

virtual bool gtpin::IGtKnobArg::AddValue | ( | const KnobValue & | value | ) | `[pure virtual]`

Assign a new value element to this argument. If this is a vector-value Knob (KNOB_FLAG_VECTOR), append the new value to the vector. Otherwise, if this is a scalar-value Knob, replace the old value with the new one.

Parameters:

  [in] | value | New value of the Knob. Its type must match the type of the Knob, as specified at Knob creation.

Returns:
  Success/failure status

virtual void gtpin::IGtKnobArg::GetDescriptor | ( | KnobDescriptor & | dsc | ) | const`[pure virtual]`

Copy descriptor of this argument into 'dsc' structure

virtual bool gtpin::IGtKnobArg::GetValue | ( | KnobValue & | value,
|  | uint32_t | index
| ) |  | const`[pure virtual]`

Get a value element specified by its position in the vector of argument's values

Note:
  Vector-value Knob (KNOB_FLAG_VECTOR) may have multiple value elements; scalar-value Knob has a single value element and its position is zero.
  For a Knob of type KNOB_TYPE_STRING, the returned C-string could be invalidated when the Knob is modified by a subsequent AddValue() call.

Parameters:

  [out] | value | Structure that receives the requested value and its type
  [in] | index | Index of the requested element in the vector of values. The index is any integer in the [0, NumValues()) range.

Returns:
  Success/failure status

virtual uint32_t gtpin::IGtKnobArg::NumValues | ( |  | ) | const`[pure virtual]`

Returns:
  Number of value elements associated with this argument

Note:
  Vector-value Knob (KNOB_FLAG_VECTOR) may have multiple value elements; scalar-value Knob has a single value element.

virtual void gtpin::IGtKnobArg::Reset | ( |  | ) | `[pure virtual]`

Reset value of the specified Knob. If 'knob' is associated with a vector of values, clear the vector. Otherwise, for scalar Knob, do nothing.

All Data Structures Functions Variables Typedefs Enumerations Enumerator

      Copyright (C) 2013-2025 Intel Corporation

      SPDX-License-Identifier: MIT