namespace simix {
class Global {
-public:
+ kernel::context::ContextFactory* context_factory_ = nullptr;
- kernel::context::ContextFactory* context_factory = nullptr;
+public:
kernel::actor::ActorImpl* maestro_ = nullptr;
-
+ kernel::context::ContextFactory* get_context_factory() const { return context_factory_; }
+ void set_context_factory(kernel::context::ContextFactory* factory) { context_factory_ = factory; }
+ bool has_context_factory() const { return context_factory_ != nullptr; }
+ void destroy_context_factory()
+ {
+ delete context_factory_;
+ context_factory_ = nullptr;
+ }
};
}
}