file multi_index.hpp

Classes

Type Name
struct eosio::const_mem_fun
struct eosio::_multi_index_detail::secondary_index_db_functions
struct eosio::_multi_index_detail::secondary_key_traits
struct eosio::_multi_index_detail::secondary_index_db_functions< uint64_t >
struct eosio::_multi_index_detail::secondary_key_traits< uint64_t >
struct eosio::_multi_index_detail::secondary_index_db_functions< uint128_t >
struct eosio::_multi_index_detail::secondary_key_traits< uint128_t >
struct eosio::_multi_index_detail::secondary_index_db_functions< double >
struct eosio::_multi_index_detail::secondary_key_traits< double >
struct eosio::_multi_index_detail::secondary_index_db_functions< long double >
struct eosio::_multi_index_detail::secondary_key_traits< long double >
struct eosio::_multi_index_detail::secondary_index_db_functions< eosio::fixed_bytes< 32 > >
struct eosio::_multi_index_detail::secondary_key_traits< eosio::fixed_bytes< 32 > >
struct eosio::indexed_by
class eosio::multi_index
struct eosio::multi_index::item
struct eosio::multi_index::item_ptr
struct eosio::multi_index::index
struct eosio::multi_index::index::const_iterator
struct eosio::multi_index::intc
struct multi_index::index
struct eosio::multi_index::const_iterator

Defines

Type Name
define WRAP_SECONDARY_SIMPLE_TYPE
define WRAP_SECONDARY_ARRAY_TYPE
define MAKE_TRAITS_FOR_ARITHMETIC_SECONDARY_KEY

Detailed Description

Copyright

defined in eos/LICENSE

Defines Documentation

define WRAP_SECONDARY_SIMPLE_TYPE

#define WRAP_SECONDARY_SIMPLE_TYPE(IDX, TYPE)\
template<>\
struct secondary_index_db_functions<TYPE> {\
   static int32_t db_idx_next( int32_t iterator, uint64_t* primary )          { return internal_use_do_not_use::db_##IDX##_next( iterator, primary ); } \
   static int32_t db_idx_previous( int32_t iterator, uint64_t* primary )      { return internal_use_do_not_use::db_##IDX##_previous( iterator, primary ); } \
   static void    db_idx_remove( int32_t iterator  )                          { internal_use_do_not_use::db_##IDX##_remove( iterator ); } \
   static int32_t db_idx_end( uint64_t code, uint64_t scope, uint64_t table ) { return internal_use_do_not_use::db_##IDX##_end( code, scope, table ); } \
   static int32_t db_idx_store( uint64_t scope, uint64_t table, uint64_t payer, uint64_t id, const TYPE& secondary ) {\
     return internal_use_do_not_use::db_##IDX##_store( scope, table, payer, id, &secondary ); \
   }\
   static void    db_idx_update( int32_t iterator, uint64_t payer, const TYPE& secondary ) {\
     internal_use_do_not_use::db_##IDX##_update( iterator, payer, &secondary ); \
   }\
   static int32_t db_idx_find_primary( uint64_t code, uint64_t scope, uint64_t table, uint64_t primary, TYPE& secondary ) {\
     return internal_use_do_not_use::db_##IDX##_find_primary( code, scope, table, &secondary, primary ); \
   }\
   static int32_t db_idx_find_secondary( uint64_t code, uint64_t scope, uint64_t table, const TYPE& secondary, uint64_t& primary ) {\
     return internal_use_do_not_use::db_##IDX##_find_secondary( code, scope, table, &secondary, &primary ); \
   }\
   static int32_t db_idx_lowerbound( uint64_t code, uint64_t scope, uint64_t table, TYPE& secondary, uint64_t& primary ) {\
     return internal_use_do_not_use::db_##IDX##_lowerbound( code, scope, table, &secondary, &primary ); \
   }\
   static int32_t db_idx_upperbound( uint64_t code, uint64_t scope, uint64_t table, TYPE& secondary, uint64_t& primary ) {\
     return internal_use_do_not_use::db_##IDX##_upperbound( code, scope, table, &secondary, &primary ); \
   }\
};

define WRAP_SECONDARY_ARRAY_TYPE

#define WRAP_SECONDARY_ARRAY_TYPE(IDX, TYPE)\
template<>\
struct secondary_index_db_functions<TYPE> {\
   static int32_t db_idx_next( int32_t iterator, uint64_t* primary )          { return internal_use_do_not_use::db_##IDX##_next( iterator, primary ); } \
   static int32_t db_idx_previous( int32_t iterator, uint64_t* primary )      { return internal_use_do_not_use::db_##IDX##_previous( iterator, primary ); } \
   static void    db_idx_remove( int32_t iterator )                           { internal_use_do_not_use::db_##IDX##_remove( iterator ); } \
   static int32_t db_idx_end( uint64_t code, uint64_t scope, uint64_t table ) { return internal_use_do_not_use::db_##IDX##_end( code, scope, table ); } \
   static int32_t db_idx_store( uint64_t scope, uint64_t table, uint64_t payer, uint64_t id, const TYPE& secondary ) {\
     return internal_use_do_not_use::db_##IDX##_store( scope, table, payer, id, secondary.data(), TYPE::num_words() ); \
   }\
   static void    db_idx_update( int32_t iterator, uint64_t payer, const TYPE& secondary ) {\
     internal_use_do_not_use::db_##IDX##_update( iterator, payer, secondary.data(), TYPE::num_words() ); \
   }\
   static int32_t db_idx_find_primary( uint64_t code, uint64_t scope, uint64_t table, uint64_t primary, TYPE& secondary ) {\
     return internal_use_do_not_use::db_##IDX##_find_primary( code, scope, table, secondary.data(), TYPE::num_words(), primary ); \
   }\
   static int32_t db_idx_find_secondary( uint64_t code, uint64_t scope, uint64_t table, const TYPE& secondary, uint64_t& primary ) {\
     return internal_use_do_not_use::db_##IDX##_find_secondary( code, scope, table, secondary.data(), TYPE::num_words(), &primary ); \
   }\
   static int32_t db_idx_lowerbound( uint64_t code, uint64_t scope, uint64_t table, TYPE& secondary, uint64_t& primary ) {\
     return internal_use_do_not_use::db_##IDX##_lowerbound( code, scope, table, secondary.data(), TYPE::num_words(), &primary ); \
   }\
   static int32_t db_idx_upperbound( uint64_t code, uint64_t scope, uint64_t table, TYPE& secondary, uint64_t& primary ) {\
     return internal_use_do_not_use::db_##IDX##_upperbound( code, scope, table, secondary.data(), TYPE::num_words(), &primary ); \
   }\
};

define MAKE_TRAITS_FOR_ARITHMETIC_SECONDARY_KEY

#define MAKE_TRAITS_FOR_ARITHMETIC_SECONDARY_KEY(TYPE)\
template<>\
struct secondary_key_traits<TYPE> {\
   static_assert( std::numeric_limits<TYPE>::is_specialized, "TYPE does not have specialized numeric_limits" );\
   static constexpr TYPE true_lowest() { return std::numeric_limits<TYPE>::lowest(); }\
};

The documentation for this class was generated from the following file: libraries/eosiolib/contracts/eosio/multi\_index.hpp