MeVisLab Toolbox Reference
AsynchronousExecution.h
Go to the documentation of this file.
1
// Copyright (c) Fraunhofer MEVIS, Germany. All rights reserved.
2
// **InsertLicense** code
3
4
#pragma once
5
6
#include <
asio/System.h
>
7
#include <
asio/ExecutionPolicy.h
>
8
#include <
asio/Context.h
>
9
#include <
asio/Semaphore.h
>
10
11
#include <FMEThirdPartyWarningsDisable.h>
12
#include <memory>
13
#include <FMEThirdPartyWarningsRestore.h>
14
15
namespace
asio
{
16
33
class
ASYNCHRONOUSIO_EXPORT
AsynchronousExecution
:
public
ExecutionPolicy
34
{
35
public
:
36
37
AsynchronousExecution
(std::shared_ptr<Context> context);
38
39
void
execute
(std::function<
void
()> callable)
override
;
40
41
private
:
42
43
std::shared_ptr<Context> _context;
44
45
Semaphore
_semaphore;
46
};
47
48
}
Context.h
ExecutionPolicy.h
Semaphore.h
System.h
ASYNCHRONOUSIO_EXPORT
#define ASYNCHRONOUSIO_EXPORT
Definition
System.h:10
asio::AsynchronousExecution::execute
void execute(std::function< void()> callable) override
asio::AsynchronousExecution::AsynchronousExecution
AsynchronousExecution(std::shared_ptr< Context > context)
asio::ExecutionPolicy::ExecutionPolicy
ExecutionPolicy()=default
asio::Semaphore
A simple semaphore with increment and decrement functionality.
Definition
Semaphore.h:40
asio
Definition
AsynchronousExecution.h:15
FMEstable
ReleaseMeVis
Projects
AsynchronousIO
Sources
asio
AsynchronousExecution.h
Generated by
1.15.0