[gnio] Minor header cleanup
- From: Alexander Larsson <alexl src gnome org>
- To: svn-commits-list gnome org
- Subject: [gnio] Minor header cleanup
- Date: Tue, 28 Apr 2009 06:08:30 -0400 (EDT)
commit 218e26e6c21b53fafc643edeb12ca67a5a380814
Author: Alexander Larsson <alexl redhat com>
Date: Tue Apr 28 10:08:45 2009 +0200
Minor header cleanup
Move all typedefs to top of file.
Reformat function declarations to not be unnecessarily wide.
---
gio/gsocket.h | 178 +++++++++++++++++++++++++--------------------------------
1 files changed, 77 insertions(+), 101 deletions(-)
diff --git a/gio/gsocket.h b/gio/gsocket.h
index a9a7837..5e84f13 100644
--- a/gio/gsocket.h
+++ b/gio/gsocket.h
@@ -62,84 +62,6 @@ typedef enum
G_SOCKET_TYPE_SEQPACKET,
} GSocketType;
-GType g_socket_get_type (void);
-
-GSocket * g_socket_new (GSocketFamily family,
- GSocketType type);
-
-GSocket * g_socket_new_from_fd (gint fd);
-
-GSocketAddress * g_socket_get_local_address (GSocket *socket,
- GError **error);
-
-GSocketAddress * g_socket_get_remote_address (GSocket *socket,
- GError **error);
-
-void g_socket_set_blocking (GSocket *socket,
- gboolean blocking);
-
-gboolean g_socket_get_blocking (GSocket *socket);
-
-void g_socket_set_reuse_address (GSocket *socket,
- gboolean reuse);
-
-gboolean g_socket_get_reuse_address (GSocket *socket);
-
-gboolean g_socket_has_error (GSocket *socket,
- GError **error);
-
-gboolean g_socket_is_connected (GSocket *socket);
-
-gboolean g_socket_bind (GSocket *socket,
- GSocketAddress *address,
- GError **error);
-
-gboolean g_socket_connect (GSocket *socket,
- GSocketAddress *address,
- GError **error);
-
-GIOCondition g_socket_condition_check (GSocket *socket,
- GIOCondition condition);
-gboolean g_socket_condition_wait (GSocket *socket,
- GIOCondition condition,
- GCancellable *cancellable,
- GError **error);
-
-GSocket * g_socket_accept (GSocket *socket,
- GError **error);
-
-gboolean g_socket_listen (GSocket *socket,
- GError **error);
-
-gssize g_socket_receive (GSocket *socket,
- gchar *buffer,
- gsize size,
- GError **error);
-
-gssize g_socket_receive_from (GSocket *socket,
- gchar *buffer,
- gsize size,
- GSocketAddress **address,
- GError **error);
-
-gssize g_socket_send (GSocket *socket,
- const gchar *buffer,
- gsize size,
- GError **error);
-
-gssize g_socket_send_to (GSocket *socket,
- const gchar *buffer,
- gsize size,
- GSocketAddress **address,
- GError **error);
-
-GSocketControlMessage * g_socket_receive_control_message (GSocket *socket,
- GError **error);
-gboolean g_socket_send_control_message (GSocket *socket,
- GSocketControlMessage *message,
- GError **error);
-
-
typedef struct
{
gpointer buffer;
@@ -152,30 +74,84 @@ typedef struct
gsize size;
} GOutputVector;
-gssize g_socket_receive_message (GSocket *socket,
- GSocketAddress **address,
- GInputVector *vectors,
- gint num_vectors,
- GSocketControlMessage ***messages,
- gint *num_messages,
- gint *flags,
- GError **error);
-
-gssize g_socket_send_message (GSocket *socket,
- GSocketAddress *address,
- GOutputVector *vectors,
- gint num_vectors,
- GSocketControlMessage **messages,
- gint num_messages,
- gint flags,
- GError **error);
-
-gboolean g_socket_close (GSocket *socket,
- GError **error);
+GType g_socket_get_type (void);
+GSocket * g_socket_new (GSocketFamily family,
+ GSocketType type);
+GSocket * g_socket_new_from_fd (gint fd);
+GSocketAddress * g_socket_get_local_address (GSocket *socket,
+ GError **error);
+GSocketAddress * g_socket_get_remote_address (GSocket *socket,
+ GError **error);
+void g_socket_set_blocking (GSocket *socket,
+ gboolean blocking);
+gboolean g_socket_get_blocking (GSocket *socket);
+void g_socket_set_reuse_address (GSocket *socket,
+ gboolean reuse);
+gboolean g_socket_get_reuse_address (GSocket *socket);
+gboolean g_socket_has_error (GSocket *socket,
+ GError **error);
+gboolean g_socket_is_connected (GSocket *socket);
+gboolean g_socket_bind (GSocket *socket,
+ GSocketAddress *address,
+ GError **error);
+gboolean g_socket_connect (GSocket *socket,
+ GSocketAddress *address,
+ GError **error);
+GIOCondition g_socket_condition_check (GSocket *socket,
+ GIOCondition condition);
+gboolean g_socket_condition_wait (GSocket *socket,
+ GIOCondition condition,
+ GCancellable *cancellable,
+ GError **error);
+GSocket * g_socket_accept (GSocket *socket,
+ GError **error);
+gboolean g_socket_listen (GSocket *socket,
+ GError **error);
+gssize g_socket_receive (GSocket *socket,
+ gchar *buffer,
+ gsize size,
+ GError **error);
+gssize g_socket_receive_from (GSocket *socket,
+ gchar *buffer,
+ gsize size,
+ GSocketAddress **address,
+ GError **error);
+gssize g_socket_send (GSocket *socket,
+ const gchar *buffer,
+ gsize size,
+ GError **error);
+gssize g_socket_send_to (GSocket *socket,
+ const gchar *buffer,
+ gsize size,
+ GSocketAddress **address,
+ GError **error);
+GSocketControlMessage *g_socket_receive_control_message (GSocket *socket,
+ GError **error);
+gboolean g_socket_send_control_message (GSocket *socket,
+ GSocketControlMessage *message,
+ GError **error);
+gssize g_socket_receive_message (GSocket *socket,
+ GSocketAddress **address,
+ GInputVector *vectors,
+ gint num_vectors,
+ GSocketControlMessage ***messages,
+ gint *num_messages,
+ gint *flags,
+ GError **error);
+gssize g_socket_send_message (GSocket *socket,
+ GSocketAddress *address,
+ GOutputVector *vectors,
+ gint num_vectors,
+ GSocketControlMessage **messages,
+ gint num_messages,
+ gint flags,
+ GError **error);
+gboolean g_socket_close (GSocket *socket,
+ GError **error);
+GSource * g_socket_create_source (GSocket *socket,
+ GIOCondition condition,
+ GCancellable *cancellable);
-GSource * g_socket_create_source (GSocket *socket,
- GIOCondition condition,
- GCancellable *cancellable);
G_END_DECLS
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]