|
Sponge
CS144's user-space TCP library
|
Go to the documentation of this file. 1 #ifndef SPONGE_LIBSPONGE_TCP_SEGMENT_HH
2 #define SPONGE_LIBSPONGE_TCP_SEGMENT_HH
36 #endif // SPONGE_LIBSPONGE_TCP_SEGMENT_HH
BufferList serialize(const uint32_t datagram_layer_checksum=0) const
Serialize the segment to a string.
A reference-counted discontiguous string that can discard bytes from the front.
A reference-counted read-only string that can discard bytes from the front.
ParseResult parse(const Buffer buffer, const uint32_t datagram_layer_checksum=0)
Parse the segment from a string.
ParseResult
The result of parsing or unparsing an IP datagram, TCP segment, Ethernet frame, or ARP message.
const Buffer & payload() const
const TCPHeader & header() const
size_t length_in_sequence_space() const
Segment's length in sequence space.