ホーム › Storage.InstallableFileSystems › FilterInstanceClose
FilterInstanceClose
関数ミニフィルターインスタンスの通信ハンドルを閉じる。
シグネチャ
// FLTLIB.dll
#include <windows.h>
HRESULT FilterInstanceClose(
HFILTER_INSTANCE hInstance
);パラメーター
| 名前 | 型 | 方向 |
|---|---|---|
| hInstance | HFILTER_INSTANCE | in |
戻り値の型: HRESULT
各言語での呼び出し定義
// FLTLIB.dll
#include <windows.h>
HRESULT FilterInstanceClose(
HFILTER_INSTANCE hInstance
);[DllImport("FLTLIB.dll", ExactSpelling = true)]
static extern int FilterInstanceClose(
IntPtr hInstance // HFILTER_INSTANCE
);<DllImport("FLTLIB.dll", ExactSpelling:=True)>
Public Shared Function FilterInstanceClose(
hInstance As IntPtr ' HFILTER_INSTANCE
) As Integer
End Function' hInstance : HFILTER_INSTANCE
Declare PtrSafe Function FilterInstanceClose Lib "fltlib" ( _
ByVal hInstance As LongPtr) As Long
' VBA7前提(PtrSafe)。32bit Office では LongPtr→Long。Integer=16bit / Long=32bit / LongLong=64bit。import ctypes
from ctypes import wintypes
FilterInstanceClose = ctypes.windll.fltlib.FilterInstanceClose
FilterInstanceClose.restype = ctypes.c_int
FilterInstanceClose.argtypes = [
ctypes.c_ssize_t, # hInstance : HFILTER_INSTANCE
]require 'fiddle'
require 'fiddle/import'
lib = Fiddle.dlopen('FLTLIB.dll')
FilterInstanceClose = Fiddle::Function.new(
lib['FilterInstanceClose'],
[
Fiddle::TYPE_INTPTR_T, # hInstance : HFILTER_INSTANCE
],
Fiddle::TYPE_INT)#[link(name = "fltlib")]
extern "system" {
fn FilterInstanceClose(
hInstance: isize // HFILTER_INSTANCE
) -> i32;
}
// crates: windows-sys provides ready-made bindings for this API.$sig = @"
[DllImport("FLTLIB.dll")]
public static extern int FilterInstanceClose(IntPtr hInstance);
"@
$api = Add-Type -MemberDefinition $sig -Name 'FLTLIB_FilterInstanceClose' -Namespace Win32 -PassThru
# $api::FilterInstanceClose(hInstance)#uselib "FLTLIB.dll"
#func global FilterInstanceClose "FilterInstanceClose" sptr
; FilterInstanceClose hInstance ; 戻り値は stat
; hInstance : HFILTER_INSTANCE -> "sptr"
; ※HSP3.7は #func のため戻り値はシステム変数 stat に格納されます。#uselib "FLTLIB.dll"
#cfunc global FilterInstanceClose "FilterInstanceClose" sptr
; res = FilterInstanceClose(hInstance)
; hInstance : HFILTER_INSTANCE -> "sptr"; HRESULT FilterInstanceClose(HFILTER_INSTANCE hInstance)
#uselib "FLTLIB.dll"
#cfunc global FilterInstanceClose "FilterInstanceClose" intptr
; res = FilterInstanceClose(hInstance)
; hInstance : HFILTER_INSTANCE -> "intptr"import (
"golang.org/x/sys/windows"
"unsafe"
)
var (
fltlib = windows.NewLazySystemDLL("FLTLIB.dll")
procFilterInstanceClose = fltlib.NewProc("FilterInstanceClose")
)
// hInstance (HFILTER_INSTANCE)
r1, _, err := procFilterInstanceClose.Call(
uintptr(hInstance),
)
_ = err // syscall.Errno (valid when the call sets last-error)
_ = r1 // HRESULTfunction FilterInstanceClose(
hInstance: NativeInt // HFILTER_INSTANCE
): Integer; stdcall;
external 'FLTLIB.dll' name 'FilterInstanceClose';result := DllCall("FLTLIB\FilterInstanceClose"
, "Ptr", hInstance ; HFILTER_INSTANCE
, "Int") ; return: HRESULT●FilterInstanceClose(hInstance) = DLL("FLTLIB.dll", "int FilterInstanceClose(int)")
# 呼び出し: FilterInstanceClose(hInstance)
# hInstance : HFILTER_INSTANCE -> "int"
# なでしこ1は32bit・ANSI(Shift_JIS)。文字列=char*(ANSI)、ポインタ/ハンドル=void*(4byte)。