22#include <kiwano/core/Common.h>
46 const std::type_index& GetType()
const;
48 bool operator==(
const EventType& rhs)
const;
49 bool operator!=(
const EventType& rhs)
const;
50 bool operator<(
const EventType& rhs)
const;
51 bool operator<=(
const EventType& rhs)
const;
52 bool operator>(
const EventType& rhs)
const;
53 bool operator>=(
const EventType& rhs)
const;
56 std::type_index type_;
61#define KGE_EVENT(EVENT_TYPE) ::kiwano::EventType(typeid(EVENT_TYPE))
63inline EventType::EventType()
68inline EventType::EventType(
const std::type_index& type)
75 return type_ ==
typeid(void);
78inline const std::type_index& EventType::GetType()
const
83inline bool EventType::operator==(
const EventType& rhs)
const
85 return type_ == rhs.type_;
88inline bool EventType::operator!=(
const EventType& rhs)
const
90 return type_ != rhs.type_;
93inline bool EventType::operator<(
const EventType& rhs)
const
95 return type_ < rhs.type_;
98inline bool EventType::operator<=(
const EventType& rhs)
const
100 return type_ <= rhs.type_;
103inline bool EventType::operator>(
const EventType& rhs)
const
105 return type_ > rhs.type_;
108inline bool EventType::operator>=(
const EventType& rhs)
const
110 return type_ >= rhs.type_;
事件类型
Definition: EventType.h:36
bool IsNull() const
是否是空类型
Definition: EventType.h:73