GebrCommProtocolSocket

GebrCommProtocolSocket

Synopsis

#define             GEBR_COMM_PROTOCOL_SOCKET_TYPE
struct              GebrCommProtocolSocket;
struct              GebrCommProtocolSocketClass;
GebrCommProtocolSocket *  gebr_comm_protocol_socket_new (void);
GebrCommProtocolSocket *  gebr_comm_protocol_socket_new_from_socket
                                                        (GebrCommStreamSocket *socket);
gboolean            gebr_comm_protocol_socket_connect   (GebrCommProtocolSocket *self,
                                                         GebrCommSocketAddress *socket_address,
                                                         gboolean wait);
void                gebr_comm_protocol_socket_disconnect
                                                        (GebrCommProtocolSocket *self);
GebrCommHttpMsg *   gebr_comm_protocol_socket_send_request
                                                        (GebrCommProtocolSocket *self,
                                                         GebrCommHttpRequestMethod method,
                                                         const gchar *url,
                                                         GebrCommJsonContent *content);
void                gebr_comm_protocol_socket_send_response
                                                        (GebrCommProtocolSocket *self,
                                                         int status_code,
                                                         GebrCommJsonContent *content);
void                gebr_comm_protocol_socket_oldmsg_send
                                                        (GebrCommProtocolSocket *self,
                                                         gboolean blocking,
                                                         struct gebr_comm_message_def gebr_comm_message_def,
                                                         guint n_params,
                                                         ...);
GList *             gebr_comm_protocol_socket_oldmsg_split
                                                        (GString *arguments,
                                                         guint parts);
void                gebr_comm_protocol_socket_oldmsg_split_free
                                                        (GList *split);
                    GebrCommProtocolSocketPrivate;

Object Hierarchy

  GObject
   +----GebrCommProtocolSocket

Properties

  "stream-socket"            gpointer              : Read / Write / Construct Only

Signals

  "connected"                                      : Action
  "disconnected"                                   : Action
  "old-parse-messages"                             : Action
  "process-request"                                : Action
  "process-response"                               : Action

Description

Details

GEBR_COMM_PROTOCOL_SOCKET_TYPE

#define GEBR_COMM_PROTOCOL_SOCKET_TYPE		(gebr_comm_protocol_socket_get_type())

struct GebrCommProtocolSocket

struct GebrCommProtocolSocket;

struct GebrCommProtocolSocketClass

struct GebrCommProtocolSocketClass {
	GObjectClass parent;

	/* signals */
	void (*connected)(GebrCommProtocolSocket *socket);
	void (*disconnected)(GebrCommProtocolSocket *socket);
	void (*process_request)(GebrCommProtocolSocket *socket, GebrCommHttpMsg * request);
	void (*process_response)(GebrCommProtocolSocket *socket, GebrCommHttpMsg * request, GebrCommHttpMsg * response);
	void (*old_parse_messages)(GebrCommProtocolSocket *socket);
};

gebr_comm_protocol_socket_new ()

GebrCommProtocolSocket *  gebr_comm_protocol_socket_new (void);

gebr_comm_protocol_socket_new_from_socket ()

GebrCommProtocolSocket *  gebr_comm_protocol_socket_new_from_socket
                                                        (GebrCommStreamSocket *socket);

gebr_comm_protocol_socket_connect ()

gboolean            gebr_comm_protocol_socket_connect   (GebrCommProtocolSocket *self,
                                                         GebrCommSocketAddress *socket_address,
                                                         gboolean wait);

gebr_comm_protocol_socket_disconnect ()

void                gebr_comm_protocol_socket_disconnect
                                                        (GebrCommProtocolSocket *self);

gebr_comm_protocol_socket_send_request ()

GebrCommHttpMsg *   gebr_comm_protocol_socket_send_request
                                                        (GebrCommProtocolSocket *self,
                                                         GebrCommHttpRequestMethod method,
                                                         const gchar *url,
                                                         GebrCommJsonContent *content);

gebr_comm_protocol_socket_send_response ()

void                gebr_comm_protocol_socket_send_response
                                                        (GebrCommProtocolSocket *self,
                                                         int status_code,
                                                         GebrCommJsonContent *content);

gebr_comm_protocol_socket_oldmsg_send ()

void                gebr_comm_protocol_socket_oldmsg_send
                                                        (GebrCommProtocolSocket *self,
                                                         gboolean blocking,
                                                         struct gebr_comm_message_def gebr_comm_message_def,
                                                         guint n_params,
                                                         ...);

gebr_comm_protocol_socket_oldmsg_split ()

GList *             gebr_comm_protocol_socket_oldmsg_split
                                                        (GString *arguments,
                                                         guint parts);

gebr_comm_protocol_socket_oldmsg_split_free ()

void                gebr_comm_protocol_socket_oldmsg_split_free
                                                        (GList *split);

GebrCommProtocolSocketPrivate

typedef struct _GebrCommProtocolSocketPrivate GebrCommProtocolSocketPrivate;

Property Details

The "stream-socket" property

  "stream-socket"            gpointer              : Read / Write / Construct Only

Signal Details

The "connected" signal

void                user_function                      (GebrCommProtocolSocket *gebrcommprotocolsocket,
                                                        gpointer                user_data)                   : Action

The "disconnected" signal

void                user_function                      (GebrCommProtocolSocket *gebrcommprotocolsocket,
                                                        gpointer                user_data)                   : Action

The "old-parse-messages" signal

void                user_function                      (GebrCommProtocolSocket *gebrcommprotocolsocket,
                                                        gpointer                user_data)                   : Action

The "process-request" signal

void                user_function                      (GebrCommProtocolSocket *gebrcommprotocolsocket,
                                                        gpointer                arg1,
                                                        gpointer                user_data)                   : Action

The "process-response" signal

void                user_function                      (GebrCommProtocolSocket *gebrcommprotocolsocket,
                                                        gpointer                arg1,
                                                        gpointer                arg2,
                                                        gpointer                user_data)                   : Action