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

Abstract base class for all protocol factories. More...

#include <protocol-factory.hpp>

Inheritance diagram for nfd::ProtocolFactory:

Classes

class  Error
 Base class for all exceptions thrown by protocol factories. More...
 

Public Member Functions

virtual void createFace (const FaceUri &uri, ndn::nfd::FacePersistency persistency, bool wantLocalFieldsEnabled, const FaceCreatedCallback &onCreated, const FaceCreationFailedCallback &onFailure)=0
 Try to create Face using the supplied FaceUri. More...
 
virtual std::vector< shared_ptr< const Channel > > getChannels () const =0
 

Detailed Description

Abstract base class for all protocol factories.

Definition at line 37 of file protocol-factory.hpp.

Member Function Documentation

◆ createFace()

virtual void nfd::ProtocolFactory::createFace ( const FaceUri uri,
ndn::nfd::FacePersistency  persistency,
bool  wantLocalFieldsEnabled,
const FaceCreatedCallback onCreated,
const FaceCreationFailedCallback onFailure 
)
pure virtual

Try to create Face using the supplied FaceUri.

This method should automatically choose channel, based on supplied FaceUri and create face.

Parameters
uriremote URI of the new face
persistencypersistency of the new face
wantLocalFieldsEnabledwhether local fields should be enabled on the face
onCreatedcallback if face creation succeeds If a face with the same remote URI already exists, its persistency and LocalFieldsEnabled setting will not be modified.
onFailurecallback if face creation fails

Implemented in nfd::UdpFactory, nfd::EthernetFactory, nfd::TcpFactory, nfd::WebSocketFactory, and nfd::UnixStreamFactory.

Referenced by nfd::ProtocolFactory::Error::Error().

◆ getChannels()

virtual std::vector<shared_ptr<const Channel> > nfd::ProtocolFactory::getChannels ( ) const
pure virtual

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