DART
6.10.1
|
This is the implementation of a standard combination of embedded-state and embedded-properties Aspect. More...
#include <EmbeddedAspect.hpp>
Public Types | |
using | Derived = EmbeddedStateAndPropertiesAspect< CompositeT, StateDataT, PropertiesDataT > |
using | AspectStateImpl = detail::EmbeddedStateAspect< CompositeTrackingAspect< CompositeT >, Derived, StateDataT > |
using | AspectPropertiesImpl = detail::EmbeddedPropertiesAspect< AspectStateImpl, Derived, PropertiesDataT > |
using | AspectImpl = Derived |
using | State = typename AspectStateImpl::State |
using | StateData = typename AspectStateImpl::StateData |
using | Properties = typename AspectPropertiesImpl::Properties |
using | PropertiesData = typename AspectPropertiesImpl::PropertiesData |
using | CompositeType = CompositeT |
using | Base = detail::EmbeddedStateAspect< CompositeTrackingAspect< CompositeT >, EmbeddedStateAndPropertiesAspect< CompositeT, StateDataT, PropertiesDataT >, StateDataT > |
template<class Mixin > | |
using | MakeState = MakeCloneable< State, Mixin > |
Use the MakeState class to easily create a State extension from an existing class or struct. More... | |
template<class Mixin > | |
using | MakeProperties = MakeCloneable< Properties, Mixin > |
Use the MakeProperties class to easily create a Properties extension from an existing class or struct. More... | |
Public Member Functions | |
EmbeddedStateAndPropertiesAspect (const EmbeddedStateAndPropertiesAspect &)=delete | |
virtual | ~EmbeddedStateAndPropertiesAspect ()=default |
EmbeddedStateAndPropertiesAspect () | |
Construct using nothing. The object will remain unaffected. More... | |
EmbeddedStateAndPropertiesAspect (const StateData &state) | |
Construct using a State. The object's Properties will remain unaffected. More... | |
EmbeddedStateAndPropertiesAspect (const PropertiesData &properties) | |
Construct using Properties. The object's State will remain unaffected. More... | |
EmbeddedStateAndPropertiesAspect (const StateData &state, const PropertiesData &properties) | |
Construct using a State and Properties instance. More... | |
EmbeddedStateAndPropertiesAspect (const PropertiesData &properties, const StateData &state) | |
Construct using a Properties and State instance. More... | |
std::unique_ptr< Aspect > | cloneAspect () const override |
Clone this Aspect into a new composite. More... | |
void | setAspectProperties (const Aspect::Properties &properties) override final |
void | setProperties (const Properties &properties) |
const Aspect::Properties * | getAspectProperties () const override final |
const Properties & | getProperties () const |
void | setAspectState (const Aspect::State &state) override final |
void | setState (const State &state) |
Set the State of this Aspect. More... | |
const Aspect::State * | getAspectState () const override final |
const State & | getState () const |
Get the State of this Aspect. More... | |
CompositeT * | getComposite () |
Get the Composite of this Aspect. More... | |
const CompositeT * | getComposite () const |
Get the Composite of this Aspect. More... | |
bool | hasComposite () const |
Returns true if this Aspect has a Composite that matches CompositeType. More... | |
Static Public Attributes | |
constexpr static void(* | SetEmbeddedProperties )(Derived *, const Properties &) |
constexpr static const Properties &(* | GetEmbeddedProperties )(const Derived *) |
constexpr static void(* | SetEmbeddedState )(Derived *, const State &) |
constexpr static const State &(* | GetEmbeddedState )(const Derived *) |
Protected Types | |
enum | DelegateTag |
Protected Member Functions | |
void | setComposite (Composite *newComposite) override |
Pass the temporary Properties of this Aspect into the new Composite. More... | |
void | loseComposite (Composite *oldComposite) override |
Save the embedded Properties of this Composite before we remove the Aspect. More... | |
Protected Attributes | |
std::unique_ptr< Properties > | mTemporaryProperties |
After this Aspect is constructed and during transitions between Composite objects, this will hold the Properties of the Aspect. More... | |
std::unique_ptr< State > | mTemporaryState |
After this Aspect is constructed and during transitions between Composite objects, this will hold the State of the Aspect. More... | |
CompositeT * | mComposite |
Pointer to the current Composite of this Aspect. More... | |
This is the implementation of a standard combination of embedded-state and embedded-properties Aspect.
Inherit the EmbedStateAndProperties (next class down in the header) to use this Aspect implementation.
using dart::common::EmbeddedStateAndPropertiesAspect< CompositeT, StateDataT, PropertiesDataT >::AspectImpl = Derived |
using dart::common::EmbeddedStateAndPropertiesAspect< CompositeT, StateDataT, PropertiesDataT >::AspectPropertiesImpl = detail:: EmbeddedPropertiesAspect<AspectStateImpl, Derived, PropertiesDataT> |
using dart::common::EmbeddedStateAndPropertiesAspect< CompositeT, StateDataT, PropertiesDataT >::AspectStateImpl = detail::EmbeddedStateAspect< CompositeTrackingAspect<CompositeT>, Derived, StateDataT> |
|
inherited |
using dart::common::EmbeddedStateAndPropertiesAspect< CompositeT, StateDataT, PropertiesDataT >::CompositeType = CompositeT |
using dart::common::EmbeddedStateAndPropertiesAspect< CompositeT, StateDataT, PropertiesDataT >::Derived = EmbeddedStateAndPropertiesAspect< CompositeT, StateDataT, PropertiesDataT> |
|
inherited |
Use the MakeProperties class to easily create a Properties extension from an existing class or struct.
|
inherited |
Use the MakeState class to easily create a State extension from an existing class or struct.
using dart::common::EmbeddedStateAndPropertiesAspect< CompositeT, StateDataT, PropertiesDataT >::Properties = typename AspectPropertiesImpl::Properties |
using dart::common::EmbeddedStateAndPropertiesAspect< CompositeT, StateDataT, PropertiesDataT >::PropertiesData = typename AspectPropertiesImpl::PropertiesData |
using dart::common::EmbeddedStateAndPropertiesAspect< CompositeT, StateDataT, PropertiesDataT >::State = typename AspectStateImpl::State |
using dart::common::EmbeddedStateAndPropertiesAspect< CompositeT, StateDataT, PropertiesDataT >::StateData = typename AspectStateImpl::StateData |
|
protectedinherited |
|
delete |
|
virtualdefault |
|
inline |
Construct using nothing. The object will remain unaffected.
|
inline |
Construct using a State. The object's Properties will remain unaffected.
|
inline |
Construct using Properties. The object's State will remain unaffected.
|
inline |
Construct using a State and Properties instance.
|
inline |
Construct using a Properties and State instance.
|
inlineoverridevirtual |
Clone this Aspect into a new composite.
Implements dart::common::Aspect.
|
inlinefinaloverridevirtualinherited |
Reimplemented from dart::common::Aspect.
|
inlinefinaloverridevirtualinherited |
Reimplemented from dart::common::Aspect.
|
inherited |
|
inherited |
|
inlineinherited |
|
inlineinherited |
Get the State of this Aspect.
|
inherited |
|
inlineoverrideprotectedvirtualinherited |
Save the embedded Properties of this Composite before we remove the Aspect.
Reimplemented from dart::common::detail::EmbeddedStateAspect< CompositeTrackingAspect< CompositeT >, EmbeddedStateAndPropertiesAspect< CompositeT, StateDataT, PropertiesDataT >, StateDataT >.
|
inlinefinaloverridevirtualinherited |
Reimplemented from dart::common::Aspect.
|
inlinefinaloverridevirtualinherited |
Reimplemented from dart::common::Aspect.
|
inlineoverrideprotectedvirtualinherited |
Pass the temporary Properties of this Aspect into the new Composite.
Reimplemented from dart::common::detail::EmbeddedStateAspect< CompositeTrackingAspect< CompositeT >, EmbeddedStateAndPropertiesAspect< CompositeT, StateDataT, PropertiesDataT >, StateDataT >.
|
inlineinherited |
|
inlineinherited |
Set the State of this Aspect.
|
staticconstexprinherited |
|
staticconstexprinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
staticconstexprinherited |
|
staticconstexprinherited |