Win32 API 日本語リファレンス
ホームGlobalization › ucnvsel_close

ucnvsel_close

関数
コンバータ選択器を解放する。
DLLicuuc.dll呼出規約cdecl

シグネチャ

// icuuc.dll
#include <windows.h>

void ucnvsel_close(
    UConverterSelector* sel
);

パラメーター

名前方向
selUConverterSelector*inout

戻り値の型: void

各言語での呼び出し定義

// icuuc.dll
#include <windows.h>

void ucnvsel_close(
    UConverterSelector* sel
);
[DllImport("icuuc.dll", ExactSpelling = true, CallingConvention = CallingConvention.Cdecl)]
static extern void ucnvsel_close(
    ref IntPtr sel   // UConverterSelector* in/out
);
<DllImport("icuuc.dll", ExactSpelling:=True, CallingConvention:=CallingConvention.Cdecl)>
Public Shared Sub ucnvsel_close(
    ByRef sel As IntPtr   ' UConverterSelector* in/out
)
End Sub
' sel : UConverterSelector* in/out
Declare PtrSafe Sub ucnvsel_close Lib "icuuc" ( _
    ByRef sel As LongPtr)
' VBA7前提(PtrSafe)。32bit Office では LongPtr→Long。Integer=16bit / Long=32bit / LongLong=64bit。
import ctypes
from ctypes import wintypes

ucnvsel_close = ctypes.cdll.icuuc.ucnvsel_close
ucnvsel_close.restype = None
ucnvsel_close.argtypes = [
    ctypes.c_void_p,  # sel : UConverterSelector* in/out
]
require 'fiddle'
require 'fiddle/import'

lib = Fiddle.dlopen('icuuc.dll')
ucnvsel_close = Fiddle::Function.new(
  lib['ucnvsel_close'],
  [
    Fiddle::TYPE_VOIDP,  # sel : UConverterSelector* in/out
  ],
  Fiddle::TYPE_VOID, Fiddle::Function::CDECL)
#[link(name = "icuuc")]
extern "C" {
    fn ucnvsel_close(
        sel: *mut isize  // UConverterSelector* in/out
    );
}
// crates: windows-sys provides ready-made bindings for this API.
$sig = @"
[DllImport("icuuc.dll", CallingConvention = CallingConvention.Cdecl)]
public static extern void ucnvsel_close(ref IntPtr sel);
"@
$api = Add-Type -MemberDefinition $sig -Name 'icuuc_ucnvsel_close' -Namespace Win32 -PassThru
# $api::ucnvsel_close(sel)
#uselib "icuuc.dll"
#func global ucnvsel_close "ucnvsel_close" sptr
; ucnvsel_close sel
; sel : UConverterSelector* in/out -> "sptr"
#uselib "icuuc.dll"
#func global ucnvsel_close "ucnvsel_close" int
; ucnvsel_close sel
; sel : UConverterSelector* in/out -> "int"
; void ucnvsel_close(UConverterSelector* sel)
#uselib "icuuc.dll"
#func global ucnvsel_close "ucnvsel_close" int
; ucnvsel_close sel
; sel : UConverterSelector* in/out -> "int"
import (
	"golang.org/x/sys/windows"
	"unsafe"
)

var (
	icuuc = windows.NewLazySystemDLL("icuuc.dll")
	procucnvsel_close = icuuc.NewProc("ucnvsel_close")
)

// sel (UConverterSelector* in/out)
r1, _, err := procucnvsel_close.Call(
	uintptr(sel),
)
_ = err  // syscall.Errno (valid when the call sets last-error)
_ = r1   // void
procedure ucnvsel_close(
  sel: Pointer   // UConverterSelector* in/out
); cdecl;
  external 'icuuc.dll' name 'ucnvsel_close';
result := DllCall("icuuc\ucnvsel_close"
    , "Ptr", sel   ; UConverterSelector* in/out
    , "Cdecl Int")   ; return: void
●ucnvsel_close(sel) = DLL("icuuc.dll", "int ucnvsel_close(void*)")
# 呼び出し: ucnvsel_close(sel)
# sel : UConverterSelector* in/out -> "void*"
# なでしこ1は32bit・ANSI(Shift_JIS)。文字列=char*(ANSI)、ポインタ/ハンドル=void*(4byte)。
# ※cdecl関数。DLL()宣言はstdcall前提。cdeclは EXEC_PTR(`cdecl`,…) を使用。