2019-03-15 02:37:38 +01:00
|
|
|
/*
|
|
|
|
* IXSelectInterruptFactory.cpp
|
|
|
|
* Author: Benjamin Sergeant
|
|
|
|
* Copyright (c) 2019 Machine Zone, Inc. All rights reserved.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#include "IXSelectInterruptFactory.h"
|
|
|
|
|
2019-03-16 01:46:40 +01:00
|
|
|
#if defined(__linux__) || defined(__APPLE__)
|
2019-09-23 19:25:23 +02:00
|
|
|
#include <ixwebsocket/IXSelectInterruptPipe.h>
|
2019-03-15 19:41:57 +01:00
|
|
|
#else
|
2019-09-23 19:25:23 +02:00
|
|
|
#include <ixwebsocket/IXSelectInterrupt.h>
|
2019-03-15 02:37:38 +01:00
|
|
|
#endif
|
|
|
|
|
|
|
|
namespace ix
|
|
|
|
{
|
|
|
|
std::shared_ptr<SelectInterrupt> createSelectInterrupt()
|
|
|
|
{
|
2019-03-16 01:46:40 +01:00
|
|
|
#if defined(__linux__) || defined(__APPLE__)
|
2019-03-15 02:37:38 +01:00
|
|
|
return std::make_shared<SelectInterruptPipe>();
|
2019-03-15 19:41:57 +01:00
|
|
|
#else
|
|
|
|
return std::make_shared<SelectInterrupt>();
|
2019-03-15 02:37:38 +01:00
|
|
|
#endif
|
|
|
|
}
|
2019-09-23 19:25:23 +02:00
|
|
|
} // namespace ix
|