ホーム › System.Threading › CloseThreadpoolIo
CloseThreadpoolIo
関数スレッドプールのI/Oオブジェクトを解放する。
シグネチャ
// KERNEL32.dll
#include <windows.h>
void CloseThreadpoolIo(
PTP_IO pio
);パラメーター
| 名前 | 型 | 方向 |
|---|---|---|
| pio | PTP_IO | in |
戻り値の型: void
各言語での呼び出し定義
// KERNEL32.dll
#include <windows.h>
void CloseThreadpoolIo(
PTP_IO pio
);[DllImport("KERNEL32.dll", ExactSpelling = true)]
static extern void CloseThreadpoolIo(
IntPtr pio // PTP_IO
);<DllImport("KERNEL32.dll", ExactSpelling:=True)>
Public Shared Sub CloseThreadpoolIo(
pio As IntPtr ' PTP_IO
)
End Sub' pio : PTP_IO
Declare PtrSafe Sub CloseThreadpoolIo Lib "kernel32" ( _
ByVal pio As LongPtr)
' VBA7前提(PtrSafe)。32bit Office では LongPtr→Long。Integer=16bit / Long=32bit / LongLong=64bit。import ctypes
from ctypes import wintypes
CloseThreadpoolIo = ctypes.windll.kernel32.CloseThreadpoolIo
CloseThreadpoolIo.restype = None
CloseThreadpoolIo.argtypes = [
ctypes.c_ssize_t, # pio : PTP_IO
]require 'fiddle'
require 'fiddle/import'
lib = Fiddle.dlopen('KERNEL32.dll')
CloseThreadpoolIo = Fiddle::Function.new(
lib['CloseThreadpoolIo'],
[
Fiddle::TYPE_INTPTR_T, # pio : PTP_IO
],
Fiddle::TYPE_VOID)#[link(name = "kernel32")]
extern "system" {
fn CloseThreadpoolIo(
pio: isize // PTP_IO
);
}
// crates: windows-sys provides ready-made bindings for this API.$sig = @"
[DllImport("KERNEL32.dll")]
public static extern void CloseThreadpoolIo(IntPtr pio);
"@
$api = Add-Type -MemberDefinition $sig -Name 'KERNEL32_CloseThreadpoolIo' -Namespace Win32 -PassThru
# $api::CloseThreadpoolIo(pio)#uselib "KERNEL32.dll"
#func global CloseThreadpoolIo "CloseThreadpoolIo" sptr
; CloseThreadpoolIo pio
; pio : PTP_IO -> "sptr"#uselib "KERNEL32.dll"
#func global CloseThreadpoolIo "CloseThreadpoolIo" sptr
; CloseThreadpoolIo pio
; pio : PTP_IO -> "sptr"; void CloseThreadpoolIo(PTP_IO pio)
#uselib "KERNEL32.dll"
#func global CloseThreadpoolIo "CloseThreadpoolIo" intptr
; CloseThreadpoolIo pio
; pio : PTP_IO -> "intptr"import (
"golang.org/x/sys/windows"
"unsafe"
)
var (
kernel32 = windows.NewLazySystemDLL("KERNEL32.dll")
procCloseThreadpoolIo = kernel32.NewProc("CloseThreadpoolIo")
)
// pio (PTP_IO)
r1, _, err := procCloseThreadpoolIo.Call(
uintptr(pio),
)
_ = err // syscall.Errno (valid when the call sets last-error)
_ = r1 // voidprocedure CloseThreadpoolIo(
pio: NativeInt // PTP_IO
); stdcall;
external 'KERNEL32.dll' name 'CloseThreadpoolIo';result := DllCall("KERNEL32\CloseThreadpoolIo"
, "Ptr", pio ; PTP_IO
, "Int") ; return: void●CloseThreadpoolIo(pio) = DLL("KERNEL32.dll", "int CloseThreadpoolIo(int)")
# 呼び出し: CloseThreadpoolIo(pio)
# pio : PTP_IO -> "int"
# なでしこ1は32bit・ANSI(Shift_JIS)。文字列=char*(ANSI)、ポインタ/ハンドル=void*(4byte)。