Win32 API 日本語リファレンス
ホームNetworking.Clustering › ClusterGroupSetCloseEnum

ClusterGroupSetCloseEnum

関数
グループセット列挙ハンドルを閉じる。
DLLCLUSAPI.dll呼出規約winapi対応OSwindowsserver2016

シグネチャ

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

DWORD ClusterGroupSetCloseEnum(
    HGROUPSETENUM hGroupSetEnum
);

パラメーター

名前方向
hGroupSetEnumHGROUPSETENUMin

戻り値の型: DWORD

各言語での呼び出し定義

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

DWORD ClusterGroupSetCloseEnum(
    HGROUPSETENUM hGroupSetEnum
);
[DllImport("CLUSAPI.dll", ExactSpelling = true)]
static extern uint ClusterGroupSetCloseEnum(
    IntPtr hGroupSetEnum   // HGROUPSETENUM
);
<DllImport("CLUSAPI.dll", ExactSpelling:=True)>
Public Shared Function ClusterGroupSetCloseEnum(
    hGroupSetEnum As IntPtr   ' HGROUPSETENUM
) As UInteger
End Function
' hGroupSetEnum : HGROUPSETENUM
Declare PtrSafe Function ClusterGroupSetCloseEnum Lib "clusapi" ( _
    ByVal hGroupSetEnum As LongPtr) As Long
' VBA7前提(PtrSafe)。32bit Office では LongPtr→Long。Integer=16bit / Long=32bit / LongLong=64bit。
import ctypes
from ctypes import wintypes

ClusterGroupSetCloseEnum = ctypes.windll.clusapi.ClusterGroupSetCloseEnum
ClusterGroupSetCloseEnum.restype = wintypes.DWORD
ClusterGroupSetCloseEnum.argtypes = [
    ctypes.c_ssize_t,  # hGroupSetEnum : HGROUPSETENUM
]
require 'fiddle'
require 'fiddle/import'

lib = Fiddle.dlopen('CLUSAPI.dll')
ClusterGroupSetCloseEnum = Fiddle::Function.new(
  lib['ClusterGroupSetCloseEnum'],
  [
    Fiddle::TYPE_INTPTR_T,  # hGroupSetEnum : HGROUPSETENUM
  ],
  -Fiddle::TYPE_INT)
#[link(name = "clusapi")]
extern "system" {
    fn ClusterGroupSetCloseEnum(
        hGroupSetEnum: isize  // HGROUPSETENUM
    ) -> u32;
}
// crates: windows-sys provides ready-made bindings for this API.
$sig = @"
[DllImport("CLUSAPI.dll")]
public static extern uint ClusterGroupSetCloseEnum(IntPtr hGroupSetEnum);
"@
$api = Add-Type -MemberDefinition $sig -Name 'CLUSAPI_ClusterGroupSetCloseEnum' -Namespace Win32 -PassThru
# $api::ClusterGroupSetCloseEnum(hGroupSetEnum)
#uselib "CLUSAPI.dll"
#func global ClusterGroupSetCloseEnum "ClusterGroupSetCloseEnum" sptr
; ClusterGroupSetCloseEnum hGroupSetEnum   ; 戻り値は stat
; hGroupSetEnum : HGROUPSETENUM -> "sptr"
; ※HSP3.7は #func のため戻り値はシステム変数 stat に格納されます。
#uselib "CLUSAPI.dll"
#cfunc global ClusterGroupSetCloseEnum "ClusterGroupSetCloseEnum" sptr
; res = ClusterGroupSetCloseEnum(hGroupSetEnum)
; hGroupSetEnum : HGROUPSETENUM -> "sptr"
; DWORD ClusterGroupSetCloseEnum(HGROUPSETENUM hGroupSetEnum)
#uselib "CLUSAPI.dll"
#cfunc global ClusterGroupSetCloseEnum "ClusterGroupSetCloseEnum" intptr
; res = ClusterGroupSetCloseEnum(hGroupSetEnum)
; hGroupSetEnum : HGROUPSETENUM -> "intptr"
import (
	"golang.org/x/sys/windows"
	"unsafe"
)

var (
	clusapi = windows.NewLazySystemDLL("CLUSAPI.dll")
	procClusterGroupSetCloseEnum = clusapi.NewProc("ClusterGroupSetCloseEnum")
)

// hGroupSetEnum (HGROUPSETENUM)
r1, _, err := procClusterGroupSetCloseEnum.Call(
	uintptr(hGroupSetEnum),
)
_ = err  // syscall.Errno (valid when the call sets last-error)
_ = r1   // DWORD
function ClusterGroupSetCloseEnum(
  hGroupSetEnum: NativeInt   // HGROUPSETENUM
): DWORD; stdcall;
  external 'CLUSAPI.dll' name 'ClusterGroupSetCloseEnum';
result := DllCall("CLUSAPI\ClusterGroupSetCloseEnum"
    , "Ptr", hGroupSetEnum   ; HGROUPSETENUM
    , "UInt")   ; return: DWORD
●ClusterGroupSetCloseEnum(hGroupSetEnum) = DLL("CLUSAPI.dll", "dword ClusterGroupSetCloseEnum(int)")
# 呼び出し: ClusterGroupSetCloseEnum(hGroupSetEnum)
# hGroupSetEnum : HGROUPSETENUM -> "int"
# なでしこ1は32bit・ANSI(Shift_JIS)。文字列=char*(ANSI)、ポインタ/ハンドル=void*(4byte)。