Wire Sysio Wire Sysion 1.0.0
Loading...
Searching...
No Matches
fc::detail::rate_limited_tcp_read_operation Class Reference
Inheritance diagram for fc::detail::rate_limited_tcp_read_operation:
Collaboration diagram for fc::detail::rate_limited_tcp_read_operation:

Public Member Functions

 rate_limited_tcp_read_operation (boost::asio::ip::tcp::socket &socket, char *buffer, size_t length, size_t offset, promise< size_t >::ptr completion_promise)
 
 rate_limited_tcp_read_operation (boost::asio::ip::tcp::socket &socket, const std::shared_ptr< char > &buffer, size_t length, size_t offset, promise< size_t >::ptr completion_promise)
 
virtual void perform_operation () override
 
- Public Member Functions inherited from fc::detail::rate_limited_operation
 rate_limited_operation (size_t length, size_t offset, promise< size_t >::ptr &&completion_promise)
 

Public Attributes

boost::asio::ip::tcp::socket & socket
 
char * raw_buffer
 
std::shared_ptr< char > shared_buffer
 
- Public Attributes inherited from fc::detail::rate_limited_operation
size_t length
 
size_t offset
 
size_t permitted_length
 
promise< size_t >::ptr completion_promise
 

Detailed Description

Definition at line 85 of file rate_limiting.cpp.

Constructor & Destructor Documentation

◆ rate_limited_tcp_read_operation() [1/2]

fc::detail::rate_limited_tcp_read_operation::rate_limited_tcp_read_operation ( boost::asio::ip::tcp::socket & socket,
char * buffer,
size_t length,
size_t offset,
promise< size_t >::ptr completion_promise )
inline

Definition at line 92 of file rate_limiting.cpp.

96 :
99 raw_buffer(buffer)
100 {}
rate_limited_operation(size_t length, size_t offset, promise< size_t >::ptr &&completion_promise)
promise< size_t >::ptr completion_promise
boost::asio::ip::tcp::socket & socket

◆ rate_limited_tcp_read_operation() [2/2]

fc::detail::rate_limited_tcp_read_operation::rate_limited_tcp_read_operation ( boost::asio::ip::tcp::socket & socket,
const std::shared_ptr< char > & buffer,
size_t length,
size_t offset,
promise< size_t >::ptr completion_promise )
inline

Definition at line 101 of file rate_limiting.cpp.

105 :
107 socket(socket),
108 raw_buffer(nullptr),
109 shared_buffer(buffer)
110 {}

Member Function Documentation

◆ perform_operation()

virtual void fc::detail::rate_limited_tcp_read_operation::perform_operation ( )
inlineoverridevirtual

Implements fc::detail::rate_limited_operation.

Definition at line 111 of file rate_limiting.cpp.

112 {
113 if (raw_buffer)
114 asio::async_read_some(socket,
117 else
118 asio::async_read_some(socket,
121
122 }

Member Data Documentation

◆ raw_buffer

char* fc::detail::rate_limited_tcp_read_operation::raw_buffer

Definition at line 89 of file rate_limiting.cpp.

◆ shared_buffer

std::shared_ptr<char> fc::detail::rate_limited_tcp_read_operation::shared_buffer

Definition at line 90 of file rate_limiting.cpp.

◆ socket

boost::asio::ip::tcp::socket& fc::detail::rate_limited_tcp_read_operation::socket

Definition at line 88 of file rate_limiting.cpp.


The documentation for this class was generated from the following file: