SEGS  0.4.2
Super Entity Game Server
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
MessageBusEndpoint.h
Go to the documentation of this file.
1 /*
2  * SEGS - Super Entity Game Server
3  * http://www.segs.io/
4  * Copyright (c) 2006 - 2018 SEGS Team (see Authors.txt)
5  * This software is licensed! (See License.txt for details)
6  */
7 
8 #pragma once
9 #include "EventProcessor.h"
10 #include <vector>
11 
19 {
20  EventProcessor &m_true_handler;
21  MessageBusEndpoint(const MessageBusEndpoint &) = delete;
22  MessageBusEndpoint &operator =(const MessageBusEndpoint &) = delete;
23  std::vector<uint32_t> m_active_subscriptions;
24 public:
25  MessageBusEndpoint(EventProcessor &h) : m_true_handler(h) {}
27  void putq(SEGSEvent *e)
28  {
29  m_true_handler.putq(e);
30  }
31  void subscribe(uint32_t ev_type);
32  void unsubscribe(uint32_t ev_type);
33 };
34 
35 
Definition: SEGSEvent.h:32
~MessageBusEndpoint()
Definition: MessageBusEndpoint.cpp:18
void subscribe(uint32_t ev_type)
Definition: MessageBusEndpoint.cpp:24
MessageBusEndpoint(EventProcessor &h)
Definition: MessageBusEndpoint.h:25
The MessageBusEndpoint class is responsible for:
Definition: MessageBusEndpoint.h:18
void putq(SEGSEvent *e)
Definition: MessageBusEndpoint.h:27
Definition: EventProcessor.h:13
void unsubscribe(uint32_t ev_type)
Definition: MessageBusEndpoint.cpp:30