summaryrefslogtreecommitdiff
path: root/libsoup/soup-connection.h
diff options
context:
space:
mode:
authorXan Lopez <xan@gnome.org>2009-07-23 16:26:51 +0300
committerXan Lopez <xan@gnome.org>2009-07-23 16:26:51 +0300
commit698d9017fb7feab33ed4a36689bb3b86e2b7da80 (patch)
treea98b0ef7007ba86a7ac9763d640b12d2f6ceb2ec /libsoup/soup-connection.h
parent5e49d5438a07fdaed7cd58365c9c79548fc55805 (diff)
parentfd5b785fbaad81f99c6c8b8bcb52028990e19120 (diff)
downloadlibsoup-698d9017fb7feab33ed4a36689bb3b86e2b7da80.tar.gz
Merge branch 'master' into cache
Conflicts: libsoup/Makefile.am libsoup/soup-session-private.h libsoup/soup-session.c libsoup/soup.h
Diffstat (limited to 'libsoup/soup-connection.h')
-rw-r--r--libsoup/soup-connection.h29
1 files changed, 17 insertions, 12 deletions
diff --git a/libsoup/soup-connection.h b/libsoup/soup-connection.h
index 180ab28d..68a36abb 100644
--- a/libsoup/soup-connection.h
+++ b/libsoup/soup-connection.h
@@ -28,13 +28,8 @@ typedef struct {
GObjectClass parent_class;
/* signals */
- void (*connect_result) (SoupConnection *, guint);
void (*disconnected) (SoupConnection *);
- void (*request_started) (SoupConnection *, SoupMessage *);
-
- /* methods */
- void (*send_request) (SoupConnection *, SoupMessage *);
} SoupConnectionClass;
GType soup_connection_get_type (void);
@@ -44,9 +39,17 @@ typedef void (*SoupConnectionCallback) (SoupConnection *conn,
guint status,
gpointer data);
-
-#define SOUP_CONNECTION_SERVER_ADDRESS "server_address"
-#define SOUP_CONNECTION_PROXY_ADDRESS "proxy-address"
+typedef enum {
+ SOUP_CONNECTION_NEW,
+ SOUP_CONNECTION_CONNECTING,
+ SOUP_CONNECTION_IDLE,
+ SOUP_CONNECTION_IN_USE,
+ SOUP_CONNECTION_DISCONNECTED
+} SoupConnectionState;
+
+#define SOUP_CONNECTION_REMOTE_ADDRESS "remote-address"
+#define SOUP_CONNECTION_TUNNEL_ADDRESS "tunnel-address"
+#define SOUP_CONNECTION_PROXY_URI "proxy-uri"
#define SOUP_CONNECTION_SSL_CREDENTIALS "ssl-creds"
#define SOUP_CONNECTION_ASYNC_CONTEXT "async-context"
#define SOUP_CONNECTION_TIMEOUT "timeout"
@@ -59,20 +62,22 @@ void soup_connection_connect_async (SoupConnection *conn,
SoupConnectionCallback callback,
gpointer user_data);
guint soup_connection_connect_sync (SoupConnection *conn);
+SoupAddress *soup_connection_get_tunnel_addr(SoupConnection *conn);
+gboolean soup_connection_start_ssl (SoupConnection *conn);
void soup_connection_disconnect (SoupConnection *conn);
SoupSocket *soup_connection_get_socket (SoupConnection *conn);
+SoupURI *soup_connection_get_proxy_uri (SoupConnection *conn);
-gboolean soup_connection_is_in_use (SoupConnection *conn);
+SoupConnectionState soup_connection_get_state (SoupConnection *conn);
+void soup_connection_set_state (SoupConnection *conn,
+ SoupConnectionState state);
time_t soup_connection_last_used (SoupConnection *conn);
void soup_connection_send_request (SoupConnection *conn,
SoupMessage *req);
-void soup_connection_reserve (SoupConnection *conn);
-void soup_connection_release (SoupConnection *conn);
-
G_END_DECLS
#endif /* SOUP_CONNECTION_H */