SEGS  0.4.2
Super Entity Game Server
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
LinkLevelEvent.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 <cassert>
10 #include <ace/INET_Addr.h>
11 #include "SEGSEvent.h"
12 
13 class ConnectEvent : public SEGSEvent
14 {
15 public:
16  ConnectEvent(EventProcessor *ev_src) : SEGSEvent(SEGS_EventTypes::evConnect,ev_src)
17  {
18  assert(ev_src);
19  }
20  ConnectEvent(EventProcessor *ev_src,const ACE_INET_Addr &addr) :
21  SEGSEvent(SEGS_EventTypes::evConnect,ev_src),
22  src_addr(addr)
23  {
24  assert(ev_src);
25  }
26  ACE_INET_Addr src_addr;
27 };
28 class DisconnectEvent : public SEGSEvent
29 {
30 public:
31  uint64_t m_session_token;
32  DisconnectEvent(uint64_t token) : SEGSEvent(SEGS_EventTypes::evDisconnect,nullptr),m_session_token(token)
33  {
34  }
35 };
ACE_INET_Addr src_addr
Definition: LinkLevelEvent.h:26
Definition: SEGSEvent.h:32
Definition: LinkLevelEvent.h:28
Definition: SEGSEvent.h:21
uint64_t m_session_token
Definition: LinkLevelEvent.h:31
DisconnectEvent(uint64_t token)
Definition: LinkLevelEvent.h:32
Definition: LinkLevelEvent.h:13
ConnectEvent(EventProcessor *ev_src)
Definition: LinkLevelEvent.h:16
Definition: EventProcessor.h:13
ConnectEvent(EventProcessor *ev_src, const ACE_INET_Addr &addr)
Definition: LinkLevelEvent.h:20