Template Class ActorThread

Inheritance Relationships

Base Types

Class Documentation

template<typename ActorT>
class ActorThread : public ActorT, private actorpp::detail::IActorThread

Wrapper around a class derived from Actor, which runs its void run() method in a thread, and its void exit() method in the destructor. For the thread to be cleaned up, exit must cause run to return.

This can’t be implemented nicely through regular inheritance, because the constructor of a base class can’t safely call derived methods, so we can’t start the thread from the constructor.

Public Functions

template<typename ...Args>
inline ActorThread(Args&&... args)
inline ~ActorThread()