mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-04-28 11:47:48 +02:00
LocalLeaseSet2 added
This commit is contained in:
parent
5398b651f7
commit
9504e69598
3 changed files with 49 additions and 4 deletions
|
@ -168,6 +168,12 @@ namespace data
|
|||
bool operator== (const LeaseSet& other) const
|
||||
{ return m_BufferLen == other.GetBufferLen () && !memcmp (other.GetBuffer (), other.GetBuffer (), m_BufferLen); };
|
||||
|
||||
virtual uint8_t GetStoreType () const { return NETDB_STORE_TYPE_LEASESET; };
|
||||
|
||||
protected:
|
||||
|
||||
// called from LocalLeaseSet2
|
||||
void SetBuffer (const uint8_t * buf, size_t len);
|
||||
|
||||
private:
|
||||
|
||||
|
@ -176,6 +182,21 @@ namespace data
|
|||
uint8_t * m_Buffer, * m_Leases;
|
||||
size_t m_BufferLen;
|
||||
};
|
||||
|
||||
class LocalLeaseSet2: public LocalLeaseSet
|
||||
{
|
||||
public:
|
||||
|
||||
LocalLeaseSet2 (uint8_t storeType, std::shared_ptr<const IdentityEx> identity,
|
||||
uint16_t keyType, uint16_t keyLen, const uint8_t * encryptionPublicKey,
|
||||
std::vector<std::shared_ptr<i2p::tunnel::InboundTunnel> > tunnels);
|
||||
|
||||
uint8_t GetStoreType () const { return m_StoreType; };
|
||||
|
||||
private:
|
||||
|
||||
uint8_t m_StoreType;
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue