Vortex Connection: Related function to create and manage Vortex Connections.


Functions

void vortex_connection_add_channel (VortexConnection *connection, VortexChannel *channel)
 Adds a VortexChannel into an existing VortexConnection.
gboolean vortex_connection_channel_exists (VortexConnection *connection, gint channel_num)
 Check if a channel is already created on the given connection.
gboolean vortex_connection_close (VortexConnection *connection)
 Tries to close properly a connection and all channels inside it.
void vortex_connection_foreach_channel (VortexConnection *connection, GHFunc func, gpointer user_data)
 Allows to perform an iterator over all channels created inside the given connection.
void vortex_connection_free (VortexConnection *connection)
 Frees vortex connection resources.
VortexChannelvortex_connection_get_channel (VortexConnection *connection, gint channel_num)
 Returns a reference to the channel identified by channel_num on this connection (or vortex session).
VortexChannelPoolvortex_connection_get_channel_pool (VortexConnection *connection, gint pool_id)
 Returns the channel pool identified by pool_id.
gpointer vortex_connection_get_data (VortexConnection *connection, gchar *key)
 Gets stored value indexed by the given key inside the given connection.
gchar * vortex_connection_get_features (VortexConnection *connection)
 Returns current features requested by the remote peer this connection is linked to.
gchar * vortex_connection_get_host (VortexConnection *connection)
 Returns the actual host this connection is connected to.
gint vortex_connection_get_id (VortexConnection *connection)
 Returns the connection unique identifier.
gchar * vortex_connection_get_localize (VortexConnection *connection)
 Returns current localize requested by the remote peer this connection is linked to.
gchar * vortex_connection_get_message (VortexConnection *connection)
 Returns actual message status for the given connection.
gint vortex_connection_get_next_channel (VortexConnection *connection)
 Returns the next channel number free to be used over this session.
gint vortex_connection_get_pending_msgs (VortexConnection *connection)
 Allows to get current frames waiting to be sent on the given connection.
gchar * vortex_connection_get_port (VortexConnection *connection)
 Returns the actual port this connection is connected to.
GList * vortex_connection_get_remote_profiles (VortexConnection *connection)
 Returns the remote peer supported profiles.
VortexPeerRole vortex_connection_get_role (VortexConnection *connection)
 Allows to get current connection role.
VORTEX_SOCKET vortex_connection_get_socket (VortexConnection *connection)
 Returns the socket used by this VortexConnection object.
glong vortex_connection_get_timeout ()
 Allows to get current timeout set for VortexConnection synchronous operations.
void vortex_connection_invoke_preread_handler (VortexConnection *connection)
 Invokes the prer-read handler defined on the given connection.
gboolean vortex_connection_is_defined_preread_handler (VortexConnection *connection)
 Allows to check if there are an pre read handler defined on the given connection.
gboolean vortex_connection_is_ok (VortexConnection *connection, gboolean free_on_fail)
 Allows to get current connection status.
gboolean vortex_connection_is_profile_supported (VortexConnection *connection, gchar *uri)
 Allows to check if the given profile is supported by the remote peer.
gboolean vortex_connection_is_tlsficated (VortexConnection *connection)
 Allows to get current status for TLS activation on the given connection.
VortexConnectionvortex_connection_new (gchar *host, gchar *port, VortexConnectionNew on_connected, gpointer user_data)
 Allows to create a new BEEP session (connection) to the given host:port.
VortexConnectionvortex_connection_new_empty (gint session, VortexPeerRole role)
 Allows to create a new VortexConnection from a socket that is already connected.
gboolean vortex_connection_parse_greetings_and_enable (VortexConnection *connection, VortexFrame *frame)
 Allows to parse greetings reply received and prepare the connection to be become usable.
gboolean vortex_connection_reconnect (VortexConnection *connection, VortexConnectionNew on_connected, gpointer user_data)
 Allows to reconnect the given connection, using actual connection settings.
void vortex_connection_ref (VortexConnection *connection, gchar *who)
 Increase internal vortex connection reference counting.
void vortex_connection_remove_channel (VortexConnection *connection, VortexChannel *channel)
 Removes the given channel from this connection.
void vortex_connection_sanity_socket_check (gboolean enable)
 Allows to disable sanity socket check, by default enabled.
void vortex_connection_set_auto_tls (gboolean enabled, gboolean allow_tls_failures, gchar *serverName)
 Allows to activate TLS profile automatic negotiation for every connection created.
gboolean vortex_connection_set_blocking_socket (VortexConnection *connection)
 Allows to change connection semantic to blocking.
void vortex_connection_set_close_socket (VortexConnection *connection, gboolean action)
 Allows to configure what to do with the underlying socket connection when the VortexConnection is closed.
void vortex_connection_set_data (VortexConnection *connection, gchar *key, gpointer value)
 Sets user defined data associated with the given connection.
void vortex_connection_set_data_full (VortexConnection *connection, gchar *key, gpointer value, GDestroyNotify key_destroy, GDestroyNotify value_destroy)
 Allows to store user space data into the connection like vortex_connection_set_data does but configuring functions to be used while unreferring data stored.
void vortex_connection_set_default_io_handler (VortexConnection *connection)
 Set default IO handlers to be used while sending and receiving data for the given connection.
gboolean vortex_connection_set_nonblocking_socket (VortexConnection *connection)
 Allows to change connection semantic to nonblocking.
VortexConnectionOnClose vortex_connection_set_on_close (VortexConnection *connection, VortexConnectionOnClose on_close_handler)
 Allows to set a new on close handler to be executed only once the connection is being closed.
void vortex_connection_set_preread_handler (VortexConnection *connection, VortexConnectionOnPreRead pre_accept_handler)
 Allows to configure a handler to be executed before any operations is applied inside the Vortex Reader process.
VortexReceiveHandler vortex_connection_set_receive_handler (VortexConnection *connection, VortexReceiveHandler receive_handler)
 Allows to configure receive handler use to actually receive data from remote peer.
VortexSendHandler vortex_connection_set_send_handler (VortexConnection *connection, VortexSendHandler send_handler)
 Allows to configure the send handler used to actually perform sending operations over the underlying connection.
void vortex_connection_timeout (glong milliseconds_to_wait)
 Allows to tweak vortex internal timeouts.
void vortex_connection_unref (VortexConnection *connection, gchar *who)
 Decrease vortex connection reference counting.