Updated Finnish translation
[rhythmbox.git] / daapsharing / rb-daap-mdns-browser.h
bloba9e563a96c73f2a34f64174c66a5dad175b34f3c
1 /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*-
3 * Header for abstraction of Multicast DNS for DAAP sharing
5 * Copyright (C) 2005 Charles Schmidt <cschmidt2@emich.edu>
6 * Copyright (C) 2006 William Jon McCann <mccann@jhu.edu>
8 * This program is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License as published by
10 * the Free Software Foundation; either version 2 of the License, or
11 * (at your option) any later version.
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU General Public License for more details.
18 * You should have received a copy of the GNU General Public License
19 * along with this program; if not, write to the Free Software
20 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
24 #ifndef __RB_DAAP_MDNS_BROWSER_H
25 #define __RB_DAAP_MDNS_BROWSER_H
27 #include <glib.h>
28 #include <glib-object.h>
30 G_BEGIN_DECLS
32 #define RB_TYPE_DAAP_MDNS_BROWSER (rb_daap_mdns_browser_get_type ())
33 #define RB_DAAP_MDNS_BROWSER(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), RB_TYPE_DAAP_MDNS_BROWSER, RBDaapMdnsBrowser))
34 #define RB_DAAP_MDNS_BROWSER_CLASS(k) (G_TYPE_CHECK_CLASS_CAST((k), RB_TYPE_DAAP_MDNS_BROWSER, RBDaapMdnsBrowserClass))
35 #define RB_IS_DAAP_MDNS_BROWSER(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), RB_TYPE_DAAP_MDNS_BROWSER))
36 #define RB_IS_DAAP_MDNS_BROWSER_CLASS(k) (G_TYPE_CHECK_CLASS_TYPE ((k), RB_TYPE_DAAP_MDNS_BROWSER))
37 #define RB_DAAP_MDNS_BROWSER_GET_CLASS(o) (G_TYPE_INSTANCE_GET_CLASS ((o), RB_TYPE_DAAP_MDNS_BROWSER, RBDaapMdnsBrowserClass))
39 typedef struct RBDaapMdnsBrowserPrivate RBDaapMdnsBrowserPrivate;
41 typedef struct
43 GObject object;
45 RBDaapMdnsBrowserPrivate *priv;
46 } RBDaapMdnsBrowser;
48 typedef struct
50 GObjectClass parent_class;
52 void (* service_added) (RBDaapMdnsBrowser *browser,
53 const char *service_name,
54 const char *name,
55 const char *host,
56 guint port,
57 gboolean password_protected);
58 void (* service_removed ) (RBDaapMdnsBrowser *browser,
59 const char *service_name);
61 } RBDaapMdnsBrowserClass;
63 typedef enum
65 RB_DAAP_MDNS_BROWSER_ERROR_NOT_RUNNING,
66 RB_DAAP_MDNS_BROWSER_ERROR_FAILED,
67 } RBDaapMdnsBrowserError;
69 #define RB_DAAP_MDNS_BROWSER_ERROR rb_daap_mdns_browser_error_quark ()
71 GQuark rb_daap_mdns_browser_error_quark (void);
73 GType rb_daap_mdns_browser_get_type (void);
75 RBDaapMdnsBrowser *rb_daap_mdns_browser_new (void);
76 gboolean rb_daap_mdns_browser_start (RBDaapMdnsBrowser *browser,
77 GError **error);
78 gboolean rb_daap_mdns_browser_stop (RBDaapMdnsBrowser *browser,
79 GError **error);
81 G_END_DECLS
83 #endif /* __RB_DAAP_MDNS_BROWSER_H */