ホーム › NetworkManagement.Dhcp › DhcpCApiCleanup
DhcpCApiCleanup
関数DHCPクライアントAPIの使用を終了し資源を解放する。
シグネチャ
// dhcpcsvc.dll
#include <windows.h>
void DhcpCApiCleanup(void);パラメーターなし。戻り値: void
各言語での呼び出し定義
// dhcpcsvc.dll
#include <windows.h>
void DhcpCApiCleanup(void);[DllImport("dhcpcsvc.dll", ExactSpelling = true)]
static extern void DhcpCApiCleanup();<DllImport("dhcpcsvc.dll", ExactSpelling:=True)>
Public Shared Sub DhcpCApiCleanup()
End SubDeclare PtrSafe Sub DhcpCApiCleanup Lib "dhcpcsvc" ()
' VBA7前提(PtrSafe)。32bit Office では LongPtr→Long。Integer=16bit / Long=32bit / LongLong=64bit。import ctypes
from ctypes import wintypes
DhcpCApiCleanup = ctypes.windll.dhcpcsvc.DhcpCApiCleanup
DhcpCApiCleanup.restype = None
DhcpCApiCleanup.argtypes = []require 'fiddle'
require 'fiddle/import'
lib = Fiddle.dlopen('dhcpcsvc.dll')
DhcpCApiCleanup = Fiddle::Function.new(
lib['DhcpCApiCleanup'],
[],
Fiddle::TYPE_VOID)#[link(name = "dhcpcsvc")]
extern "system" {
fn DhcpCApiCleanup();
}
// crates: windows-sys provides ready-made bindings for this API.$sig = @"
[DllImport("dhcpcsvc.dll")]
public static extern void DhcpCApiCleanup();
"@
$api = Add-Type -MemberDefinition $sig -Name 'dhcpcsvc_DhcpCApiCleanup' -Namespace Win32 -PassThru
# $api::DhcpCApiCleanup()#uselib "dhcpcsvc.dll"
#func global DhcpCApiCleanup "DhcpCApiCleanup"
; DhcpCApiCleanup#uselib "dhcpcsvc.dll"
#func global DhcpCApiCleanup "DhcpCApiCleanup"
; DhcpCApiCleanup; void DhcpCApiCleanup()
#uselib "dhcpcsvc.dll"
#func global DhcpCApiCleanup "DhcpCApiCleanup"
; DhcpCApiCleanupimport (
"golang.org/x/sys/windows"
"unsafe"
)
var (
dhcpcsvc = windows.NewLazySystemDLL("dhcpcsvc.dll")
procDhcpCApiCleanup = dhcpcsvc.NewProc("DhcpCApiCleanup")
)
r1, _, err := procDhcpCApiCleanup.Call()
_ = err // syscall.Errno (valid when the call sets last-error)
_ = r1 // voidprocedure DhcpCApiCleanup; stdcall;
external 'dhcpcsvc.dll' name 'DhcpCApiCleanup';result := DllCall("dhcpcsvc\DhcpCApiCleanup", "Int")●DhcpCApiCleanup() = DLL("dhcpcsvc.dll", "int DhcpCApiCleanup()")
# 呼び出し: DhcpCApiCleanup()
# なでしこ1は32bit・ANSI(Shift_JIS)。文字列=char*(ANSI)、ポインタ/ハンドル=void*(4byte)。