* Added 'get_d_ratio', 'view_list', 'get_d_tracker_focus',

'get_d_tracker_size', etc.

* Added tracker commands.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@945 e378c898-3ddf-0310-93e7-cc216c733640
This commit is contained in:
rakshasa
2007-07-29 16:59:34 +00:00
parent 1232cd44cb
commit ac92b56f37
19 changed files with 527 additions and 81 deletions
+10 -3
View File
@@ -46,15 +46,17 @@ namespace core {
namespace torrent {
class File;
class Object;
class Tracker;
}
namespace rpc {
class XmlRpc {
public:
typedef rak::function1<core::Download*, const char*> slot_find_download;
typedef rak::function2<torrent::File*, core::Download*, uint32_t> slot_find_file;
typedef rak::function2<bool, const char*, uint32_t> slot_write;
typedef rak::function1<core::Download*, const char*> slot_find_download;
typedef rak::function2<torrent::File*, core::Download*, uint32_t> slot_find_file;
typedef rak::function2<torrent::Tracker*, core::Download*, uint32_t> slot_find_tracker;
typedef rak::function2<bool, const char*, uint32_t> slot_write;
static const int dialect_generic = 0;
static const int dialect_i8 = 1;
@@ -63,6 +65,7 @@ public:
static const int call_generic = 0;
static const int call_download = 1;
static const int call_file = 2;
static const int call_tracker = 3;
XmlRpc() : m_env(NULL), m_registry(NULL), m_dialect(dialect_i8) {}
@@ -84,6 +87,9 @@ public:
slot_find_file& get_slot_find_file() { return m_slotFindFile; }
void set_slot_find_file(slot_find_file::base_type* slot) { m_slotFindFile.set(slot); }
slot_find_tracker& get_slot_find_tracker() { return m_slotFindTracker; }
void set_slot_find_tracker(slot_find_tracker::base_type* slot) { m_slotFindTracker.set(slot); }
private:
void* m_env;
void* m_registry;
@@ -92,6 +98,7 @@ private:
slot_find_download m_slotFindDownload;
slot_find_file m_slotFindFile;
slot_find_tracker m_slotFindTracker;
};
}