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