/* */ #ifndef _D_XML_RPC_METHOD_H_ #define _D_XML_RPC_METHOD_H_ #include "common.h" #include #include "SharedHandle.h" namespace aria2 { class DownloadEngine; class OptionParser; class BDE; class Logger; class Option; class Exception; namespace xmlrpc { struct XmlRpcRequest; struct XmlRpcResponse; // This class offers abstract implementation of processing XML-RPC // request. You have to inherit this class and implement process() // method to add new XML-RPC API. // // There is XmlRpcMethodFactory class which instantiates XmlRpcMethod // subclass. If you add new XmlRpcMethod subclass, don't forget to add // it to XmlRpcMethodFactory. class XmlRpcMethod { protected: SharedHandle _optionParser; Logger* _logger; // Subclass must implement this function to fulfil XmlRpcRequest // req. The return value of this method is used as a return value // of XML-RPC request. virtual BDE process(const XmlRpcRequest& req, DownloadEngine* e) = 0; void gatherRequestOption(const SharedHandle