HtmlForgeX

API Reference

Class

ImageUtilities

Namespace HtmlForgeX.Email
Assembly HtmlForgeX.Email
Modifiers static

Provides utility methods for working with images.

Inheritance

  • Object
  • ImageUtilities

Methods

public static String GetExtensionFromMimeType(String mimeType) #
Returns: String

Gets the file extension from a MIME type.

Parameters

mimeType System.String requiredposition: 0
The MIME type.

Returns

The file extension (including the dot).

public static String GetMimeTypeFromExtension(String extension) #
Returns: String

Gets the MIME type from a file extension.

Parameters

extension System.String requiredposition: 0
The file extension (with or without the dot).

Returns

The MIME type string.

public static String GetMimeTypeFromFile(String filePath) #
Returns: String

Gets the MIME type from a file path.

Parameters

filePath System.String requiredposition: 0
The file path.

Returns

The MIME type string.

public static String GetMimeTypeFromUrl(String url) #
Returns: String

Gets the MIME type from a URL, ignoring query-string and fragment suffixes.

Parameters

url System.String requiredposition: 0
The URL or URL-like path.

Returns

The MIME type string.