Fix reflection problem

This commit is contained in:
Srdjan Obucina 2019-12-09 20:50:40 +01:00
parent 0ecffdd4a8
commit a2d71689c1
5 changed files with 9 additions and 7 deletions

View file

@ -396,11 +396,11 @@ void get_relevant_accounts( const object* obj, flat_set<account_id_type>& accoun
assert( aobj != nullptr ); assert( aobj != nullptr );
accounts.insert( aobj->son_account ); accounts.insert( aobj->son_account );
break; break;
/*} case sidechain_address_object_type:{ } case sidechain_address_object_type:{
const auto& aobj = dynamic_cast<const sidechain_address_object*>(obj); const auto& aobj = dynamic_cast<const sidechain_address_object*>(obj);
assert( aobj != nullptr ); assert( aobj != nullptr );
accounts.insert( aobj->sidechain_address_account ); accounts.insert( aobj->sidechain_address_account );
break;*/ break;
} }
} }
} }

View file

@ -56,8 +56,8 @@ FC_REFLECT(graphene::chain::sidechain_address_add_operation, (fee)(sidechain_add
(address)(private_key)(public_key) ) (address)(private_key)(public_key) )
FC_REFLECT(graphene::chain::sidechain_address_update_operation::fee_parameters_type, (fee) ) FC_REFLECT(graphene::chain::sidechain_address_update_operation::fee_parameters_type, (fee) )
//FC_REFLECT(graphene::chain::sidechain_address_update_operation, (fee)(sidechain_address_id)(sidechain_address_account)/*(sidechain)*/ FC_REFLECT(graphene::chain::sidechain_address_update_operation, (fee)(sidechain_address_id)(sidechain_address_account)(sidechain)
// (address)(private_key)(public_key) ) /*(address)(private_key)(public_key)*/ )
FC_REFLECT(graphene::chain::sidechain_address_delete_operation::fee_parameters_type, (fee) ) FC_REFLECT(graphene::chain::sidechain_address_delete_operation::fee_parameters_type, (fee) )
//FC_REFLECT(graphene::chain::sidechain_address_delete_operation, (fee)(sidechain_address_id)(sidechain_address_account)/*(sidechain)*/ ) FC_REFLECT(graphene::chain::sidechain_address_delete_operation, (fee)(sidechain_address_id)(sidechain_address_account)(sidechain) )

View file

@ -45,7 +45,7 @@ namespace graphene { namespace chain {
member<sidechain_address_object, account_id_type, &sidechain_address_object::sidechain_address_account> member<sidechain_address_object, account_id_type, &sidechain_address_object::sidechain_address_account>
>, >,
ordered_unique< tag<by_network>, ordered_unique< tag<by_network>,
member<sidechain_address_object, const peerplays_sidechain::sidechain_type, &sidechain_address_object::sidechain> member<sidechain_address_object, peerplays_sidechain::sidechain_type, &sidechain_address_object::sidechain>
>, >,
ordered_unique< tag<by_account_and_network>, ordered_unique< tag<by_account_and_network>,
composite_key<sidechain_address_object, composite_key<sidechain_address_object,
@ -60,4 +60,4 @@ namespace graphene { namespace chain {
} } // graphene::chain } } // graphene::chain
FC_REFLECT_DERIVED( graphene::chain::sidechain_address_object, (graphene::db::object), FC_REFLECT_DERIVED( graphene::chain::sidechain_address_object, (graphene::db::object),
(sidechain_address_account)/*(sidechain)*/(address)(private_key)(public_key) ) (sidechain_address_account)(sidechain)(address)(private_key)(public_key) )

View file

@ -69,3 +69,4 @@ struct sidechain_event_data {
} } // graphene::peerplays_sidechain } } // graphene::peerplays_sidechain
FC_REFLECT_ENUM(graphene::peerplays_sidechain::sidechain_type, (bitcoin) )

View file

@ -44,6 +44,7 @@
#include <graphene/chain/match_object.hpp> #include <graphene/chain/match_object.hpp>
#include <graphene/chain/game_object.hpp> #include <graphene/chain/game_object.hpp>
#include <graphene/chain/son_object.hpp> #include <graphene/chain/son_object.hpp>
#include <graphene/chain/sidechain_address_object.hpp>
#include <fc/smart_ref_impl.hpp> #include <fc/smart_ref_impl.hpp>
#include <iostream> #include <iostream>