BinaryPrimitives.TryReadUInt32BigEndian(ReadOnlySpan<Byte>, UInt32) 方法
定义
重要
此 API 不符合 CLS。
public:
static bool TryReadUInt32BigEndian(ReadOnlySpan<System::Byte> source, [Runtime::InteropServices::Out] System::UInt32 % value);
[System.CLSCompliant(false)]
public static bool TryReadUInt32BigEndian (ReadOnlySpan<byte> source, out uint value);
[<System.CLSCompliant(false)>]
static member TryReadUInt32BigEndian : ReadOnlySpan<byte> * uint32 -> bool
Public Shared Function TryReadUInt32BigEndian (source As ReadOnlySpan(Of Byte), ByRef value As UInteger) As Boolean
参数
- source
- ReadOnlySpan<Byte>
要读取的字节只读范围。The read-only span of bytes to read.
- value
- UInt32
此方法返回时,值作为大字节序从字节只读范围中读取。When this method returns, the value read out of the read-only span of bytes, as big endian.
返回
如果范围足够大,可以包含 UInt32,则为 true;否则为 false。true if the span is large enough to contain a UInt32; otherwise, false.
- 属性
注解
从跨度的开头精确读取4个字节。Reads exactly 4 bytes from the beginning of the span.