Unosquare
    Show / Hide Table of Contents

    Class WebServerOptionsExtensions

    Provides extension methods for WebServerOptions.

    Inheritance
    Object
    WebServerOptionsExtensions
    Inherited Members
    Object.ToString()
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Namespace: EmbedIO
    Syntax
    public static class WebServerOptionsExtensions

    Methods

    WithAutoLoadCertificate(WebServerOptions)

    Instructs a WebServerOptions instance to automatically load the X.509 certificate.

    Declaration
    public static WebServerOptions WithAutoLoadCertificate(this WebServerOptions this)
    Parameters
    Type Name Description
    WebServerOptions this

    The WebServerOptions on which this method is called.

    Returns
    Type Description
    WebServerOptions

    this with its AutoLoadCertificate property set to true.

    WithAutoLoadCertificate(WebServerOptions, Boolean)

    Sets a value indicating whether to automatically load the X.509 certificate.

    Declaration
    public static WebServerOptions WithAutoLoadCertificate(this WebServerOptions this, bool value)
    Parameters
    Type Name Description
    WebServerOptions this

    The WebServerOptions on which this method is called.

    Boolean value

    If true, automatically load the X.509 certificate.

    Returns
    Type Description
    WebServerOptions

    this with its AutoLoadCertificate property set to value.

    WithAutoRegisterCertificate(WebServerOptions)

    Instructs a WebServerOptions instance to automatically bind the X.509 certificate to the port used for HTTPS.

    Declaration
    public static WebServerOptions WithAutoRegisterCertificate(this WebServerOptions this)
    Parameters
    Type Name Description
    WebServerOptions this

    The WebServerOptions on which this method is called.

    Returns
    Type Description
    WebServerOptions

    this with its AutoRegisterCertificate property set to true.

    WithAutoRegisterCertificate(WebServerOptions, Boolean)

    Sets a value indicating whether to automatically bind the X.509 certificate to the port used for HTTPS.

    Declaration
    public static WebServerOptions WithAutoRegisterCertificate(this WebServerOptions this, bool value)
    Parameters
    Type Name Description
    WebServerOptions this

    The WebServerOptions on which this method is called.

    Boolean value

    If true, automatically bind the X.509 certificate to the port used for HTTPS.

    Returns
    Type Description
    WebServerOptions

    this with its AutoRegisterCertificate property set to value.

    WithCertificate(WebServerOptions, X509Certificate2)

    Sets the X.509 certificate to use for SSL connections.

    Declaration
    public static WebServerOptions WithCertificate(this WebServerOptions this, X509Certificate2 value)
    Parameters
    Type Name Description
    WebServerOptions this

    The WebServerOptions on which this method is called.

    X509Certificate2 value

    The X.509 certificate to use for SSL connections.

    Returns
    Type Description
    WebServerOptions

    this with its Certificate property set to value.

    WithCertificateThumbprint(WebServerOptions, String)

    Sets the thumbprint of the X.509 certificate to use for SSL connections.

    Declaration
    public static WebServerOptions WithCertificateThumbprint(this WebServerOptions this, string value)
    Parameters
    Type Name Description
    WebServerOptions this

    The WebServerOptions on which this method is called.

    String value

    The thumbprint of the X.509 certificate to use for SSL connections.

    Returns
    Type Description
    WebServerOptions

    this with its CertificateThumbprint property set to value.

    WithEmbedIOHttpListener(WebServerOptions)

    Sets the type of HTTP listener to EmbedIO.

    Declaration
    public static WebServerOptions WithEmbedIOHttpListener(this WebServerOptions this)
    Parameters
    Type Name Description
    WebServerOptions this

    The WebServerOptions on which this method is called.

    Returns
    Type Description
    WebServerOptions

    this with its Mode property set to EmbedIO.

    WithMicrosoftHttpListener(WebServerOptions)

    Sets the type of HTTP listener to Microsoft.

    Declaration
    public static WebServerOptions WithMicrosoftHttpListener(this WebServerOptions this)
    Parameters
    Type Name Description
    WebServerOptions this

    The WebServerOptions on which this method is called.

    Returns
    Type Description
    WebServerOptions

    this with its Mode property set to Microsoft.

    WithMode(WebServerOptions, HttpListenerMode)

    Sets the type of HTTP listener.

    Declaration
    public static WebServerOptions WithMode(this WebServerOptions this, HttpListenerMode value)
    Parameters
    Type Name Description
    WebServerOptions this

    The WebServerOptions on which this method is called.

    HttpListenerMode value

    The type of HTTP listener.

    Returns
    Type Description
    WebServerOptions

    this with its Mode property set to value.

    WithoutAutoLoadCertificate(WebServerOptions)

    Instructs a WebServerOptions instance to not load the X.509 certificate automatically .

    Declaration
    public static WebServerOptions WithoutAutoLoadCertificate(this WebServerOptions this)
    Parameters
    Type Name Description
    WebServerOptions this

    The WebServerOptions on which this method is called.

    Returns
    Type Description
    WebServerOptions

    this with its AutoLoadCertificate property set to false.

    WithoutAutoRegisterCertificate(WebServerOptions)

    Instructs a WebServerOptions instance to not bind the X.509 certificate automatically.

    Declaration
    public static WebServerOptions WithoutAutoRegisterCertificate(this WebServerOptions this)
    Parameters
    Type Name Description
    WebServerOptions this

    The WebServerOptions on which this method is called.

    Returns
    Type Description
    WebServerOptions

    this with its AutoRegisterCertificate property set to false.

    WithStore(WebServerOptions, StoreName, StoreLocation)

    Sets the name and location of the X.509 certificate store where to load the certificate from.

    Declaration
    public static WebServerOptions WithStore(this WebServerOptions this, StoreName name, StoreLocation location)
    Parameters
    Type Name Description
    WebServerOptions this

    The WebServerOptions on which this method is called.

    StoreName name

    One of the constants.

    StoreLocation location

    One of the constants.

    Returns
    Type Description
    WebServerOptions

    this with its StoreName property set to name and its StoreLocation property set to location.

    WithStoreLocation(WebServerOptions, StoreLocation)

    Sets a value indicating the location of the X.509 certificate store where to load the certificate from.

    Declaration
    public static WebServerOptions WithStoreLocation(this WebServerOptions this, StoreLocation value)
    Parameters
    Type Name Description
    WebServerOptions this

    The WebServerOptions on which this method is called.

    StoreLocation value

    One of the constants.

    Returns
    Type Description
    WebServerOptions

    this with its StoreLocation property set to value.

    WithStoreName(WebServerOptions, StoreName)

    Sets a value indicating the X.509 certificate store where to load the certificate from.

    Declaration
    public static WebServerOptions WithStoreName(this WebServerOptions this, StoreName value)
    Parameters
    Type Name Description
    WebServerOptions this

    The WebServerOptions on which this method is called.

    StoreName value

    One of the constants.

    Returns
    Type Description
    WebServerOptions

    this with its StoreName property set to value.

    WithUrlPrefix(WebServerOptions, String)

    Adds a URL prefix.

    Declaration
    public static WebServerOptions WithUrlPrefix(this WebServerOptions this, string prefix)
    Parameters
    Type Name Description
    WebServerOptions this

    The WebServerOptions on which this method is called.

    String prefix

    The URL prefix.

    Returns
    Type Description
    WebServerOptions

    this with prefix added.

    WithUrlPrefixes(WebServerOptions, IEnumerable<String>)

    Adds zero or more URL prefixes.

    Declaration
    public static WebServerOptions WithUrlPrefixes(this WebServerOptions this, IEnumerable<string> urlPrefixes)
    Parameters
    Type Name Description
    WebServerOptions this

    The WebServerOptions on which this method is called.

    IEnumerable<String> urlPrefixes

    An enumeration of URL prefixes to add.

    Returns
    Type Description
    WebServerOptions

    this with every non-null element of urlPrefixes added.

    WithUrlPrefixes(WebServerOptions, String[])

    Adds zero or more URL prefixes.

    Declaration
    public static WebServerOptions WithUrlPrefixes(this WebServerOptions this, params string[] urlPrefixes)
    Parameters
    Type Name Description
    WebServerOptions this

    The WebServerOptions on which this method is called.

    String[] urlPrefixes

    An array of URL prefixes to add.

    Returns
    Type Description
    WebServerOptions

    this with every non-null element of urlPrefixes added.

    Comments

    Back to top Copyright © 2017-2019 Unosquare