TuttleOFX
1
|
#include <OfxhPropertyTemplate.hpp>
Public Types | |
typedef OfxhPropertyTemplate< T > | This |
typedef T::Type | Type |
typedef T::ReturnType | ReturnType |
typedef T::APIType | APIType |
typedef T::APITypeConstless | APITypeConstless |
Public Member Functions | |
OfxhPropertyTemplate () | |
OfxhPropertyTemplate (const std::string &name, size_t dimension, bool pluginReadOnly, APIType defaultValue) | |
constructor | |
OfxhPropertyTemplate (const OfxhPropertyTemplate< T > &pt) | |
OfxhPropertyTemplate< T > * | clone () const |
override this to return a clone of the property | |
~OfxhPropertyTemplate () | |
bool | operator== (const OfxhProperty &other) const |
bool | operator== (const This &other) const |
void | copyValues (const OfxhProperty &other) |
void | copyValues (const This &other) |
const std::vector< Type > & | getValues () const |
get the vector | |
void | getValueN (APIType *value, int count) const OFX_EXCEPTION_SPEC |
ReturnType | getValue (int index=0) const OFX_EXCEPTION_SPEC |
get one value | |
ReturnType | getValueRaw (int index=0) const OFX_EXCEPTION_SPEC |
get one value, without going through the getHook | |
void | getValueNRaw (APIType *value, const int count) const OFX_EXCEPTION_SPEC |
void | setValue (const Type &value, const int index=0, const EModifiedBy who=eModifiedByHost) OFX_EXCEPTION_SPEC |
set one value | |
void | setValueN (const APIType *value, const int count, const EModifiedBy who=eModifiedByHost) OFX_EXCEPTION_SPEC |
set multiple values | |
void | reset () OFX_EXCEPTION_SPEC |
reset | |
size_t | getDimension () const OFX_EXCEPTION_SPEC |
get the size of the vector | |
std::string | getStringValueAt (int index=0) const |
return the value as a string | |
ReturnType | getConstlessValue (int index=0) const OFX_EXCEPTION_SPEC |
ReturnType | getConstlessValueRaw (int index=0) const OFX_EXCEPTION_SPEC |
APITypeConstless | getAPIConstlessValue (int index=0) const OFX_EXCEPTION_SPEC |
Our pointer property. | |
template<> | |
void | getValueN (OfxhStringValue::APIType *values, int count) const OFX_EXCEPTION_SPEC |
Protected Attributes | |
std::vector< Type > | _value |
this is the present value of the property | |
std::vector< Type > | _defaultValue |
this is the default value of the property | |
Private Member Functions | |
template<class Archive > | |
void | serialize (Archive &ar, const unsigned int version) |
Friends | |
class | boost::serialization::access |
this represents a generic property. template parameter T is the type descriptor of the type of property to model. the class holds an internal _value vector which can be used to store the values. if set and get hooks are installed, these will be called instead of using this variable. Make sure that T::ReturnType is const if appropriate, as no extra qualifiers are applied here.
Definition at line 90 of file OfxhPropertyTemplate.hpp.
typedef T::APIType tuttle::host::ofx::property::OfxhPropertyTemplate< T >::APIType |
Definition at line 96 of file OfxhPropertyTemplate.hpp.
typedef T::APITypeConstless tuttle::host::ofx::property::OfxhPropertyTemplate< T >::APITypeConstless |
Definition at line 97 of file OfxhPropertyTemplate.hpp.
typedef T::ReturnType tuttle::host::ofx::property::OfxhPropertyTemplate< T >::ReturnType |
Definition at line 95 of file OfxhPropertyTemplate.hpp.
typedef OfxhPropertyTemplate<T> tuttle::host::ofx::property::OfxhPropertyTemplate< T >::This |
Reimplemented from tuttle::host::ofx::property::OfxhProperty.
Definition at line 93 of file OfxhPropertyTemplate.hpp.
typedef T::Type tuttle::host::ofx::property::OfxhPropertyTemplate< T >::Type |
Definition at line 94 of file OfxhPropertyTemplate.hpp.
tuttle::host::ofx::property::OfxhPropertyTemplate< T >::OfxhPropertyTemplate | ( | ) |
Definition at line 80 of file OfxhPropertyTemplate.cpp.
Referenced by tuttle::host::ofx::property::OfxhPropertyTemplate< T >::clone().
tuttle::host::ofx::property::OfxhPropertyTemplate< T >::OfxhPropertyTemplate | ( | const std::string & | name, |
size_t | dimension, | ||
bool | pluginReadOnly, | ||
APIType | defaultValue | ||
) |
constructor
Definition at line 85 of file OfxhPropertyTemplate.cpp.
References tuttle::host::ofx::property::OfxhPropertyTemplate< T >::_defaultValue, and tuttle::host::ofx::property::OfxhPropertyTemplate< T >::_value.
tuttle::host::ofx::property::OfxhPropertyTemplate< T >::OfxhPropertyTemplate | ( | const OfxhPropertyTemplate< T > & | pt | ) |
Definition at line 108 of file OfxhPropertyTemplate.cpp.
tuttle::host::ofx::property::OfxhPropertyTemplate< T >::~OfxhPropertyTemplate | ( | ) | [inline] |
Definition at line 122 of file OfxhPropertyTemplate.hpp.
OfxhPropertyTemplate<T>* tuttle::host::ofx::property::OfxhPropertyTemplate< T >::clone | ( | ) | const [inline, virtual] |
override this to return a clone of the property
Implements tuttle::host::ofx::property::OfxhProperty.
Definition at line 117 of file OfxhPropertyTemplate.hpp.
References tuttle::host::ofx::property::OfxhPropertyTemplate< T >::OfxhPropertyTemplate().
void tuttle::host::ofx::property::OfxhPropertyTemplate< T >::copyValues | ( | const OfxhProperty & | other | ) | [inline, virtual] |
Implements tuttle::host::ofx::property::OfxhProperty.
Definition at line 157 of file OfxhPropertyTemplate.hpp.
References tuttle::host::ofx::property::OfxhProperty::getType().
void tuttle::host::ofx::property::OfxhPropertyTemplate< T >::copyValues | ( | const This & | other | ) | [inline, virtual] |
Implements tuttle::host::ofx::property::OfxhProperty.
Definition at line 167 of file OfxhPropertyTemplate.hpp.
References tuttle::host::ofx::property::OfxhProperty::_modifiedBy, and tuttle::host::ofx::property::OfxhPropertyTemplate< T >::_value.
String::APITypeConstless tuttle::host::ofx::property::String::getAPIConstlessValue | ( | int | index = 0 | ) | const [inline] |
Our pointer property.
Definition at line 226 of file OfxhPropertyTemplate.hpp.
References tuttle::host::ofx::property::OfxhPropertyTemplate< T >::getConstlessValue().
T::ReturnType tuttle::host::ofx::property::OfxhPropertyTemplate< T >::getConstlessValue | ( | int | index = 0 | ) | const |
Definition at line 133 of file OfxhPropertyTemplate.cpp.
Referenced by tuttle::host::ofx::property::OfxhPropertyTemplate< T >::getAPIConstlessValue().
T::ReturnType tuttle::host::ofx::property::OfxhPropertyTemplate< T >::getConstlessValueRaw | ( | int | index = 0 | ) | const |
Definition at line 199 of file OfxhPropertyTemplate.cpp.
References _value.
std::size_t tuttle::host::ofx::property::OfxhPropertyTemplate< T >::getDimension | ( | ) | const [virtual] |
get the size of the vector
get the dimension of the property
Implements tuttle::host::ofx::property::OfxhProperty.
Definition at line 283 of file OfxhPropertyTemplate.cpp.
References _value.
std::string tuttle::host::ofx::property::OfxhPropertyTemplate< T >::getStringValueAt | ( | int | index = 0 | ) | const [inline, virtual] |
return the value as a string
Implements tuttle::host::ofx::property::OfxhProperty.
Definition at line 216 of file OfxhPropertyTemplate.hpp.
References tuttle::host::ofx::property::OfxhPropertyTemplate< T >::_value.
T::ReturnType tuttle::host::ofx::property::OfxhPropertyTemplate< T >::getValue | ( | int | index = 0 | ) | const |
get one value
Definition at line 120 of file OfxhPropertyTemplate.cpp.
Referenced by tuttle::host::ofx::imageEffect::OfxhImageEffectNode::setupClipInstancePreferences().
void tuttle::host::ofx::property::OfxhPropertyTemplate< OfxhStringValue >::getValueN | ( | OfxhStringValue::APIType * | values, |
int | count | ||
) | const |
Definition at line 166 of file OfxhPropertyTemplate.cpp.
References tuttle::host::ofx::property::castToAPIType().
void tuttle::host::ofx::property::OfxhPropertyTemplate< T >::getValueN | ( | typename T::APIType * | values, |
int | count | ||
) | const |
Definition at line 151 of file OfxhPropertyTemplate.cpp.
void tuttle::host::ofx::property::OfxhPropertyTemplate< T >::getValueNRaw | ( | APIType * | value, |
const int | count | ||
) | const |
get multiple values, without going through the getHook
Definition at line 216 of file OfxhPropertyTemplate.cpp.
References _value, and tuttle::host::ofx::property::castToAPIType().
T::ReturnType tuttle::host::ofx::property::OfxhPropertyTemplate< T >::getValueRaw | ( | int | index = 0 | ) | const |
get one value, without going through the getHook
Definition at line 189 of file OfxhPropertyTemplate.cpp.
References _value.
const std::vector<Type>& tuttle::host::ofx::property::OfxhPropertyTemplate< T >::getValues | ( | ) | const [inline] |
get the vector
Definition at line 180 of file OfxhPropertyTemplate.hpp.
References tuttle::host::ofx::property::OfxhPropertyTemplate< T >::_value.
Referenced by tuttle::host::ofx::property::OfxhSet::findStringPropValueIndex().
bool tuttle::host::ofx::property::OfxhPropertyTemplate< T >::operator== | ( | const OfxhProperty & | other | ) | const [inline, virtual] |
Reimplemented from tuttle::host::ofx::property::OfxhProperty.
Definition at line 125 of file OfxhPropertyTemplate.hpp.
References tuttle::host::ofx::property::OfxhProperty::getType().
bool tuttle::host::ofx::property::OfxhPropertyTemplate< T >::operator== | ( | const This & | other | ) | const [inline, virtual] |
Reimplemented from tuttle::host::ofx::property::OfxhProperty.
Definition at line 135 of file OfxhPropertyTemplate.hpp.
References tuttle::host::ofx::property::OfxhPropertyTemplate< T >::_value, tuttle::host::ofx::property::ePropTypePointer, and tuttle::host::ofx::property::OfxhProperty::getType().
void tuttle::host::ofx::property::OfxhPropertyTemplate< T >::reset | ( | ) | [virtual] |
reset
Implements tuttle::host::ofx::property::OfxhProperty.
Definition at line 304 of file OfxhPropertyTemplate.cpp.
References _value, and tuttle::host::ofx::property::eModifiedByHost.
void tuttle::host::ofx::property::Pointer::serialize | ( | Archive & | ar, |
const unsigned int | version | ||
) | [inline, private] |
Reimplemented from tuttle::host::ofx::property::OfxhProperty.
Definition at line 231 of file OfxhPropertyTemplate.hpp.
References tuttle::host::ofx::property::OfxhPropertyTemplate< T >::_defaultValue, and tuttle::host::ofx::property::OfxhPropertyTemplate< T >::_value.
void tuttle::host::ofx::property::OfxhPropertyTemplate< T >::setValue | ( | const Type & | value, |
const int | index = 0 , |
||
const EModifiedBy | who = eModifiedByHost |
||
) |
set one value
Referenced by tuttle::host::ofx::attribute::OfxhClipImage::setBitDepthString(), tuttle::host::ofx::attribute::OfxhClipImage::setBitDepthStringIfUpper(), tuttle::host::ofx::attribute::OfxhClipImage::setBitDepthStringIfUpperAndNotModifiedByPlugin(), tuttle::host::ofx::attribute::OfxhClipImage::setComponentsString(), tuttle::host::ofx::attribute::OfxhClipImage::setComponentsStringIfNotModifiedByPlugin(), and tuttle::host::ofx::attribute::OfxhClipImage::setPixelAspectRatio().
void tuttle::host::ofx::property::OfxhPropertyTemplate< T >::setValueN | ( | const APIType * | value, |
const int | count, | ||
const EModifiedBy | who = eModifiedByHost |
||
) |
friend class boost::serialization::access [friend] |
Reimplemented from tuttle::host::ofx::property::OfxhProperty.
Definition at line 229 of file OfxhPropertyTemplate.hpp.
std::vector<Type> tuttle::host::ofx::property::OfxhPropertyTemplate< T >::_defaultValue [protected] |
this is the default value of the property
Definition at line 104 of file OfxhPropertyTemplate.hpp.
Referenced by tuttle::host::ofx::property::OfxhPropertyTemplate< T >::OfxhPropertyTemplate(), and tuttle::host::ofx::property::OfxhPropertyTemplate< T >::serialize().
std::vector<Type> tuttle::host::ofx::property::OfxhPropertyTemplate< T >::_value [protected] |
this is the present value of the property
Definition at line 101 of file OfxhPropertyTemplate.hpp.
Referenced by tuttle::host::ofx::property::OfxhPropertyTemplate< T >::copyValues(), tuttle::host::ofx::property::OfxhPropertyTemplate< T >::getStringValueAt(), tuttle::host::ofx::property::OfxhPropertyTemplate< T >::getValues(), tuttle::host::ofx::property::OfxhPropertyTemplate< T >::OfxhPropertyTemplate(), tuttle::host::ofx::property::OfxhPropertyTemplate< T >::operator==(), and tuttle::host::ofx::property::OfxhPropertyTemplate< T >::serialize().