SimGrid  3.16
Versatile Simulation of Distributed Systems
simgrid::kernel::context::ContextFactory Class Referenceabstract

#include <Context.hpp>

Inheritance diagram for simgrid::kernel::context::ContextFactory:
simgrid::kernel::context::BoostContextFactory simgrid::kernel::context::RawContextFactory simgrid::kernel::context::ThreadContextFactory simgrid::kernel::context::UContextFactory

Public Member Functions

 ContextFactory (std::string name)
 
virtual ~ContextFactory ()
 
virtual Contextcreate_context (std::function< void()> code, void_pfn_smxprocess_t cleanup, smx_actor_t process)=0
 
virtual Contextattach (void_pfn_smxprocess_t cleanup_func, smx_actor_t process)
 Creates a context from the current context of execution. More...
 
virtual Contextcreate_maestro (std::function< void()> code, smx_actor_t process)
 
virtual void run_all ()=0
 
virtual Contextself ()
 
std::string const & name () const
 

Protected Member Functions

template<class T , class... Args>
T * new_context (Args &&... args)
 

Constructor & Destructor Documentation

◆ ContextFactory()

simgrid::kernel::context::ContextFactory::ContextFactory ( std::string  name)
inlineexplicit

◆ ~ContextFactory()

simgrid::kernel::context::ContextFactory::~ContextFactory ( )
virtualdefault

Member Function Documentation

◆ create_context()

◆ attach()

Context * simgrid::kernel::context::ContextFactory::attach ( void_pfn_smxprocess_t  cleanup_func,
smx_actor_t  process 
)
virtual

Creates a context from the current context of execution.

This will not work on all implementation of ContextFactory.

Reimplemented in simgrid::kernel::context::ThreadContextFactory.

◆ create_maestro()

Context * simgrid::kernel::context::ContextFactory::create_maestro ( std::function< void()>  code,
smx_actor_t  process 
)
virtual

◆ run_all()

◆ self()

Context * simgrid::kernel::context::ContextFactory::self ( )
virtual

◆ name()

std::string const& simgrid::kernel::context::ContextFactory::name ( ) const
inline

◆ new_context()

template<class T , class... Args>
T* simgrid::kernel::context::ContextFactory::new_context ( Args &&...  args)
inlineprotected

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