struct eosio::action_wrapper

Class List > eosio :: action_wrapper

Used to wrap an a particular action to simplify the process of other contracts sending inline actions to "wrapped" action. Example: More...

Public Static Attributes

Type Name
static constexpr eosio::name action_name

Public Attributes

Type Name
eosio::name code_name
std::vector< eosio::permission_level > permissions

Public Functions

Type Name
constexpr action_wrapper (Code && code, std::vector< eosio::permission_level > && perms)
constexpr action_wrapper (Code && code, const std::vector< eosio::permission_level > & perms)
constexpr action_wrapper (Code && code, eosio::permission_level && perm)
constexpr action_wrapper (Code && code, const eosio::permission_level & perm)
action to_action (Args &&... args) const
void send (Args &&... args) const
void send_context_free (Args &&... args) const

Public Static Functions

Type Name
static constexpr auto get_mem_ptr ()

Detailed Description

Wrapper for an action object.

// defined by contract writer of the actions
using transfer act = action_wrapper<"transfer"_n, &token::transfer>;( *this, transfer, {st.issuer,N(active)}, {st.issuer, to, quantity, memo} );
// usage by different contract writer
transfer_act{"eosio.token"_n, {st.issuer, "active"_n}}.send(st.issuer, to, quantity, memo);
// or
transfer_act trans_action{ "eosio.token"_n, {st.issuer, "active"_n}};
trans_action.send(st.issuer, to, quantity, memo);

Public Static Attributes Documentation

variable action_name

constexpr eosio::name eosio::action_wrapper< Name, Action >::action_name;

Public Attributes Documentation

variable code_name

eosio::name eosio::action_wrapper< Name, Action >::code_name;

variable permissions

std::vector<eosio::permission_level> eosio::action_wrapper< Name, Action >::permissions;

Public Functions Documentation

function action_wrapper (1/4)

constexpr eosio::action_wrapper::action_wrapper (
    Code && code,
    std::vector< eosio::permission_level > && perms
)

function action_wrapper (2/4)

constexpr eosio::action_wrapper::action_wrapper (
    Code && code,
    const std::vector< eosio::permission_level > & perms
)

function action_wrapper (3/4)

constexpr eosio::action_wrapper::action_wrapper (
    Code && code,
    eosio::permission_level && perm
)

function action_wrapper (4/4)

constexpr eosio::action_wrapper::action_wrapper (
    Code && code,
    const eosio::permission_level & perm
)

function to_action

action eosio::action_wrapper::to_action (
    Args &&... args
) const

function send

void eosio::action_wrapper::send (
    Args &&... args
) const

function send_context_free

void eosio::action_wrapper::send_context_free (
    Args &&... args
) const

Public Static Functions Documentation

function get_mem_ptr

static constexpr auto eosio::action_wrapper::get_mem_ptr ()

The documentation for this class was generated from the following file: in/eosio.cdt/libraries/eosiolib/contracts/eosio/action.hpp

results matching ""

    No results matching ""