GoPxL SDK
GoResponseType.h
Go to the documentation of this file.
1 
9 #ifndef GO_PXL_SDK_RESPONSETYPE_H
10 #define GO_PXL_SDK_RESPONSETYPE_H
11 
12 namespace GoPxLSdk
13 {
14 
16 {
17 public:
18  enum Type : k32s
19  {
23  };
24 
25  GoResponseType() = default;
26 
27  constexpr GoResponseType(Type type) : type(type) { }
28 
29  operator Type() const { return type; }
30  constexpr bool operator==(GoResponseType t) const { return type == t.type; }
31  constexpr bool operator==(Type t) const { return type == t; }
32  constexpr bool operator!=(GoResponseType t) const { return type != t.type; }
33  constexpr bool operator!=(Type t) const { return type != t; }
34 
35  static std::string ToString(Type type);
36 
37  static GoResponseType FromString(const std::string& type);
38 
39 private:
40  Type type;
41 };
42 
43 }
44 
45 #endif
constexpr bool operator==(Type t) const
Definition: GoResponseType.h:31
constexpr bool operator!=(Type t) const
Definition: GoResponseType.h:33
static std::string ToString(Type type)
constexpr bool operator!=(GoResponseType t) const
Definition: GoResponseType.h:32
constexpr GoResponseType(Type type)
Definition: GoResponseType.h:27
static GoResponseType FromString(const std::string &type)
Definition: GoResponseType.h:15
A change notification.
Definition: GoResponseType.h:21
A streamed message.
Definition: GoResponseType.h:22
Type
Definition: GoResponseType.h:18
constexpr bool operator==(GoResponseType t) const
Definition: GoResponseType.h:30
A reply to a request (e.g. Read or Update).
Definition: GoResponseType.h:20
Definition: Def.h:46