Språk

ContentInfo Konstruktorer

Definition

Skapar en instans av ContentInfo klassen.

Överlagringar

Name Description
ContentInfo(Byte[])

Konstruktorn ContentInfo(Byte[]) skapar en instans av ContentInfo klassen med hjälp av en matris med bytevärden som data och en standardobjektidentifierare (OID) som representerar innehållstypen.

ContentInfo(Oid, Byte[])

Konstruktorn ContentInfo(Oid, Byte[]) skapar en instans av ContentInfo klassen med hjälp av den angivna innehållstypen och en matris med bytevärden som data.

ContentInfo(Byte[])

Källa:
ContentInfo.cs
Källa:
ContentInfo.cs
Källa:
ContentInfo.cs
Källa:
ContentInfo.cs
Källa:
ContentInfo.cs
Källa:
ContentInfo.cs
Källa:
ContentInfo.cs
Källa:
ContentInfo.cs

Konstruktorn ContentInfo(Byte[]) skapar en instans av ContentInfo klassen med hjälp av en matris med bytevärden som data och en standardobjektidentifierare (OID) som representerar innehållstypen.

public:
 ContentInfo(cli::array <System::Byte> ^ content);
public ContentInfo(byte[] content);
new System.Security.Cryptography.Pkcs.ContentInfo : byte[] -> System.Security.Cryptography.Pkcs.ContentInfo
Public Sub New (content As Byte())

Parametrar

content
Byte[]

En matris med bytevärden som representerar de data som objektet ska skapas ContentInfo från.

Undantag

En null-referens skickades till en metod som inte accepterar den som ett giltigt argument.

Kommentarer

Klassen ContentInfo har följande standardegenskapsvärden.

Fastighet Standardvärdet
ContentType 1.2.840.113549.1.7.1 (data)

Gäller för

ContentInfo(Oid, Byte[])

Källa:
ContentInfo.cs
Källa:
ContentInfo.cs
Källa:
ContentInfo.cs
Källa:
ContentInfo.cs
Källa:
ContentInfo.cs
Källa:
ContentInfo.cs
Källa:
ContentInfo.cs
Källa:
ContentInfo.cs

Konstruktorn ContentInfo(Oid, Byte[]) skapar en instans av ContentInfo klassen med hjälp av den angivna innehållstypen och en matris med bytevärden som data.

public:
 ContentInfo(System::Security::Cryptography::Oid ^ contentType, cli::array <System::Byte> ^ content);
public ContentInfo(System.Security.Cryptography.Oid contentType, byte[] content);
new System.Security.Cryptography.Pkcs.ContentInfo : System.Security.Cryptography.Oid * byte[] -> System.Security.Cryptography.Pkcs.ContentInfo
Public Sub New (contentType As Oid, content As Byte())

Parametrar

contentType
Oid

Ett Oid objekt som innehåller en object identifier (OID) som anger innehållstypen för innehållet. Detta kan vara data, digestedData, encryptedData, envelopedData, hashedData, signedAndEnvelopedData eller signedData. Mer information finns i Anmärkningar.

content
Byte[]

En matris med bytevärden som representerar de data som objektet ska skapas ContentInfo från.

Undantag

En null-referens skickades till en metod som inte accepterar den som ett giltigt argument.

Kommentarer

Innehållstyperna digestedData och encryptedData, som visas i standarddokumentet CMS/PKCS #7, är inte innehållstyper som kan skapas av den här implementeringen. Dessa innehållstyper kan dock skickas till den här konstruktorn.

Använd följande OID-strängar som argument till ContentInfo(Oid, Byte[]) konstruktorn för att skapa contentType innehållstypsparametern.

contentType innehållstyp OID-sträng
data 1.2.840.113549.1.7.1
digestedData 1.2.840.113549.1.7.5
encryptedData 1.2.840.113549.1.7.6
envelopedData 1.2.840.113549.1.7.3
hashedData 1.2.840.113549.1.7.5
signedAndEnvelopedData 1.2.840.113549.1.7.4
signedData 1.2.840.113549.1.7.2

Gäller för