NS-3 based Named Data Networking (NDN) simulator
ndnSIM 2.5: NDN, CCN, CCNx, content centric networks
API Documentation
nfd::face::LinkService Class Referenceabstract

the upper part of a Face More...

#include <link-service.hpp>

Inheritance diagram for nfd::face::LinkService:
Collaboration diagram for nfd::face::LinkService:

Public Types

typedef LinkServiceCounters Counters
 counters provided by LinkService More...
 

Public Member Functions

 LinkService ()
 
virtual ~LinkService ()
 
void setFaceAndTransport (Face &face, Transport &transport)
 set Face and Transport for LinkService More...
 
const FacegetFace () const
 
const TransportgetTransport () const
 
TransportgetTransport ()
 
virtual const CountersgetCounters () const
 
virtual ssize_t getEffectiveMtu () const
 
void sendInterest (const Interest &interest)
 Send Interest. More...
 
void sendData (const Data &data)
 Send Data. More...
 
void sendNack (const ndn::lp::Nack &nack)
 Send Nack. More...
 
void receivePacket (const Block &packet, const EndpointId &endpoint)
 performs LinkService specific operations to receive a lower-layer packet More...
 

Public Attributes

signal::Signal< LinkService, Interest, EndpointIdafterReceiveInterest
 signals on Interest received More...
 
signal::Signal< LinkService, Data, EndpointIdafterReceiveData
 signals on Data received More...
 
signal::Signal< LinkService, lp::Nack, EndpointIdafterReceiveNack
 signals on Nack received More...
 
signal::Signal< LinkService, InterestonDroppedInterest
 signals on Interest dropped by reliability system for exceeding allowed number of retx More...
 
signal::Signal< LinkService, InterestafterSendInterest
 signals on Interest sent More...
 
signal::Signal< LinkService, DataafterSendData
 signals on Data sent More...
 
signal::Signal< LinkService, lp::NackafterSendNack
 signals on Nack sent More...
 

Protected Member Functions

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

Additional Inherited Members

- Protected Attributes inherited from nfd::face::LinkServiceCounters
PacketCounter nInInterests
 count of incoming Interests More...
 
PacketCounter nOutInterests
 count of outgoing Interests More...
 
PacketCounter nInterestsExceededRetx
 count of Interests dropped by reliability system for exceeding allowed number of retx More...
 
PacketCounter nInData
 count of incoming Data packets More...
 
PacketCounter nOutData
 count of outgoing Data packets More...
 
PacketCounter nInNacks
 count of incoming Nacks More...
 
PacketCounter nOutNacks
 count of outgoing Nacks More...
 

Detailed Description

the upper part of a Face

See also
Face

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

Member Typedef Documentation

◆ Counters

counters provided by LinkService

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

Constructor & Destructor Documentation

◆ LinkService()

nfd::face::LinkService::LinkService ( )

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

◆ ~LinkService()

nfd::face::LinkService::~LinkService ( )
virtual

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

Member Function Documentation

◆ setFaceAndTransport()

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

set Face and Transport for LinkService

Precondition
setFaceAndTransport has not been called

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

◆ getFace()

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

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

◆ getTransport() [1/2]

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

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

◆ getTransport() [2/2]

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

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

◆ getCounters()

const LinkService::Counters & nfd::face::LinkService::getCounters ( ) const
inlinevirtual

◆ getEffectiveMtu()

ssize_t nfd::face::LinkService::getEffectiveMtu ( ) const
inlinevirtual

Reimplemented in nfd::face::NFD_FINAL_UNLESS_WITH_TESTS.

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

◆ sendInterest()

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

Send Interest.

Precondition
setTransport has been called

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

References afterSendInterest, NFD_LOG_FACE_TRACE, and nfd::face::LinkServiceCounters::nOutInterests.

◆ sendData()

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

Send Data.

Precondition
setTransport has been called

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

References afterSendData, NFD_LOG_FACE_TRACE, and nfd::face::LinkServiceCounters::nOutData.

◆ sendNack()

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

Send Nack.

Precondition
setTransport has been called

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

References afterSendNack, NFD_LOG_FACE_TRACE, and nfd::face::LinkServiceCounters::nOutNacks.

◆ receivePacket()

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

performs LinkService specific operations to receive a lower-layer packet

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

Referenced by nfd::face::Transport::receive().

◆ receiveInterest()

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

delivers received Interest to forwarding

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

References afterReceiveInterest, NFD_LOG_FACE_TRACE, and nfd::face::LinkServiceCounters::nInInterests.

Referenced by ns3::ndn::AppLinkService::onReceiveInterest().

◆ receiveData()

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

delivers received Data to forwarding

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

References afterReceiveData, NFD_LOG_FACE_TRACE, and nfd::face::LinkServiceCounters::nInData.

Referenced by ns3::ndn::AppLinkService::onReceiveData().

◆ receiveNack()

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

delivers received Nack to forwarding

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

References afterReceiveNack, NFD_LOG_FACE_TRACE, and nfd::face::LinkServiceCounters::nInNacks.

Referenced by ns3::ndn::AppLinkService::onReceiveNack().

◆ sendPacket()

void nfd::face::LinkService::sendPacket ( const Block packet)
inlineprotected

send a lower-layer packet via Transport

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

◆ notifyDroppedInterest()

void nfd::face::LinkService::notifyDroppedInterest ( const Interest packet)
protected

Member Data Documentation

◆ afterReceiveInterest

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

signals on Interest received

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

Referenced by receiveInterest().

◆ afterReceiveData

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

signals on Data received

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

Referenced by receiveData().

◆ afterReceiveNack

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

signals on Nack received

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

Referenced by receiveNack().

◆ onDroppedInterest

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

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

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

Referenced by notifyDroppedInterest().

◆ afterSendInterest

signal::Signal<LinkService, Interest> nfd::face::LinkService::afterSendInterest

signals on Interest sent

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

Referenced by sendInterest().

◆ afterSendData

signal::Signal<LinkService, Data> nfd::face::LinkService::afterSendData

signals on Data sent

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

Referenced by sendData().

◆ afterSendNack

signal::Signal<LinkService, lp::Nack> nfd::face::LinkService::afterSendNack

signals on Nack sent

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

Referenced by sendNack().


The documentation for this class was generated from the following files: