Kagome
Polkadot Runtime Engine in C++17
kagome::api::Parser< Cb > Struct Template Reference
Collaboration diagram for kagome::api::Parser< Cb >:

Public Member Functions

bool parse (std::string_view request)
 
bool scalar () const
 
bool Null ()
 
bool Bool (bool)
 
bool Int (int)
 
bool Uint (unsigned)
 
bool Int64 (int64_t)
 
bool Uint64 (uint64_t)
 
bool Double (double)
 
bool RawNumber (const char *, size_t, bool)
 
bool String (const char *, size_t, bool)
 
bool Key (const char *, size_t, bool)
 
bool StartArray ()
 
bool EndArray (size_t)
 
bool StartObject ()
 
bool EndObject (size_t)
 

Public Attributes

Cb cb
 
rapidjson::MemoryStream stream {nullptr, 0}
 
size_t level = 0
 
size_t begin = 0
 

Detailed Description

template<typename Cb>
struct kagome::api::Parser< Cb >

Parses jsonrpc batch request. Callback is invoked for each request.

Definition at line 16 of file jrpc_handle_batch.cpp.

Member Function Documentation

template<typename Cb >
bool kagome::api::Parser< Cb >::Bool ( bool  )
inline

Definition at line 35 of file jrpc_handle_batch.cpp.

template<typename Cb >
bool kagome::api::Parser< Cb >::Double ( double  )
inline

Definition at line 50 of file jrpc_handle_batch.cpp.

template<typename Cb >
bool kagome::api::Parser< Cb >::EndArray ( size_t  )
inline

Definition at line 69 of file jrpc_handle_batch.cpp.

template<typename Cb >
bool kagome::api::Parser< Cb >::EndObject ( size_t  )
inline

Definition at line 83 of file jrpc_handle_batch.cpp.

template<typename Cb >
bool kagome::api::Parser< Cb >::Int ( int  )
inline

Definition at line 38 of file jrpc_handle_batch.cpp.

template<typename Cb >
bool kagome::api::Parser< Cb >::Int64 ( int64_t  )
inline

Definition at line 44 of file jrpc_handle_batch.cpp.

template<typename Cb >
bool kagome::api::Parser< Cb >::Key ( const char *  ,
size_t  ,
bool   
)
inline

Definition at line 59 of file jrpc_handle_batch.cpp.

template<typename Cb >
bool kagome::api::Parser< Cb >::Null ( )
inline

Definition at line 32 of file jrpc_handle_batch.cpp.

template<typename Cb >
bool kagome::api::Parser< Cb >::parse ( std::string_view  request)
inline

Definition at line 23 of file jrpc_handle_batch.cpp.

template<typename Cb >
bool kagome::api::Parser< Cb >::RawNumber ( const char *  ,
size_t  ,
bool   
)
inline

Definition at line 53 of file jrpc_handle_batch.cpp.

template<typename Cb >
bool kagome::api::Parser< Cb >::scalar ( ) const
inline

Definition at line 29 of file jrpc_handle_batch.cpp.

template<typename Cb >
bool kagome::api::Parser< Cb >::StartArray ( )
inline

Definition at line 62 of file jrpc_handle_batch.cpp.

template<typename Cb >
bool kagome::api::Parser< Cb >::StartObject ( )
inline

Definition at line 73 of file jrpc_handle_batch.cpp.

template<typename Cb >
bool kagome::api::Parser< Cb >::String ( const char *  ,
size_t  ,
bool   
)
inline

Definition at line 56 of file jrpc_handle_batch.cpp.

template<typename Cb >
bool kagome::api::Parser< Cb >::Uint ( unsigned  )
inline

Definition at line 41 of file jrpc_handle_batch.cpp.

template<typename Cb >
bool kagome::api::Parser< Cb >::Uint64 ( uint64_t  )
inline

Definition at line 47 of file jrpc_handle_batch.cpp.

Member Data Documentation

template<typename Cb >
size_t kagome::api::Parser< Cb >::begin = 0

Definition at line 21 of file jrpc_handle_batch.cpp.

template<typename Cb >
Cb kagome::api::Parser< Cb >::cb

Definition at line 17 of file jrpc_handle_batch.cpp.

template<typename Cb >
size_t kagome::api::Parser< Cb >::level = 0

Definition at line 20 of file jrpc_handle_batch.cpp.

template<typename Cb >
rapidjson::MemoryStream kagome::api::Parser< Cb >::stream {nullptr, 0}

Definition at line 19 of file jrpc_handle_batch.cpp.


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