Add socket module with overlapped socket support

This commit is contained in:
Eugen Wissner 2016-10-08 19:29:07 +02:00
parent e9a0a93d3c
commit 154e2f2ff7
2 changed files with 1405 additions and 0 deletions

32
source/tanya/async/iocp.d Normal file
View File

@ -0,0 +1,32 @@
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
/**
* Copyright: Eugene Wissner 2016.
* License: $(LINK2 https://www.mozilla.org/en-US/MPL/2.0/,
* Mozilla Public License, v. 2.0).
* Authors: $(LINK2 mailto:belka@caraus.de, Eugene Wissner)
*/
module tanya.async.iocp;
version (Windows):
import core.sys.windows.winbase;
import core.sys.windows.windef;
/**
* Provides an extendable representation of a Win32 $(D_PSYMBOL OVERLAPPED)
* structure.
*/
class State
{
/// For internal use by Windows API.
align(1) OVERLAPPED overlapped;
/// File/socket handle.
HANDLE handle;
/// For keeping events or event masks.
int event;
}

File diff suppressed because it is too large Load Diff