Line data Source code
1 : /********************************************************************************
2 : * Copyright (c) 2024 Accenture
3 : *
4 : * This program and the accompanying materials are made available under the
5 : * terms of the Apache License Version 2.0 which is available at
6 : * https://www.apache.org/licenses/LICENSE-2.0
7 : *
8 : * SPDX-License-Identifier: Apache-2.0
9 : ********************************************************************************/
10 :
11 : #pragma once
12 :
13 : namespace os
14 : {
15 : /**
16 : * Class providing interface for synchronization between the main thread and the worker thread
17 : *
18 : *
19 : */
20 : class IFutureSupport
21 : {
22 : public:
23 : IFutureSupport(IFutureSupport const&) = delete;
24 : IFutureSupport& operator=(IFutureSupport const&) = delete;
25 1 : IFutureSupport() = default;
26 :
27 : virtual void wait() = 0;
28 : virtual void notify() = 0;
29 : virtual void assertTaskContext() = 0;
30 : virtual bool verifyTaskContext() = 0;
31 : };
32 :
33 : } /* namespace os */
|