ADTF
Loading...
Searching...
No Matches
rpc::cJSONConversions Class Reference

#include <json_rpc.h>

Inherited by rpc::jsonrpc_object_server< ServerStub, Connector > [protected], and rpc::jsonrpc_remote_interface< Stub, Interface, Connector, ConnectorInitializer > [protected].

Static Public Member Functions

static Json::Value result_to_json (a_util::result::Result nResult)
 
static std::string to_string (uint64_t nValue)
 
static std::string to_string (int64_t nValue)
 
static a_util::result::Result json_to_result (const Json::Value &oValue)
 
static uint64_t stoull (const std::string &strValue)
 
static int64_t stoll (const std::string &strValue)
 

Detailed Description

Utility base class to facilitate JSON conversions

Member Function Documentation

◆ json_to_result()

static a_util::result::Result rpc::cJSONConversions::json_to_result ( const Json::Value & oValue)
static

Get the a_util::result::Result representation of an object of type Json::Value

Parameters
[in]oValueThe json value object to convert
Returns
a_util::result::Result representation

◆ result_to_json()

static Json::Value rpc::cJSONConversions::result_to_json ( a_util::result::Result nResult)
static

Get the Json::Value representation of an object of type a_util::result::Result

Parameters
[in]nResultThe result object to convert
Returns
Json::Value representation

◆ stoll()

static int64_t rpc::cJSONConversions::stoll ( const std::string & strValue)
static

Convert a string to a signed integer

Parameters
[in]strValueThe value to convert
Returns
Signed integer representation of strValue

◆ stoull()

static uint64_t rpc::cJSONConversions::stoull ( const std::string & strValue)
static

Convert a string to an unsigned integer

Parameters
[in]strValueThe value to convert
Returns
Unsigned integer representation of strValue

◆ to_string() [1/2]

static std::string rpc::cJSONConversions::to_string ( int64_t nValue)
static

Convert a signed integer to a string

Parameters
[in]nValueThe value to convert
Returns
String representation of nValue

◆ to_string() [2/2]

static std::string rpc::cJSONConversions::to_string ( uint64_t nValue)
static

Convert an unsigned integer to a string

Parameters
[in]nValueThe value to convert
Returns
String representation of nValue

The documentation for this class was generated from the following file: