~ubuntu-branches/ubuntu/lucid/gnome-media/lucid

« back to all changes in this revision

Viewing changes to cddb-slave2/inetaddr.h

  • Committer: Bazaar Package Importer
  • Author(s): Luke Yelavich
  • Date: 2009-07-28 09:49:30 UTC
  • mfrom: (0.1.33 upstream)
  • Revision ID: james.westby@ubuntu.com-20090728094930-2atfxgwqd0wj55ph
Tags: 2.27.5-0ubuntu1
* New upstream release
  - General:
    + vumeter, gnome-cd and cddb-slave have been removed
  - gnome-volume-control
    + Add card and port selection (Bastien Nocera)
    + Excessive CPU usage when trying to reconnect to PulseAudio (Chris Coulson)
    + Many fixes (Bastien Nocera)
  - Updated translations:
    + es (Jorge González)
    + et (Ivar Smolin)
    + fi (Ilkka Tuohela)
    + gu (Sweta Kothari)
    + he (Yaron Shahrabani)
    + hu (Gabor Kelemen)
    + pt_BR (André Gondim)
    + sv (Daniel Nylander)
    + ta (Dr.T.Vasudevan)
    + zh_HK (Chao-Hsiung Liao)
    + zh_TW (Chao-Hsiung Liao)
* debian/rules: Remove configure flags to disable cddb-slave and gnome-cd
* 01_vumeter_nodisplay.patch: Dropped, as vumeter has been removed
* 03_menu_changes.patch: Removed references to gnome-cd and vumeter files
* 99_autoconf.patch: Refreshed

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/* GNet - Networking library
2
 
 * Copyright (C) 2000  David Helder
3
 
 * Copyright (C) 2000  Andrew Lanoix
4
 
 *
5
 
 * This library is free software; you can redistribute it and/or
6
 
 * modify it under the terms of the GNU Library General Public
7
 
 * License as published by the Free Software Foundation; either
8
 
 * version 2 of the License, or (at your option) any later version.
9
 
 *
10
 
 * This library is distributed in the hope that it will be useful,
11
 
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12
 
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
13
 
 * Library General Public License for more details.
14
 
 *
15
 
 * You should have received a copy of the GNU Library General Public
16
 
 * License along with this library; if not, write to the
17
 
 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
18
 
 * Boston, MA  02111-1307, USA.
19
 
 */
20
 
 
21
 
 
22
 
#ifndef _GNET_INETADDR_H
23
 
#define _GNET_INETADDR_H
24
 
 
25
 
#include <glib.h>
26
 
 
27
 
#ifdef   GNET_WIN32
28
 
#include <winsock2.h>   /* This needs to be here */
29
 
#endif
30
 
 
31
 
#ifdef __cplusplus
32
 
extern "C" {
33
 
#endif /* __cplusplus */
34
 
 
35
 
 
36
 
/*
37
 
 
38
 
  All fields in GInetAddr are private and should be accessed only by
39
 
  using the functions below.
40
 
 
41
 
 */
42
 
typedef struct _GInetAddr GInetAddr;
43
 
 
44
 
 
45
 
 
46
 
 
47
 
/* ********** */
48
 
 
49
 
 
50
 
/**
51
 
 *   GInetAddrAsyncStatus:
52
 
 *
53
 
 *   Status of a asynchronous lookup (from gnet_inetaddr_new_async()
54
 
 *   or gnet_inetaddr_get_name_async()), passed by
55
 
 *   GInetAddrNewAsyncFunc or GInetAddrGetNameAsyncFunc.  More errors
56
 
 *   may be added in the future, so it's best to compare against
57
 
 *   %GINETADDR_ASYNC_STATUS_OK.
58
 
 *
59
 
 **/
60
 
typedef enum {
61
 
  GINETADDR_ASYNC_STATUS_OK,
62
 
  GINETADDR_ASYNC_STATUS_ERROR
63
 
} GInetAddrAsyncStatus;
64
 
 
65
 
 
66
 
 
67
 
/**
68
 
 *   GInetAddrNewAsyncID:
69
 
 *
70
 
 *   ID of an asynchronous InetAddr creation started with
71
 
 *   gnet_inetaddr_new_async().  The creation can be canceled by
72
 
 *   calling gnet_inetaddr_new_async_cancel() with the ID.
73
 
 *
74
 
 **/
75
 
typedef gpointer GInetAddrNewAsyncID;
76
 
 
77
 
 
78
 
 
79
 
/**
80
 
 *   GInetAddrNewAsyncFunc:
81
 
 *   @inetaddr: InetAddr that was looked up
82
 
 *   @status: Status of the lookup
83
 
 *   @data: User data
84
 
 *
85
 
 *   Callback for gnet_inetaddr_new_async().
86
 
 *
87
 
 **/
88
 
typedef void (*GInetAddrNewAsyncFunc)(GInetAddr* inetaddr,
89
 
                                      GInetAddrAsyncStatus status,
90
 
                                      gpointer data);
91
 
 
92
 
 
93
 
 
94
 
/**
95
 
 *   GInetAddrGetNameAsyncID:
96
 
 *
97
 
 *   ID of an asynchronous InetAddr name lookup started with
98
 
 *   gnet_inetaddr_get_name_async().  The lookup can be canceled by
99
 
 *   calling gnet_inetaddr_get_name_async_cancel() with the ID.
100
 
 *
101
 
 **/
102
 
typedef gpointer GInetAddrGetNameAsyncID;
103
 
 
104
 
 
105
 
 
106
 
/**
107
 
 *   GInetAddrGetNameAsyncFunc:
108
 
 *   @inetaddr: InetAddr whose was looked up
109
 
 *   @status: Status of the lookup
110
 
 *   @name: Nice name of the address
111
 
 *   @data: User data
112
 
 *
113
 
 *   Callback for gnet_inetaddr_get_name_async().  Delete the name
114
 
 *   when you're done with it.
115
 
 *
116
 
 **/
117
 
typedef void (*GInetAddrGetNameAsyncFunc)(GInetAddr* inetaddr,
118
 
                                          GInetAddrAsyncStatus status,
119
 
                                          gchar* name,
120
 
                                          gpointer data);
121
 
 
122
 
 
123
 
 
124
 
 
125
 
/* ********** */
126
 
 
127
 
GInetAddr* gnet_inetaddr_new (const gchar* name, gint port);
128
 
 
129
 
GInetAddrNewAsyncID
130
 
gnet_inetaddr_new_async (const gchar* name, gint port,
131
 
                         GInetAddrNewAsyncFunc func, gpointer data);
132
 
 
133
 
void       gnet_inetaddr_new_async_cancel (GInetAddrNewAsyncID id);
134
 
 
135
 
GInetAddr* gnet_inetaddr_new_nonblock (const gchar* name, gint port);
136
 
 
137
 
GInetAddr* gnet_inetaddr_clone (const GInetAddr* ia);
138
 
 
139
 
void       gnet_inetaddr_delete (GInetAddr* ia);
140
 
 
141
 
void gnet_inetaddr_ref (GInetAddr* ia);
142
 
void gnet_inetaddr_unref (GInetAddr* ia);
143
 
 
144
 
 
145
 
/* ********** */
146
 
 
147
 
gchar* gnet_inetaddr_get_name (/* const */ GInetAddr* ia);
148
 
 
149
 
GInetAddrGetNameAsyncID
150
 
gnet_inetaddr_get_name_async (GInetAddr* ia,
151
 
                              GInetAddrGetNameAsyncFunc func,
152
 
                              gpointer data);
153
 
 
154
 
void gnet_inetaddr_get_name_async_cancel (GInetAddrGetNameAsyncID id);
155
 
 
156
 
gchar* gnet_inetaddr_get_canonical_name (const GInetAddr* ia);
157
 
 
158
 
gint gnet_inetaddr_get_port (const GInetAddr* ia);
159
 
 
160
 
void gnet_inetaddr_set_port (const GInetAddr* ia, guint port);
161
 
 
162
 
 
163
 
/* ********** */
164
 
 
165
 
gboolean gnet_inetaddr_is_canonical (const gchar* name);
166
 
 
167
 
gboolean gnet_inetaddr_is_internet  (const GInetAddr* inetaddr);
168
 
gboolean gnet_inetaddr_is_private   (const GInetAddr* inetaddr);
169
 
gboolean gnet_inetaddr_is_reserved  (const GInetAddr* inetaddr);
170
 
gboolean gnet_inetaddr_is_loopback  (const GInetAddr* inetaddr);
171
 
gboolean gnet_inetaddr_is_multicast (const GInetAddr* inetaddr);
172
 
gboolean gnet_inetaddr_is_broadcast (const GInetAddr* inetaddr);
173
 
 
174
 
 
175
 
/* ********** */
176
 
 
177
 
guint gnet_inetaddr_hash (gconstpointer p);
178
 
gint  gnet_inetaddr_equal (gconstpointer p1, gconstpointer p2);
179
 
gint  gnet_inetaddr_noport_equal (gconstpointer p1, gconstpointer p2);
180
 
 
181
 
 
182
 
/* ********** */
183
 
 
184
 
gchar*     gnet_inetaddr_gethostname (void);
185
 
GInetAddr* gnet_inetaddr_gethostaddr (void);
186
 
 
187
 
 
188
 
/* ********** */
189
 
 
190
 
GInetAddr* gnet_inetaddr_new_any (void);
191
 
GInetAddr* gnet_inetaddr_autodetect_internet_interface (void);
192
 
GInetAddr* gnet_inetaddr_get_interface_to (const GInetAddr* addr);
193
 
GInetAddr* gnet_inetaddr_get_internet_interface (void);
194
 
 
195
 
gboolean   gnet_inetaddr_is_internet_domainname (const gchar* name);
196
 
 
197
 
 
198
 
/* ********** */
199
 
 
200
 
GList* gnet_inetaddr_list_interfaces (void);
201
 
 
202
 
 
203
 
#ifdef __cplusplus
204
 
}
205
 
#endif                          /* __cplusplus */
206
 
 
207
 
#endif /* _GNET_INETADDR_H */