mirror of
https://github.com/rakshasa/rtorrent.git
synced 2026-08-08 03:02:30 +00:00
* Removed old Command classes.
* Redirects can now be made efficiently using rpc::CommandMap::create_redirect or "methods.redirect=new_key,dest_key". git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1155 e378c898-3ddf-0310-93e7-cc216c733640
This commit is contained in:
@@ -104,6 +104,8 @@ public:
|
||||
static const int flag_public_xmlrpc = 0x4;
|
||||
static const int flag_no_target = 0x8;
|
||||
static const int flag_modifiable = 0x10;
|
||||
static const int flag_is_redirect = 0x20;
|
||||
static const int flag_has_redirects = 0x40;
|
||||
|
||||
CommandMap() {}
|
||||
~CommandMap();
|
||||
@@ -127,6 +129,8 @@ public:
|
||||
void insert(key_type key, const command_map_data_type src);
|
||||
void erase(iterator itr);
|
||||
|
||||
void create_redirect(key_type key_new, key_type key_dest, int flags);
|
||||
|
||||
const mapped_type call(key_type key, const mapped_type& args = mapped_type());
|
||||
const mapped_type call(key_type key, target_type target, const mapped_type& args = mapped_type()) { return call_command(key, args, target); }
|
||||
const mapped_type call_catch(key_type key, target_type target, const mapped_type& args = mapped_type(), const char* err = "Command failed: ");
|
||||
|
||||
Reference in New Issue
Block a user