nuget server logo nuget api documents
↑

API Docs / Microsoft.VisualBasic.Runtime / IntPtr

IntPtr

Full name Microsoft.VisualBasic.Emit.Marshal.IntPtr`1 Assembly Microsoft.VisualBasic.Runtime Members 11

Unmanaged Memory pointer in VisualBasic language.(内存指针)

00 Remarks

只不过这个对象是封装了写内存操作的

Type Parameters
NameDescription
T

01 Syntax

Microsoft.VisualBasic.Emit.Marshal.IntPtr`1

02 Methods

NameOverloadsSummary
.ctor 2 方便进行数组操作的
Write 2 Unsafe write memory
op_Addition 1 Move forward the current position of this memory pointer ptr by a specific step d
op_Subtraction 1 Move backward the current position of this memory pointer ptr by a specific step d
Dispose 1 write memory and release the memory pointer
Read 1
ToString 1

03 Properties

NameOverloadsSummary
Scan0 1 The position in the memory region of the first byte for read.

04 Fields

NameOverloadsSummary
__writeMemory 1 vbnet Public Delegate Sub UnsafeWrite(Of T)(destination As T(), startIndex As Integer, source As System.IntPtr, length As Integer)

05 Members

method .ctor overload 2 #
#ctor(IntPtr, Int32, UnsafeCopys(Of `0), UnsafeWrite(Of `0))

Make data unsafe copy in this constructor function

Parameters
NameTypeDescription
pIntPtr

-

chunkSizeInt32

-

unsafeCopysUnsafeCopys(Of `0)
 Public Sub UnsafeCopys(Of T)(source As IntPtr, destination As T(), startIndex As Int32, length As Int32)
unsafeWriteUnsafeWrite(Of `0)
 Public Sub UnsafeWrite(Of T)(destination As T(), startIndex As Int32, source As IntPtr, length As Int32)
method .ctor #
#ctor(`0(), Nullable(Of IntPtr))

方便进行数组操作的

Parameters
NameTypeDescription
raw`0()

-

pNullable(Of IntPtr)

-

method Write #
Write

Unsafe write memory

method Write overload 2 #
Write(IntPtr)

Please be carefull by using this method, if the memory region size of IntPtr.Scan0 in this memory pointer is larger than des, this method will caused exception.

Parameters
NameTypeDescription
desIntPtr

-

method op_Addition #
op_Addition(IntPtr(Of `0), Int32)

Move forward the current position of this memory pointer ptr by a specific step d

Parameters
NameTypeDescription
ptrIntPtr(Of `0)

-

dInt32

-

method op_Subtraction #
op_Subtraction(IntPtr(Of `0), Int32)

Move backward the current position of this memory pointer ptr by a specific step d

Parameters
NameTypeDescription
ptrIntPtr(Of `0)

-

dInt32

-

method Dispose #
Dispose

write memory and release the memory pointer

property Scan0 #
Scan0

The position in the memory region of the first byte for read.

Returns

(第一个位置)

field __writeMemory #
__writeMemory
 Public Delegate Sub UnsafeWrite(Of T)(destination As T(), startIndex As Integer, source As System.IntPtr, length As Integer)
method Read #
Read()
method ToString #
ToString()