nfd::face::GenericLinkService Class Reference

GenericLinkService is a LinkService that implements the NDNLPv2 protocol. More...

#include <daemon/face/generic-link-service.hpp>

+ Inheritance diagram for nfd::face::GenericLinkService:
+ Collaboration diagram for nfd::face::GenericLinkService:

Classes

class  Options
 Options that control the behavior of GenericLinkService. More...
 

Public Types

using Counters = GenericLinkServiceCounters
 counters provided by GenericLinkService More...
 

Public Member Functions

 GenericLinkService (const Options &options=Options())
 
const CountersgetCounters () const override
 
const FacegetFace () const
 
const OptionsgetOptions () const
 get Options used by GenericLinkService More...
 
const TransportgetTransport () const
 
TransportgetTransport ()
 
void receivePacket (Transport::Packet &&packet)
 performs LinkService specific operations to receive a lower-layer packet More...
 
void sendData (const Data &data)
 send Data More...
 
void sendInterest (const Interest &interest)
 send Interest More...
 
void sendNack (const ndn::lp::Nack &nack)
 send Nack More...
 
void setFaceAndTransport (Face &face, Transport &transport)
 set Face and Transport for LinkService More...
 
void setOptions (const Options &options)
 sets Options used by GenericLinkService More...
 

Public Attributes

signal::Signal< LinkService, Data > afterReceiveData
 signals on Data received More...
 
signal::Signal< LinkService, Interest > afterReceiveInterest
 signals on Interest received More...
 
signal::Signal< LinkService, lp::Nack > afterReceiveNack
 signals on Nack received More...
 

Protected Member Functions

void receiveData (const Data &data)
 delivers received Data to forwarding More...
 
void receiveInterest (const Interest &interest)
 delivers received Interest to forwarding More...
 
void receiveNack (const lp::Nack &nack)
 delivers received Nack to forwarding More...
 
void sendPacket (Transport::Packet &&packet)
 sends a lower-layer packet via Transport More...
 

Protected Attributes

PacketCounter nAcknowledged
 count of network-layer packets that did not require retransmission of a fragment More...
 
PacketCounter nFragmentationErrors
 count of failed fragmentations More...
 
PacketCounter nInData
 count of incoming Data More...
 
PacketCounter nInInterests
 count of incoming Interests More...
 
PacketCounter nInLpInvalid
 count of invalid LpPackets dropped before reassembly More...
 
PacketCounter nInNacks
 count of incoming Nacks More...
 
PacketCounter nInNetInvalid
 count of invalid reassembled network-layer packets dropped More...
 
PacketCounter nOutData
 count of outgoing Data More...
 
PacketCounter nOutInterests
 count of outgoing Interests More...
 
PacketCounter nOutNacks
 count of outgoing Nacks More...
 
PacketCounter nOutOverMtu
 count of outgoing LpPackets dropped due to exceeding MTU limit More...
 
SizeCounter< LpReassemblernReassembling
 count of network-layer packets currently being reassembled More...
 
PacketCounter nReassemblyTimeouts
 count of dropped partial network-layer packets due to reassembly timeout More...
 
PacketCounter nRetransmitted
 count of network-layer packets that had at least one fragment retransmitted, but were eventually received in full More...
 
PacketCounter nRetxExhausted
 count of network-layer packets dropped because a fragment reached the maximum number of retransmissions More...
 

Friends

class LpReliability
 

Detailed Description

GenericLinkService is a LinkService that implements the NDNLPv2 protocol.

See also
https://redmine.named-data.net/projects/nfd/wiki/NDNLPv2

Definition at line 88 of file generic-link-service.hpp.

Member Typedef Documentation

Constructor & Destructor Documentation

nfd::face::GenericLinkService::GenericLinkService ( const Options options = Options())
explicit

Definition at line 41 of file generic-link-service.cpp.

Member Function Documentation

const GenericLinkService::Counters & nfd::face::GenericLinkService::getCounters ( ) const
inlineoverridevirtual

Reimplemented from nfd::face::LinkService.

Definition at line 265 of file generic-link-service.hpp.

const Face * nfd::face::LinkService::getFace ( ) const
inlineinherited
Returns
Face to which this LinkService is attached

Definition at line 195 of file link-service.hpp.

const GenericLinkService::Options & nfd::face::GenericLinkService::getOptions ( ) const
inline

get Options used by GenericLinkService

Definition at line 259 of file generic-link-service.hpp.

const Transport * nfd::face::LinkService::getTransport ( ) const
inlineinherited
Returns
Transport to which this LinkService is attached

Definition at line 201 of file link-service.hpp.

Transport * nfd::face::LinkService::getTransport ( )
inlineinherited
Returns
Transport to which this LinkService is attached

Definition at line 207 of file link-service.hpp.

void nfd::face::LinkService::receiveData ( const Data &  data)
protectedinherited

delivers received Data to forwarding

Definition at line 98 of file link-service.cpp.

void nfd::face::LinkService::receiveInterest ( const Interest &  interest)
protectedinherited

delivers received Interest to forwarding

Definition at line 88 of file link-service.cpp.

void nfd::face::LinkService::receiveNack ( const lp::Nack &  nack)
protectedinherited

delivers received Nack to forwarding

Definition at line 108 of file link-service.cpp.

void nfd::face::LinkService::receivePacket ( Transport::Packet &&  packet)
inlineinherited

performs LinkService specific operations to receive a lower-layer packet

Definition at line 219 of file link-service.hpp.

void nfd::face::LinkService::sendData ( const Data &  data)
inherited

send Data

Precondition
setTransport has been called

Definition at line 66 of file link-service.cpp.

void nfd::face::LinkService::sendInterest ( const Interest &  interest)
inherited

send Interest

Precondition
setTransport has been called

Definition at line 55 of file link-service.cpp.

void nfd::face::LinkService::sendNack ( const ndn::lp::Nack &  nack)
inherited

send Nack

Precondition
setTransport has been called

Definition at line 77 of file link-service.cpp.

void nfd::face::LinkService::sendPacket ( Transport::Packet &&  packet)
inlineprotectedinherited

sends a lower-layer packet via Transport

Definition at line 225 of file link-service.hpp.

void nfd::face::LinkService::setFaceAndTransport ( Face face,
Transport transport 
)
inherited

set Face and Transport for LinkService

Precondition
setFaceAndTransport has not been called

Definition at line 45 of file link-service.cpp.

void nfd::face::GenericLinkService::setOptions ( const Options options)

sets Options used by GenericLinkService

Definition at line 53 of file generic-link-service.cpp.

Friends And Related Function Documentation

friend class LpReliability
friend

Definition at line 255 of file generic-link-service.hpp.

Member Data Documentation

signal::Signal<LinkService, Data> nfd::face::LinkService::afterReceiveData
inherited

signals on Data received

Definition at line 135 of file link-service.hpp.

signal::Signal<LinkService, Interest> nfd::face::LinkService::afterReceiveInterest
inherited

signals on Interest received

Definition at line 131 of file link-service.hpp.

signal::Signal<LinkService, lp::Nack> nfd::face::LinkService::afterReceiveNack
inherited

signals on Nack received

Definition at line 139 of file link-service.hpp.

PacketCounter nfd::face::GenericLinkServiceCounters::nAcknowledged
inherited

count of network-layer packets that did not require retransmission of a fragment

Definition at line 72 of file generic-link-service.hpp.

PacketCounter nfd::face::GenericLinkServiceCounters::nFragmentationErrors
inherited

count of failed fragmentations

Definition at line 46 of file generic-link-service.hpp.

PacketCounter nfd::face::LinkServiceCounters::nInData
inherited

count of incoming Data

Definition at line 55 of file link-service.hpp.

PacketCounter nfd::face::LinkServiceCounters::nInInterests
inherited

count of incoming Interests

Definition at line 47 of file link-service.hpp.

PacketCounter nfd::face::GenericLinkServiceCounters::nInLpInvalid
inherited

count of invalid LpPackets dropped before reassembly

Definition at line 56 of file generic-link-service.hpp.

PacketCounter nfd::face::LinkServiceCounters::nInNacks
inherited

count of incoming Nacks

Definition at line 63 of file link-service.hpp.

PacketCounter nfd::face::GenericLinkServiceCounters::nInNetInvalid
inherited

count of invalid reassembled network-layer packets dropped

Definition at line 68 of file generic-link-service.hpp.

PacketCounter nfd::face::LinkServiceCounters::nOutData
inherited

count of outgoing Data

Definition at line 59 of file link-service.hpp.

PacketCounter nfd::face::LinkServiceCounters::nOutInterests
inherited

count of outgoing Interests

Definition at line 51 of file link-service.hpp.

PacketCounter nfd::face::LinkServiceCounters::nOutNacks
inherited

count of outgoing Nacks

Definition at line 67 of file link-service.hpp.

PacketCounter nfd::face::GenericLinkServiceCounters::nOutOverMtu
inherited

count of outgoing LpPackets dropped due to exceeding MTU limit

If this counter is non-zero, the operator should enable fragmentation.

Definition at line 52 of file generic-link-service.hpp.

SizeCounter<LpReassembler> nfd::face::GenericLinkServiceCounters::nReassembling
inherited

count of network-layer packets currently being reassembled

Definition at line 60 of file generic-link-service.hpp.

PacketCounter nfd::face::GenericLinkServiceCounters::nReassemblyTimeouts
inherited

count of dropped partial network-layer packets due to reassembly timeout

Definition at line 64 of file generic-link-service.hpp.

PacketCounter nfd::face::GenericLinkServiceCounters::nRetransmitted
inherited

count of network-layer packets that had at least one fragment retransmitted, but were eventually received in full

Definition at line 77 of file generic-link-service.hpp.

PacketCounter nfd::face::GenericLinkServiceCounters::nRetxExhausted
inherited

count of network-layer packets dropped because a fragment reached the maximum number of retransmissions

Definition at line 82 of file generic-link-service.hpp.