From c58379bde376cb2298fca14f83a86626f1b76f2f Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Sat, 7 May 2005 13:37:03 +0000 Subject: rename libavahi-core to avahi-core git-svn-id: file:///home/lennart/svn/public/avahi/trunk@57 941a03a8-eaeb-0310-b9a0-b1bbd8fe43fe --- avahi-core/announce.h | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 avahi-core/announce.h (limited to 'avahi-core/announce.h') diff --git a/avahi-core/announce.h b/avahi-core/announce.h new file mode 100644 index 0000000..71b2f03 --- /dev/null +++ b/avahi-core/announce.h @@ -0,0 +1,72 @@ +#ifndef fooannouncehfoo +#define fooannouncehfoo + +/* $Id$ */ + +/*** + This file is part of avahi. + + avahi is free software; you can redistribute it and/or modify it + under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation; either version 2.1 of the + License, or (at your option) any later version. + + avahi is distributed in the hope that it will be useful, but WITHOUT + ANY WARRANTY; without even the implied warranty of MERCHANTABILITY + or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General + Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with avahi; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 + USA. +***/ + +#include + +typedef struct _AvahiAnnouncement AvahiAnnouncement; + +#include "llist.h" +#include "iface.h" +#include "server.h" +#include "timeeventq.h" + +typedef enum { + AVAHI_PROBING, + AVAHI_WAITING, /* wait for other records in group */ + AVAHI_ANNOUNCING, + AVAHI_ESTABLISHED +} AvahiAnnouncementState; + +struct _AvahiAnnouncement { + AvahiServer *server; + AvahiInterface *interface; + AvahiEntry *entry; + + AvahiTimeEvent *time_event; + + AvahiAnnouncementState state; + guint n_iteration; + guint sec_delay; + + AVAHI_LLIST_FIELDS(AvahiAnnouncement, by_interface); + AVAHI_LLIST_FIELDS(AvahiAnnouncement, by_entry); +}; + +void avahi_announce_interface(AvahiServer *s, AvahiInterface *i); +void avahi_announce_entry(AvahiServer *s, AvahiEntry *e); +void avahi_announce_group(AvahiServer *s, AvahiEntryGroup *g); + +void avahi_entry_group_check_probed(AvahiEntryGroup *g, gboolean immediately); + +gboolean avahi_entry_registered(AvahiServer *s, AvahiEntry *e, AvahiInterface *i); +gboolean avahi_entry_registering(AvahiServer *s, AvahiEntry *e, AvahiInterface *i); + +void avahi_goodbye_interface(AvahiServer *s, AvahiInterface *i, gboolean send); +void avahi_goodbye_entry(AvahiServer *s, AvahiEntry *e, gboolean send); + +void avahi_goodbye_all(AvahiServer *s, gboolean send); + +AvahiAnnouncement *avahi_get_announcement(AvahiServer *s, AvahiEntry *e, AvahiInterface *i); + +#endif -- cgit