D-Bus: Emit cast to avoid C warning for signal handling in clients
[vala-lang.git] / vapi / libepc-1.0.vapi
bloba72cf447883450aefc47f8db848f4f255e8d8634
1 /* libepc-1.0.vapi generated by vapigen, do not modify. */
3 [CCode (cprefix = "Epc", lower_case_cprefix = "epc_")]
4 namespace Epc {
5         [Compact]
6         [CCode (cheader_filename = "libepc/publisher.h")]
7         public class AuthContext {
8                 public bool check_password (string password);
9                 public unowned string get_key ();
10                 public unowned string get_password ();
11                 public unowned Epc.Publisher get_publisher ();
12         }
13         [CCode (cheader_filename = "libepc/consumer.h")]
14         public class Consumer : GLib.Object {
15                 [CCode (has_construct_function = false)]
16                 public Consumer (Epc.ServiceInfo service);
17                 [CCode (has_construct_function = false)]
18                 public Consumer.for_name (string name);
19                 [CCode (has_construct_function = false)]
20                 public Consumer.for_name_full (string name, string application, string domain);
21                 public unowned string get_password ();
22                 public Epc.Protocol get_protocol ();
23                 public unowned string get_username ();
24                 public bool is_publisher_resolved ();
25                 public unowned GLib.List list (string pattern) throws GLib.Error;
26                 public void* lookup (string key, out unowned size_t? length) throws GLib.Error;
27                 public bool resolve_publisher (uint timeout);
28                 public void set_password (string password);
29                 public void set_protocol (Epc.Protocol protocol);
30                 public void set_username (string username);
31                 [NoAccessorMethod]
32                 public string application { owned get; construct; }
33                 [NoAccessorMethod]
34                 public string domain { owned get; construct; }
35                 [NoAccessorMethod]
36                 public string hostname { owned get; construct; }
37                 [NoAccessorMethod]
38                 public string name { owned get; construct; }
39                 public string password { get; set construct; }
40                 [NoAccessorMethod]
41                 public string path { owned get; construct; }
42                 [NoAccessorMethod]
43                 public int port { get; construct; }
44                 public Epc.Protocol protocol { get; set construct; }
45                 public string username { get; set construct; }
46                 public virtual signal bool authenticate (string realm);
47                 public virtual signal void publisher_resolved (Epc.Protocol protocol, string hostname, uint port);
48         }
49         [Compact]
50         [CCode (ref_function = "epc_contents_ref", unref_function = "epc_contents_unref", cheader_filename = "libepc/contents.h")]
51         public class Contents {
52                 [CCode (has_construct_function = false)]
53                 public Contents (string type, void* data, ssize_t length, GLib.DestroyNotify destroy_data);
54                 [CCode (has_construct_function = false)]
55                 public Contents.dup (string type, void* data, ssize_t length);
56                 public void* get_data (size_t length);
57                 public unowned string get_mime_type ();
58                 public bool is_stream ();
59                 public static unowned Epc.Contents stream_new (string type, Epc.ContentsReadFunc callback, GLib.DestroyNotify destroy_data);
60                 public void* stream_read (size_t length);
61         }
62         [CCode (cheader_filename = "libepc/dispatcher.h")]
63         public class Dispatcher : GLib.Object {
64                 [CCode (has_construct_function = false)]
65                 public Dispatcher (string name);
66                 public void add_service (Epc.AddressFamily protocol, string type, string domain, string host, uint16 port);
67                 public void add_service_subtype (string type, string subtype);
68                 public Epc.CollisionHandling get_collision_handling ();
69                 public unowned string get_cookie ();
70                 public unowned string get_name ();
71                 public void reset ();
72                 public bool run () throws GLib.Error;
73                 public void set_collision_handling (Epc.CollisionHandling method);
74                 public void set_cookie (string cookie);
75                 public void set_name (string name);
76                 public void set_service_details (string type);
77                 public Epc.CollisionHandling collision_handling { get; set construct; }
78                 public string cookie { get; set construct; }
79                 public string name { get; set construct; }
80         }
81         [CCode (cheader_filename = "libepc/publisher.h")]
82         public class Publisher : GLib.Object {
83                 [CCode (has_construct_function = false)]
84                 public Publisher (string? name, string application, string? domain);
85                 public void add (string key, void* data, ssize_t length);
86                 public void add_bookmark (string key, string label);
87                 public void add_file (string key, string filename);
88                 public void add_handler (string key, Epc.ContentsHandler handler, GLib.DestroyNotify destroy_data);
89                 public static unowned string expand_name (string name) throws GLib.Error;
90                 public Epc.AuthFlags get_auth_flags ();
91                 public unowned string get_certificate_file ();
92                 public Epc.CollisionHandling get_collision_handling ();
93                 public unowned string get_contents_path ();
94                 public unowned string get_path (string key);
95                 public unowned string get_private_key_file ();
96                 public Epc.Protocol get_protocol ();
97                 public unowned string get_service_cookie ();
98                 public unowned string get_service_domain ();
99                 public unowned string get_service_name ();
100                 public unowned string get_uri (string key) throws GLib.Error;
101                 public bool has_key (string key);
102                 public unowned GLib.List list (string pattern);
103                 public void* lookup (string key);
104                 public bool quit ();
105                 public bool remove (string key);
106                 public bool run () throws GLib.Error;
107                 public bool run_async () throws GLib.Error;
108                 public void set_auth_flags (Epc.AuthFlags flags);
109                 public void set_auth_handler (string key, Epc.AuthHandler handler, GLib.DestroyNotify destroy_data);
110                 public void set_collision_handling (Epc.CollisionHandling method);
111                 public void set_contents_path (string path);
112                 public void set_credentials (string certfile, string keyfile);
113                 public void set_protocol (Epc.Protocol protocol);
114                 public void set_service_cookie (string cookie);
115                 public void set_service_name (string name);
116                 [NoAccessorMethod]
117                 public string application { owned get; set construct; }
118                 public Epc.AuthFlags auth_flags { get; set construct; }
119                 [NoAccessorMethod]
120                 public string certificate_file { owned get; set construct; }
121                 public Epc.CollisionHandling collision_handling { get; set construct; }
122                 public string contents_path { get; set construct; }
123                 [NoAccessorMethod]
124                 public string private_key_file { owned get; set construct; }
125                 public Epc.Protocol protocol { get; set construct; }
126                 public string service_cookie { get; set construct; }
127                 [NoAccessorMethod]
128                 public string service_domain { owned get; set construct; }
129                 public string service_name { get; set construct; }
130         }
131         [Compact]
132         [CCode (ref_function = "epc_service_info_ref", unref_function = "epc_service_info_unref", type_id = "EPC_TYPE_SERVICE_INFO", cheader_filename = "libepc/service-info.h")]
133         public class ServiceInfo {
134                 public Epc.AddressFamily get_address_family ();
135                 public unowned string get_detail (string name);
136                 public unowned string get_host ();
137                 public unowned string get_interface ();
138                 public uint get_port ();
139                 public unowned string get_service_type ();
140         }
141         [CCode (cheader_filename = "libepc/service-monitor.h")]
142         public class ServiceMonitor : GLib.Object {
143                 [CCode (has_construct_function = false)]
144                 public ServiceMonitor (string? application, string? domain, ...);
145                 [CCode (has_construct_function = false)]
146                 public ServiceMonitor.for_types (string? domain, ...);
147                 [CCode (has_construct_function = false)]
148                 public ServiceMonitor.for_types_strv (string? domain, string types);
149                 public bool get_skip_our_own ();
150                 public void set_skip_our_own (bool setting);
151                 [NoAccessorMethod]
152                 public string application { owned get; construct; }
153                 [NoAccessorMethod]
154                 public string domain { owned get; construct; }
155                 [NoAccessorMethod]
156                 [CCode (array_length = false, array_null_terminated = true)]
157                 public string[] service_types { owned get; construct; }
158                 public bool skip_our_own { get; set construct; }
159                 public virtual signal void scanning_done (string type);
160                 public virtual signal void service_found (string name, Epc.ServiceInfo info);
161                 public virtual signal void service_removed (string name, string type);
162         }
163         [CCode (cprefix = "EPC_ADDRESS_", cheader_filename = "libepc/enums.h")]
164         public enum AddressFamily {
165                 UNSPEC,
166                 IPV4,
167                 IPV6
168         }
169         [CCode (cprefix = "EPC_AUTH_", cheader_filename = "libepc/enums.h")]
170         [Flags]
171         public enum AuthFlags {
172                 DEFAULT,
173                 PASSWORD_TEXT_NEEDED
174         }
175         [CCode (cprefix = "EPC_COLLISIONS_", cheader_filename = "libepc/enums.h")]
176         public enum CollisionHandling {
177                 IGNORE,
178                 CHANGE_NAME,
179                 UNIQUE_SERVICE
180         }
181         [CCode (cprefix = "EPC_PROTOCOL_", cheader_filename = "libepc/enums.h")]
182         public enum Protocol {
183                 UNKNOWN,
184                 HTTP,
185                 HTTPS
186         }
187         [CCode (cheader_filename = "libepc/service-type.h")]
188         public delegate bool AuthHandler (Epc.AuthContext context, string username);
189         [CCode (cheader_filename = "libepc/service-type.h")]
190         public delegate unowned Epc.Contents ContentsHandler (Epc.Publisher publisher, string key);
191         [CCode (cheader_filename = "libepc/service-type.h")]
192         public delegate bool ContentsReadFunc (Epc.Contents contents, void* buffer, size_t length);
193         [CCode (cheader_filename = "libepc/service-type.h")]
194         public const string SERVICE_TYPE_HTTP;
195         [CCode (cheader_filename = "libepc/service-type.h")]
196         public const string SERVICE_TYPE_HTTPS;
197         [CCode (cheader_filename = "libepc/service-type.h")]
198         public static unowned GLib.EnumClass address_family_get_class ();
199         [CCode (cheader_filename = "libepc/service-type.h")]
200         public static unowned GLib.FlagsClass auth_flags_get_class ();
201         [CCode (cheader_filename = "libepc/service-type.h")]
202         public static unowned string auth_flags_to_string (Epc.AuthFlags value);
203         [CCode (cheader_filename = "libepc/service-type.h")]
204         public static unowned GLib.EnumClass collision_handling_get_class ();
205         [CCode (cheader_filename = "libepc/service-type.h")]
206         public static unowned string collision_handling_to_string (Epc.CollisionHandling value);
207         [CCode (cheader_filename = "libepc/service-type.h")]
208         public static GLib.Quark http_error_quark ();
209         [CCode (cheader_filename = "libepc/service-type.h")]
210         public static unowned string protocol_build_uri (Epc.Protocol protocol, string hostname, uint16 port, string path);
211         [CCode (cheader_filename = "libepc/service-type.h")]
212         public static Epc.Protocol protocol_from_name (string name, Epc.Protocol fallback);
213         [CCode (cheader_filename = "libepc/service-type.h")]
214         public static unowned GLib.EnumClass protocol_get_class ();
215         [CCode (cheader_filename = "libepc/service-type.h")]
216         public static unowned string protocol_get_service_type (Epc.Protocol protocol);
217         [CCode (cheader_filename = "libepc/service-type.h")]
218         public static unowned string protocol_get_uri_scheme (Epc.Protocol protocol);
219         [CCode (cheader_filename = "libepc/service-type.h")]
220         public static unowned string protocol_to_string (Epc.Protocol value);
221         [CCode (cheader_filename = "libepc/service-type.h")]
222         public static unowned string service_type_get_base (string type);
223         [CCode (cheader_filename = "libepc/service-type.h")]
224         public static Epc.Protocol service_type_get_protocol (string service_type);
225         [CCode (cheader_filename = "libepc/service-type.h")]
226         public static unowned string service_type_list_supported (string application);
227         [CCode (cheader_filename = "libepc/service-type.h")]
228         public static unowned string service_type_new (Epc.Protocol protocol, string application);