SObjectizer 5.8
Loading...
Searching...
No Matches
so_5::disp::active_obj Namespace Reference

Active objects dispatcher. More...

Namespaces

namespace  impl
 Active objects dispatcher implemetation details.
 

Classes

class  disp_params_t
 Alias for namespace with traits of event queue. More...
 
class  dispatcher_handle_t
 A handle for active_obj dispatcher. More...
 

Functions

SO_5_FUNC dispatcher_handle_t make_dispatcher ( environment_t &env, const std::string_view data_sources_name_base, disp_params_t params)
 Create an instance of active_obj dispatcher.
 
dispatcher_handle_t make_dispatcher (environment_t &env, const std::string_view data_sources_name_base)
 Create an instance of active_obj dispatcher.
 
dispatcher_handle_t make_dispatcher (environment_t &env)
 Create a private active_obj dispatcher.
 

Detailed Description

Active objects dispatcher.

Function Documentation

◆ make_dispatcher() [1/3]

SO_5_FUNC dispatcher_handle_t so_5::disp::active_obj::make_dispatcher ( environment_t & env,
const std::string_view data_sources_name_base,
disp_params_t params )
nodiscard

Create an instance of active_obj dispatcher.

Usage sample
env,
"db_handler",
// Additional params with specific options for queue's traits.
[]( so_5::disp::active_obj::queue_traits::queue_params_t & p ) {
p.lock_factory( so_5::disp::active_obj::queue_traits::simple_lock_factory() );
} ) );
auto coop = env.make_coop(
// The main dispatcher for that coop will be
// this instance of active_obj dispatcher.
disp->binder() );
Alias for namespace with traits of event queue.
disp_params_t & tune_queue_params(L tunner)
Tuner for queue parameters.
SO_5_FUNC dispatcher_handle_t make_dispatcher(environment_t &env, const std::string_view data_sources_name_base, disp_params_t params)
Create an instance of active_obj dispatcher.
Since
v.5.6.0
Parameters
envSObjectizer Environment to work in.
data_sources_name_baseValue for creating names of data sources for run-time monitoring.
paramsParameters for dispatcher.
Examples
so_5/bind_transformer/main.cpp, so_5/chameneos_prealloc_msgs/main.cpp, so_5/chameneos_simple/main.cpp, so_5/child_soenv/main.cpp, so_5/disp/main.cpp, so_5/dispatcher_for_children/main.cpp, so_5/dispatcher_for_children_2/main.cpp, so_5/dispatcher_hello/main.cpp, so_5/dispatcher_restarts/main.cpp, so_5/many_timers/main.cpp, so_5/ping_pong/main.cpp, so_5/ping_pong_with_owner/main.cpp, so_5/queue_size_stats/main.cpp, and so_5/wrapped_env_demo_2/main.cpp.

Definition at line 318 of file active_obj/pub.cpp.

◆ make_dispatcher() [2/3]

dispatcher_handle_t so_5::disp::active_obj::make_dispatcher ( environment_t & env)
inline

Create a private active_obj dispatcher.

Usage sample
auto coop = env.make_coop(
// The main dispatcher for that coop will be
// this instance of active_obj dispatcher.
disp.binder() );
Since
v.5.6.0
Parameters
envSObjectizer Environment to work in.

Definition at line 250 of file active_obj/pub.hpp.

◆ make_dispatcher() [3/3]

dispatcher_handle_t so_5::disp::active_obj::make_dispatcher ( environment_t & env,
const std::string_view data_sources_name_base )
inline

Create an instance of active_obj dispatcher.

Usage sample
env,
"db_handler" );
auto coop = env.make_coop(
// The main dispatcher for that coop will be
// this instance of active_obj dispatcher.
disp.binder() );
Since
v.5.6.0
Parameters
envSObjectizer Environment to work in.
data_sources_name_baseValue for creating names of data sources for run-time monitoring.

Definition at line 223 of file active_obj/pub.hpp.