dart
Public Types | Public Member Functions | List of all members
dart::common::EmbeddedStateAspect< CompositeT, StateDataT > Class Template Reference

This is the implementation of a standard embedded-state Aspect. More...

#include <EmbeddedAspect.hpp>

Inheritance diagram for dart::common::EmbeddedStateAspect< CompositeT, StateDataT >:
Inheritance graph
[legend]
Collaboration diagram for dart::common::EmbeddedStateAspect< CompositeT, StateDataT >:
Collaboration graph
[legend]

Public Types

using Base = CompositeTrackingAspect< CompositeT >
 
using Derived = EmbeddedStateAspect< CompositeT, StateDataT >
 
using Impl = detail::EmbeddedStateAspect< Base, Derived, StateDataT >
 
using State = typename Impl::State
 
using StateData = typename Impl::StateData
 
- Public Types inherited from dart::common::detail::EmbeddedStateAspect< CompositeTrackingAspect< CompositeT >, EmbeddedStateAspect< CompositeT, StateDataT >, StateDataT >
enum  DelegateTag
 
using Base = CompositeTrackingAspect< CompositeT >
 
using Derived = EmbeddedStateAspect< CompositeT, StateDataT >
 
using State = common::Aspect::MakeState< StateDataT >
 
using StateData = StateDataT
 
- Public Types inherited from dart::common::Aspect
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

template<typename... Args>
 EmbeddedStateAspect (Args &&... args)
 
- Public Member Functions inherited from dart::common::detail::EmbeddedStateAspect< CompositeTrackingAspect< CompositeT >, EmbeddedStateAspect< CompositeT, StateDataT >, StateDataT >
 EmbeddedStateAspect (const EmbeddedStateAspect &)=delete
 
 EmbeddedStateAspect ()
 Construct this Aspect without affecting the State.
 
 EmbeddedStateAspect (const T &arg1, RemainingArgs &&... remainingArgs)
 Construct this Aspect. More...
 
void setAspectState (const Aspect::State &state) override final
 
void setState (const State &state)
 Set the State of this Aspect.
 
const Aspect::StategetAspectState () const override final
 
const StategetState () const
 Get the State of this Aspect.
 
std::unique_ptr< AspectcloneAspect () const override
 
- Public Member Functions inherited from dart::common::CompositeTrackingAspect< CompositeT >
 CompositeTrackingAspect ()
 Default constructor.
 
CompositeT * getComposite ()
 Get the Composite of this Aspect.
 
const CompositeT * getComposite () const
 Get the Composite of this Aspect.
 
bool hasComposite () const
 Returns true if this Aspect has a Composite that matches CompositeType.
 
- Public Member Functions inherited from dart::common::Aspect
virtual ~Aspect ()=default
 Virtual destructor.
 
virtual void setAspectProperties (const Properties &someProperties)
 Set the Properties of this Aspect. By default, this does nothing.
 
virtual const PropertiesgetAspectProperties () const
 Get the Properties of this Aspect. More...
 

Additional Inherited Members

- Static Public Attributes inherited from dart::common::detail::EmbeddedStateAspect< CompositeTrackingAspect< CompositeT >, EmbeddedStateAspect< CompositeT, StateDataT >, StateDataT >
static constexpr void(* SetEmbeddedState )(Derived *, const State &)
 
static constexpr const State &(* GetEmbeddedState )(const Derived *)
 
- Protected Member Functions inherited from dart::common::detail::EmbeddedStateAspect< CompositeTrackingAspect< CompositeT >, EmbeddedStateAspect< CompositeT, StateDataT >, StateDataT >
 EmbeddedStateAspect (DelegateTag, const StateData &state, RemainingArgs &&... remainingArgs)
 Construct this Aspect using the StateData, and pass the remaining arguments into the constructor of the Base class. More...
 
 EmbeddedStateAspect (DelegateTag, BaseArgs &&... args)
 Construct this Aspect without affecting the State, and pass all the arguments into the constructor of the Base class. More...
 
void setComposite (Composite *newComposite) override
 Pass the temporary State of this Aspect into the new Composite.
 
void loseComposite (Composite *oldComposite) override
 Save the embedded State of this Composite before we remove the Aspect.
 
- Protected Attributes inherited from dart::common::detail::EmbeddedStateAspect< CompositeTrackingAspect< CompositeT >, EmbeddedStateAspect< CompositeT, StateDataT >, StateDataT >
std::unique_ptr< StatemTemporaryState
 After this Aspect is constructed and during transitions between Composite objects, this will hold the State of the Aspect. More...
 
- Protected Attributes inherited from dart::common::CompositeTrackingAspect< CompositeT >
CompositeT * mComposite
 Pointer to the current Composite of this Aspect.
 

Detailed Description

template<class CompositeT, typename StateDataT>
class dart::common::EmbeddedStateAspect< CompositeT, StateDataT >

This is the implementation of a standard embedded-state Aspect.

Inherit the EmbedState class (next class down in the header) to use this Aspect implementation.

For more control over how your embedded-state Aspect is implemented, you can use the detail::EmbeddedStateAspect class.


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