26 #ifndef NFD_DAEMON_FACE_LP_REASSEMBLER_HPP 27 #define NFD_DAEMON_FACE_LP_REASSEMBLER_HPP 33 #include <ndn-cxx/lp/packet.hpp> 89 std::tuple<bool, Block, lp::Packet>
111 std::vector<lp::Packet> fragments;
113 size_t nReceivedFragments;
125 doReassembly(
const Key& key);
128 timeoutPartialPacket(
const Key& key);
132 std::map<Key, PartialPacket> m_partialPackets;
137 operator<<(std::ostream& os, const FaceLogHelper<LpReassembler>& flh);
148 return m_linkService;
154 return m_partialPackets.size();
160 #endif // NFD_DAEMON_FACE_LP_REASSEMBLER_HPP time::nanoseconds reassemblyTimeout
timeout before a partially reassembled packet is dropped
LpReassembler(const Options &options=Options(), const LinkService *linkService=nullptr)
size_t nMaxFragments
maximum number of fragments in a packet
const LinkService * getLinkService() const
size_t size() const
count of partial packets
cancels an event automatically upon destruction
Options that control the behavior of LpReassembler.
Copyright (c) 2014-2015, Regents of the University of California, Arizona Board of Regents...
signal::Signal< LpReassembler, Transport::EndpointId, size_t > beforeTimeout
signals before a partial packet is dropped due to timeout
reassembles fragmented network-layer packets
uint64_t EndpointId
identifies an endpoint on the link
std::tuple< bool, Block, lp::Packet > receiveFragment(Transport::EndpointId remoteEndpoint, const lp::Packet &packet)
adds received fragment to buffer
void setOptions(const Options &options)
set options for reassembler