nfd::face::GenericLinkService Class Referencefinal

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={})
 
const CountersgetCounters () const final
 
const FacegetFace () const
 
const OptionsgetOptions () const
 get Options used by GenericLinkService More...
 
const TransportgetTransport () const
 
TransportgetTransport ()
 
void receivePacket (const Block &packet, const EndpointId &endpoint)
 performs LinkService specific operations to receive a lower-layer packet More...
 
void sendData (const Data &data, const EndpointId &endpoint)
 Send Data to endpoint. More...
 
void sendInterest (const Interest &interest, const EndpointId &endpoint)
 Send Interest to endpoint. More...
 
void sendNack (const ndn::lp::Nack &nack, const EndpointId &endpoint)
 Send Nack to endpoint. 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, EndpointIdafterReceiveData
 signals on Data received More...
 
signal::Signal< LinkService, Interest, EndpointIdafterReceiveInterest
 signals on Interest received More...
 
signal::Signal< LinkService, lp::Nack, EndpointIdafterReceiveNack
 signals on Nack received More...
 
signal::Signal< LinkService, Interest > onDroppedInterest
 signals on Interest dropped by reliability system for exceeding allowed number of retx More...
 

Protected Member Functions

void notifyDroppedInterest (const Interest &packet)
 
void receiveData (const Data &data, const EndpointId &endpoint)
 delivers received Data to forwarding More...
 
void receiveInterest (const Interest &interest, const EndpointId &endpoint)
 delivers received Interest to forwarding More...
 
void receiveNack (const lp::Nack &nack, const EndpointId &endpoint)
 delivers received Nack to forwarding More...
 
void sendPacket (const Block &packet, const EndpointId &endpoint)
 send a lower-layer packet via Transport to endpoint More...
 

Protected Attributes

PacketCounter nAcknowledged
 count of network-layer packets that did not require retransmission of a fragment More...
 
PacketCounter nCongestionMarked
 count of outgoing LpPackets that were marked with congestion marks More...
 
PacketCounter nDroppedInterests
 count of Interests dropped by reliability system for exceeding allowed number of retx More...
 
PacketCounter nFragmentationErrors
 count of failed fragmentations More...
 
PacketCounter nInData
 count of incoming Data packets 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 packets 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 92 of file generic-link-service.hpp.

Member Typedef Documentation

◆ Counters

Constructor & Destructor Documentation

◆ GenericLinkService()

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

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

Member Function Documentation

◆ getCounters()

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

Reimplemented from nfd::face::LinkService.

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

◆ getFace()

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

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

◆ getOptions()

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

get Options used by GenericLinkService

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

◆ getTransport() [1/2]

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

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

◆ getTransport() [2/2]

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

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

◆ notifyDroppedInterest()

void nfd::face::LinkService::notifyDroppedInterest ( const Interest &  packet)
protectedinherited

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

◆ receiveData()

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

delivers received Data to forwarding

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

◆ receiveInterest()

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

delivers received Interest to forwarding

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

◆ receiveNack()

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

delivers received Nack to forwarding

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

◆ receivePacket()

void nfd::face::LinkService::receivePacket ( const Block &  packet,
const EndpointId endpoint 
)
inlineinherited

performs LinkService specific operations to receive a lower-layer packet

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

◆ sendData()

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

Send Data to endpoint.

Precondition
setTransport has been called

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

◆ sendInterest()

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

Send Interest to endpoint.

Precondition
setTransport has been called

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

◆ sendNack()

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

Send Nack to endpoint.

Precondition
setTransport has been called

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

◆ sendPacket()

void nfd::face::LinkService::sendPacket ( const Block &  packet,
const EndpointId endpoint 
)
inlineprotectedinherited

send a lower-layer packet via Transport to endpoint

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

◆ setFaceAndTransport()

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.

◆ setOptions()

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

sets Options used by GenericLinkService

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

Friends And Related Function Documentation

◆ LpReliability

friend class LpReliability
friend

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

Member Data Documentation

◆ afterReceiveData

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

signals on Data received

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

◆ afterReceiveInterest

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

signals on Interest received

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

◆ afterReceiveNack

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

signals on Nack received

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

◆ nAcknowledged

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.

◆ nCongestionMarked

PacketCounter nfd::face::GenericLinkServiceCounters::nCongestionMarked
inherited

count of outgoing LpPackets that were marked with congestion marks

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

◆ nDroppedInterests

PacketCounter nfd::face::LinkServiceCounters::nDroppedInterests
inherited

count of Interests dropped by reliability system for exceeding allowed number of retx

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

◆ nFragmentationErrors

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

count of failed fragmentations

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

◆ nInData

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

count of incoming Data packets

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

◆ nInInterests

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

count of incoming Interests

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

◆ nInLpInvalid

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

count of invalid LpPackets dropped before reassembly

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

◆ nInNacks

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

count of incoming Nacks

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

◆ nInNetInvalid

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

count of invalid reassembled network-layer packets dropped

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

◆ nOutData

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

count of outgoing Data packets

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

◆ nOutInterests

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

count of outgoing Interests

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

◆ nOutNacks

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

count of outgoing Nacks

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

◆ nOutOverMtu

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.

◆ nReassembling

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.

◆ nReassemblyTimeouts

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.

◆ nRetransmitted

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.

◆ nRetxExhausted

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.

◆ onDroppedInterest

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

signals on Interest dropped by reliability system for exceeding allowed number of retx

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