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