Public Attributes
AvahiPoll Struct Reference

#include <watch.h>

List of all members.

Public Attributes

void(* timeout_free )(AvahiTimeout *t)
AvahiTimeout *(* timeout_new )(const AvahiPoll *api, const struct timeval *tv, AvahiTimeoutCallback callback, void *userdata)
void(* timeout_update )(AvahiTimeout *, const struct timeval *tv)
voiduserdata
void(* watch_free )(AvahiWatch *w)
AvahiWatchEvent(* watch_get_events )(AvahiWatch *w)
AvahiWatch *(* watch_new )(const AvahiPoll *api, int fd, AvahiWatchEvent event, AvahiWatchCallback callback, void *userdata)
void(* watch_update )(AvahiWatch *w, AvahiWatchEvent event)

Detailed Description

Defines an abstracted event polling API. This may be used to connect Avahi to other main loops. This is losely based on Unix poll(2). A consumer will call watch_new() for all file descriptors it wants to listen for events on. In addition he can call timeout_new() to define time based events .

Definition at line 62 of file watch.h.


Member Data Documentation

Free a timeout. It is safe to call this function from an AvahiTimeoutCallback

Definition at line 93 of file watch.h.

AvahiTimeout*(* AvahiPoll::timeout_new)(const AvahiPoll *api, const struct timeval *tv, AvahiTimeoutCallback callback, void *userdata)

Set a wakeup time for the polling loop. The API will call the callback function when the absolute time *tv is reached. If tv is NULL, the timeout is disabled. After the timeout expired the callback function will be called and the timeout is disabled. You can reenable it by calling timeout_update()

Definition at line 86 of file watch.h.

void(* AvahiPoll::timeout_update)(AvahiTimeout *, const struct timeval *tv)

Update the absolute expiration time for a timeout, If tv is null, the timeout is disabled. It is safe to call this function from an AvahiTimeoutCallback

Definition at line 90 of file watch.h.

Some abstract user data usable by the provider of the API

Definition at line 65 of file watch.h.

Free a watch. It is safe to call this function from an AvahiWatchCallback

Definition at line 79 of file watch.h.

Return the events that happened. It is safe to call this function from an AvahiWatchCallback

Definition at line 76 of file watch.h.

Create a new watch for the specified file descriptor and for the specified events. The API will call the callback function whenever any of the events happens.

Definition at line 70 of file watch.h.

Update the events to wait for. It is safe to call this function from an AvahiWatchCallback

Definition at line 73 of file watch.h.


The documentation for this struct was generated from the following file:


pedal_monitor
Author(s): Pedro Mendes
autogenerated on Fri Jun 6 2014 18:37:22