Share via


Asn1Tag.TryDecode(ReadOnlySpan<Byte>, Asn1Tag, Int32) Metodo

Definizione

Prova a leggere un tag con codifica BER che inizia in corrispondenza di source.

public:
 static bool TryDecode(ReadOnlySpan<System::Byte> source, [Runtime::InteropServices::Out] System::Formats::Asn1::Asn1Tag % tag, [Runtime::InteropServices::Out] int % bytesConsumed);
public static bool TryDecode (ReadOnlySpan<byte> source, out System.Formats.Asn1.Asn1Tag tag, out int bytesConsumed);
static member TryDecode : ReadOnlySpan<byte> * Asn1Tag * int -> bool
Public Shared Function TryDecode (source As ReadOnlySpan(Of Byte), ByRef tag As Asn1Tag, ByRef bytesConsumed As Integer) As Boolean

Parametri

source
ReadOnlySpan<Byte>

Sequenza di byte di sola lettura il cui inizio è un tag con codifica BER.

tag
Asn1Tag

Tag decodificato.

bytesConsumed
Int32

Al termine di questo metodo, contiene il numero di byte che hanno contribuito al tag codificato oppure 0 in caso di errore. Questo parametro viene trattato come non inizializzato.

Restituisce

true se un tag è stato decodificato correttamente; in caso contrario, false.

Si applica a