Wire Sysio Wire Sysion 1.0.0
|
#include <api_connection.hpp>
Public Member Functions | |
any_api (api_id_type api_id, const std::shared_ptr< fc::api_connection > &con) | |
virtual uint64_t | get_handle () const override |
virtual api_id_type | register_api (api_connection &conn) const override |
any_api (api_id_type api_id, const std::shared_ptr< fc::binary_api_connection > &con) | |
virtual uint64_t | get_handle () const override |
virtual api_id_type | register_api (binary_api_connection &conn) const override |
Public Member Functions inherited from fc::api_base | |
api_base () | |
virtual | ~api_base () |
template<typename T > | |
api< T, identity_member > | as () |
template<typename T > | |
api< T > | as () |
Public Attributes | |
api_id_type | _api_id |
std::weak_ptr< fc::api_connection > | _api_connection |
std::weak_ptr< fc::binary_api_connection > | _binary_api_connection |
If api<T> is returned from a remote method, the API is eagerly bound to api<T> of the correct type in api_visitor::from_variant(). This binding [1] needs a reference to the api_connection, which is made available to from_variant() as a parameter.
However, in the case of a remote method which returns api_base which can subsequently be cast by the caller with as<T>, we need to keep track of the connection because the binding is done later (when the client code actually calls as<T>).
[1] The binding actually happens in get_remote_api().
If api<T> is returned from a remote method, the API is eagerly bound to api<T> of the correct type in api_visitor::from_variant(). This binding [1] needs a reference to the binary_api_connection, which is made available to from_variant() as a parameter.
However, in the case of a remote method which returns api_base which can subsequently be cast by the caller with as<T>, we need to keep track of the connection because the binding is done later (when the client code actually calls as<T>).
[1] The binding actually happens in get_remote_api().
Definition at line 79 of file binary_api_connection.hpp.
|
inline |
Definition at line 81 of file api_connection.hpp.
|
inline |
Definition at line 82 of file binary_api_connection.hpp.
|
inlineoverridevirtual |
|
inlineoverridevirtual |
|
inlineoverridevirtual |
Implements fc::api_base.
Definition at line 87 of file api_connection.hpp.
|
inlineoverridevirtual |
Definition at line 88 of file binary_api_connection.hpp.
std::weak_ptr<fc::api_connection> fc::detail::any_api::_api_connection |
Definition at line 91 of file api_connection.hpp.
api_id_type fc::detail::any_api::_api_id |
Definition at line 90 of file api_connection.hpp.
std::weak_ptr<fc::binary_api_connection> fc::detail::any_api::_binary_api_connection |
Definition at line 92 of file binary_api_connection.hpp.