summaryrefslogtreecommitdiff
path: root/src/trg-client.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/trg-client.h')
-rw-r--r--src/trg-client.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/trg-client.h b/src/trg-client.h
index a0bee33..21833fc 100644
--- a/src/trg-client.h
+++ b/src/trg-client.h
@@ -57,6 +57,9 @@
#define FAIL_RESPONSE_UNSUCCESSFUL -3
#define DISPATCH_POOL_SIZE 3
+#define HTTP_CLASS_TRANSMISSION 0
+#define HTTP_CLASS_PUBLIC 1
+
typedef struct {
int status;
int size;
@@ -69,6 +72,7 @@ typedef struct {
gint connid;
JsonNode *node;
gchar *str;
+ gchar *url;
GSourceFunc callback;
gpointer cb_data;
} trg_request;
@@ -109,6 +113,7 @@ typedef struct {
* We lock updating (and checking for updates) with priv->configMutex
*/
int serial;
+ guint client_class;
CURL *curl;
} trg_tls;
@@ -123,6 +128,8 @@ trg_response *dispatch(TrgClient * client, JsonNode * req);
trg_response *dispatch_str(TrgClient * client, gchar * req);
gboolean dispatch_async(TrgClient * client, JsonNode * req,
GSourceFunc callback, gpointer data);
+gboolean async_http_request(TrgClient *tc, gchar *url, GSourceFunc callback, gpointer data);
+
/* end dispatch.c*/
GType trg_client_get_type(void);