YACLib
C++ library for concurrent tasks execution
Loading...
Searching...
No Matches
func.hpp
Go to the documentation of this file.
1#pragma once
2
3#include <yaclib/util/ref.hpp>
4
5#include <type_traits>
6#include <utility>
7
8namespace yaclib {
9
10/**
11 * Callable interface
12 */
13class IFunc : public IRef { // TODO(MBkkt) Maybe remove inheritance from IRef
14 public:
15 // compiler remove this call from tests
16 virtual void Call() noexcept { // LCOV_EXCL_LINE
17 YACLIB_PURE_VIRTUAL(); // LCOV_EXCL_LINE
18 } // LCOV_EXCL_LINE
19};
20
21} // namespace yaclib
Callable interface.
Definition func.hpp:13
virtual void Call() noexcept
Definition func.hpp:16
Reference counting interface.
Definition ref.hpp:8
#define YACLIB_PURE_VIRTUAL()
Definition log.hpp:86
Contract< V, E > MakeContract()
Creates related future and promise.
Definition contract.hpp:25