summaryrefslogtreecommitdiff
path: root/src/requests.h
diff options
context:
space:
mode:
authorGravatar Alan F <ajf@eth0.org.uk>2014-02-19 08:54:10 +0000
committerGravatar Alan F <ajf@eth0.org.uk>2014-02-19 08:54:10 +0000
commit1d6f77d4c4fafd0a9cafddd2797249557e601dba (patch)
tree33dee51882a0475aff63ec6c6d9095c92c9ac5d4 /src/requests.h
parentadf06453574270bf467b5f37e632c04c153ee90a (diff)
refactor the torrent upload code (it's called from a few places so is probably worth it), and make it easier to use a HTTP response as the input.
Diffstat (limited to 'src/requests.h')
-rw-r--r--src/requests.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/requests.h b/src/requests.h
index 5ea9b2a..7430fda 100644
--- a/src/requests.h
+++ b/src/requests.h
@@ -23,6 +23,8 @@
#include <glib-object.h>
#include <json-glib/json-glib.h>
+#include "trg-client.h"
+
JsonNode *generic_request(gchar * method, JsonArray * array);
JsonNode *session_set(void);
@@ -34,7 +36,8 @@ JsonNode *torrent_start(JsonArray * array);
JsonNode *torrent_verify(JsonArray * array);
JsonNode *torrent_reannounce(JsonArray * array);
JsonNode *torrent_remove(JsonArray * array, int removeData);
-JsonNode *torrent_add(gchar * filename, gint flags);
+JsonNode *torrent_add_from_response(trg_response *response, gint flags);
+JsonNode *torrent_add_from_file(gchar * filename, gint flags);
JsonNode *torrent_add_url(const gchar * url, gboolean paused);
JsonNode *torrent_set_location(JsonArray * array, gchar * location,
gboolean move);