Unosquare
    Show / Hide Table of Contents

    Interface IMimeTypeCustomizer

    Represents an object that can set information about specific MIME types and media ranges, to be later retrieved via an IMimeTypeProvider interface.

    Inherited Members
    IMimeTypeProvider.GetMimeType(String)
    IMimeTypeProvider.TryDetermineCompression(String, Boolean)
    Namespace: EmbedIO
    Syntax
    public interface IMimeTypeCustomizer : IMimeTypeProvider

    Methods

    AddCustomMimeType(String, String)

    Adds a custom association between a file extension and a MIME type.

    Declaration
    void AddCustomMimeType(string extension, string mimeType)
    Parameters
    Type Name Description
    String extension

    The file extension to associate to mimeType.

    String mimeType

    The MIME type to associate to extension.

    PreferCompression(String, Boolean)

    Indicates whether to prefer compression when negotiating content encoding for a response with the specified content type, or whose content type is in the specified media range.

    Declaration
    void PreferCompression(string mimeType, bool preferCompression)
    Parameters
    Type Name Description
    String mimeType

    The MIME type or media range.

    Boolean preferCompression

    true to prefer compression; otherwise, false.

    See Also

    IMimeTypeProvider

    Comments

    Back to top Copyright © 2017-2019 Unosquare