ホーム › UI.Accessibility › UiaGetReservedMixedAttributeValue
UiaGetReservedMixedAttributeValue
関数属性混在を表すUIオートメーション予約値を取得する。
シグネチャ
// UIAutomationCore.dll
#include <windows.h>
HRESULT UiaGetReservedMixedAttributeValue(
IUnknown** punkMixedAttributeValue
);パラメーター
| 名前 | 型 | 方向 | 説明 |
|---|---|---|---|
| punkMixedAttributeValue | IUnknown** | out | 混在属性値を表す予約済みIUnknownオブジェクトを受け取る出力先。テキスト範囲内で属性が一様でない場合に用いる。 |
戻り値の型: HRESULT
各言語での呼び出し定義
// UIAutomationCore.dll
#include <windows.h>
HRESULT UiaGetReservedMixedAttributeValue(
IUnknown** punkMixedAttributeValue
);[DllImport("UIAutomationCore.dll", ExactSpelling = true)]
static extern int UiaGetReservedMixedAttributeValue(
IntPtr punkMixedAttributeValue // IUnknown** out
);<DllImport("UIAutomationCore.dll", ExactSpelling:=True)>
Public Shared Function UiaGetReservedMixedAttributeValue(
punkMixedAttributeValue As IntPtr ' IUnknown** out
) As Integer
End Function' punkMixedAttributeValue : IUnknown** out
Declare PtrSafe Function UiaGetReservedMixedAttributeValue Lib "uiautomationcore" ( _
ByVal punkMixedAttributeValue As LongPtr) As Long
' VBA7前提(PtrSafe)。32bit Office では LongPtr→Long。Integer=16bit / Long=32bit / LongLong=64bit。import ctypes
from ctypes import wintypes
UiaGetReservedMixedAttributeValue = ctypes.windll.uiautomationcore.UiaGetReservedMixedAttributeValue
UiaGetReservedMixedAttributeValue.restype = ctypes.c_int
UiaGetReservedMixedAttributeValue.argtypes = [
ctypes.c_void_p, # punkMixedAttributeValue : IUnknown** out
]require 'fiddle'
require 'fiddle/import'
lib = Fiddle.dlopen('UIAutomationCore.dll')
UiaGetReservedMixedAttributeValue = Fiddle::Function.new(
lib['UiaGetReservedMixedAttributeValue'],
[
Fiddle::TYPE_VOIDP, # punkMixedAttributeValue : IUnknown** out
],
Fiddle::TYPE_INT)#[link(name = "uiautomationcore")]
extern "system" {
fn UiaGetReservedMixedAttributeValue(
punkMixedAttributeValue: *mut *mut core::ffi::c_void // IUnknown** out
) -> i32;
}
// crates: windows-sys provides ready-made bindings for this API.$sig = @"
[DllImport("UIAutomationCore.dll")]
public static extern int UiaGetReservedMixedAttributeValue(IntPtr punkMixedAttributeValue);
"@
$api = Add-Type -MemberDefinition $sig -Name 'UIAutomationCore_UiaGetReservedMixedAttributeValue' -Namespace Win32 -PassThru
# $api::UiaGetReservedMixedAttributeValue(punkMixedAttributeValue)#uselib "UIAutomationCore.dll"
#func global UiaGetReservedMixedAttributeValue "UiaGetReservedMixedAttributeValue" sptr
; UiaGetReservedMixedAttributeValue punkMixedAttributeValue ; 戻り値は stat
; punkMixedAttributeValue : IUnknown** out -> "sptr"
; ※HSP3.7は #func のため戻り値はシステム変数 stat に格納されます。#uselib "UIAutomationCore.dll"
#cfunc global UiaGetReservedMixedAttributeValue "UiaGetReservedMixedAttributeValue" sptr
; res = UiaGetReservedMixedAttributeValue(punkMixedAttributeValue)
; punkMixedAttributeValue : IUnknown** out -> "sptr"; HRESULT UiaGetReservedMixedAttributeValue(IUnknown** punkMixedAttributeValue)
#uselib "UIAutomationCore.dll"
#cfunc global UiaGetReservedMixedAttributeValue "UiaGetReservedMixedAttributeValue" intptr
; res = UiaGetReservedMixedAttributeValue(punkMixedAttributeValue)
; punkMixedAttributeValue : IUnknown** out -> "intptr"import (
"golang.org/x/sys/windows"
"unsafe"
)
var (
uiautomationcore = windows.NewLazySystemDLL("UIAutomationCore.dll")
procUiaGetReservedMixedAttributeValue = uiautomationcore.NewProc("UiaGetReservedMixedAttributeValue")
)
// punkMixedAttributeValue (IUnknown** out)
r1, _, err := procUiaGetReservedMixedAttributeValue.Call(
uintptr(punkMixedAttributeValue),
)
_ = err // syscall.Errno (valid when the call sets last-error)
_ = r1 // HRESULTfunction UiaGetReservedMixedAttributeValue(
punkMixedAttributeValue: Pointer // IUnknown** out
): Integer; stdcall;
external 'UIAutomationCore.dll' name 'UiaGetReservedMixedAttributeValue';result := DllCall("UIAutomationCore\UiaGetReservedMixedAttributeValue"
, "Ptr", punkMixedAttributeValue ; IUnknown** out
, "Int") ; return: HRESULT●UiaGetReservedMixedAttributeValue(punkMixedAttributeValue) = DLL("UIAutomationCore.dll", "int UiaGetReservedMixedAttributeValue(void*)")
# 呼び出し: UiaGetReservedMixedAttributeValue(punkMixedAttributeValue)
# punkMixedAttributeValue : IUnknown** out -> "void*"
# なでしこ1は32bit・ANSI(Shift_JIS)。文字列=char*(ANSI)、ポインタ/ハンドル=void*(4byte)。const std = @import("std");
extern "uiautomationcore" fn UiaGetReservedMixedAttributeValue(
punkMixedAttributeValue: ?*anyopaque // IUnknown** out
) callconv(std.os.windows.WINAPI) i32;proc UiaGetReservedMixedAttributeValue(
punkMixedAttributeValue: pointer # IUnknown** out
): int32 {.importc: "UiaGetReservedMixedAttributeValue", stdcall, dynlib: "UIAutomationCore.dll".}pragma(lib, "uiautomationcore");
extern(Windows)
int UiaGetReservedMixedAttributeValue(
void* punkMixedAttributeValue // IUnknown** out
);ccall((:UiaGetReservedMixedAttributeValue, "UIAutomationCore.dll"), stdcall, Int32,
(Ptr{Cvoid},),
punkMixedAttributeValue)
# punkMixedAttributeValue : IUnknown** out -> Ptr{Cvoid}
# stdcall は 32bit のみ意味を持つ(x64 では無視)。local ffi = require("ffi")
ffi.cdef[[
int32_t UiaGetReservedMixedAttributeValue(
void* punkMixedAttributeValue);
]]
local uiautomationcore = ffi.load("uiautomationcore")
-- uiautomationcore.UiaGetReservedMixedAttributeValue(punkMixedAttributeValue)
-- punkMixedAttributeValue : IUnknown** out
-- 構造体/GUIDへのポインタは cdef が通るよう void* で表記(実型は各引数コメント参照)。値渡し構造体・enum は対応する typedef を cdef に追加すること。const koffi = require('koffi');
const lib = koffi.load('UIAutomationCore.dll');
const UiaGetReservedMixedAttributeValue = lib.func('__stdcall', 'UiaGetReservedMixedAttributeValue', 'int32_t', ['void *']);
// UiaGetReservedMixedAttributeValue(punkMixedAttributeValue)
// punkMixedAttributeValue : IUnknown** out -> 'void *'
// 出力ポインタは koffi.out(...) で包む。構造体は koffi.struct で定義。const lib = Deno.dlopen("UIAutomationCore.dll", {
UiaGetReservedMixedAttributeValue: { parameters: ["pointer"], result: "i32" },
});
// lib.symbols.UiaGetReservedMixedAttributeValue(punkMixedAttributeValue)
// punkMixedAttributeValue : IUnknown** out -> "pointer"
// 文字列引数は "buffer"(NUL 終端のバイト列を Uint8Array で渡す)。
// 値渡し構造体は { struct: [ ...field types... ] } を使用。<?php
$ffi = FFI::cdef(<<<C
int32_t UiaGetReservedMixedAttributeValue(
void* punkMixedAttributeValue);
C, "UIAutomationCore.dll");
// $ffi->UiaGetReservedMixedAttributeValue(punkMixedAttributeValue);
// punkMixedAttributeValue : IUnknown** out
// 構造体/GUIDへのポインタは cdef が通るよう void* で表記(実型は各引数コメント参照)。値渡し構造体・enum は対応する typedef を cdef に追加すること。
// WINAPI(stdcall): x64 では呼出規約が統一されるため問題なし。x86 では __stdcall 対応のラッパが必要な場合あり。import com.sun.jna.*;
import com.sun.jna.ptr.*;
import com.sun.jna.win32.StdCallLibrary;
import com.sun.jna.win32.W32APIOptions;
public interface Uiautomationcore extends StdCallLibrary {
Uiautomationcore INSTANCE = Native.load("uiautomationcore", Uiautomationcore.class);
int UiaGetReservedMixedAttributeValue(
Pointer punkMixedAttributeValue // IUnknown** out
);
}@[Link("uiautomationcore")]
lib LibUIAutomationCore
fun UiaGetReservedMixedAttributeValue = UiaGetReservedMixedAttributeValue(
punkMixedAttributeValue : Void* # IUnknown** out
) : Int32
end
# 構造体/GUID/enum は lib 内に対応する型定義が必要。
# 呼出規約: x64 は規約統一のため OK。x86(32bit)は WINAPI=stdcall だが Crystal の fun に stdcall 付与構文がなく非対応。import 'dart:ffi';
import 'package:ffi/ffi.dart';
typedef UiaGetReservedMixedAttributeValueNative = Int32 Function(Pointer<Void>);
typedef UiaGetReservedMixedAttributeValueDart = int Function(Pointer<Void>);
final UiaGetReservedMixedAttributeValue = DynamicLibrary.open('UIAutomationCore.dll')
.lookupFunction<UiaGetReservedMixedAttributeValueNative, UiaGetReservedMixedAttributeValueDart>('UiaGetReservedMixedAttributeValue');
// punkMixedAttributeValue : IUnknown** out -> Pointer<Void>
// 文字列は package:ffi の "...".toNativeUtf16()/toNativeUtf8() で変換。{$mode objfpc}{$H+}
function UiaGetReservedMixedAttributeValue(
punkMixedAttributeValue: Pointer // IUnknown** out
): Integer; stdcall;
external 'UIAutomationCore.dll' name 'UiaGetReservedMixedAttributeValue';import Foreign
import Foreign.C.Types
import Foreign.C.String
foreign import stdcall safe "UiaGetReservedMixedAttributeValue"
c_UiaGetReservedMixedAttributeValue :: Ptr () -> IO Int32
-- punkMixedAttributeValue : IUnknown** out -> Ptr ()
-- 要 GHC(Windows)。stdcall は x64 では ccall として扱われる。ブロックする API は safe 呼び出し推奨。open Ctypes
open Foreign
let uiagetreservedmixedattributevalue =
foreign "UiaGetReservedMixedAttributeValue"
((ptr void) @-> returning int32_t)
(* punkMixedAttributeValue : IUnknown** out -> (ptr void) *)
(* foreign は cdecl 前提。x64 Windows では WINAPI と一致。構造体は ctypes structure を定義のこと。 *)(cffi:define-foreign-library uiautomationcore (t "UIAutomationCore.dll"))
(cffi:use-foreign-library uiautomationcore)
(cffi:defcfun ("UiaGetReservedMixedAttributeValue" uia-get-reserved-mixed-attribute-value :convention :stdcall) :int32
(punk-mixed-attribute-value :pointer)) ; IUnknown** out
; isize/usize(INT_PTR/SIZE_T)は x64 前提で :int64/:uint64。x86 では :int32/:uint32。use Win32::API;
my $UiaGetReservedMixedAttributeValue = Win32::API::More->new('UIAutomationCore',
'int UiaGetReservedMixedAttributeValue(LPVOID punkMixedAttributeValue)');
# my $ret = $UiaGetReservedMixedAttributeValue->Call($punkMixedAttributeValue);
# punkMixedAttributeValue : IUnknown** out -> LPVOID
# 値渡し構造体は pack() した文字列、または Win32::API::Struct を使用。関連項目
使用する型