![]() |
ndn-lite
|
Abstract NDN network face. More...
![]() |
Data Structures | |
struct | ndn_face_intf |
Abstract NDN network face. More... | |
Typedefs | |
typedef int(* | ndn_face_intf_up) (struct ndn_face_intf *self) |
Turn on the face. More... | |
typedef int(* | ndn_face_intf_send) (struct ndn_face_intf *self, const uint8_t *packet, uint32_t size) |
Send out a packet. More... | |
typedef int(* | ndn_face_intf_down) (struct ndn_face_intf *self) |
Shutdown the face temporarily. More... | |
typedef void(* | ndn_face_intf_destroy) (struct ndn_face_intf *self) |
Destructor. More... | |
typedef struct ndn_face_intf | ndn_face_intf_t |
Abstract NDN network face. More... | |
Functions | |
static int | ndn_face_up (ndn_face_intf_t *self) |
Turn on the face. More... | |
static int | ndn_face_send (ndn_face_intf_t *self, const uint8_t *packet, uint32_t size) |
Send out a packet. More... | |
static int | ndn_face_down (ndn_face_intf_t *self) |
Shutdown the face temporarily. More... | |
static void | ndn_face_destroy (ndn_face_intf_t *self) |
Destructor. More... | |
Abstract NDN network face.
typedef void(* ndn_face_intf_destroy) (struct ndn_face_intf *self) |
Destructor.
typedef int(* ndn_face_intf_down) (struct ndn_face_intf *self) |
Shutdown the face temporarily.
typedef int(* ndn_face_intf_send) (struct ndn_face_intf *self, const uint8_t *packet, uint32_t size) |
Send out a packet.
typedef struct ndn_face_intf ndn_face_intf_t |
Abstract NDN network face.
An abstract base class for all faces. Derived classes should implement the function ndn_face_intf::up, ndn_face_intf::send, ndn_face_intf::down, and ndn_face_intf::destroy with platform-specific APIs via assigning function pointers in ndn_face_intf
.
ndn_face_intf
should always be the first member of any face class. typedef int(* ndn_face_intf_up) (struct ndn_face_intf *self) |
Turn on the face.
|
inlinestatic |
Destructor.
Destroy the face permanently.
[in,out] | self | The face to destroy. |
|
inlinestatic |
Shutdown the face temporarily.
[in,out] | self | Input. The interface to turn off. |
|
inlinestatic |
Send out a packet.
[in,out] | self | The face through which to send. |
[in] | packet | The encoded packet. |
[in] | size | The size of packet . |
|
inlinestatic |
Turn on the face.
[in,out] | self | The face to trun on. |