26 #ifndef NFD_DAEMON_FACE_LP_REASSEMBLER_HPP 27 #define NFD_DAEMON_FACE_LP_REASSEMBLER_HPP 33 #include <ndn-cxx/lp/packet.hpp> 85 std::tuple<bool, Block, lp::Packet>
107 std::vector<lp::Packet> fragments;
109 size_t nReceivedFragments;
110 scheduler::ScopedEventId dropTimer;
121 doReassembly(
const Key& key);
124 timeoutPartialPacket(
const Key& key);
128 std::map<Key, PartialPacket> m_partialPackets;
133 operator<<(std::ostream& os, const FaceLogHelper<LpReassembler>& flh);
144 return m_linkService;
150 return m_partialPackets.size();
156 #endif // NFD_DAEMON_FACE_LP_REASSEMBLER_HPP LpReassembler(const Options &options, const LinkService *linkService=nullptr)
const LinkService * getLinkService() const
size_t size() const
count of partial packets
Copyright (c) 2014-2015, Regents of the University of California, Arizona Board of Regents...
Options that control the behavior of LpReassembler.
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
size_t nMaxFragments
maximum number of fragments in a packet
std::tuple< bool, Block, lp::Packet > receiveFragment(Transport::EndpointId remoteEndpoint, const lp::Packet &packet)
adds received fragment to buffer
time::nanoseconds reassemblyTimeout
timeout before a partially reassembled packet is dropped
void setOptions(const Options &options)
set options for reassembler