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