Go to the source code of this file.
Functions | |
void | r_util_gettime (const struct ccn_gettime *self, struct ccn_timeval *result) |
int | r_util_timecmp (long secA, unsigned usecA, long secB, unsigned usecB) |
void | r_util_reseed (struct ccnr_handle *h) |
void | r_util_indexbuf_release (struct ccnr_handle *h, struct ccn_indexbuf *c) |
struct ccn_indexbuf * | r_util_indexbuf_obtain (struct ccnr_handle *h) |
void | r_util_charbuf_release (struct ccnr_handle *h, struct ccn_charbuf *c) |
struct ccn_charbuf * | r_util_charbuf_obtain (struct ccnr_handle *h) |
intmax_t | r_util_segment_from_component (const unsigned char *ccnb, size_t start, size_t stop) |
int | r_util_name_comp_compare (const unsigned char *data, const struct ccn_indexbuf *indexbuf, unsigned int i, const void *val, size_t length) |
Compare a name component at index i to bytes in buf and return 0 if they are equal length and equal value. | |
int | r_util_is_final_pco (const unsigned char *ccnb, struct ccn_parsed_ContentObject *pco, struct ccn_indexbuf *comps) |
Given a ccnb encoded content object, the parsed form, and name components report whether this is the last (FinalBlockID) segment of a stream. |
Definition in file ccnr_util.h.
struct ccn_charbuf* r_util_charbuf_obtain | ( | struct ccnr_handle * | h | ) | [read] |
Definition at line 60 of file ccnr_util.c.
Referenced by r_link_stuff_and_send(), and r_sync_notify_content().
void r_util_charbuf_release | ( | struct ccnr_handle * | h, | |
struct ccn_charbuf * | c | |||
) |
Definition at line 71 of file ccnr_util.c.
Referenced by r_link_stuff_and_send(), and r_sync_notify_content().
void r_util_gettime | ( | const struct ccn_gettime * | self, | |
struct ccn_timeval * | result | |||
) |
struct ccn_indexbuf* r_util_indexbuf_obtain | ( | struct ccnr_handle * | h | ) | [read] |
void r_util_indexbuf_release | ( | struct ccnr_handle * | h, | |
struct ccn_indexbuf * | c | |||
) |
int r_util_is_final_pco | ( | const unsigned char * | ccnb, | |
struct ccn_parsed_ContentObject * | pco, | |||
struct ccn_indexbuf * | comps | |||
) |
Given a ccnb encoded content object, the parsed form, and name components report whether this is the last (FinalBlockID) segment of a stream.
This is very similar to ccn_is_final_block()
Definition at line 194 of file ccnr_util.c.
Referenced by load_policy(), and r_proto_policy_update().
int r_util_name_comp_compare | ( | const unsigned char * | data, | |
const struct ccn_indexbuf * | indexbuf, | |||
unsigned int | i, | |||
const void * | buf, | |||
size_t | length | |||
) |
Compare a name component at index i to bytes in buf and return 0 if they are equal length and equal value.
In the case of inequality, a negative or positive value is returned, according to the canonical ordering of names.
Definition at line 173 of file ccnr_util.c.
Referenced by r_proto_answer_req().
void r_util_reseed | ( | struct ccnr_handle * | h | ) |
intmax_t r_util_segment_from_component | ( | const unsigned char * | ccnb, | |
size_t | start, | |||
size_t | stop | |||
) |
Definition at line 146 of file ccnr_util.c.
Referenced by r_proto_continue_enumeration(), and r_proto_expect_content().
int r_util_timecmp | ( | long | secA, | |
unsigned | usecA, | |||
long | secB, | |||
unsigned | usecB | |||
) |