Wire Sysio Wire Sysion 1.0.0
Loading...
Searching...
No Matches
sysio::chain::impl::abi_to_variant_visitor< T, Resolver > Class Template Reference

#include <abi_serializer.hpp>

Public Member Functions

 abi_to_variant_visitor (mutable_variant_object &_mvo, const T &_val, Resolver _resolver, abi_traverse_context &_ctx)
 
template<typename Member , class Class , Member Class::* member>
void operator() (const char *name) const
 

Detailed Description

template<typename T, typename Resolver>
class sysio::chain::impl::abi_to_variant_visitor< T, Resolver >

Reflection visitor that uses a resolver to resolve ABIs for nested types this will degrade to the common fc::to_variant as soon as the type no longer contains ABI related info

Template Parameters
Reslover- callable with the signature (const name& code_account) -> std::optional<abi_def>

Definition at line 666 of file abi_serializer.hpp.

Constructor & Destructor Documentation

◆ abi_to_variant_visitor()

template<typename T , typename Resolver >
sysio::chain::impl::abi_to_variant_visitor< T, Resolver >::abi_to_variant_visitor ( mutable_variant_object & _mvo,
const T & _val,
Resolver _resolver,
abi_traverse_context & _ctx )
inline

Definition at line 669 of file abi_serializer.hpp.

670 :_vo(_mvo)
671 ,_val(_val)
672 ,_resolver(_resolver)
673 ,_ctx(_ctx)
674 {}

Member Function Documentation

◆ operator()()

template<typename T , typename Resolver >
template<typename Member , class Class , Member Class::* member>
void sysio::chain::impl::abi_to_variant_visitor< T, Resolver >::operator() ( const char * name) const
inline

Visit a single member and add it to the variant object

Template Parameters
Member- the member to visit
Class- the class we are traversing
member- pointer to the member
Parameters
name- the name of the member

Definition at line 684 of file abi_serializer.hpp.

685 {
686 abi_to_variant::add( _vo, name, (_val.*member), _resolver, _ctx );
687 }
std::string name
static void add(mutable_variant_object &mvo, const char *name, const M &v, Resolver, abi_traverse_context &ctx)
Here is the call graph for this function:

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