From fe09838ed65eee6c1a100c1e3cbe70d38e46667c Mon Sep 17 00:00:00 2001 From: Juerg Billeter Date: Mon, 18 Feb 2008 15:18:51 +0000 Subject: [PATCH] update to use vala-gen-introspect 2008-02-18 Juerg Billeter * vapi/packages/gnet-2.0/: update to use vala-gen-introspect * vapi/gnet-2.0.vapi: regenerated svn path=/trunk/; revision=1015 --- ChangeLog | 6 + vapi/gnet-2.0.vapi | 907 ++++++++------- vapi/packages/gnet-2.0/gnet-2.0-custom.vala | 7 +- vapi/packages/gnet-2.0/gnet-2.0.files | 4 +- vapi/packages/gnet-2.0/gnet-2.0.gi | 1642 +++++++++++++++++++++++++++ vapi/packages/gnet-2.0/gnet-2.0.gidl | 1401 ----------------------- vapi/packages/gnet-2.0/gnet-2.0.metadata | 2 +- 7 files changed, 2140 insertions(+), 1829 deletions(-) create mode 100644 vapi/packages/gnet-2.0/gnet-2.0.gi delete mode 100644 vapi/packages/gnet-2.0/gnet-2.0.gidl diff --git a/ChangeLog b/ChangeLog index 926ffa2..6a9893d 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,11 @@ 2008-02-18 Jürg Billeter + * vapi/packages/gnet-2.0/: update to use vala-gen-introspect + + * vapi/gnet-2.0.vapi: regenerated + +2008-02-18 Jürg Billeter + * vapi/glib-2.0.vapi: fix GObjectClass binding 2008-02-16 Jürg Billeter diff --git a/vapi/gnet-2.0.vapi b/vapi/gnet-2.0.vapi index 1bd00e6..2138e7b 100644 --- a/vapi/gnet-2.0.vapi +++ b/vapi/gnet-2.0.vapi @@ -1,15 +1,15 @@ -/* gnet-2.0.vala generated by lt-vapigen, do not modify. */ +/* gnet-2.0.vapi generated by lt-vapigen, do not modify. */ [CCode (cprefix = "G", lower_case_cprefix = "gnet_")] namespace GNet { - [CCode (cprefix = "GNET_IO_ERROR_", cheader_filename = "gnet-2.0-custom.h")] + [CCode (cprefix = "GNET_IO_ERROR_", cheader_filename = "gnet.h")] public enum IOError { NONE, AGAIN, INVAL, UNKNOWN, } - [CCode (cprefix = "GNET_CONN_", cheader_filename = "gnet-2.0.h")] + [CCode (cprefix = "GNET_CONN_", cheader_filename = "gnet.h")] public enum ConnEventType { ERROR, CONNECT, @@ -20,12 +20,13 @@ namespace GNet { READABLE, WRITABLE, } - [CCode (cprefix = "GNET_CONN_HTTP_ERROR_", cheader_filename = "gnet-2.0.h")] + [CCode (cprefix = "GNET_CONN_HTTP_ERROR_", cheader_filename = "gnet.h")] public enum ConnHttpError { UNSPECIFIED, PROTOCOL_UNSUPPORTED, + HOSTNAME_RESOLUTION, } - [CCode (cprefix = "GNET_CONN_HTTP_", cheader_filename = "gnet-2.0.h")] + [CCode (cprefix = "GNET_CONN_HTTP_", cheader_filename = "gnet.h")] public enum ConnHttpEventType { RESOLVED, CONNECTED, @@ -36,23 +37,23 @@ namespace GNet { TIMEOUT, ERROR, } - [CCode (cprefix = "GNET_CONN_HTTP_FLAG_SKIP_HEADER_", cheader_filename = "gnet-2.0.h")] + [CCode (cprefix = "GNET_CONN_HTTP_FLAG_SKIP_HEADER_", cheader_filename = "gnet.h")] public enum ConnHttpHeaderFlags { CHECK, } - [CCode (cprefix = "GNET_CONN_HTTP_METHOD_", cheader_filename = "gnet-2.0.h")] + [CCode (cprefix = "GNET_CONN_HTTP_METHOD_", cheader_filename = "gnet.h")] public enum ConnHttpMethod { GET, POST, } - [CCode (cprefix = "GIPV6_POLICY_", cheader_filename = "gnet-2.0.h")] + [CCode (cprefix = "GIPV6_POLICY_", cheader_filename = "gnet.h")] public enum IPv6Policy { IPV4_THEN_IPV6, IPV6_THEN_IPV4, IPV4_ONLY, IPV6_ONLY, } - [CCode (cprefix = "GNET_TOS_", cheader_filename = "gnet-2.0.h")] + [CCode (cprefix = "GNET_TOS_", cheader_filename = "gnet.h")] public enum TOS { NONE, LOWDELAY, @@ -60,31 +61,13 @@ namespace GNet { RELIABILITY, LOWCOST, } - [CCode (cprefix = "GTCP_SOCKET_CONNECT_ASYNC_STATUS_", cheader_filename = "gnet-2.0.h")] + [CCode (cprefix = "GTCP_SOCKET_CONNECT_ASYNC_STATUS_", cheader_filename = "gnet.h")] public enum TcpSocketConnectAsyncStatus { OK, INETADDR_ERROR, TCP_ERROR, } - [CCode (cheader_filename = "gnet-2.0-custom.h")] - public class NetTOS { - } - [CCode (cheader_filename = "gnet-2.0-custom.h")] - public class InetAddrGetNameAsyncID { - } - [CCode (cheader_filename = "gnet-2.0-custom.h")] - public class InetAddrNewAsyncID { - } - [CCode (cheader_filename = "gnet-2.0-custom.h")] - public class InetAddrNewListAsyncID { - } - [CCode (cheader_filename = "gnet-2.0-custom.h")] - public class TcpSocketConnectAsyncID { - } - [CCode (cheader_filename = "gnet-2.0-custom.h")] - public class TcpSocketNewAsyncID { - } - [CCode (cheader_filename = "gnet-2.0.h")] + [CCode (cheader_filename = "gnet.h")] public class Conn { public weak string hostname; public int port; @@ -110,62 +93,91 @@ namespace GNet { public uint timer; public GNet.ConnFunc func; public pointer user_data; + public weak GLib.MainContext context; + public int priority; } - [CCode (cheader_filename = "gnet-2.0.h")] + [CCode (cheader_filename = "gnet.h")] public class ConnEvent { public GNet.ConnEventType type; public weak string buffer; public int length; } - [CCode (cheader_filename = "gnet-2.0.h")] + [CCode (cheader_filename = "gnet.h")] public class ConnHttp { } - [CCode (cheader_filename = "gnet-2.0.h")] + [CCode (cheader_filename = "gnet.h")] public class ConnHttpEvent { public GNet.ConnHttpEventType type; + public ulong stsize; + [NoArrayLength] + public weak pointer[] padding; } - [CCode (cheader_filename = "gnet-2.0.h")] + [CCode (cheader_filename = "gnet.h")] public class ConnHttpEventData { + public weak GNet.ConnHttpEvent parent; public uint64 content_length; public uint64 data_received; public weak string buffer; public ulong buffer_length; + [NoArrayLength] + public weak pointer[] padding; } - [CCode (cheader_filename = "gnet-2.0.h")] + [CCode (cheader_filename = "gnet.h")] public class ConnHttpEventError { + public weak GNet.ConnHttpEvent parent; public GNet.ConnHttpError code; public weak string message; + [NoArrayLength] + public weak pointer[] padding; } - [CCode (cheader_filename = "gnet-2.0.h")] + [CCode (cheader_filename = "gnet.h")] public class ConnHttpEventRedirect { + public weak GNet.ConnHttpEvent parent; public uint num_redirects; public uint max_redirects; public weak string new_location; public bool auto_redirect; + [NoArrayLength] + public weak pointer[] padding; } - [CCode (cheader_filename = "gnet-2.0.h")] + [CCode (cheader_filename = "gnet.h")] public class ConnHttpEventResolved { + public weak GNet.ConnHttpEvent parent; public weak GNet.InetAddr ia; + [NoArrayLength] + public weak pointer[] padding; } - [CCode (cheader_filename = "gnet-2.0.h")] + [CCode (cheader_filename = "gnet.h")] public class ConnHttpEventResponse { + public weak GNet.ConnHttpEvent parent; public uint response_code; public weak string header_fields; public weak string header_values; + [NoArrayLength] + public weak pointer[] padding; } - [CCode (cheader_filename = "gnet-2.0.h")] + [CCode (cheader_filename = "gnet.h")] public class InetAddr { } - [CCode (cheader_filename = "gnet-2.0.h")] + [CCode (cheader_filename = "gnet.h")] + public class InetAddrGetNameAsyncID { + } + [CCode (cheader_filename = "gnet.h")] + public class InetAddrNewAsyncID { + } + [CCode (cheader_filename = "gnet.h")] + public class InetAddrNewListAsyncID { + } + [CCode (cheader_filename = "gnet.h")] public class MD5 { } - [CCode (cheader_filename = "gnet-2.0.h")] + [CCode (cheader_filename = "gnet.h")] public class McastSocket { } - [CCode (cheader_filename = "gnet-2.0.h")] + [CCode (cheader_filename = "gnet.h")] public class SHA { } - [CCode (cheader_filename = "gnet-2.0.h")] + [CCode (cheader_filename = "gnet.h")] public class Server { public weak GNet.InetAddr iface; public int port; @@ -174,10 +186,16 @@ namespace GNet { public GNet.ServerFunc func; public pointer user_data; } - [CCode (cheader_filename = "gnet-2.0.h")] + [CCode (cheader_filename = "gnet.h")] public class TcpSocket { } - [CCode (cheader_filename = "gnet-2.0.h")] + [CCode (cheader_filename = "gnet.h")] + public class TcpSocketConnectAsyncID { + } + [CCode (cheader_filename = "gnet.h")] + public class TcpSocketNewAsyncID { + } + [CCode (cheader_filename = "gnet.h")] public class URI { public weak string scheme; public weak string userinfo; @@ -187,386 +205,14 @@ namespace GNet { public weak string query; public weak string fragment; } - [CCode (cheader_filename = "gnet-2.0.h")] + [CCode (cheader_filename = "gnet.h")] public class UdpSocket { } - [CCode (cheader_filename = "gnet-2.0.h")] + [CCode (cheader_filename = "gnet.h")] public class UnixSocket { } - [CCode (ref_function = "gnet_conn_ref", unref_function = "gnet_conn_unref", cheader_filename = "gnet-2.0.h")] - public class netConn { - [CCode (cname = "gnet_conn_connect")] - public static void connect (GNet.Conn conn); - [CCode (cname = "gnet_conn_delete")] - public static void delete (GNet.Conn conn); - [CCode (cname = "gnet_conn_disconnect")] - public static void disconnect (GNet.Conn conn); - [CCode (cname = "gnet_conn_http_cancel")] - public static void http_cancel (GNet.ConnHttp conn); - [CCode (cname = "gnet_conn_http_delete")] - public static void http_delete (GNet.ConnHttp conn); - [CCode (cname = "gnet_conn_http_new")] - public static weak GNet.ConnHttp http_new (); - [CCode (cname = "gnet_conn_http_run")] - public static bool http_run (GNet.ConnHttp conn, GNet.ConnHttpFunc func, pointer user_data); - [CCode (cname = "gnet_conn_http_run_async")] - public static void http_run_async (GNet.ConnHttp conn, GNet.ConnHttpFunc func, pointer user_data); - [CCode (cname = "gnet_conn_http_set_header")] - public static bool http_set_header (GNet.ConnHttp conn, string field, string value, GNet.ConnHttpHeaderFlags flags); - [CCode (cname = "gnet_conn_http_set_max_redirects")] - public static void http_set_max_redirects (GNet.ConnHttp conn, uint num); - [CCode (cname = "gnet_conn_http_set_method")] - public static bool http_set_method (GNet.ConnHttp conn, GNet.ConnHttpMethod method, string post_data, ulong post_data_len); - [CCode (cname = "gnet_conn_http_set_timeout")] - public static void http_set_timeout (GNet.ConnHttp conn, uint timeout); - [CCode (cname = "gnet_conn_http_set_uri")] - public static bool http_set_uri (GNet.ConnHttp conn, string uri); - [CCode (cname = "gnet_conn_http_set_user_agent")] - public static bool http_set_user_agent (GNet.ConnHttp conn, string agent); - [CCode (cname = "gnet_conn_http_steal_buffer")] - public static bool http_steal_buffer (GNet.ConnHttp conn, string buffer, ulong length); - [CCode (cname = "gnet_conn_is_connected")] - public static bool is_connected (GNet.Conn conn); - [CCode (cname = "gnet_conn_new")] - public netConn (string hostname, int port, GNet.ConnFunc func, pointer user_data); - [CCode (cname = "gnet_conn_new_inetaddr")] - public netConn.from_inetaddr (GNet.InetAddr inetaddr, GNet.ConnFunc func, pointer user_data); - [CCode (cname = "gnet_conn_new_socket")] - public netConn.from_socket (GNet.TcpSocket socket, GNet.ConnFunc func, pointer user_data); - [CCode (cname = "gnet_conn_read")] - public static void read (GNet.Conn conn); - [CCode (cname = "gnet_conn_readline")] - public static void readline (GNet.Conn conn); - [CCode (cname = "gnet_conn_readn")] - public static void readn (GNet.Conn conn, int length); - [CCode (cname = "gnet_conn_set_callback")] - public static void set_callback (GNet.Conn conn, GNet.ConnFunc func, pointer user_data); - [CCode (cname = "gnet_conn_set_watch_error")] - public static void set_watch_error (GNet.Conn conn, bool enable); - [CCode (cname = "gnet_conn_set_watch_readable")] - public static void set_watch_readable (GNet.Conn conn, bool enable); - [CCode (cname = "gnet_conn_set_watch_writable")] - public static void set_watch_writable (GNet.Conn conn, bool enable); - [CCode (cname = "gnet_conn_timeout")] - public static void timeout (GNet.Conn conn, uint timeout); - [CCode (cname = "gnet_conn_write")] - public static void write (GNet.Conn conn, string buffer, int length); - } - [CCode (ref_function = "gnet_inetaddr_ref", unref_function = "gnet_inetaddr_unref", cheader_filename = "gnet-2.0.h")] - public class netInetaddr { - [CCode (cname = "gnet_inetaddr_autodetect_internet_interface")] - public static weak GNet.InetAddr autodetect_internet_interface (); - [CCode (cname = "gnet_inetaddr_clone")] - public static weak GNet.InetAddr clone (GNet.InetAddr inetaddr); - [CCode (cname = "gnet_inetaddr_delete")] - public static void delete (GNet.InetAddr inetaddr); - [CCode (cname = "gnet_inetaddr_delete_list")] - public static void delete_list (GLib.List list); - [CCode (cname = "gnet_inetaddr_equal")] - public static bool equal (pointer p1, pointer p2); - [CCode (cname = "gnet_inetaddr_get_bytes")] - public static void get_bytes (GNet.InetAddr inetaddr, string buffer); - [CCode (cname = "gnet_inetaddr_get_canonical_name")] - public static weak string get_canonical_name (GNet.InetAddr inetaddr); - [CCode (cname = "gnet_inetaddr_get_host_addr")] - public static weak GNet.InetAddr get_host_addr (); - [CCode (cname = "gnet_inetaddr_get_host_name")] - public static weak string get_host_name (); - [CCode (cname = "gnet_inetaddr_get_interface_to")] - public static weak GNet.InetAddr get_interface_to (GNet.InetAddr inetaddr); - [CCode (cname = "gnet_inetaddr_get_internet_interface")] - public static weak GNet.InetAddr get_internet_interface (); - [CCode (cname = "gnet_inetaddr_get_length")] - public static int get_length (GNet.InetAddr inetaddr); - [CCode (cname = "gnet_inetaddr_get_name")] - public static weak string get_name (GNet.InetAddr inetaddr); - [CCode (cname = "gnet_inetaddr_get_name_async")] - public static weak GNet.InetAddrGetNameAsyncID get_name_async (GNet.InetAddr inetaddr, GNet.InetAddrGetNameAsyncFunc func, pointer data); - [CCode (cname = "gnet_inetaddr_get_name_async_cancel")] - public static void get_name_async_cancel (GNet.InetAddrGetNameAsyncID id); - [CCode (cname = "gnet_inetaddr_get_name_nonblock")] - public static weak string get_name_nonblock (GNet.InetAddr inetaddr); - [CCode (cname = "gnet_inetaddr_get_port")] - public static int get_port (GNet.InetAddr inetaddr); - [CCode (cname = "gnet_inetaddr_hash")] - public static uint hash (pointer p); - [CCode (cname = "gnet_inetaddr_is_broadcast")] - public static bool is_broadcast (GNet.InetAddr inetaddr); - [CCode (cname = "gnet_inetaddr_is_canonical")] - public static bool is_canonical (string hostname); - [CCode (cname = "gnet_inetaddr_is_internet")] - public static bool is_internet (GNet.InetAddr inetaddr); - [CCode (cname = "gnet_inetaddr_is_internet_domainname")] - public static bool is_internet_domainname (string name); - [CCode (cname = "gnet_inetaddr_is_ipv4")] - public static bool is_ipv4 (GNet.InetAddr inetaddr); - [CCode (cname = "gnet_inetaddr_is_ipv6")] - public static bool is_ipv6 (GNet.InetAddr inetaddr); - [CCode (cname = "gnet_inetaddr_is_loopback")] - public static bool is_loopback (GNet.InetAddr inetaddr); - [CCode (cname = "gnet_inetaddr_is_multicast")] - public static bool is_multicast (GNet.InetAddr inetaddr); - [CCode (cname = "gnet_inetaddr_is_private")] - public static bool is_private (GNet.InetAddr inetaddr); - [CCode (cname = "gnet_inetaddr_is_reserved")] - public static bool is_reserved (GNet.InetAddr inetaddr); - [CCode (cname = "gnet_inetaddr_list_interfaces")] - public static weak GLib.List list_interfaces (); - [CCode (cname = "gnet_inetaddr_new")] - public netInetaddr (string hostname, int port); - [CCode (cname = "gnet_inetaddr_new_async")] - public netInetaddr.async (string hostname, int port, GNet.InetAddrNewAsyncFunc func, pointer data); - [CCode (cname = "gnet_inetaddr_new_async_cancel")] - public netInetaddr.async_cancel (GNet.InetAddrNewAsyncID id); - [CCode (cname = "gnet_inetaddr_new_bytes")] - public netInetaddr.bytes (string bytes, uint length); - [CCode (cname = "gnet_inetaddr_new_list")] - public netInetaddr.list (string hostname, int port); - [CCode (cname = "gnet_inetaddr_new_list_async")] - public netInetaddr.list_async (string hostname, int port, GNet.InetAddrNewListAsyncFunc func, pointer data); - [CCode (cname = "gnet_inetaddr_new_list_async_cancel")] - public netInetaddr.list_async_cancel (GNet.InetAddrNewListAsyncID id); - [CCode (cname = "gnet_inetaddr_new_nonblock")] - public netInetaddr.nonblock (string hostname, int port); - [CCode (cname = "gnet_inetaddr_noport_equal")] - public static bool noport_equal (pointer p1, pointer p2); - [CCode (cname = "gnet_inetaddr_set_bytes")] - public static void set_bytes (GNet.InetAddr inetaddr, string bytes, int length); - [CCode (cname = "gnet_inetaddr_set_port")] - public static void set_port (GNet.InetAddr inetaddr, int port); - } - [CCode (cheader_filename = "gnet-2.0.h")] - public class netIo { - [CCode (cname = "gnet_io_channel_readline")] - public static GNet.IOError channel_readline (GLib.IOChannel channel, string buffer, ulong length, ulong bytes_readp); - [CCode (cname = "gnet_io_channel_readline_strdup")] - public static GNet.IOError channel_readline_strdup (GLib.IOChannel channel, string bufferp, ulong bytes_readp); - [CCode (cname = "gnet_io_channel_readn")] - public static GNet.IOError channel_readn (GLib.IOChannel channel, pointer buffer, ulong length, ulong bytes_readp); - [CCode (cname = "gnet_io_channel_writen")] - public static GNet.IOError channel_writen (GLib.IOChannel channel, pointer buffer, ulong length, ulong bytes_writtenp); - } - [CCode (cheader_filename = "gnet-2.0.h")] - public class netMcast { - [CCode (cname = "gnet_mcast_socket_delete")] - public static void socket_delete (GNet.McastSocket socket); - [CCode (cname = "gnet_mcast_socket_get_io_channel")] - public static weak GLib.IOChannel socket_get_io_channel (GNet.McastSocket socket); - [CCode (cname = "gnet_mcast_socket_get_local_inetaddr")] - public static weak GNet.InetAddr socket_get_local_inetaddr (GNet.McastSocket socket); - [CCode (cname = "gnet_mcast_socket_get_ttl")] - public static int socket_get_ttl (GNet.McastSocket socket); - [CCode (cname = "gnet_mcast_socket_has_packet")] - public static bool socket_has_packet (GNet.McastSocket socket); - [CCode (cname = "gnet_mcast_socket_is_loopback")] - public static int socket_is_loopback (GNet.McastSocket socket); - [CCode (cname = "gnet_mcast_socket_join_group")] - public static int socket_join_group (GNet.McastSocket socket, GNet.InetAddr inetaddr); - [CCode (cname = "gnet_mcast_socket_leave_group")] - public static int socket_leave_group (GNet.McastSocket socket, GNet.InetAddr inetaddr); - [CCode (cname = "gnet_mcast_socket_new")] - public static weak GNet.McastSocket socket_new (); - [CCode (cname = "gnet_mcast_socket_new_full")] - public static weak GNet.McastSocket socket_new_full (GNet.InetAddr iface, int port); - [CCode (cname = "gnet_mcast_socket_new_with_port")] - public static weak GNet.McastSocket socket_new_with_port (int port); - [CCode (cname = "gnet_mcast_socket_receive")] - public static int socket_receive (GNet.McastSocket socket, string buffer, int length, GNet.InetAddr src); - [CCode (cname = "gnet_mcast_socket_ref")] - public static void socket_ref (GNet.McastSocket socket); - [CCode (cname = "gnet_mcast_socket_send")] - public static int socket_send (GNet.McastSocket socket, string buffer, int length, GNet.InetAddr dst); - [CCode (cname = "gnet_mcast_socket_set_loopback")] - public static int socket_set_loopback (GNet.McastSocket socket, bool enable); - [CCode (cname = "gnet_mcast_socket_set_ttl")] - public static int socket_set_ttl (GNet.McastSocket socket, int ttl); - [CCode (cname = "gnet_mcast_socket_unref")] - public static void socket_unref (GNet.McastSocket socket); - } - [CCode (ref_function = "gnet_server_ref", unref_function = "gnet_server_unref", cheader_filename = "gnet-2.0.h")] - public class netServer { - [CCode (cname = "gnet_server_delete")] - public static void delete (GNet.Server server); - [CCode (cname = "gnet_server_new")] - public netServer (GNet.InetAddr iface, int port, GNet.ServerFunc func, pointer user_data); - } - [CCode (cheader_filename = "gnet-2.0.h")] - public class netSha { - [CCode (cname = "gnet_sha_clone")] - public static weak GNet.SHA clone (GNet.SHA sha); - [CCode (cname = "gnet_sha_copy_string")] - public static void copy_string (GNet.SHA sha, string buffer); - [CCode (cname = "gnet_sha_delete")] - public static void delete (GNet.SHA sha); - [CCode (cname = "gnet_sha_equal")] - public static bool equal (pointer p1, pointer p2); - [CCode (cname = "gnet_sha_final")] - public static void final (GNet.SHA sha); - [CCode (cname = "gnet_sha_get_digest")] - public static weak string get_digest (GNet.SHA sha); - [CCode (cname = "gnet_sha_get_string")] - public static weak string get_string (GNet.SHA sha); - [CCode (cname = "gnet_sha_hash")] - public static uint hash (pointer p); - [CCode (cname = "gnet_sha_new")] - public netSha (string buffer, uint length); - [CCode (cname = "gnet_sha_new_incremental")] - public netSha.incremental (); - [CCode (cname = "gnet_sha_new_string")] - public netSha.string (string str); - [CCode (cname = "gnet_sha_update")] - public static void update (GNet.SHA sha, string buffer, uint length); - } - [CCode (cheader_filename = "gnet-2.0.h")] - public class netSocks { - [CCode (cname = "gnet_socks_get_enabled")] - public static bool get_enabled (); - [CCode (cname = "gnet_socks_get_server")] - public static weak GNet.InetAddr get_server (); - [CCode (cname = "gnet_socks_get_version")] - public static int get_version (); - [CCode (cname = "gnet_socks_set_enabled")] - public static void set_enabled (bool enabled); - [CCode (cname = "gnet_socks_set_server")] - public static void set_server (GNet.InetAddr inetaddr); - [CCode (cname = "gnet_socks_set_version")] - public static void set_version (int version); - } - [CCode (cheader_filename = "gnet-2.0.h")] - public class netTcp { - [CCode (cname = "gnet_tcp_socket_connect")] - public static weak GNet.TcpSocket socket_connect (string hostname, int port); - [CCode (cname = "gnet_tcp_socket_connect_async")] - public static weak GNet.TcpSocketConnectAsyncID socket_connect_async (string hostname, int port, GNet.TcpSocketConnectAsyncFunc func, pointer data); - [CCode (cname = "gnet_tcp_socket_connect_async_cancel")] - public static void socket_connect_async_cancel (GNet.TcpSocketConnectAsyncID id); - [CCode (cname = "gnet_tcp_socket_delete")] - public static void socket_delete (GNet.TcpSocket socket); - [CCode (cname = "gnet_tcp_socket_get_io_channel")] - public static weak GLib.IOChannel socket_get_io_channel (GNet.TcpSocket socket); - [CCode (cname = "gnet_tcp_socket_get_local_inetaddr")] - public static weak GNet.InetAddr socket_get_local_inetaddr (GNet.TcpSocket socket); - [CCode (cname = "gnet_tcp_socket_get_port")] - public static int socket_get_port (GNet.TcpSocket socket); - [CCode (cname = "gnet_tcp_socket_get_remote_inetaddr")] - public static weak GNet.InetAddr socket_get_remote_inetaddr (GNet.TcpSocket socket); - [CCode (cname = "gnet_tcp_socket_new")] - public static weak GNet.TcpSocket socket_new (GNet.InetAddr addr); - [CCode (cname = "gnet_tcp_socket_new_async")] - public static weak GNet.TcpSocketNewAsyncID socket_new_async (GNet.InetAddr addr, GNet.TcpSocketNewAsyncFunc func, pointer data); - [CCode (cname = "gnet_tcp_socket_new_async_cancel")] - public static void socket_new_async_cancel (GNet.TcpSocketNewAsyncID id); - [CCode (cname = "gnet_tcp_socket_new_async_direct")] - public static weak GNet.TcpSocketNewAsyncID socket_new_async_direct (GNet.InetAddr addr, GNet.TcpSocketNewAsyncFunc func, pointer data); - [CCode (cname = "gnet_tcp_socket_new_direct")] - public static weak GNet.TcpSocket socket_new_direct (GNet.InetAddr addr); - [CCode (cname = "gnet_tcp_socket_ref")] - public static void socket_ref (GNet.TcpSocket socket); - [CCode (cname = "gnet_tcp_socket_server_accept")] - public static weak GNet.TcpSocket socket_server_accept (GNet.TcpSocket socket); - [CCode (cname = "gnet_tcp_socket_server_accept_async")] - public static void socket_server_accept_async (GNet.TcpSocket socket, GNet.TcpSocketAcceptFunc accept_func, pointer user_data); - [CCode (cname = "gnet_tcp_socket_server_accept_async_cancel")] - public static void socket_server_accept_async_cancel (GNet.TcpSocket socket); - [CCode (cname = "gnet_tcp_socket_server_accept_nonblock")] - public static weak GNet.TcpSocket socket_server_accept_nonblock (GNet.TcpSocket socket); - [CCode (cname = "gnet_tcp_socket_server_new")] - public static weak GNet.TcpSocket socket_server_new (); - [CCode (cname = "gnet_tcp_socket_server_new_full")] - public static weak GNet.TcpSocket socket_server_new_full (GNet.InetAddr iface, int port); - [CCode (cname = "gnet_tcp_socket_server_new_with_port")] - public static weak GNet.TcpSocket socket_server_new_with_port (int port); - [CCode (cname = "gnet_tcp_socket_set_tos")] - public static void socket_set_tos (GNet.TcpSocket socket, GNet.NetTOS tos); - [CCode (cname = "gnet_tcp_socket_unref")] - public static void socket_unref (GNet.TcpSocket socket); - } - [CCode (cheader_filename = "gnet-2.0.h")] - public class netUdp { - [CCode (cname = "gnet_udp_socket_delete")] - public static void socket_delete (GNet.UdpSocket socket); - [CCode (cname = "gnet_udp_socket_get_io_channel")] - public static weak GLib.IOChannel socket_get_io_channel (GNet.UdpSocket socket); - [CCode (cname = "gnet_udp_socket_get_local_inetaddr")] - public static weak GNet.InetAddr socket_get_local_inetaddr (GNet.UdpSocket socket); - [CCode (cname = "gnet_udp_socket_get_ttl")] - public static int socket_get_ttl (GNet.UdpSocket socket); - [CCode (cname = "gnet_udp_socket_has_packet")] - public static bool socket_has_packet (GNet.UdpSocket socket); - [CCode (cname = "gnet_udp_socket_new")] - public static weak GNet.UdpSocket socket_new (); - [CCode (cname = "gnet_udp_socket_new_full")] - public static weak GNet.UdpSocket socket_new_full (GNet.InetAddr iface, int port); - [CCode (cname = "gnet_udp_socket_new_with_port")] - public static weak GNet.UdpSocket socket_new_with_port (int port); - [CCode (cname = "gnet_udp_socket_receive")] - public static int socket_receive (GNet.UdpSocket socket, string buffer, int length, GNet.InetAddr src); - [CCode (cname = "gnet_udp_socket_ref")] - public static void socket_ref (GNet.UdpSocket socket); - [CCode (cname = "gnet_udp_socket_send")] - public static int socket_send (GNet.UdpSocket socket, string buffer, int length, GNet.InetAddr dst); - [CCode (cname = "gnet_udp_socket_set_ttl")] - public static int socket_set_ttl (GNet.UdpSocket socket, int ttl); - [CCode (cname = "gnet_udp_socket_unref")] - public static void socket_unref (GNet.UdpSocket socket); - } - [CCode (cheader_filename = "gnet-2.0.h")] - public class netUnix { - [CCode (cname = "gnet_unix_socket_delete")] - public static void socket_delete (GNet.UnixSocket socket); - [CCode (cname = "gnet_unix_socket_get_io_channel")] - public static weak GLib.IOChannel socket_get_io_channel (GNet.UnixSocket socket); - [CCode (cname = "gnet_unix_socket_get_path")] - public static weak string socket_get_path (GNet.UnixSocket socket); - [CCode (cname = "gnet_unix_socket_new")] - public static weak GNet.UnixSocket socket_new (string path); - [CCode (cname = "gnet_unix_socket_ref")] - public static void socket_ref (GNet.UnixSocket socket); - [CCode (cname = "gnet_unix_socket_server_accept")] - public static weak GNet.UnixSocket socket_server_accept (GNet.UnixSocket socket); - [CCode (cname = "gnet_unix_socket_server_accept_nonblock")] - public static weak GNet.UnixSocket socket_server_accept_nonblock (GNet.UnixSocket socket); - [CCode (cname = "gnet_unix_socket_server_new")] - public static weak GNet.UnixSocket socket_server_new (string path); - [CCode (cname = "gnet_unix_socket_unref")] - public static void socket_unref (GNet.UnixSocket socket); - } - [CCode (cheader_filename = "gnet-2.0.h")] - public class netUri { - [CCode (cname = "gnet_uri_clone")] - public static weak GNet.URI clone (GNet.URI uri); - [CCode (cname = "gnet_uri_delete")] - public static void delete (GNet.URI uri); - [CCode (cname = "gnet_uri_equal")] - public static bool equal (pointer p1, pointer p2); - [CCode (cname = "gnet_uri_escape")] - public static void escape (GNet.URI uri); - [CCode (cname = "gnet_uri_get_string")] - public static weak string get_string (GNet.URI uri); - [CCode (cname = "gnet_uri_hash")] - public static uint hash (pointer p); - [CCode (cname = "gnet_uri_new")] - public netUri (string uri); - [CCode (cname = "gnet_uri_new_fields")] - public netUri.fields (string scheme, string hostname, int port, string path); - [CCode (cname = "gnet_uri_new_fields_all")] - public netUri.fields_all (string scheme, string userinfo, string hostname, int port, string path, string query, string fragment); - [CCode (cname = "gnet_uri_set_fragment")] - public static void set_fragment (GNet.URI uri, string fragment); - [CCode (cname = "gnet_uri_set_hostname")] - public static void set_hostname (GNet.URI uri, string hostname); - [CCode (cname = "gnet_uri_set_path")] - public static void set_path (GNet.URI uri, string path); - [CCode (cname = "gnet_uri_set_port")] - public static void set_port (GNet.URI uri, int port); - [CCode (cname = "gnet_uri_set_query")] - public static void set_query (GNet.URI uri, string query); - [CCode (cname = "gnet_uri_set_scheme")] - public static void set_scheme (GNet.URI uri, string scheme); - [CCode (cname = "gnet_uri_set_userinfo")] - public static void set_userinfo (GNet.URI uri, string userinfo); - [CCode (cname = "gnet_uri_unescape")] - public static void unescape (GNet.URI uri); + [CCode (cheader_filename = "gnet.h")] + public struct NetTOS { } public static delegate void ConnFunc (GNet.Conn conn, GNet.ConnEvent event, pointer user_data); public static delegate void ConnHttpFunc (GNet.ConnHttp conn, GNet.ConnHttpEvent event, pointer user_data); @@ -577,6 +223,427 @@ namespace GNet { public static delegate void TcpSocketAcceptFunc (GNet.TcpSocket server, GNet.TcpSocket client, pointer data); public static delegate void TcpSocketConnectAsyncFunc (GNet.TcpSocket socket, GNet.TcpSocketConnectAsyncStatus status, pointer data); public static delegate void TcpSocketNewAsyncFunc (GNet.TcpSocket socket, pointer data); + public const int INETADDR_MAX_LEN; + public const int MD5_HASH_LENGTH; + public const int SHA_HASH_LENGTH; + public const int SOCKS_PORT; + public const int SOCKS_VERSION; + [CCode (cheader_filename = "gnet.h")] + public static weak string base64_decode (string src, int srclen, int dstlenp); + [CCode (cheader_filename = "gnet.h")] + public static weak string base64_encode (string src, int srclen, int dstlenp, bool strict); + [CCode (cheader_filename = "gnet.h")] + public static int calcsize (string format); + [CCode (cheader_filename = "gnet.h")] + public static void conn_connect (GNet.Conn conn); + [CCode (cheader_filename = "gnet.h")] + public static void conn_delete (GNet.Conn conn); + [CCode (cheader_filename = "gnet.h")] + public static void conn_disconnect (GNet.Conn conn); + [CCode (cheader_filename = "gnet.h")] + public static void conn_http_cancel (GNet.ConnHttp conn); + [CCode (cheader_filename = "gnet.h")] + public static void conn_http_delete (GNet.ConnHttp conn); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.ConnHttp conn_http_new (); + [CCode (cheader_filename = "gnet.h")] + public static bool conn_http_run (GNet.ConnHttp conn, GNet.ConnHttpFunc func, pointer user_data); + [CCode (cheader_filename = "gnet.h")] + public static void conn_http_run_async (GNet.ConnHttp conn, GNet.ConnHttpFunc func, pointer user_data); + [CCode (cheader_filename = "gnet.h")] + public static bool conn_http_set_escaped_uri (GNet.ConnHttp conn, string uri); + [CCode (cheader_filename = "gnet.h")] + public static bool conn_http_set_header (GNet.ConnHttp conn, string field, string value, GNet.ConnHttpHeaderFlags flags); + [CCode (cheader_filename = "gnet.h")] + public static bool conn_http_set_main_context (GNet.ConnHttp conn, GLib.MainContext context); + [CCode (cheader_filename = "gnet.h")] + public static void conn_http_set_max_redirects (GNet.ConnHttp conn, uint num); + [CCode (cheader_filename = "gnet.h")] + public static bool conn_http_set_method (GNet.ConnHttp conn, GNet.ConnHttpMethod method, string post_data, ulong post_data_len); + [CCode (cheader_filename = "gnet.h")] + public static void conn_http_set_timeout (GNet.ConnHttp conn, uint timeout); + [CCode (cheader_filename = "gnet.h")] + public static bool conn_http_set_uri (GNet.ConnHttp conn, string uri); + [CCode (cheader_filename = "gnet.h")] + public static bool conn_http_set_user_agent (GNet.ConnHttp conn, string agent); + [CCode (cheader_filename = "gnet.h")] + public static bool conn_http_steal_buffer (GNet.ConnHttp conn, string buffer, ulong length); + [CCode (cheader_filename = "gnet.h")] + public static bool conn_is_connected (GNet.Conn conn); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.Conn conn_new (string hostname, int port, GNet.ConnFunc func, pointer user_data); + [CCode (cname = "gnet_conn_new_inetaddr", cheader_filename = "gnet.h")] + public static weak GNet.Conn from_inetaddr (GNet.InetAddr inetaddr, GNet.ConnFunc func, pointer user_data); + [CCode (cname = "gnet_conn_new_socket", cheader_filename = "gnet.h")] + public static weak GNet.Conn from_socket (GNet.TcpSocket socket, GNet.ConnFunc func, pointer user_data); + [CCode (cheader_filename = "gnet.h")] + public static void conn_read (GNet.Conn conn); + [CCode (cheader_filename = "gnet.h")] + public static void conn_readline (GNet.Conn conn); + [CCode (cheader_filename = "gnet.h")] + public static void conn_readn (GNet.Conn conn, int length); + [CCode (cheader_filename = "gnet.h")] + public static void conn_ref (GNet.Conn conn); + [CCode (cheader_filename = "gnet.h")] + public static void conn_set_callback (GNet.Conn conn, GNet.ConnFunc func, pointer user_data); + [CCode (cheader_filename = "gnet.h")] + public static bool conn_set_main_context (GNet.Conn conn, GLib.MainContext context); + [CCode (cheader_filename = "gnet.h")] + public static void conn_set_watch_error (GNet.Conn conn, bool enable); + [CCode (cheader_filename = "gnet.h")] + public static void conn_set_watch_readable (GNet.Conn conn, bool enable); + [CCode (cheader_filename = "gnet.h")] + public static void conn_set_watch_writable (GNet.Conn conn, bool enable); + [CCode (cheader_filename = "gnet.h")] + public static void conn_timeout (GNet.Conn conn, uint timeout); + [CCode (cheader_filename = "gnet.h")] + public static void conn_unref (GNet.Conn conn); + [CCode (cheader_filename = "gnet.h")] + public static void conn_write (GNet.Conn conn, string buffer, int length); + [CCode (cheader_filename = "gnet.h")] + public static void conn_write_direct (GNet.Conn conn, string buffer, int length, GLib.DestroyNotify buffer_destroy_cb); + [CCode (cheader_filename = "gnet.h")] public static bool http_get (string url, string buffer, ulong length, uint response); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.InetAddr inetaddr_autodetect_internet_interface (); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.InetAddr inetaddr_clone (GNet.InetAddr inetaddr); + [CCode (cheader_filename = "gnet.h")] + public static void inetaddr_delete (GNet.InetAddr inetaddr); + [CCode (cheader_filename = "gnet.h")] + public static void inetaddr_delete_list (GLib.List list); + [CCode (cheader_filename = "gnet.h")] + public static bool inetaddr_equal (pointer p1, pointer p2); + [CCode (cheader_filename = "gnet.h")] + public static void inetaddr_get_bytes (GNet.InetAddr inetaddr, string buffer); + [CCode (cheader_filename = "gnet.h")] + public static weak string inetaddr_get_canonical_name (GNet.InetAddr inetaddr); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.InetAddr inetaddr_get_host_addr (); + [CCode (cheader_filename = "gnet.h")] + public static weak string inetaddr_get_host_name (); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.InetAddr inetaddr_get_interface_to (GNet.InetAddr inetaddr); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.InetAddr inetaddr_get_internet_interface (); + [CCode (cheader_filename = "gnet.h")] + public static int inetaddr_get_length (GNet.InetAddr inetaddr); + [CCode (cheader_filename = "gnet.h")] + public static weak string inetaddr_get_name (GNet.InetAddr inetaddr); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.InetAddrGetNameAsyncID inetaddr_get_name_async (GNet.InetAddr inetaddr, GNet.InetAddrGetNameAsyncFunc func, pointer data); + [CCode (cheader_filename = "gnet.h")] + public static void inetaddr_get_name_async_cancel (GNet.InetAddrGetNameAsyncID id); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.InetAddrGetNameAsyncID inetaddr_get_name_async_full (GNet.InetAddr inetaddr, GNet.InetAddrGetNameAsyncFunc func, pointer data, GLib.DestroyNotify notify, GLib.MainContext context, int priority); + [CCode (cheader_filename = "gnet.h")] + public static weak string inetaddr_get_name_nonblock (GNet.InetAddr inetaddr); + [CCode (cheader_filename = "gnet.h")] + public static int inetaddr_get_port (GNet.InetAddr inetaddr); + [CCode (cheader_filename = "gnet.h")] + public static uint inetaddr_hash (pointer p); + [CCode (cheader_filename = "gnet.h")] + public static bool inetaddr_is_broadcast (GNet.InetAddr inetaddr); + [CCode (cheader_filename = "gnet.h")] + public static bool inetaddr_is_canonical (string hostname); + [CCode (cheader_filename = "gnet.h")] + public static bool inetaddr_is_internet (GNet.InetAddr inetaddr); + [CCode (cheader_filename = "gnet.h")] + public static bool inetaddr_is_internet_domainname (string name); + [CCode (cheader_filename = "gnet.h")] + public static bool inetaddr_is_ipv4 (GNet.InetAddr inetaddr); + [CCode (cheader_filename = "gnet.h")] + public static bool inetaddr_is_ipv6 (GNet.InetAddr inetaddr); + [CCode (cheader_filename = "gnet.h")] + public static bool inetaddr_is_loopback (GNet.InetAddr inetaddr); + [CCode (cheader_filename = "gnet.h")] + public static bool inetaddr_is_multicast (GNet.InetAddr inetaddr); + [CCode (cheader_filename = "gnet.h")] + public static bool inetaddr_is_private (GNet.InetAddr inetaddr); + [CCode (cheader_filename = "gnet.h")] + public static bool inetaddr_is_reserved (GNet.InetAddr inetaddr); + [CCode (cheader_filename = "gnet.h")] + public static weak GLib.List inetaddr_list_interfaces (); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.InetAddr inetaddr_new (string hostname, int port); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.InetAddrNewAsyncID inetaddr_new_async (string hostname, int port, GNet.InetAddrNewAsyncFunc func, pointer data); + [CCode (cheader_filename = "gnet.h")] + public static void inetaddr_new_async_cancel (GNet.InetAddrNewAsyncID id); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.InetAddrNewAsyncID inetaddr_new_async_full (string hostname, int port, GNet.InetAddrNewAsyncFunc func, pointer data, GLib.DestroyNotify notify, GLib.MainContext context, int priority); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.InetAddr inetaddr_new_bytes (string bytes, uint length); + [CCode (cheader_filename = "gnet.h")] + public static weak GLib.List inetaddr_new_list (string hostname, int port); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.InetAddrNewListAsyncID inetaddr_new_list_async (string hostname, int port, GNet.InetAddrNewListAsyncFunc func, pointer data); + [CCode (cheader_filename = "gnet.h")] + public static void inetaddr_new_list_async_cancel (GNet.InetAddrNewListAsyncID id); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.InetAddrNewListAsyncID inetaddr_new_list_async_full (string hostname, int port, GNet.InetAddrNewListAsyncFunc func, pointer data, GLib.DestroyNotify notify, GLib.MainContext context, int priority); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.InetAddr inetaddr_new_nonblock (string hostname, int port); + [CCode (cheader_filename = "gnet.h")] + public static bool inetaddr_noport_equal (pointer p1, pointer p2); + [CCode (cheader_filename = "gnet.h")] + public static void inetaddr_ref (GNet.InetAddr inetaddr); + [CCode (cheader_filename = "gnet.h")] + public static void inetaddr_set_bytes (GNet.InetAddr inetaddr, string bytes, int length); + [CCode (cheader_filename = "gnet.h")] + public static void inetaddr_set_port (GNet.InetAddr inetaddr, int port); + [CCode (cheader_filename = "gnet.h")] + public static void inetaddr_unref (GNet.InetAddr inetaddr); + [CCode (cheader_filename = "gnet.h")] + public static void init (); + [CCode (cheader_filename = "gnet.h")] + public static GNet.IOError io_channel_readline (GLib.IOChannel channel, string buffer, ulong length, ulong bytes_readp); + [CCode (cheader_filename = "gnet.h")] + public static GNet.IOError io_channel_readline_strdup (GLib.IOChannel channel, string bufferp, ulong bytes_readp); + [CCode (cheader_filename = "gnet.h")] + public static GNet.IOError io_channel_readn (GLib.IOChannel channel, pointer buffer, ulong length, ulong bytes_readp); + [CCode (cheader_filename = "gnet.h")] + public static GNet.IOError io_channel_writen (GLib.IOChannel channel, pointer buffer, ulong length, ulong bytes_writtenp); + [CCode (cheader_filename = "gnet.h")] + public static GNet.IPv6Policy ipv6_get_policy (); + [CCode (cheader_filename = "gnet.h")] + public static void ipv6_set_policy (GNet.IPv6Policy policy); + [CCode (cheader_filename = "gnet.h")] + public static void mcast_socket_delete (GNet.McastSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static weak GLib.IOChannel mcast_socket_get_io_channel (GNet.McastSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.InetAddr mcast_socket_get_local_inetaddr (GNet.McastSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static int mcast_socket_get_ttl (GNet.McastSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static bool mcast_socket_has_packet (GNet.McastSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static int mcast_socket_is_loopback (GNet.McastSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static int mcast_socket_join_group (GNet.McastSocket socket, GNet.InetAddr inetaddr); + [CCode (cheader_filename = "gnet.h")] + public static int mcast_socket_leave_group (GNet.McastSocket socket, GNet.InetAddr inetaddr); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.McastSocket mcast_socket_new (); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.McastSocket mcast_socket_new_full (GNet.InetAddr iface, int port); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.McastSocket mcast_socket_new_with_port (int port); + [CCode (cheader_filename = "gnet.h")] + public static int mcast_socket_receive (GNet.McastSocket socket, string buffer, int length, out weak GNet.InetAddr src); + [CCode (cheader_filename = "gnet.h")] + public static void mcast_socket_ref (GNet.McastSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static int mcast_socket_send (GNet.McastSocket socket, string buffer, int length, GNet.InetAddr dst); + [CCode (cheader_filename = "gnet.h")] + public static int mcast_socket_set_loopback (GNet.McastSocket socket, bool enable); + [CCode (cheader_filename = "gnet.h")] + public static int mcast_socket_set_ttl (GNet.McastSocket socket, int ttl); + [CCode (cheader_filename = "gnet.h")] + public static void mcast_socket_unref (GNet.McastSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.MD5 md5_clone (GNet.MD5 md5); + [CCode (cheader_filename = "gnet.h")] + public static void md5_copy_string (GNet.MD5 md5, string buffer); + [CCode (cheader_filename = "gnet.h")] + public static void md5_delete (GNet.MD5 md5); + [CCode (cheader_filename = "gnet.h")] + public static bool md5_equal (pointer p1, pointer p2); + [CCode (cheader_filename = "gnet.h")] + public static void md5_final (GNet.MD5 md5); + [CCode (cheader_filename = "gnet.h")] + public static weak string md5_get_digest (GNet.MD5 md5); + [CCode (cheader_filename = "gnet.h")] + public static weak string md5_get_string (GNet.MD5 md5); + [CCode (cheader_filename = "gnet.h")] + public static uint md5_hash (pointer p); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.MD5 md5_new (string buffer, uint length); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.MD5 md5_new_incremental (); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.MD5 md5_new_string (string str); + [CCode (cheader_filename = "gnet.h")] + public static void md5_update (GNet.MD5 md5, string buffer, uint length); + [CCode (cheader_filename = "gnet.h")] + public static int pack (string format, string buffer, int length); + [CCode (cheader_filename = "gnet.h")] public static int pack_strdup (string format, string bufferp); + [CCode (cheader_filename = "gnet.h")] + public static void server_delete (GNet.Server server); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.Server server_new (GNet.InetAddr iface, int port, GNet.ServerFunc func, pointer user_data); + [CCode (cheader_filename = "gnet.h")] + public static void server_ref (GNet.Server server); + [CCode (cheader_filename = "gnet.h")] + public static void server_unref (GNet.Server server); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.SHA sha_clone (GNet.SHA sha); + [CCode (cheader_filename = "gnet.h")] + public static void sha_copy_string (GNet.SHA sha, string buffer); + [CCode (cheader_filename = "gnet.h")] + public static void sha_delete (GNet.SHA sha); + [CCode (cheader_filename = "gnet.h")] + public static bool sha_equal (pointer p1, pointer p2); + [CCode (cheader_filename = "gnet.h")] + public static void sha_final (GNet.SHA sha); + [CCode (cheader_filename = "gnet.h")] + public static weak string sha_get_digest (GNet.SHA sha); + [CCode (cheader_filename = "gnet.h")] + public static weak string sha_get_string (GNet.SHA sha); + [CCode (cheader_filename = "gnet.h")] + public static uint sha_hash (pointer p); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.SHA sha_new (string buffer, uint length); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.SHA sha_new_incremental (); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.SHA sha_new_string (string str); + [CCode (cheader_filename = "gnet.h")] + public static void sha_update (GNet.SHA sha, string buffer, uint length); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.TcpSocket tcp_socket_connect (string hostname, int port); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.TcpSocketConnectAsyncID tcp_socket_connect_async (string hostname, int port, GNet.TcpSocketConnectAsyncFunc func, pointer data); + [CCode (cheader_filename = "gnet.h")] + public static void tcp_socket_connect_async_cancel (GNet.TcpSocketConnectAsyncID id); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.TcpSocketConnectAsyncID tcp_socket_connect_async_full (string hostname, int port, GNet.TcpSocketConnectAsyncFunc func, pointer data, GLib.DestroyNotify notify, GLib.MainContext context, int priority); + [CCode (cheader_filename = "gnet.h")] + public static void tcp_socket_delete (GNet.TcpSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static weak GLib.IOChannel tcp_socket_get_io_channel (GNet.TcpSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.InetAddr tcp_socket_get_local_inetaddr (GNet.TcpSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static int tcp_socket_get_port (GNet.TcpSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.InetAddr tcp_socket_get_remote_inetaddr (GNet.TcpSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.TcpSocket tcp_socket_new (GNet.InetAddr addr); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.TcpSocketNewAsyncID tcp_socket_new_async (GNet.InetAddr addr, GNet.TcpSocketNewAsyncFunc func, pointer data); + [CCode (cheader_filename = "gnet.h")] + public static void tcp_socket_new_async_cancel (GNet.TcpSocketNewAsyncID id); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.TcpSocketNewAsyncID tcp_socket_new_async_direct (GNet.InetAddr addr, GNet.TcpSocketNewAsyncFunc func, pointer data); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.TcpSocketNewAsyncID tcp_socket_new_async_direct_full (GNet.InetAddr addr, GNet.TcpSocketNewAsyncFunc func, pointer data, GLib.DestroyNotify notify, GLib.MainContext context, int priority); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.TcpSocketNewAsyncID tcp_socket_new_async_full (GNet.InetAddr addr, GNet.TcpSocketNewAsyncFunc func, pointer data, GLib.DestroyNotify notify, GLib.MainContext context, int priority); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.TcpSocket tcp_socket_new_direct (GNet.InetAddr addr); + [CCode (cheader_filename = "gnet.h")] + public static void tcp_socket_ref (GNet.TcpSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.TcpSocket tcp_socket_server_accept (GNet.TcpSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static void tcp_socket_server_accept_async (GNet.TcpSocket socket, GNet.TcpSocketAcceptFunc accept_func, pointer user_data); + [CCode (cheader_filename = "gnet.h")] + public static void tcp_socket_server_accept_async_cancel (GNet.TcpSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.TcpSocket tcp_socket_server_accept_nonblock (GNet.TcpSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.TcpSocket tcp_socket_server_new (); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.TcpSocket tcp_socket_server_new_full (GNet.InetAddr iface, int port); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.TcpSocket tcp_socket_server_new_with_port (int port); + [CCode (cheader_filename = "gnet.h")] + public static void tcp_socket_set_tos (GNet.TcpSocket socket, GNet.NetTOS tos); + [CCode (cheader_filename = "gnet.h")] + public static void tcp_socket_unref (GNet.TcpSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static void udp_socket_delete (GNet.UdpSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static weak GLib.IOChannel udp_socket_get_io_channel (GNet.UdpSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.InetAddr udp_socket_get_local_inetaddr (GNet.UdpSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static int udp_socket_get_ttl (GNet.UdpSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static bool udp_socket_has_packet (GNet.UdpSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.UdpSocket udp_socket_new (); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.UdpSocket udp_socket_new_full (GNet.InetAddr iface, int port); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.UdpSocket udp_socket_new_with_port (int port); + [CCode (cheader_filename = "gnet.h")] + public static int udp_socket_receive (GNet.UdpSocket socket, string buffer, int length, out weak GNet.InetAddr src); + [CCode (cheader_filename = "gnet.h")] + public static void udp_socket_ref (GNet.UdpSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static int udp_socket_send (GNet.UdpSocket socket, string buffer, int length, GNet.InetAddr dst); + [CCode (cheader_filename = "gnet.h")] + public static int udp_socket_set_ttl (GNet.UdpSocket socket, int ttl); + [CCode (cheader_filename = "gnet.h")] + public static void udp_socket_unref (GNet.UdpSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static void unix_socket_delete (GNet.UnixSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static weak GLib.IOChannel unix_socket_get_io_channel (GNet.UnixSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static weak string unix_socket_get_path (GNet.UnixSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.UnixSocket unix_socket_new (string path); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.UnixSocket unix_socket_new_abstract (string path); + [CCode (cheader_filename = "gnet.h")] + public static void unix_socket_ref (GNet.UnixSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.UnixSocket unix_socket_server_accept (GNet.UnixSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.UnixSocket unix_socket_server_accept_nonblock (GNet.UnixSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.UnixSocket unix_socket_server_new (string path); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.UnixSocket unix_socket_server_new_abstract (string path); + [CCode (cheader_filename = "gnet.h")] + public static void unix_socket_unref (GNet.UnixSocket socket); + [CCode (cheader_filename = "gnet.h")] + public static int unpack (string format, string buffer, int length); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.URI uri_clone (GNet.URI uri); + [CCode (cheader_filename = "gnet.h")] + public static void uri_delete (GNet.URI uri); + [CCode (cheader_filename = "gnet.h")] + public static bool uri_equal (pointer p1, pointer p2); + [CCode (cheader_filename = "gnet.h")] + public static void uri_escape (GNet.URI uri); + [CCode (cheader_filename = "gnet.h")] + public static weak string uri_get_string (GNet.URI uri); + [CCode (cheader_filename = "gnet.h")] + public static uint uri_hash (pointer p); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.URI uri_new (string uri); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.URI uri_new_fields (string scheme, string hostname, int port, string path); + [CCode (cheader_filename = "gnet.h")] + public static weak GNet.URI uri_new_fields_all (string scheme, string userinfo, string hostname, int port, string path, string query, string fragment); + [CCode (cheader_filename = "gnet.h")] + public static bool uri_parse_inplace (GNet.URI guri, string uri, string hostname, ulong len); + [CCode (cheader_filename = "gnet.h")] + public static void uri_set_fragment (GNet.URI uri, string fragment); + [CCode (cheader_filename = "gnet.h")] + public static void uri_set_hostname (GNet.URI uri, string hostname); + [CCode (cheader_filename = "gnet.h")] + public static void uri_set_path (GNet.URI uri, string path); + [CCode (cheader_filename = "gnet.h")] + public static void uri_set_port (GNet.URI uri, int port); + [CCode (cheader_filename = "gnet.h")] + public static void uri_set_query (GNet.URI uri, string query); + [CCode (cheader_filename = "gnet.h")] + public static void uri_set_scheme (GNet.URI uri, string scheme); + [CCode (cheader_filename = "gnet.h")] + public static void uri_set_userinfo (GNet.URI uri, string userinfo); + [CCode (cheader_filename = "gnet.h")] + public static void uri_unescape (GNet.URI uri); + [CCode (cheader_filename = "gnet.h")] + public static int vcalcsize (string format, pointer args); + [CCode (cheader_filename = "gnet.h")] + public static int vpack (string format, string buffer, int length, pointer args); + [CCode (cheader_filename = "gnet.h")] + public static int vunpack (string format, string buffer, int length, pointer args); } diff --git a/vapi/packages/gnet-2.0/gnet-2.0-custom.vala b/vapi/packages/gnet-2.0/gnet-2.0-custom.vala index 6165b2b..7d03b92 100644 --- a/vapi/packages/gnet-2.0/gnet-2.0-custom.vala +++ b/vapi/packages/gnet-2.0/gnet-2.0-custom.vala @@ -1,11 +1,6 @@ [CCode (cprefix = "G")] namespace GNet { - public class NetTOS {} - public class InetAddrGetNameAsyncID {} - public class InetAddrNewAsyncID {} - public class InetAddrNewListAsyncID {} - public class TcpSocketConnectAsyncID {} - public class TcpSocketNewAsyncID {} + public struct NetTOS {} /* Deprecated glib API */ public enum IOError { diff --git a/vapi/packages/gnet-2.0/gnet-2.0.files b/vapi/packages/gnet-2.0/gnet-2.0.files index 8eba6c8..df2dcc8 100644 --- a/vapi/packages/gnet-2.0/gnet-2.0.files +++ b/vapi/packages/gnet-2.0/gnet-2.0.files @@ -1 +1,3 @@ -src/ +include/gnet-2.0/ +lib/libgnet-2.0.so + diff --git a/vapi/packages/gnet-2.0/gnet-2.0.gi b/vapi/packages/gnet-2.0/gnet-2.0.gi new file mode 100644 index 0000000..e7bb2f2 --- /dev/null +++ b/vapi/packages/gnet-2.0/gnet-2.0.gi @@ -0,0 +1,1642 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/vapi/packages/gnet-2.0/gnet-2.0.gidl b/vapi/packages/gnet-2.0/gnet-2.0.gidl deleted file mode 100644 index e0683c0..0000000 --- a/vapi/packages/gnet-2.0/gnet-2.0.gidl +++ /dev/null @@ -1,1401 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/vapi/packages/gnet-2.0/gnet-2.0.metadata b/vapi/packages/gnet-2.0/gnet-2.0.metadata index 170c1f9..627fccc 100644 --- a/vapi/packages/gnet-2.0/gnet-2.0.metadata +++ b/vapi/packages/gnet-2.0/gnet-2.0.metadata @@ -1,4 +1,4 @@ -GNet cprefix="Gnet,G" +GNet cprefix="Gnet,G" cheader_filename="gnet.h" gnet_conn_new_inetaddr name="from_inetaddr" gnet_conn_new_socket name="from_socket" -- 2.7.4