[#CRPCCommand-2constructor-09] = xref:CRPCCommand.adoc[CRPCCommand]::CRPCCommand :relfileprefix: ../ :mrdocs: Constructors == Synopses Declared in `<rpc/server.h>` Construct a command from a plain RpcMethodFnType factory function pointer. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- xref:CRPCCommand/2constructor-03.adoc[CRPCCommand]( std::string category, xref:RpcMethodFnType.adoc[RpcMethodFnType] fn); ---- [.small]#xref:CRPCCommand/2constructor-03.adoc[_» more..._]# Construct a command from an Actor callback supporting multiple handlers. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- xref:CRPCCommand/2constructor-04.adoc[CRPCCommand]( std::string category, std::string name, xref:CRPCCommand/Actor-05.adoc[Actor] actor, std::vector<std::pair<std::string, bool>> args, intptr_t unique_id); ---- [.small]#xref:CRPCCommand/2constructor-04.adoc[_» more..._]# == Parameters [cols="1,4"] |=== | Name| Description | *category* | The help category the command is grouped under. | *fn* | Factory returning the method metadata and request handler. | *name* | The method name clients invoke. | *actor* | The handler callback that processes the request. | *args* | Method arguments paired with whether each is named‐only. | *unique_id* | Identifier used to detect aliased commands. |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#