|
YACLib
C++ library for concurrent tasks execution
|
#include <result_core.hpp>
Public Types | |
| using | Value = V |
| using | Trait = T |
| using | Result = typename T::template Result< V > |
Public Types inherited from yaclib::detail::BaseCore | |
| enum | State : std::uintptr_t { kEmpty = std::uintptr_t{0} , kResult = std::numeric_limits<std::uintptr_t>::max() } |
Public Member Functions | |
| ResultCore () noexcept | |
| template<typename... Args> | |
| ResultCore (std::in_place_t, Args &&... args) | |
| ~ResultCore () noexcept override | |
| template<typename... Args> | |
| void | Store (Args &&... args) |
| Result & | Get () noexcept |
| template<bool Condition> | |
| decltype(auto) | MoveOrConst () |
| virtual Result | Retire ()=0 |
Public Member Functions inherited from yaclib::detail::BaseCore | |
| bool | Empty () const noexcept |
| template<bool Shared> | |
| void | TransferExecutorTo (BaseCore &callback) noexcept |
Public Member Functions inherited from yaclib::detail::InlineCore | |
| virtual InlineCore * | Here (InlineCore &caller) noexcept=0 |
Public Member Functions inherited from yaclib::Job | |
| virtual void | Drop () noexcept |
Public Member Functions inherited from yaclib::IFunc | |
| virtual void | Call () noexcept |
Public Member Functions inherited from yaclib::IRef | |
| virtual void | IncRef () noexcept |
| Increments reference counter. | |
| virtual void | DecRef () noexcept |
| Decrements reference counter. | |
| virtual std::size_t | GetRef () noexcept |
| virtual | ~IRef () noexcept=default |
Public Attributes | ||
| union { | ||
| Result _result | ||
| Callback _self | ||
| }; | ||
Public Attributes inherited from yaclib::detail::BaseCore | ||
| IExecutorPtr | _executor {NoRefTag{}, &MakeInline()} | |
Public Attributes inherited from yaclib::detail::Node | ||
| Node * | next = nullptr | |
Protected Member Functions | |
| template<bool SymmetricTransfer, bool Shared> | |
| YACLIB_INLINE auto | Impl (InlineCore &caller) noexcept |
Protected Member Functions inherited from yaclib::detail::BaseCore | |
| BaseCore (State state) noexcept | |
| void | StoreCallbackImpl (InlineCore &callback) noexcept |
| template<bool Shared> | |
| bool | SetCallbackImpl (InlineCore &callback) noexcept |
| bool | ResetImpl () noexcept |
| template<bool SymmetricTransfer, bool Shared> | |
| Transfer< SymmetricTransfer > | SetInlineImpl (InlineCore &callback) noexcept |
| template<bool SymmetricTransfer, bool Shared> | |
| Transfer< SymmetricTransfer > | SetResultImpl () noexcept |
Additional Inherited Members | |
Protected Attributes inherited from yaclib::detail::BaseCore | |
| yaclib_std::atomic_uintptr_t | _callback |
Definition at line 17 of file result_core.hpp.
| using yaclib::detail::ResultCore< V, T >::Result = typename T::template Result<V> |
Definition at line 21 of file result_core.hpp.
| using yaclib::detail::ResultCore< V, T >::Trait = T |
Definition at line 20 of file result_core.hpp.
| using yaclib::detail::ResultCore< V, T >::Value = V |
Definition at line 19 of file result_core.hpp.
|
inlinenoexcept |
Definition at line 23 of file result_core.hpp.
References yaclib::detail::BaseCore::kEmpty.
|
inlineexplicit |
Definition at line 27 of file result_core.hpp.
References yaclib::MakeContract(), and yaclib::detail::ResultCore< V, T >::Store().
|
inlineoverridenoexcept |
Definition at line 35 of file result_core.hpp.
References yaclib::detail::BaseCore::_callback, yaclib::detail::ResultCore< V, T >::_result, yaclib::detail::BaseCore::kResult, and YACLIB_ASSERT.
|
inlinenoexcept |
Definition at line 45 of file result_core.hpp.
References yaclib::detail::ResultCore< V, T >::_result.
Referenced by yaclib::detail::ResultCore< V, T >::Impl(), yaclib::detail::ResultCore< V, T >::MoveOrConst(), yaclib::detail::SharedCore< V, T >::Retire(), and yaclib::detail::UniqueCore< V, T >::Retire().
|
inlineprotectednoexcept |
Definition at line 67 of file result_core.hpp.
References yaclib::DownCast(), yaclib::detail::ResultCore< V, T >::Get(), yaclib::MakeContract(), yaclib::detail::ResultCore< V, T >::Store(), and YACLIB_PURE_VIRTUAL.
|
inline |
Definition at line 50 of file result_core.hpp.
References yaclib::detail::ResultCore< V, T >::Get(), and yaclib::MakeContract().
|
pure virtual |
Implemented in yaclib::detail::SharedCore< V, T >, and yaclib::detail::UniqueCore< V, T >.
|
inline |
Definition at line 41 of file result_core.hpp.
References yaclib::detail::ResultCore< V, T >::_result, and yaclib::MakeContract().
Referenced by yaclib::detail::ReadyCore< V, T >::Drop(), yaclib::detail::ResultCore< V, T >::Impl(), yaclib::detail::ReadyCore< V, T >::ReadyCore(), and yaclib::detail::ResultCore< V, T >::ResultCore().
| union { ... } yaclib::detail::ResultCore< V, T > |
| Result yaclib::detail::ResultCore< V, T >::_result |
Definition at line 61 of file result_core.hpp.
Referenced by yaclib::detail::ReadyCore< V, T >::Drop(), yaclib::detail::ResultCore< V, T >::Get(), yaclib::detail::ResultCore< V, T >::Store(), and yaclib::detail::ResultCore< V, T >::~ResultCore().
| Callback yaclib::detail::ResultCore< V, T >::_self |
Definition at line 62 of file result_core.hpp.