EHS/include/IO/Socket/Fragments.h

43 lines
632 B
C
Raw Normal View History

2023-12-17 03:29:08 -08:00
#pragma once
#include "../../EHS.h"
#include "../../Serializer.h"
#include "Utils.h"
namespace lwe
{
class Fragments
{
private:
Header header;
Serializer<>* data;
UInt_64 size;
public:
~Fragments();
Fragments();
Fragments(const Header& header, const Serializer<>& payload);
Fragments(const Header& header, const UInt_64 size);
Fragments(const Fragments& frags);
Fragments& operator=(const Fragments& frags);
operator const Serializer<>* () const;
operator Serializer<>* ();
Header GetHeader() const;
UInt_64 Size() const;
bool IsComplete() const;
Packet Combine() const;
};
}