UIntPtr 构造函数
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
初始化 的新 UIntPtr实例。
重载
| 名称 | 说明 |
|---|---|
| UIntPtr(UInt32) |
使用指定的 32 位无符号整数初始化结构的新实例 UIntPtr 。 |
| UIntPtr(UInt64) |
初始化使用指定的 64 位无符号整数的新实例 UIntPtr 。 |
| UIntPtr(Void*) |
初始化使用指向未指定类型的指定指针的新实例 UIntPtr 。 |
UIntPtr(UInt32)
- Source:
- UIntPtr.cs
- Source:
- UIntPtr.cs
- Source:
- UIntPtr.cs
- Source:
- UIntPtr.cs
- Source:
- UIntPtr.cs
使用指定的 32 位无符号整数初始化结构的新实例 UIntPtr 。
public:
UIntPtr(System::UInt32 value);
public UIntPtr(uint value);
new unativeint : uint32 -> unativeint
Public Sub New (value As UInteger)
参数
- value
- UInt32
32 位无符号整数。
适用于
UIntPtr(UInt64)
- Source:
- UIntPtr.cs
- Source:
- UIntPtr.cs
- Source:
- UIntPtr.cs
- Source:
- UIntPtr.cs
- Source:
- UIntPtr.cs
初始化使用指定的 64 位无符号整数的新实例 UIntPtr 。
public:
UIntPtr(System::UInt64 value);
public UIntPtr(ulong value);
new unativeint : uint64 -> unativeint
Public Sub New (value As ULong)
参数
- value
- UInt64
64 位无符号整数。
例外
在 32 位进程中,value太大而无法表示为 。UIntPtr
注解
仅当需要比执行进程支持的位数更多的位时 value ,才会引发异常。
适用于
UIntPtr(Void*)
- Source:
- UIntPtr.cs
- Source:
- UIntPtr.cs
- Source:
- UIntPtr.cs
- Source:
- UIntPtr.cs
- Source:
- UIntPtr.cs
重要
此 API 不符合 CLS。
初始化使用指向未指定类型的指定指针的新实例 UIntPtr 。
public:
UIntPtr(void* value);
[System.CLSCompliant(false)]
[System.Security.SecurityCritical]
public UIntPtr(void* value);
public UIntPtr(void* value);
[System.CLSCompliant(false)]
public UIntPtr(void* value);
[<System.CLSCompliant(false)>]
[<System.Security.SecurityCritical>]
new unativeint : nativeptr<unit> -> unativeint
new unativeint : nativeptr<unit> -> unativeint
[<System.CLSCompliant(false)>]
new unativeint : nativeptr<unit> -> unativeint
参数
- value
- Void*
指向未指定类型的指针。
- 属性