This file is indexed.

/usr/share/vala-0.40/vapi/avahi-gobject.vapi is in valac-0.40-vapi 0.40.4-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
/* avahi.vala
 *
 * Copyright (C) 2009  Sebastian Noack
 *
 * This library 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.
 *
 * This library 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 this library; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301  USA
 *
 * As a special exception, if you use inline functions from this file, this
 * file does not by itself cause the resulting executable to be covered by
 * the GNU Lesser General Public License.
 *
 * Author:
 *  Sebastian Noack <sebastian.noack@gmail.com>
 */

[CCode(cprefix="Ga", lower_case_cprefix="ga_")]
namespace Avahi {
	/* Error handling */

	[CCode(cheader_filename="avahi-gobject/ga-error.h", cprefix="AVAHI_ERR_")]
	public errordomain Error {
		FAILURE,
		BAD_STATE,
		INVALID_HOST_NAME,
		INVALID_DOMAIN_NAME,
		NO_NETWORK,
		INVALID_TTL,
		IS_PATTERN,
		COLLISION,
		INVALID_RECORD,

		INVALID_SERVICE_NAME,
		INVALID_SERVICE_TYPE,
		INVALID_PORT,
		INVALID_KEY,
		INVALID_ADDRESS,
		TIMEOUT,
		TOO_MANY_CLIENTS,
		TOO_MANY_OBJECTS,
		TOO_MANY_ENTRIES,
		OS,

		ACCESS_DENIED,
		INVALID_OPERATION,
		DBUS_ERROR,
		DISCONNECTED,
		NO_MEMORY,
		INVALID_OBJECT,
		NO_DAEMON,
		INVALID_INTERFACE,
		INVALID_PROTOCOL,
		INVALID_FLAGS,

		NOT_FOUND,
		INVALID_CONFIG,
		VERSION_MISMATCH,
		INVALID_SERVICE_SUBTYPE,
		INVALID_PACKET,
		INVALID_DNS_ERROR,
		DNS_FORMERR,
		DNS_SERVFAIL,
		DNS_NXDOMAIN,
		DNS_NOTIMP,

		DNS_REFUSED,
		DNS_YXDOMAIN,
		DNS_YXRRSET,
		DNS_NXRRSET,
		DNS_NOTAUTH,
		DNS_NOTZONE,
		INVALID_RDATA,
		INVALID_DNS_CLASS,
		INVALID_DNS_TYPE,
		NOT_SUPPORTED,

		NOT_PERMITTED,
		INVALID_ARGUMENT,
		IS_EMPTY,
		NO_CHANGE
	}

	[CCode(cheader_filename="avahi-gobject/ga-error.h", cname="avahi_strerror")]
	public unowned string strerror(int errno);


	/* Lookup flags */

	[CCode(cheader_filename="avahi-gobject/ga-enums.h", cprefix="GA_LOOKUP_RESULT_")]
	public enum LookupResultFlags {
		CACHED,
		WIDE_AREA,
		MULTICAST,
		LOCAL,
		OUR_OWN,
		STATIC
	}

	[Flags]
	[CCode(cheader_filename="avahi-gobject/ga-enums.h", cprefix="GA_LOOKUP_")]
	public enum LookupFlags {
		NO_FLAGS,
		USE_WIDE_AREA,
		USE_MULTICAST,
		NO_TXT,
		NO_ADDRESS
	}


	/* Client */

	[CCode(cheader_filename="avahi-gobject/ga-client.h")]
	public enum ClientState {
		NOT_STARTED,
		S_REGISTERING,
		S_RUNNING,
		S_COLLISION,
		FAILURE,
		CONNECTING
	}

	[Flags]
	[CCode(cheader_filename="avahi-gobject/ga-client.h", cprefix="GA_CLIENT_FLAG_")]
	public enum ClientFlags {
		NO_FLAGS,
		IGNORE_USER_CONFIG,
		NO_FAIL
	}

	[CCode(cheader_filename="avahi-gobject/ga-client.h")]
	public class Client : GLib.Object {
		public Client(ClientFlags flags=ClientFlags.NO_FLAGS);

		public void start() throws Error;

		[NoAccessorMethod]
		public ClientState state { get; }
		[NoAccessorMethod]
		public ClientFlags flags { get; construct; }

		public signal void state_changed(ClientState state);
	}


	/* Record browser */

	[CCode(cheader_filename="avahi-gobject/ga-record-browser.h")]
	public class RecordBrowser : GLib.Object {
		public RecordBrowser(string name, uint16 type);
		public RecordBrowser.full(Interface interface, Protocol protocol, string name, uint16 class, uint16 type, LookupFlags flags=LookupFlags.NO_FLAGS);

		public void attach(Client client) throws Error;

		[NoAccessorMethod]
		public Protocol protocol { get; set; }
		[NoAccessorMethod]
		public Interface interface { get; set; }
		[NoAccessorMethod]
		public string name { owned get; set; }
		[NoAccessorMethod]
		public uint16 type { get; set; }
		[NoAccessorMethod]
		public uint16 class { get; set; }
		[NoAccessorMethod]
		public LookupFlags flags { get; set; }

		public signal void new_record(Interface interface, Protocol protocol, string name, uint16 class, uint16 type, char[] data, LookupResultFlags flags);
		public signal void removed_record(Interface interface, Protocol protocol, string name, uint16 class, uint16 type, char[] data, LookupResultFlags flags);
		public signal void all_for_now();
		public signal void cache_exhausted();
		public signal void failure(GLib.Error error);
	}


	/* Service browser */

	[CCode(cheader_filename="avahi-gobject/ga-service-browser.h")]
	public class ServiceBrowser : GLib.Object {
		public ServiceBrowser(string type);
		public ServiceBrowser.full(Interface interface, Protocol protocol, string type, string? domain=null, LookupFlags flags=LookupFlags.NO_FLAGS);

		public void attach(Client client) throws Error;

		[NoAccessorMethod]
		public Protocol protocol { get; set; }
		[NoAccessorMethod]
		public Protocol aprotocol { get; set; }
		[NoAccessorMethod]
		public Interface interface { get; set; }
		[NoAccessorMethod]
		public string type { owned get; set; }
		[NoAccessorMethod]
		public string? domain { owned get; set; }
		[NoAccessorMethod]
		public LookupFlags flags { get; set; }

		public signal void new_service(Interface interface, Protocol protocol, string name, string type, string domain, LookupResultFlags flags);
		public signal void removed_service(Interface interface, Protocol protocol, string name, string type, string domain, LookupResultFlags flags);
		public signal void all_for_now();
		public signal void cache_exhausted();
		public signal void failure(GLib.Error error);
	}


	/* Service resolver */

	[CCode(cheader_filename="avahi-gobject/ga-service-resolver.h")]
	public class ServiceResolver : GLib.Object {
		public ServiceResolver(Interface interface, Protocol protocol, string name, string type, string domain, Protocol address_protocol, LookupFlags flags=LookupFlags.NO_FLAGS);

		public void attach(Client client) throws Error;
		public bool get_address(out Address address, out uint16 port);

		[NoAccessorMethod]
		public Protocol protocol { get; set; }
		[NoAccessorMethod]
		public Protocol aprotocol { get; set; }
		[NoAccessorMethod]
		public Interface interface { get; set; }
		[NoAccessorMethod]
		public string name { owned get; set; }
		[NoAccessorMethod]
		public string type { owned get; set; }
		[NoAccessorMethod]
		public string domain { owned get; set; }
		[NoAccessorMethod]
		public LookupFlags flags { get; set; }

		public signal void found(Interface interface, Protocol protocol, string name, string type, string domain, string hostname, Address? address, uint16 port, StringList? txt, LookupResultFlags flags);
		public signal void failure(GLib.Error error);
	}

	[CCode(cheader_filename="avahi-gobject/ga-entry-group.h")]
	public enum EntryGroupState {
		UNCOMMITED,
		REGISTERING,
		ESTABLISHED,
		COLLISION,
		FAILURE
	}

	[Compact]
	[CCode(cheader_filename="avahi-gobject/ga-entry-group.h", ref_function="", unref_function="")]
	public class EntryGroupService {
		public Interface interface;
		public Protocol protocol;
		public PublishFlags flags;
		public string name;
		public string type;
		public string domain;
		public string host;
		public uint16 port;

		public void freeze();
		public void set(string key, string value) throws Error;
		public void set_arbitrary(string key, char[] value) throws Error;
		public void remove_key(string key) throws Error;
		public void thaw() throws Error;
	}

	[CCode(cheader_filename="avahi-gobject/ga-entry-group.h")]
	public class EntryGroup : GLib.Object {
		public EntryGroup();

		public void attach(Client client) throws Error;
		[CCode(sentinel="")]
		public EntryGroupService add_service_strlist(string name, string type, uint16 port, ...) throws Error;
		[CCode(sentinel="")]
		public EntryGroupService add_service_full_strlist(Interface interface, Protocol protocol, PublishFlags flags, string name, string type, string domain, string host, uint16 port, ...) throws Error;
		public EntryGroupService add_service(string name, string type, uint16 port, ...) throws Error;
		public EntryGroupService add_service_full(Interface interface, Protocol protocol, PublishFlags flags, string name, string type, string domain, string host, uint16 port, ...) throws Error;
		public void add_record(PublishFlags flags, string name, uint16 type, uint32 ttl, char[] data) throws Error;
		public void add_record_full(Interface interface, Protocol protocol, PublishFlags flags, string name, uint16 class, uint16 type, uint32 ttl, char[] data) throws Error;
		public void commit() throws Error;
		public void reset() throws Error;

		[NoAccessorMethod]
		public EntryGroupState state { get; }

		public signal void state_changed(EntryGroupState state);
	}
}