All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Typedefs | Functions
event.c File Reference
#include <freeradius-devel/libradius.h>
#include <freeradius-devel/heap.h>
#include <freeradius-devel/event.h>
+ Include dependency graph for event.c:

Go to the source code of this file.

Data Structures

struct  fr_event_fd_t
 
struct  fr_event_list_t
 
struct  fr_event_t
 

Macros

#define FR_EV_MAX_FDS   (256)
 
#define USEC   (1000000)
 

Typedefs

typedef struct fr_event_fd_t fr_event_fd_t
 

Functions

static int _event_list_free (fr_event_list_t *list)
 
int fr_event_delete (fr_event_list_t *el, fr_event_t **parent)
 
int fr_event_fd_delete (fr_event_list_t *el, int type, int fd)
 
int fr_event_fd_insert (fr_event_list_t *el, int type, int fd, fr_event_fd_handler_t handler, void *ctx)
 
int fr_event_insert (fr_event_list_t *el, fr_event_callback_t callback, void *ctx, struct timeval *when, fr_event_t **parent)
 
fr_event_list_tfr_event_list_create (TALLOC_CTX *ctx, fr_event_status_t status)
 
int fr_event_list_num_elements (fr_event_list_t *el)
 
int fr_event_list_num_fds (fr_event_list_t *el)
 
static int fr_event_list_time_cmp (void const *one, void const *two)
 
int fr_event_loop (fr_event_list_t *el)
 
void fr_event_loop_exit (fr_event_list_t *el, int code)
 
bool fr_event_loop_exiting (fr_event_list_t *el)
 
int fr_event_now (fr_event_list_t *el, struct timeval *when)
 
int fr_event_run (fr_event_list_t *el, struct timeval *when)
 

Data Structure Documentation

struct fr_event_fd_t

Definition at line 40 of file event.c.

+ Collaboration diagram for fr_event_fd_t:
Data Fields
void * ctx
int fd
fr_event_fd_handler_t handler
struct fr_event_list_t

Definition at line 51 of file event.c.

+ Collaboration diagram for fr_event_list_t:
Data Fields
bool changed
bool dispatch
int exit
int max_readers
struct timeval now
int num_readers
fr_event_fd_t readers[FR_EV_MAX_FDS]
fr_event_status_t status
fr_heap_t * times
struct fr_event_t

Definition at line 77 of file event.c.

+ Collaboration diagram for fr_event_t:
Data Fields
fr_event_callback_t callback
void * ctx
int heap
fr_event_t ** parent
struct timeval when

Macro Definition Documentation

#define FR_EV_MAX_FDS   (256)

Definition at line 46 of file event.c.

#define USEC   (1000000)

Definition at line 49 of file event.c.

Typedef Documentation

typedef struct fr_event_fd_t fr_event_fd_t

Function Documentation

static int _event_list_free ( fr_event_list_t list)
static

Definition at line 101 of file event.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int fr_event_delete ( fr_event_list_t el,
fr_event_t **  parent 
)

Definition at line 172 of file event.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int fr_event_fd_delete ( fr_event_list_t el,
int  type,
int  fd 
)

Definition at line 444 of file event.c.

+ Here is the caller graph for this function:

int fr_event_fd_insert ( fr_event_list_t el,
int  type,
int  fd,
fr_event_fd_handler_t  handler,
void *  ctx 
)

Definition at line 324 of file event.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int fr_event_insert ( fr_event_list_t el,
fr_event_callback_t  callback,
void *  ctx,
struct timeval *  when,
fr_event_t **  parent 
)

Definition at line 204 of file event.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

fr_event_list_t* fr_event_list_create ( TALLOC_CTX *  ctx,
fr_event_status_t  status 
)

Definition at line 120 of file event.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int fr_event_list_num_elements ( fr_event_list_t el)

Definition at line 164 of file event.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int fr_event_list_num_fds ( fr_event_list_t el)

Definition at line 157 of file event.c.

+ Here is the caller graph for this function:

static int fr_event_list_time_cmp ( void const *  one,
void const *  two 
)
static

Definition at line 86 of file event.c.

+ Here is the caller graph for this function:

int fr_event_loop ( fr_event_list_t el)

Definition at line 507 of file event.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void fr_event_loop_exit ( fr_event_list_t el,
int  code 
)

Definition at line 495 of file event.c.

+ Here is the caller graph for this function:

bool fr_event_loop_exiting ( fr_event_list_t el)

Definition at line 502 of file event.c.

+ Here is the caller graph for this function:

int fr_event_now ( fr_event_list_t el,
struct timeval *  when 
)

Definition at line 310 of file event.c.

+ Here is the caller graph for this function:

int fr_event_run ( fr_event_list_t el,
struct timeval *  when 
)

Definition at line 266 of file event.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function: