ccnr_match.c File Reference

Part of ccnr - CCNx Repository Daemon. More...

Go to the source code of this file.

Functions

PUBLIC void r_match_consume_interest (struct ccnr_handle *h, struct propagating_entry *pe)
PUBLIC int r_match_consume_matching_interests (struct ccnr_handle *h, struct nameprefix_entry *npe, struct content_entry *content, struct ccn_parsed_ContentObject *pc, struct fdholder *fdholder)
 Consume matching interests given a nameprefix_entry and a piece of content.
PUBLIC int r_match_match_interests (struct ccnr_handle *h, struct content_entry *content, struct ccn_parsed_ContentObject *pc, struct fdholder *fdholder, struct fdholder *from_face)
 Find and consume interests that match given content.


Detailed Description

Part of ccnr - CCNx Repository Daemon.

Definition in file ccnr_match.c.


Function Documentation

PUBLIC void r_match_consume_interest ( struct ccnr_handle h,
struct propagating_entry pe 
)

Definition at line 68 of file ccnr_match.c.

Referenced by r_fwd_finalize_nameprefix(), and r_match_consume_matching_interests().

PUBLIC int r_match_consume_matching_interests ( struct ccnr_handle h,
struct nameprefix_entry npe,
struct content_entry content,
struct ccn_parsed_ContentObject pc,
struct fdholder fdholder 
)

Consume matching interests given a nameprefix_entry and a piece of content.

If fdholder is not NULL, pay attention only to interests from that fdholder. It is allowed to pass NULL for pc, but if you have a (valid) one it will avoid a re-parse.

Returns:
number of matches found.

Definition at line 97 of file ccnr_match.c.

Referenced by r_match_match_interests().

PUBLIC int r_match_match_interests ( struct ccnr_handle h,
struct content_entry content,
struct ccn_parsed_ContentObject pc,
struct fdholder fdholder,
struct fdholder from_face 
)

Find and consume interests that match given content.

Schedules the sending of the content. If fdholder is not NULL, pay attention only to interests from that fdholder. It is allowed to pass NULL for pc, but if you have a (valid) one it will avoid a re-parse. For new content, from_face is the source; for old content, from_face is NULL.

Returns:
number of matches, or -1 if the new content should be dropped.

Definition at line 146 of file ccnr_match.c.

Referenced by process_incoming_content().


Generated on Thu Feb 16 00:44:06 2012 for Content-Centric Networking in C by  doxygen 1.5.6