qb  2.0.0.0
C++17 Actor Framework
qb Issue Watch Star Fork Follow @isndev
Loading...
Searching...
No Matches

Base event types and core system events for actors. More...

Collaboration diagram for Core Event System:

Files

file  event.h
 Convenience header for the QB Event system.

Classes

class  qb::Actor::EventBuilder
 Helper class for building and sending events to actors. More...
struct  qb::type< T >
 Template struct used for type identification in the event system. More...
class  qb::Event
 Base class for all events in the actor system. More...
struct  qb::EventQOS0
 Event with lowest quality of service level. More...
class  qb::ServiceEvent
 Event type for service-to-service communication. More...
struct  qb::KillEvent
 Event used to terminate an actor. More...
struct  qb::UnregisterCallbackEvent
 Event used to unregister an actor's callback. More...
struct  qb::SignalEvent
 Event used to handle system signals. More...
struct  qb::PingEvent
 Event used for actor health checks. More...
struct  qb::RequireEvent
 Event used to query actor status. More...
struct  qb::WithData< _Args >
 Event template that includes data payload. More...
struct  qb::WithoutData< _Args >
 Event template without data payload. More...
struct  qb::AskData< _Args >
 Event template for requesting data, typically without carrying data itself. More...
struct  qb::FillEvent< _Args >
 Event template for events that carry and "fill" data. More...

Typedefs

using qb::EventQOS2 = Event
 Event with highest quality of service (priority level 2)
using qb::EventQOS1 = Event
 Event with medium quality of service (priority level 1)
using qb::VirtualPipe = allocator::pipe<EventBucket>
 Pipe for event transmission in the actor system.
using qb::event = Event
 Alias for the base Event class.
using qb::service_event = ServiceEvent
 Alias for the ServiceEvent class.

Enumerations

enum class  qb::ActorStatus : uint32_t { ActorStatus::Alive , ActorStatus::Dead }
 Represents the current status of an actor in the system. More...

Functions

template<typename T>
constexpr TypeId qb::type_id ()
 Function to get a unique type identifier for a given type.

Detailed Description

Base event types and core system events for actors.

Defines `qb::Event` and essential system events like `qb::KillEvent`. This group is for actor-level events.

Typedef Documentation

◆ EventQOS2

Event with highest quality of service (priority level 2)

Events with QOS level 2 have the highest priority in the event system and will be processed before events with lower QOS levels.

◆ EventQOS1

Event with medium quality of service (priority level 1)

Events with QOS level 1 have medium priority in the event system and will be processed after QOS2 events but before QOS0 events.

◆ VirtualPipe

Pipe for event transmission in the actor system.

A specialized pipe based on the allocator::pipe template that is configured to handle EventBucket objects, which contain events for transmission between actors and cores.

◆ event

using qb::event = Event

Alias for the base Event class.

Provided for naming consistency with other lowercase aliases in the framework.

◆ service_event

Alias for the ServiceEvent class.

Provided for naming consistency with other lowercase aliases in the framework.

Enumeration Type Documentation

◆ ActorStatus

enum class qb::ActorStatus : uint32_t
strong

Represents the current status of an actor in the system.

This enumeration is used to indicate whether an actor is currently active (Alive) or has been terminated/removed from the system (Dead). It is typically used in status queries and responses between actors and the core system.

Enumerator
Alive 

The actor is active and operational.

Dead 

The actor has been terminated or removed from the system.

Function Documentation

◆ type_id()

template<typename T>
TypeId qb::type_id ( )
constexpr

Function to get a unique type identifier for a given type.

This function obtains a unique TypeId for the template parameter type T by taking the address of the static id() method in the type<T> template specialization and converting it to a TypeId. This provides a consistent mechanism for generating unique compile-time type identifiers.

Template Parameters
TThe type to get an identifier for
Returns
A unique TypeId corresponding to the type T