UnmanagedMemoryAccessor.ReadUInt16(Int64) 方法

定義

重要

此 API 不符合 CLS 規範。

符合 CLS 規範替代方案
System.Int32

從存取子讀取不帶正負號的 16 位元整數。

public:
 System::UInt16 ReadUInt16(long position);
[System.CLSCompliant(false)]
public ushort ReadUInt16 (long position);
[<System.CLSCompliant(false)>]
member this.ReadUInt16 : int64 -> uint16
Public Function ReadUInt16 (position As Long) As UShort

參數

position
Int64

會在此處開始讀取存取子的位元組數。

傳回

已讀取的值。

屬性

例外狀況

position 之後,沒有足夠的位元組可讀取值。

position 小於零或大於這個存取子的容量。

存取子不支援讀取。

存取子已經被處置。

適用於