|
HDK
|
#include <BRAY_Interface.h>
Public Member Functions | |
| OptionSet () | |
| OptionSet (const OptionSet &src) | |
| OptionSet (const VPRM_OptionSetPtr &o) | |
| ~OptionSet () | |
| OptionSet & | operator= (const OptionSet &o) |
| OptionSet | duplicate () const |
| bool | canErase (int token) const |
| void | erase (const UT_Set< int > &tokens) |
| Erase properties. More... | |
| SYS_SAFE_BOOL | operator bool () const |
| exint | numProperties () const |
| Return the number of pre-defined properties in the option set. More... | |
| const UT_StringHolder & | name (int token) const |
| Return the name associated with a given option (i.e. dicingquality) More... | |
| UT_StringHolder | fullName (int token) const |
| Return the fully qualified name (i.e. karma::object::dicingquality) More... | |
| int | find (const UT_StringRef &name) const |
| Return the token associated with a given name (or -1 if invalid) More... | |
| template<typename T > | |
| const T * | import (int token, T *val, size_t n) const |
| template<typename T > | |
| bool | set (int token, const T *value, exint tuple_size) |
| template<typename T > | |
| SYS_FORCE_INLINE bool | set (int token, const T &value) |
| Simple interface to set a scalar property. More... | |
| template<typename T > | |
| bool | isEqual (int token, const T *value, exint tuple_size) const |
| Test whether a value is the same as the current property. More... | |
| template<typename T > | |
| SYS_FORCE_INLINE bool | isEqual (int token, const T &value) const |
| Simple interface for equality of a scalar value. More... | |
| bool | isVariadic (int token) const |
| Test whether an option has variadic arguments. More... | |
| exint | size (int token) const |
| Return the size of an option. This can be used for variadics. More... | |
| GT_Storage | storage (int token) const |
| bool | isValid () const |
| VPRM_OptionSetPtr & | options () |
| const VPRM_OptionSetPtr & | options () const |
| const bool * | bval (int token) const |
| const int64 * | ival (int token) const |
| const fpreal64 * | fval (int token) const |
| const UT_StringHolder * | sval (int token) const |
The OptionSet acts as a pointer to an underlying set of options for various different object types.
Definition at line 110 of file BRAY_Interface.h.
| BRAY::OptionSet::OptionSet | ( | ) |
| BRAY::OptionSet::OptionSet | ( | const OptionSet & | src | ) |
The copy c-tor will copy the underlying pointer, but refer to the same underlying object.
|
explicit |
| BRAY::OptionSet::~OptionSet | ( | ) |
| const bool* BRAY::OptionSet::bval | ( | int | token | ) | const |
Direct access to internal option data. There are no checks on these methods
| bool BRAY::OptionSet::canErase | ( | int | token | ) | const |
Returns true if property can be erased to revert back to default value. If the options aren't inherited (i.e. offline render), it cannot be erased.
| OptionSet BRAY::OptionSet::duplicate | ( | ) | const |
This will create a new OptionSet, inheriting state information from the this option set. Note that changing values in the this set may result in unexpected changes in the new option set.
| int BRAY::OptionSet::find | ( | const UT_StringRef & | name | ) | const |
Return the token associated with a given name (or -1 if invalid)
| UT_StringHolder BRAY::OptionSet::fullName | ( | int | token | ) | const |
Return the fully qualified name (i.e. karma::object::dicingquality)
Direct access to internal option data. There are no checks on these methods
| const T* BRAY::OptionSet::import | ( | int | token, |
| T * | val, | ||
| size_t | n | ||
| ) | const |
Import a property value. Method is specialized for T in:
| bool BRAY::OptionSet::isEqual | ( | int | token, |
| const T * | value, | ||
| exint | tuple_size | ||
| ) | const |
Test whether a value is the same as the current property.
|
inline |
Simple interface for equality of a scalar value.
Definition at line 189 of file BRAY_Interface.h.
|
inline |
Private access
Definition at line 139 of file BRAY_Interface.h.
| bool BRAY::OptionSet::isVariadic | ( | int | token | ) | const |
Test whether an option has variadic arguments.
Direct access to internal option data. There are no checks on these methods
| const UT_StringHolder& BRAY::OptionSet::name | ( | int | token | ) | const |
Return the name associated with a given option (i.e. dicingquality)
| exint BRAY::OptionSet::numProperties | ( | ) | const |
Return the number of pre-defined properties in the option set.
|
inline |
Bool operator to test validity of pointer
Definition at line 144 of file BRAY_Interface.h.
The assignment operator will change the pointer to the underlying object. Both OptionSets will point to the same underlying object.
|
inline |
Private access
Definition at line 140 of file BRAY_Interface.h.
|
inline |
Private access
Definition at line 141 of file BRAY_Interface.h.
Interface to set an property. This template class is specialized for:
|
inline |
Simple interface to set a scalar property.
Definition at line 178 of file BRAY_Interface.h.
Return the size of an option. This can be used for variadics.
| GT_Storage BRAY::OptionSet::storage | ( | int | token | ) | const |
Return the storage of an option. This will only be one of:
| const UT_StringHolder* BRAY::OptionSet::sval | ( | int | token | ) | const |
Direct access to internal option data. There are no checks on these methods