mirror of
https://github.com/monero-project/monero.git
synced 2025-08-14 06:25:32 -04:00
epee: better network buffer data structure
avoids pointless allocs and memcpy
This commit is contained in:
parent
6bc0c7e685
commit
85665003a7
22 changed files with 325 additions and 85 deletions
|
@ -80,8 +80,8 @@ namespace levin
|
|||
template<class t_connection_context = net_utils::connection_context_base>
|
||||
struct levin_commands_handler
|
||||
{
|
||||
virtual int invoke(int command, const std::string& in_buff, std::string& buff_out, t_connection_context& context)=0;
|
||||
virtual int notify(int command, const std::string& in_buff, t_connection_context& context)=0;
|
||||
virtual int invoke(int command, const epee::span<const uint8_t> in_buff, std::string& buff_out, t_connection_context& context)=0;
|
||||
virtual int notify(int command, const epee::span<const uint8_t> in_buff, t_connection_context& context)=0;
|
||||
virtual void callback(t_connection_context& context){};
|
||||
|
||||
virtual void on_connection_new(t_connection_context& context){};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue