summaryrefslogtreecommitdiff
path: root/src/RpcMethodImpl.h
diff options
context:
space:
mode:
authorTatsuhiro Tsujikawa <tatsuhiro.t@gmail.com>2011-06-17 22:45:42 +0900
committerTatsuhiro Tsujikawa <tatsuhiro.t@gmail.com>2011-06-17 22:45:42 +0900
commitcc7bc0aad3f27b4201ce5870d018cb40599389ca (patch)
tree78dbec15ecfa01da8d8d6d0e6030ad03a7657f87 /src/RpcMethodImpl.h
parentbb7e2e69db46c1abd51cdfc5dbfe11814adc06f4 (diff)
Added aria2.getGlobalStat RPC method.
It returns overall download/upload speed and the number of active/stopped/waiting downloads.
Diffstat (limited to 'src/RpcMethodImpl.h')
-rw-r--r--src/RpcMethodImpl.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/RpcMethodImpl.h b/src/RpcMethodImpl.h
index b83c4dfe..e3fbc338 100644
--- a/src/RpcMethodImpl.h
+++ b/src/RpcMethodImpl.h
@@ -530,6 +530,18 @@ public:
}
};
+class GetGlobalStatRpcMethod:public RpcMethod {
+protected:
+ virtual SharedHandle<ValueBase> process
+ (const RpcRequest& req, DownloadEngine* e);
+public:
+ static const std::string& getMethodName()
+ {
+ static std::string methodName = "aria2.getGlobalStat";
+ return methodName;
+ }
+};
+
class ForceShutdownRpcMethod:public RpcMethod {
protected:
virtual SharedHandle<ValueBase> process