ホーム › System.Iis › HSE_UNICODE_URL_MAPEX_INFO
HSE_UNICODE_URL_MAPEX_INFO
構造体サイズ=各フィールドのバイト数(x64/x86 で異なる場合は x64/x86 と併記)。x64/x86 列=フィールドのバイトオフセット(HSPで dupptr / lpoke / wpoke 等に使用)。
フィールド
| フィールド | 型 | サイズ | x64 | x86 | 説明 |
|---|---|---|---|---|---|
| lpszPath | WCHAR | 520 | +0 | +0 | URLに対応する物理パスを格納するWCHAR配列(Unicode)である。 |
| dwFlags | DWORD | 4 | +520 | +520 | マッピングのアクセスフラグを示すDWORDである。 |
| cchMatchingPath | DWORD | 4 | +524 | +524 | 一致した物理パスの文字数を示すDWORDである。 |
| cchMatchingURL | DWORD | 4 | +528 | +528 | 一致したURLの文字数を示すDWORDである。 |
各言語での定義
#include <windows.h>
// HSE_UNICODE_URL_MAPEX_INFO (x64 532 / x86 532 バイト)
typedef struct HSE_UNICODE_URL_MAPEX_INFO {
WCHAR lpszPath[260];
DWORD dwFlags;
DWORD cchMatchingPath;
DWORD cchMatchingURL;
} HSE_UNICODE_URL_MAPEX_INFO;using System;
using System.Runtime.InteropServices;
[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
public struct HSE_UNICODE_URL_MAPEX_INFO
{
[MarshalAs(UnmanagedType.ByValTStr, SizeConst = 260)] public string lpszPath;
public uint dwFlags;
public uint cchMatchingPath;
public uint cchMatchingURL;
}Imports System.Runtime.InteropServices
<StructLayout(LayoutKind.Sequential, CharSet:=CharSet.Unicode)>
Public Structure HSE_UNICODE_URL_MAPEX_INFO
<MarshalAs(UnmanagedType.ByValTStr, SizeConst:=260)> Public lpszPath As String
Public dwFlags As UInteger
Public cchMatchingPath As UInteger
Public cchMatchingURL As UInteger
End Structureimport ctypes
from ctypes import wintypes
class HSE_UNICODE_URL_MAPEX_INFO(ctypes.Structure):
_fields_ = [
("lpszPath", ctypes.c_wchar * 260),
("dwFlags", wintypes.DWORD),
("cchMatchingPath", wintypes.DWORD),
("cchMatchingURL", wintypes.DWORD),
]#[repr(C)]
pub struct HSE_UNICODE_URL_MAPEX_INFO {
pub lpszPath: [u16; 260],
pub dwFlags: u32,
pub cchMatchingPath: u32,
pub cchMatchingURL: u32,
}import "golang.org/x/sys/windows"
type HSE_UNICODE_URL_MAPEX_INFO struct {
lpszPath [260]uint16
dwFlags uint32
cchMatchingPath uint32
cchMatchingURL uint32
}type
HSE_UNICODE_URL_MAPEX_INFO = record
lpszPath: array[0..259] of WideChar;
dwFlags: DWORD;
cchMatchingPath: DWORD;
cchMatchingURL: DWORD;
end;const HSE_UNICODE_URL_MAPEX_INFO = extern struct {
lpszPath: [260]u16,
dwFlags: u32,
cchMatchingPath: u32,
cchMatchingURL: u32,
};type
HSE_UNICODE_URL_MAPEX_INFO {.bycopy.} = object
lpszPath: array[260, uint16]
dwFlags: uint32
cchMatchingPath: uint32
cchMatchingURL: uint32struct HSE_UNICODE_URL_MAPEX_INFO
{
wchar[260] lpszPath;
uint dwFlags;
uint cchMatchingPath;
uint cchMatchingURL;
}HSP用 定義
HSP3.7/3.8 は構造体機能が無いため4byte整数配列(dim)+peek/poke で操作(32/64bitでサイズ・位置が異なる場合はタブで分割)。IronHSP は NSTRUCT(#defstruct/stdim/->)で32/64bit共通。
; HSP3.7/3.8 は構造体機能が無いため、4byte整数の配列変数で操作します。(x64 レイアウト)
; HSE_UNICODE_URL_MAPEX_INFO サイズ: 532 バイト(x64)
dim st, 133 ; 4byte整数×133(構造体サイズ 532 / 4 切り上げ)
; lpszPath : WCHAR (+0, 520byte) varptr(st)+0 を基点に操作(520byte:入れ子/配列)
; dwFlags : DWORD (+520, 4byte) st.130 = 値 / 値 = st.130 (lpoke/lpeek も可)
; cchMatchingPath : DWORD (+524, 4byte) st.131 = 値 / 値 = st.131 (lpoke/lpeek も可)
; cchMatchingURL : DWORD (+528, 4byte) st.132 = 値 / 値 = st.132 (lpoke/lpeek も可)
; ※4byte境界の整数は添字 st.N(N=オフセット/4)で読み書き可。それ以外は peek/poke 系を使用。; IronHSP は NSTRUCT(構造体)をサポート。32bit/64bit どちらでも同じコードで動作します。
#defstruct global HSE_UNICODE_URL_MAPEX_INFO
#field wchar lpszPath 260
#field int dwFlags
#field int cchMatchingPath
#field int cchMatchingURL
#endstruct
stdim st, HSE_UNICODE_URL_MAPEX_INFO ; NSTRUCT 変数を確保
st->dwFlags = 100
mes "dwFlags=" + st->dwFlags