> ## Documentation Index
> Fetch the complete documentation index at: https://easyaf.nimbleapps.cloud/llms.txt
> Use this file to discover all available pages before exploring further.

# MimeTypeMap

> Class MimeTypeMap.

## Definition

**Assembly:** CloudNimble.Breakdance.Assemblies.dll

**Namespace:** MimeTypes

**Inheritance:** System.Object

## Syntax

```csharp theme={"dark"}
MimeTypes.MimeTypeMap
```

## Summary

Class MimeTypeMap.

## Methods

### &#x20;GetExtension

Gets the extension from the provided MINE type.

#### Syntax

```csharp theme={"dark"}
public static string GetExtension(string mimeType, bool throwErrorIfNotFound = true)
```

#### Parameters

| Name | Type | Description |
| - | - | - |
| `mimeType` | `string` | Type of the MIME. |
| `throwErrorIfNotFound` | `bool` | if set to `true`, throws error if extension's not found. |

#### Returns

Type: `string`
The extension.

#### Exceptions

| Exception | Description |
| - | - |
| `ArgumentNullException` | |
| `ArgumentException` | |

### &#x20;GetMimeType

Gets the type of the MIME from the provided string.

#### Syntax

```csharp theme={"dark"}
public static string GetMimeType(string str)
```

#### Parameters

| Name | Type | Description |
| - | - | - |
| `str` | `string` | The filename or extension. |

#### Returns

Type: `string`
The MIME type.

#### Exceptions

| Exception | Description |
| - | - |
| `ArgumentNullException` | |

### &#x20;TryGetMimeType

Tries to get the type of the MIME from the provided string.

#### Syntax

```csharp theme={"dark"}
public static bool TryGetMimeType(string str, out string mimeType)
```

#### Parameters

| Name | Type | Description |
| - | - | - |
| `str` | `string` | The filename or extension. |
| `mimeType` | `string` | The variable to store the MIME type. |

#### Returns

Type: `bool`
The MIME type.

#### Exceptions

| Exception | Description |
| - | - |
| `ArgumentNullException` | |


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.