dart
Public Types | Public Member Functions | Protected Attributes | List of all members
dart::common::ProxyCloneable< Base, OwnerT, DataT, setData, getData > Class Template Reference
Inheritance diagram for dart::common::ProxyCloneable< Base, OwnerT, DataT, setData, getData >:
Inheritance graph
[legend]
Collaboration diagram for dart::common::ProxyCloneable< Base, OwnerT, DataT, setData, getData >:
Collaboration graph
[legend]

Public Types

using Data = DataT
 
using Owner = OwnerT
 

Public Member Functions

 ProxyCloneable ()
 Default constructor. Constructs a default version of Data.
 
 ProxyCloneable (OwnerT *owner)
 Constructor that ties this instance to an Owner.
 
template<typename... Args>
 ProxyCloneable (OwnerT *owner, Args &&... args)
 Constructor that ties this instance to an Owner and then sets its data using the remaining arguments. More...
 
template<typename... Args>
 ProxyCloneable (Args &&... args)
 Templated constructor. More...
 
 ProxyCloneable (const ProxyCloneable &other)
 Copy constructor.
 
 ProxyCloneable (ProxyCloneable &&other)
 Move constructor.
 
ProxyCloneableoperator= (const Data &data)
 Copy assignment operator that uses a Data instance.
 
ProxyCloneableoperator= (Data &&other)
 Move assignment operator that uses a Data instance.
 
ProxyCloneableoperator= (const ProxyCloneable &other)
 Copy assignment operator.
 
ProxyCloneableoperator= (ProxyCloneable &&other)
 Move assignment operator.
 
void set (const Data &data)
 Set the Data of this ProxyCloneable.
 
void set (Data &&data)
 Set the Data of this ProxyCloneable.
 
void set (const ProxyCloneable &other)
 Set the Data of this ProxyCloneable based on another.
 
void set (ProxyCloneable &&other)
 Set the Data of this ProxyCloneable based on another.
 
Data get () const
 Get the Data of this ProxyCloneable.
 
OwnerT * getOwner ()
 Get the Owner of this ProxyCloneable.
 
const OwnerT * getOwner () const
 Get the Owner of this ProxyCloneable.
 
std::unique_ptr< Base > clone () const override final
 
void copy (const Base &other) override final
 

Protected Attributes

OwnerT * mOwner
 The ProxyCloneable will not store any data in mData if it has an Owner.
 
std::unique_ptr< Data > mData
 The ProxyCloneable will hold data in this field if it does not have an owner.
 

Constructor & Destructor Documentation

◆ ProxyCloneable() [1/2]

template<class Base , class OwnerT , class DataT , void(*)(OwnerT *, const DataT &) setData, DataT(*)(const OwnerT *) getData>
template<typename... Args>
dart::common::ProxyCloneable< Base, OwnerT, DataT, setData, getData >::ProxyCloneable ( OwnerT *  owner,
Args &&...  args 
)

Constructor that ties this instance to an Owner and then sets its data using the remaining arguments.

◆ ProxyCloneable() [2/2]

template<class Base , class OwnerT , class DataT , void(*)(OwnerT *, const DataT &) setData, DataT(*)(const OwnerT *) getData>
template<typename... Args>
dart::common::ProxyCloneable< Base, OwnerT, DataT, setData, getData >::ProxyCloneable ( Args &&...  args)

Templated constructor.

Uses whichever Data constructor is able to match the arguments.


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