ContentInfo.GetContentType 方法

定義

多載

GetContentType(Byte[])

擷取已編碼 CMS ContentInfo 訊息的外部內容類型。

GetContentType(ReadOnlySpan<Byte>)

擷取已編碼 CMS ContentInfo 訊息的外部內容類型。

GetContentType(Byte[])

擷取已編碼 CMS ContentInfo 訊息的外部內容類型。

public:
 static System::Security::Cryptography::Oid ^ GetContentType(cli::array <System::Byte> ^ encodedMessage);
public static System.Security.Cryptography.Oid GetContentType (byte[] encodedMessage);
static member GetContentType : byte[] -> System.Security.Cryptography.Oid
Public Shared Function GetContentType (encodedMessage As Byte()) As Oid

參數

encodedMessage
Byte[]

位元組值陣列,表示編碼 CMS ContentInfo 訊息 (外部內容類型的擷取來源)。

傳回

Oid

指定編碼 CMS ContentInfo 訊息的外部內容類型。

例外狀況

encodedMessagenull

encodedMessage 無法解碼為有效的 CMS ContentInfo 值。

適用於

GetContentType(ReadOnlySpan<Byte>)

擷取已編碼 CMS ContentInfo 訊息的外部內容類型。

public:
 static System::Security::Cryptography::Oid ^ GetContentType(ReadOnlySpan<System::Byte> encodedMessage);
public static System.Security.Cryptography.Oid GetContentType (ReadOnlySpan<byte> encodedMessage);
static member GetContentType : ReadOnlySpan<byte> -> System.Security.Cryptography.Oid
Public Shared Function GetContentType (encodedMessage As ReadOnlySpan(Of Byte)) As Oid

參數

encodedMessage
ReadOnlySpan<Byte>

位元組值陣列,表示編碼 CMS ContentInfo 訊息 (外部內容類型的擷取來源)。

傳回

Oid

指定編碼 CMS ContentInfo 訊息的外部內容類型。

例外狀況

encodedMessage 無法解碼為有效的 CMS ContentInfo 值。

適用於