acl/lib_acl_cpp/include/acl_cpp/connpool/tcp_sender.hpp

37 lines
504 B
C++
Raw Normal View History

/**
* Copyright (C) 2017-2018
* All rights reserved.
*
* AUTHOR(S)
* Zheng Shuxin
* E-mail: zhengshuxin@qiyi.com
*
* VERSION
* Tue 08 Aug 2017 02:11:05 PM CST
*/
#pragma once
#include "../acl_cpp_define.hpp"
2017-08-08 18:54:13 +08:00
struct iovec;
namespace acl
{
class socket_stream;
class ACL_CPP_API tcp_sender
{
public:
tcp_sender(socket_stream& conn);
2017-08-08 18:54:13 +08:00
~tcp_sender(void);
bool send(const void* data, unsigned int len);
private:
acl::socket_stream* conn_;
2017-08-08 18:54:13 +08:00
struct iovec* v2_;
};
} // namespace acl