forked from dulikvor/cppKin
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathAnnotation.h
More file actions
46 lines (40 loc) · 1.13 KB
/
Copy pathAnnotation.h
File metadata and controls
46 lines (40 loc) · 1.13 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
#pragma once
#include <string>
#include <stdint.h>
#include "AnnotationType.h"
#include "Export.h"
namespace cppkin
{
class CPPKIN_EXPORT Annotation
{
public:
struct CPPKIN_EXPORT EndPoint
{
public:
EndPoint(const std::string& serviceName, std::string host, uint_fast16_t port);
public:
std::string ServiceName;
std::string Host;
int_fast16_t Port;
int32_t BinaryHost;
};
struct CPPKIN_EXPORT Value
{
public:
static const char* SERVER_SEND;
static const char* SERVER_RECEIVE;
static const char* CLIENT_SEND;
static const char* CLIENT_RECEIVE;
static const char* NOP;
};
public:
Annotation(AnnotationType type, const EndPoint& endPoint): m_type(type),
m_endPoint(endPoint){}
virtual ~Annotation() = default;
AnnotationType GetType() const{ return m_type; }
const EndPoint& GetEndPoint() const {return m_endPoint;}
protected:
AnnotationType m_type;
EndPoint m_endPoint;
};
}