ADTF
Loading...
Searching...
No Matches
adtf::base::ant::property< T > Class Template Reference

#include <property.h>

Inherits adtf::base::ant::cPropertyBase.

Public Member Functions

 property ()
 CTOR.
 
 ~property ()=default
 DTOR.
 
 property (const property &oProperty)
 Copy CTOR.
 
 property (property &&oProperty)
 implementation of the move CTOR (but it is not moving yet)
 
propertyoperator= (const property &oValue)
 copy assignment
 
propertyoperator= (property &&oProperty)
 move assignment (its not moving yet)
 
 property (const adtf_util::cString &strName, const T &oValue)
 
 property (std_string_helper, std::string_view strName)
 
 property (const T &oValue)
 
const propertyoperator= (const T &oValue)
 
bool operator== (const property &oProperty) const
 
bool operator== (const T &oValue) const
 
GetValueT () const
 
tResult Set (const property &oProperty)
 
virtual const IPropertyValueGetValue () const
 
virtual IPropertyValueGetValue ()
 
virtual tResult SetValue (const IPropertyValue &oValue)
 
tResult Set (const IProperty &oProp)
 
- Public Member Functions inherited from adtf::base::ant::cPropertyBase
tResult GetName (IString &&strName) const override
 
bool HasProperties () const override
 
bool HasAttachedProperties () const override
 
tResult SetProperties (const IProperties &oProperties) override
 will copy given properties
 
tResult AttachProperties (const ucom::ant::iobject_ptr< IProperties > &pAttachedProperties) override
 will set given properties to be attached
 
tResult GetAttachedProperties (IProperty &oProperty) const override
 
tResult DetachProperties () override
 
tResult GetProperties (ucom::ant::iobject_ptr< IProperties > &pSubProperties) override
 get subproperties for writing access
 
tResult GetProperties (ucom::ant::iobject_ptr< const IProperties > &pSubProperties) const override
 get subproperties for readonly access
 
tResult SetName (const IString &strName) override
 

Additional Inherited Members

- Protected Attributes inherited from adtf::base::ant::cPropertyBase
util::cString m_strName
 
ucom::object_ptr< IPropertiesm_poSubProperties = nullptr
 
ucom::object_ptr< IPropertiesm_poAttachedProperties = nullptr
 

Detailed Description

template<typename T>
class adtf::base::ant::property< T >

Property property implementation template. Use this template to create an instance of an property with for the given value type T.

Template Parameters
TRaw Value type for the property.

Constructor & Destructor Documentation

◆ property() [1/3]

template<typename T>
adtf::base::ant::property< T >::property ( const adtf_util::cString & strName,
const T & oValue )
inline

CTOR with name an value.

Parameters
strName[in] Name of the property
oValue[in] Value of the property

◆ property() [2/3]

template<typename T>
adtf::base::ant::property< T >::property ( std_string_helper ,
std::string_view strName )
inline

CTOR with name an value.

Parameters
strName[in] Name of the property
oValue[in] Value of the property

◆ property() [3/3]

template<typename T>
adtf::base::ant::property< T >::property ( const T & oValue)
inline

CTOR with value.

Parameters
oValue[in] Value of the property

Member Function Documentation

◆ GetValue() [1/2]

template<typename T>
virtual IPropertyValue * adtf::base::ant::property< T >::GetValue ( )
inlinevirtual

◆ GetValue() [2/2]

template<typename T>
virtual const IPropertyValue * adtf::base::ant::property< T >::GetValue ( ) const
inlinevirtual

◆ GetValueT()

template<typename T>
T adtf::base::ant::property< T >::GetValueT ( ) const
inline

Get the containing value

Returns
The Value content of as T

◆ operator=()

template<typename T>
const property & adtf::base::ant::property< T >::operator= ( const T & oValue)
inline

value assignment

Parameters
oValue[in] Value of the property

◆ operator==() [1/2]

template<typename T>
bool adtf::base::ant::property< T >::operator== ( const property< T > & oProperty) const
inline

compare operator

Parameters
oProperty[in] property to compare to
Return values
trueThe value (only the value!) is equal.
falseThe value (only the value!) is not equal.

◆ operator==() [2/2]

template<typename T>
bool adtf::base::ant::property< T >::operator== ( const T & oValue) const
inline

compare operator

Parameters
oValue[in] value to compare to
Return values
trueThe value (only the value!) is equal.
falseThe value (only the value!) is not equal.

◆ Set() [1/2]

template<typename T>
tResult adtf::base::ant::property< T >::Set ( const IProperty & oProp)
inlinevirtual

◆ Set() [2/2]

template<typename T>
tResult adtf::base::ant::property< T >::Set ( const property< T > & oProperty)
inline

Sets the property value and name as COPY of oProperty.

Also every Subproperty is copied. If the oProperty has attached properties they will be referenced.

Returns
Standard Result Code

◆ SetValue()

template<typename T>
virtual tResult adtf::base::ant::property< T >::SetValue ( const IPropertyValue & oValue)
inlinevirtual

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