IXWebSocket/ixwebsocket/IXCancellationRequest.h

20 lines
434 B
C
Raw Normal View History

2018-12-15 01:28:11 +01:00
/*
* IXCancellationRequest.h
* Author: Benjamin Sergeant
* Copyright (c) 2018 Machine Zone, Inc. All rights reserved.
*/
#pragma once
#include <functional>
2019-01-03 21:53:44 +01:00
#include <atomic>
2018-12-15 01:28:11 +01:00
namespace ix
2018-12-15 01:28:11 +01:00
{
using CancellationRequest = std::function<bool()>;
2019-01-03 21:53:44 +01:00
CancellationRequest makeCancellationRequestWithTimeout(int seconds,
std::atomic<bool>& requestInitCancellation);
2018-12-15 01:28:11 +01:00
}