Commit 5767946c authored by Evan Nemerson's avatar Evan Nemerson

gio-2.0: set error domain in metadata instead of custom vala

Fixes bug 669497.
parent b2756dbe
/* gio-2.0.vapi generated by vapigen, do not modify. */
/* gio-2.0.vapi generated by lt-vapigen, do not modify. */
[CCode (cprefix = "G", gir_namespace = "Gio", gir_version = "2.0", lower_case_cprefix = "g_")]
namespace GLib {
......@@ -359,7 +359,7 @@ namespace GLib {
public bool auto_grow { get; set; }
public uint buffer_size { get; set construct; }
}
[CCode (cheader_filename = "gio/gio.h")]
[CCode (cheader_filename = "gio/gio.h", type_id = "g_cancellable_get_type ()")]
public class Cancellable : GLib.Object {
[CCode (has_construct_function = false)]
public Cancellable ();
......@@ -487,7 +487,7 @@ namespace GLib {
public uint register_subtree (string object_path, GLib.DBusSubtreeVTable vtable, GLib.DBusSubtreeFlags flags, void* user_data, GLib.DestroyNotify user_data_free_func) throws GLib.Error;
public void remove_filter (uint filter_id);
public bool send_message (GLib.DBusMessage message, GLib.DBusSendMessageFlags flags, out uint32 out_serial) throws GLib.Error;
public async GLib.DBusMessage send_message_with_reply (GLib.DBusMessage message, GLib.DBusSendMessageFlags flags, int timeout_msec, uint32* out_serial = null, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public async GLib.DBusMessage send_message_with_reply (GLib.DBusMessage message, GLib.DBusSendMessageFlags flags, int timeout_msec, out uint32 out_serial = null, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public GLib.DBusMessage send_message_with_reply_sync (GLib.DBusMessage message, GLib.DBusSendMessageFlags flags, int timeout_msec, out uint32 out_serial = null, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public void set_exit_on_close (bool exit_on_close);
public uint signal_subscribe (string? sender, string? interface_name, string? member, string? object_path, string? arg0, GLib.DBusSignalFlags flags, owned GLib.DBusSignalCallback callback);
......@@ -842,23 +842,26 @@ namespace GLib {
public int16 read_int16 (GLib.Cancellable? cancellable = null) throws GLib.IOError;
public int32 read_int32 (GLib.Cancellable? cancellable = null) throws GLib.IOError;
public int64 read_int64 (GLib.Cancellable? cancellable = null) throws GLib.IOError;
[CCode (array_length = false, array_null_terminated = true)]
public string? read_line (out size_t length, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public async string? read_line_async (int io_priority = GLib.Priority.DEFAULT, GLib.Cancellable? cancellable = null, out size_t length = null) throws GLib.IOError;
public unowned string read_line_finish_utf8 (GLib.AsyncResult _result, size_t length) throws GLib.Error;
public unowned string read_line_utf8 (size_t length, GLib.Cancellable? cancellable = null) throws GLib.Error;
[CCode (array_length = false, array_null_terminated = true)]
public async string? read_line_async (int io_priority = GLib.Priority.DEFAULT, GLib.Cancellable? cancellable = null, out size_t length) throws GLib.IOError, GLib.IOError;
public string? read_line_utf8 (out size_t length, GLib.Cancellable? cancellable = null) throws GLib.IOError;
[CCode (cname = "g_data_input_stream_read_line_async", finish_function = "g_data_input_stream_read_line_finish_utf8")]
public async string? read_line_utf8_async (int io_priority = GLib.Priority.DEFAULT, GLib.Cancellable? cancellable = null, out size_t length) throws GLib.IOError, GLib.IOError;
public uint16 read_uint16 (GLib.Cancellable? cancellable = null) throws GLib.IOError;
public uint32 read_uint32 (GLib.Cancellable? cancellable = null) throws GLib.IOError;
public uint64 read_uint64 (GLib.Cancellable? cancellable = null) throws GLib.IOError;
public string? read_until (string stop_chars, out size_t length, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public async string? read_until_async (string stop_chars, int io_priority = GLib.Priority.DEFAULT, GLib.Cancellable? cancellable = null, out size_t? length = null) throws GLib.IOError;
public string? read_upto (string stop_chars, ssize_t stop_chars_len, out size_t length, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public async string? read_upto_async (string stop_chars, ssize_t stop_chars_len, int io_priority = GLib.Priority.DEFAULT, GLib.Cancellable? cancellable = null, out size_t? length = null) throws GLib.IOError;
public string read_until (string stop_chars, out size_t length, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public async string read_until_async (string stop_chars, int io_priority = GLib.Priority.DEFAULT, GLib.Cancellable? cancellable = null, out size_t length) throws GLib.IOError, GLib.IOError;
public string read_upto (string stop_chars, ssize_t stop_chars_len, out size_t length, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public async string read_upto_async (string stop_chars, ssize_t stop_chars_len, int io_priority = GLib.Priority.DEFAULT, GLib.Cancellable? cancellable = null, out size_t length) throws GLib.IOError, GLib.IOError;
public void set_byte_order (GLib.DataStreamByteOrder order);
public void set_newline_type (GLib.DataStreamNewlineType type);
public GLib.DataStreamByteOrder byte_order { get; set; }
public GLib.DataStreamNewlineType newline_type { get; set; }
}
[CCode (cheader_filename = "gio/gio.h")]
[CCode (cheader_filename = "gio/gio.h", type_id = "g_data_output_stream_get_type ()")]
public class DataOutputStream : GLib.FilterOutputStream {
[CCode (has_construct_function = false)]
public DataOutputStream (GLib.OutputStream base_stream);
......@@ -1287,8 +1290,8 @@ namespace GLib {
public bool is_closed ();
[CCode (vfunc_name = "read_fn")]
public abstract ssize_t read ([CCode (array_length_type = "gsize")] uint8[] buffer, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public bool read_all ([CCode (array_length_type = "gsize")] uint8[] buffer, out size_t bytes_read, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public virtual async ssize_t read_async ([CCode (array_length_type = "gsize")] uint8[] buffer, int io_priority = GLib.Priority.DEFAULT, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public bool read_all ([CCode (array_length_cname = "count", array_length_pos = 1.5, array_length_type = "gsize", type = "void*")] uint8[] buffer, out size_t bytes_read, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public virtual async ssize_t read_async ([CCode (array_length_cname = "count", array_length_pos = 1.5, array_length_type = "gsize", type = "void*")] uint8[] buffer, int io_priority = GLib.Priority.DEFAULT, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public bool set_pending () throws GLib.Error;
public virtual ssize_t skip (size_t count, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public virtual async ssize_t skip_async (size_t count, int io_priority = GLib.Priority.DEFAULT, GLib.Cancellable? cancellable = null) throws GLib.IOError;
......@@ -1483,8 +1486,8 @@ namespace GLib {
public virtual async ssize_t splice_async (GLib.InputStream source, GLib.OutputStreamSpliceFlags flags, int io_priority = GLib.Priority.DEFAULT, GLib.Cancellable? cancellable = null) throws GLib.IOError;
[CCode (vfunc_name = "write_fn")]
public abstract ssize_t write ([CCode (array_length_type = "gsize")] uint8[] buffer, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public bool write_all ([CCode (array_length_type = "gsize")] uint8[] buffer, out size_t bytes_written, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public virtual async ssize_t write_async ([CCode (array_length_type = "gsize")] uint8[] buffer, int io_priority = GLib.Priority.DEFAULT, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public bool write_all ([CCode (array_length_cname = "count", array_length_pos = 1.5, array_length_type = "gsize")] uint8[] buffer, out size_t bytes_written, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public virtual async ssize_t write_async ([CCode (array_length_cname = "count", array_length_pos = 1.5, array_length_type = "gsize")] uint8[] buffer, int io_priority = GLib.Priority.DEFAULT, GLib.Cancellable? cancellable = null) throws GLib.IOError;
}
[CCode (cheader_filename = "gio/gio.h", type_id = "g_permission_get_type ()")]
public abstract class Permission : GLib.Object {
......@@ -1731,7 +1734,7 @@ namespace GLib {
[CCode (has_construct_function = false, type = "GPermission*")]
public SimplePermission (bool allowed);
}
[CCode (cheader_filename = "gio/gio.h")]
[CCode (cheader_filename = "gio/gio.h", type_id = "g_socket_get_type ()")]
public class Socket : GLib.Object, GLib.Initable {
[CCode (has_construct_function = false)]
public Socket (GLib.SocketFamily family, GLib.SocketType type, GLib.SocketProtocol protocol) throws GLib.Error;
......
......@@ -7,10 +7,6 @@ namespace GLib {
public T get_proxy_sync<T> (GLib.BusType bus_type, string name, string object_path, GLib.DBusProxyFlags flags = 0, GLib.Cancellable? cancellable = null) throws GLib.IOError;
}
public class Cancellable : GLib.Object {
public bool set_error_if_cancelled () throws GLib.IOError;
}
[Compact]
[CCode (cname = "GSource", ref_function = "g_source_ref", unref_function = "g_source_unref")]
public class CancellableSource : GLib.Source {
......@@ -26,8 +22,6 @@ namespace GLib {
public async T get_proxy<T> (string? name, string object_path, GLib.DBusProxyFlags flags = 0, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public T get_proxy_sync<T> (string? name, string object_path, GLib.DBusProxyFlags flags = 0, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public uint register_object<T> (string object_path, T object) throws GLib.IOError;
public async GLib.DBusMessage send_message_with_reply (GLib.DBusMessage message, GLib.DBusSendMessageFlags flags, int timeout_msec, uint32 *out_serial = null, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public GLib.DBusMessage send_message_with_reply_sync (GLib.DBusMessage message, GLib.DBusSendMessageFlags flags, int timeout_msec, out uint32 out_serial = null, GLib.Cancellable? cancellable = null) throws GLib.IOError;
}
public class DBusMessage : GLib.Object {
......@@ -59,32 +53,8 @@ namespace GLib {
}
public class DataInputStream : GLib.BufferedInputStream {
public uint8 read_byte (GLib.Cancellable? cancellable = null) throws GLib.IOError;
public int16 read_int16 (GLib.Cancellable? cancellable = null) throws GLib.IOError;
public int32 read_int32 (GLib.Cancellable? cancellable = null) throws GLib.IOError;
public int64 read_int64 (GLib.Cancellable? cancellable = null) throws GLib.IOError;
public string? read_line (out size_t length, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public async string? read_line_async (int io_priority = GLib.Priority.DEFAULT, GLib.Cancellable? cancellable = null, out size_t length = null) throws GLib.IOError;
public unowned string read_line_finish_utf8 (GLib.AsyncResult _result, size_t length) throws GLib.Error;
public unowned string read_line_utf8 (size_t length, GLib.Cancellable? cancellable = null) throws GLib.Error;
public uint16 read_uint16 (GLib.Cancellable? cancellable = null) throws GLib.IOError;
public uint32 read_uint32 (GLib.Cancellable? cancellable = null) throws GLib.IOError;
public uint64 read_uint64 (GLib.Cancellable? cancellable = null) throws GLib.IOError;
public string? read_until (string stop_chars, out size_t length, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public async string? read_until_async (string stop_chars, int io_priority = GLib.Priority.DEFAULT, GLib.Cancellable? cancellable = null, out size_t? length = null) throws GLib.IOError;
public string? read_upto (string stop_chars, ssize_t stop_chars_len, out size_t length, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public async string? read_upto_async (string stop_chars, ssize_t stop_chars_len, int io_priority = GLib.Priority.DEFAULT, GLib.Cancellable? cancellable = null, out size_t? length = null) throws GLib.IOError;
}
public class DataOutputStream : GLib.FilterOutputStream {
public bool put_byte (uint8 data, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public bool put_int16 (int16 data, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public bool put_int32 (int32 data, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public bool put_int64 (int64 data, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public bool put_string (string str, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public bool put_uint16 (uint16 data, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public bool put_uint32 (uint32 data, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public bool put_uint64 (uint64 data, GLib.Cancellable? cancellable = null) throws GLib.IOError;
[CCode (cname = "g_data_input_stream_read_line_async", finish_function = "g_data_input_stream_read_line_finish_utf8")]
public async string? read_line_utf8_async (int io_priority = GLib.Priority.DEFAULT, GLib.Cancellable? cancellable = null, out size_t length) throws GLib.IOError, GLib.IOError;
}
[Compact]
......@@ -97,18 +67,14 @@ namespace GLib {
[CCode (vfunc_name = "close_fn")]
public virtual bool close (GLib.Cancellable? cancellable = null) throws GLib.IOError;
public virtual async bool close_async (int io_priority = GLib.Priority.DEFAULT, GLib.Cancellable? cancellable = null) throws GLib.IOError;
}
public abstract class InputStream : GLib.Object {
[CCode (vfunc_name = "close_fn")]
public abstract bool close (GLib.Cancellable? cancellable = null) throws GLib.IOError;
public virtual async bool close_async (int io_priority = GLib.Priority.DEFAULT, GLib.Cancellable? cancellable = null) throws GLib.IOError;
[CCode (vfunc_name = "read_fn")]
public abstract ssize_t read ([CCode (array_length_type = "gsize")] uint8[] buffer, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public bool read_all ([CCode (array_length_type = "gsize")] uint8[] buffer, out size_t bytes_read, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public virtual async ssize_t read_async ([CCode (array_length_type = "gsize")] uint8[] buffer, int io_priority = GLib.Priority.DEFAULT, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public virtual ssize_t skip (size_t count, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public virtual async ssize_t skip_async (size_t count, int io_priority = GLib.Priority.DEFAULT, GLib.Cancellable? cancellable = null) throws GLib.IOError;
}
public class MemoryOutputStream : GLib.OutputStream {
......@@ -124,13 +90,8 @@ namespace GLib {
public abstract class OutputStream : GLib.Object {
[CCode (vfunc_name = "close_fn")]
public abstract bool close (GLib.Cancellable? cancellable = null) throws GLib.IOError;
public virtual async bool close_async (int io_priority = GLib.Priority.DEFAULT, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public virtual ssize_t splice (GLib.InputStream source, GLib.OutputStreamSpliceFlags flags, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public virtual async ssize_t splice_async (GLib.InputStream source, GLib.OutputStreamSpliceFlags flags, int io_priority = GLib.Priority.DEFAULT, GLib.Cancellable? cancellable = null) throws GLib.IOError;
[CCode (vfunc_name = "write_fn")]
public abstract ssize_t write ([CCode (array_length_type = "gsize")] uint8[] buffer, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public bool write_all ([CCode (array_length_type = "gsize")] uint8[] buffer, out size_t bytes_written, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public virtual async ssize_t write_async ([CCode (array_length_type = "gsize")] uint8[] buffer, int io_priority = GLib.Priority.DEFAULT, GLib.Cancellable? cancellable = null) throws GLib.IOError;
}
[Compact]
......@@ -172,10 +133,6 @@ namespace GLib {
public void set_op_res_gpointer<T> (owned T op_res);
}
public class Socket : GLib.Object {
public bool condition_wait (GLib.IOCondition condition, GLib.Cancellable? cancellable = null) throws GLib.IOError;
}
[Compact]
[CCode (cname = "GSource", ref_function = "g_source_ref", unref_function = "g_source_unref")]
public class SocketSource : GLib.Source {
......@@ -207,9 +164,6 @@ namespace GLib {
}
public interface File : GLib.Object {
[CCode (vfunc_name = "monitor_dir")]
public abstract GLib.FileMonitor monitor_directory (GLib.FileMonitorFlags flags, GLib.Cancellable? cancellable = null) throws GLib.IOError;
public abstract GLib.FileMonitor monitor_file (GLib.FileMonitorFlags flags, GLib.Cancellable? cancellable = null) throws GLib.IOError;
[NoWrapper, Deprecated (since = "vala-0.16", replacement = "has_prefix")]
public abstract bool prefix_matches (GLib.File file);
[NoWrapper, Deprecated (since = "vala-0.16", replacement = "read")]
......
......@@ -68,12 +68,22 @@ BufferedInputStream
Cancellable
.connect.callback type="owned GLib.Func<GLib.Cancellable>"
.get_current nullable
.set_error_if_cancelled throws="GLib.IOError"
.source_new skip=false type="GLib.CancellableSource"
Credentials
.get_native skip=false
DataInputStream
.read_* throws="GLib.IOError"
.read_line* nullable
.read_line_finish_utf8 skip
DataOutputStream
.put_* throws="GLib.IOError"
DBusAuthObserver.authorize_authenticated_peer virtual
DBusConnection
.*.observer#parameter default=null
.send_message_with_reply*.out_serial default=null
.send_message_with_reply_finish throws="GLib.IOError"
.send_message_with_reply_sync throws="GLib.IOError"
DBusInterfaceSkeleton
.get_vtable skip=false nullable unowned=false
DBusMessage
......@@ -95,14 +105,29 @@ DBusObjectManagerClient
.name_owner nullable
DBusServer
.new_sync.observer default=null
File
.monitor_dir* throws="GLib.IOError"
.monitor_file throws="GLib.IOError"
FileAttributeInfo struct=false
IOModuleScope
.free skip
IOStream
.close* skip
.input_stream abstract
.output_stream abstract
.closed skip=false
InetAddress
.to_bytes type="unowned uint8[]" skip=false
InputStream
.close skip
.close_finish throws="GLib.IOError"
.close_fn skip
.read skip
.read_all throws="GLib.IOError"
.read_fn skip
.read_finish throws="GLib.IOError"
.skip throws="GLib.IOError"
.skip_finish throws="GLib.IOError"
MemoryOutputStream
.get_data type="unowned uint8[]"
.steal_data type="uint8[]"
......@@ -113,6 +138,16 @@ MenuItem
.set_attribute skip=false
MenuModel
.get_item_attribute skip=false
OutputStream
.close skip
.close_finish throws="GLib.IOError"
.close_fn skip
.splice throws="GLib.IOError"
.splice_finish throws="GLib.IOError"
.write skip
.write_finish throws="GLib.IOError"
.write_fn skip
.write_all throws="GLib.IOError"
Resolver
.lookup_service_async skip
.lookup_service#virtual_method skip=false name="lookup_service_fn" type="GLib.List<GLib.SrvTarget>"
......@@ -138,6 +173,7 @@ SimpleAsyncResult
.new_error skip
.new_from_error skip
Socket
.condition_wait throws="GLib.IOError"
.create_source skip=false type="GLib.SocketSource"
SocketControlMessage
.serialize.data type="uint8[]"
......@@ -213,32 +249,6 @@ simple_async_report_gerror_in_idle parent="GLib.SimpleAsyncResult" name="report_
tls_* skip
// Bug #667448: GIR parser does not offer a way to set error domain
Cancellable
.set_error_if_cancelled skip
DBusConnection
.send_message_with_reply* skip
DataInputStream
.read_* skip
DataOutputStream
.put_* skip
IOStream
.close* skip
.closed skip=false
InputStream
.close* skip
.read* skip
.skip* skip
OutputStream
.close* skip
.splice* skip
.write* skip
Socket
.condition_wait skip
File
.monitor_dir* skip
.monitor_file skip
// Bug #666796: GIR parser doesn't pick up ref/unref functions
DBus*Info
.ref skip
......@@ -308,6 +318,9 @@ DBus*Info.generate_xml.string_builder out=false
// Back compat
TlsCertificate abstract=false
DataInputStream
.read_line type="string?"
.read_line_finish type="string?"
// Forward upstream
content_type_from_mime_type nullable
......@@ -324,6 +337,8 @@ AppInfo
AsyncReadyCallback.source_object nullable
DBusSubtreeDispatchFunc nullable unowned
DBusSubtreeVTable.enumerate skip=false
InputStream
.read*.buffer type="uint8[]" array_length_idx=1
LoadableIcon
.load_finish.type out nullable unowned=false default=null
Socket
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment