$version
$version :
A simple JSON-RPC client.
__construct(Array $opts)
Build a JSON-RPC client.
| Array | $opts | Named parameters. 'debug' If true, we enable debugging. 'idtype' One of JSONRPC_ID_RAND, JSONRPC_ID_TIME, JSONRPC_ID_UUID. 'version' Either 1 (default) or 2 (for JSON-RPC 2.0). 'batch' If true, we use batch mode (2.0 only) 'batch_name' Override the method name used to send batch requests. We use 'send' by default. (Only if batch is true.) 'notifications' An array of methods that are notifications. 'named_params' An array of methods that use named params (2.0 only.) 'transport' One of the transport classes: 'http' A simple HTTP stream class (default). 'curl' The Nano Curl library is used for transport. 'socket' The Nano Socket library is used for transport. Any extra parameters are sent to the Transport object's constructor. The default 'http' transport REQUIRES the 'url' parameter to specify the JSON-RPC URL endpoint. Any of the parameters other than 'transport' can be changed after initialization using object properties of the same name. |