-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathCallbacks.h
More file actions
24 lines (19 loc) · 753 Bytes
/
Copy pathCallbacks.h
File metadata and controls
24 lines (19 loc) · 753 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
//
// Created by cleon on 22-10-2.
//
#ifndef LMUDUO_CALLBACKS_H
#define LMUDUO_CALLBACKS_H
#include <memory>
#include <functional>
class Buffer;
class TcpConnection;
class Timestamp;
using TcpConnectionPtr = std::shared_ptr<TcpConnection>;
using ConnectionCallback = std::function<void(const TcpConnectionPtr&)>;
using CloseCallback = std::function<void(const TcpConnectionPtr&)>;
using WriteCompleteCallback = std::function<void(const TcpConnectionPtr&)>;
using MessageCallback = std::function<void(const TcpConnectionPtr&,
Buffer*,
Timestamp)>;
using HighWaterMarkCallback = std::function<void(const TcpConnectionPtr&, size_t)>;
#endif //LMUDUO_CALLBACKS_H