Implementation of Face abstraction that uses stream-oriented Unix domain sockets as underlying transport mechanism. More...
#include <unix-stream-face.hpp>
Public Member Functions | |
UnixStreamFace (const FaceUri &remoteUri, const FaceUri &localUri, protocol::socket socket) | |
Public Member Functions inherited from nfd::StreamFace< boost::asio::local::stream_protocol, LocalFace > | |
StreamFace (const FaceUri &remoteUri, const FaceUri &localUri, typename protocol::socket socket, bool isOnDemand) | |
void | sendInterest (const Interest &interest) 1 |
void | sendData (const Data &data) 1 |
void | close () 1 |
Public Member Functions inherited from nfd::LocalFace | |
LocalFace (const FaceUri &remoteUri, const FaceUri &localUri) | |
bool | isLocalControlHeaderEnabled () const |
get whether any LocalControlHeader feature is enabled More... | |
bool | isLocalControlHeaderEnabled (LocalControlFeature feature) const |
get whether a specific LocalControlHeader feature is enabled More... | |
void | setLocalControlHeaderFeature (LocalControlFeature feature, bool enabled=true) |
enable or disable a LocalControlHeader feature More... | |
Public Member Functions inherited from nfd::Face | |
Face (const FaceUri &remoteUri, const FaceUri &localUri, bool isLocal=false, bool isMultiAccess=false) | |
virtual | ~Face () |
FaceId | getId () const |
const std::string & | getDescription () const |
Get the description. More... | |
void | setDescription (const std::string &description) |
Set the face description. More... | |
void | setMetric (uint64_t metric) |
uint64_t | getMetric () const |
bool | isLocal () const |
Get whether face is connected to a local app. More... | |
ndn::nfd::FacePersistency | getPersistency () const |
Get the persistency setting. More... | |
bool | isMultiAccess () const |
Get whether packets sent by this face may reach multiple peers. More... | |
virtual bool | isUp () const |
Get whether underlying communication is up. More... | |
const FaceCounters & | getCounters () const |
const FaceUri & | getRemoteUri () const |
const FaceUri & | getLocalUri () const |
template<typename FaceTraits > | |
void | copyStatusTo (FaceTraits &traits) const |
virtual ndn::nfd::FaceStatus | getFaceStatus () const |
Additional Inherited Members | |
Public Types inherited from nfd::StreamFace< boost::asio::local::stream_protocol, LocalFace > | |
typedef boost::asio::local::stream_protocol | protocol |
Public Attributes inherited from nfd::Face | |
signal::Signal< Face, Interest > | onReceiveInterest |
fires when an Interest is received More... | |
signal::Signal< Face, Data > | onReceiveData |
fires when a Data is received More... | |
signal::Signal< Face, Interest > | onSendInterest |
fires when an Interest is sent out More... | |
signal::Signal< Face, Data > | onSendData |
fires when a Data is sent out More... | |
signal::Signal< Face, std::string > | onFail |
fires when face disconnects or fails to perform properly More... | |
Static Public Attributes inherited from nfd::LocalFace | |
static const size_t | LOCAL_CONTROL_FEATURE_MAX = 3 |
static const size_t | LOCAL_CONTROL_FEATURE_ANY = 0 |
upper bound of LocalControlFeature enum More... | |
Protected Member Functions inherited from nfd::StreamFace< boost::asio::local::stream_protocol, LocalFace > | |
void | processErrorCode (const boost::system::error_code &error) |
void | sendFromQueue () |
void | handleSend (const boost::system::error_code &error, size_t nBytesSent) |
void | handleReceive (const boost::system::error_code &error, size_t nBytesReceived) |
void | shutdownSocket () |
void | deferredClose (const shared_ptr< Face > &face) |
NFD_LOG_INCLASS_DECLARE () | |
Protected Member Functions inherited from nfd::LocalFace | |
bool | decodeAndDispatchInput (const Block &element) |
any feature More... | |
bool | isEmptyFilteredLocalControlHeader (const ndn::nfd::LocalControlHeader &header) const |
Check if LocalControlHeader needs to be included, taking into account both set parameters in supplied LocalControlHeader and features enabled on the local face. More... | |
template<class Packet > | |
Block | filterAndEncodeLocalControlHeader (const Packet &packet) |
Create LocalControlHeader, considering enabled features. More... | |
Protected Member Functions inherited from nfd::Face | |
void | setPersistency (ndn::nfd::FacePersistency persistency) |
bool | decodeAndDispatchInput (const Block &element) |
void | fail (const std::string &reason) |
fail the face and raise onFail event if it's UP; otherwise do nothing More... | |
FaceCounters & | getMutableCounters () |
Protected Attributes inherited from nfd::StreamFace< boost::asio::local::stream_protocol, LocalFace > | |
protocol::socket | m_socket |
Implementation of Face abstraction that uses stream-oriented Unix domain sockets as underlying transport mechanism.
Definition at line 40 of file unix-stream-face.hpp.
nfd::UnixStreamFace::UnixStreamFace | ( | const FaceUri & | remoteUri, |
const FaceUri & | localUri, | ||
protocol::socket | socket | ||
) |
Definition at line 36 of file unix-stream-face.cpp.