Skip to main content
Version: 4.1

MimeTypes

Namespace: Wisej.Core

Assembly: Wisej.Framework (4.1.0.0)

Maps document extensions to content MIME types.

public class MimeTypes

Methods

Static member GetMimeType(fileName)

Returns the MIME mapping for the specified file name.

ParameterTypeDescription
fileNameStringThe file name that is used to determine the MIME type.

Returns: String.

Static member IsKnownType(extension)

Returns if the file extension corresponds to a known mime type.

ParameterTypeDescription
extensionStringThe file extension to check.

Returns: Boolean.

Static member SetMimeType(extension, mimeType)

Adds or changes the mime type for the specified file extension.

ParameterTypeDescription
extensionStringThe file extension to add to the mime type list.
mimeTypeStringThe mime type to add to the mime type list.