mirror of
https://github.com/PurpleI2P/i2pd
synced 2024-11-10 00:00:29 +03:00
36 lines
620 B
C++
36 lines
620 B
C++
#ifndef TUNNEL_ENDPOINT_H__
|
|
#define TUNNEL_ENDPOINT_H__
|
|
|
|
#include <inttypes.h>
|
|
#include <map>
|
|
#include <string>
|
|
#include "I2NPProtocol.h"
|
|
#include "TunnelBase.h"
|
|
|
|
namespace i2p
|
|
{
|
|
namespace tunnel
|
|
{
|
|
class TunnelEndpoint
|
|
{
|
|
public:
|
|
|
|
TunnelEndpoint (): m_NumReceivedBytes (0) {};
|
|
size_t GetNumReceivedBytes () const { return m_NumReceivedBytes; };
|
|
|
|
void HandleDecryptedTunnelDataMsg (I2NPMessage * msg);
|
|
|
|
private:
|
|
|
|
void HandleNextMessage (const TunnelMessageBlock& msg);
|
|
|
|
private:
|
|
|
|
std::map<uint32_t, TunnelMessageBlock> m_IncompleteMessages;
|
|
size_t m_NumReceivedBytes;
|
|
};
|
|
}
|
|
}
|
|
|
|
#endif
|