共用方式為


X509CertificateValidator 建構函式

定義

初始化 X509CertificateValidator 類別的新執行個體。

protected:
 X509CertificateValidator();
protected X509CertificateValidator ();
Protected Sub New ()

範例

public MyX509CertificateValidator(string allowedIssuerName)
{
    if (allowedIssuerName == null)
    {
        throw new ArgumentNullException("allowedIssuerName");
    }

    this.allowedIssuerName = allowedIssuerName;
}
Public Sub New(ByVal allowedIssuerName As String)
    If allowedIssuerName Is Nothing Then
        Throw New ArgumentNullException("allowedIssuerName")
    End If

    Me.allowedIssuerName = allowedIssuerName

End Sub

備註

根據預設,這個建構函式 (Constructor) 不會初始化任何屬性。

適用於