> ## 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.

# DotHttpFileParser

> Parses .http files into structured [DotHttpFile](/breakdance/api-reference/CloudNimble/Breakdance/DotHttp/Models/DotHttpFile) objects.

## Definition

**Assembly:** CloudNimble.Breakdance.DotHttp.dll

**Namespace:** CloudNimble.Breakdance.DotHttp

**Inheritance:** System.Object

## Syntax

```csharp theme={"dark"}
CloudNimble.Breakdance.DotHttp.DotHttpFileParser
```

## Summary

Parses .http files into structured [DotHttpFile](https://easyaf.nimbleapps.cloud/breakdance/api-reference/CloudNimble/Breakdance/DotHttp/Models/DotHttpFile.md) objects.

## Remarks

Implements the full .http file specification as documented at
[https://learn.microsoft.com/en-us/aspnet/core/test/http-files](https://learn.microsoft.com/en-us/aspnet/core/test/http-files)
including variables, request chaining, file references, and multi-line headers.

## Examples

```csharp theme={"dark"}
var parser = new DotHttpFileParser();
var file = parser.Parse(httpFileContent, "api.http");

// Check for parse diagnostics
foreach (var diagnostic in file.Diagnostics)
{
    Console.WriteLine($"{diagnostic.Location}: {diagnostic.GetMessage()}");
}

// Process requests
foreach (var request in file.Requests)
{
    Console.WriteLine($"{request.Method} {request.Url}");
}
```

## Constructors

### &#x20;.ctor

#### Syntax

```csharp theme={"dark"}
public DotHttpFileParser()
```

### &#x20;.ctor Inherited

> [!NOTE]
>
> Inherited from `object`

#### Syntax

```csharp theme={"dark"}
public Object()
```

## Methods

### &#x20;Equals Inherited Virtual

> [!NOTE]
>
> Inherited from `object`

#### Syntax

```csharp theme={"dark"}
public virtual bool Equals(object obj)
```

#### Parameters

| Name | Type | Description |
| - | - | - |
| `obj` | `object?` | - |

#### Returns

Type: `bool`

### &#x20;Equals Inherited

> [!NOTE]
>
> Inherited from `object`

#### Syntax

```csharp theme={"dark"}
public static bool Equals(object objA, object objB)
```

#### Parameters

| Name | Type | Description |
| - | - | - |
| `objA` | `object?` | - |
| `objB` | `object?` | - |

#### Returns

Type: `bool`

### &#x20;GetHashCode Inherited Virtual

> [!NOTE]
>
> Inherited from `object`

#### Syntax

```csharp theme={"dark"}
public virtual int GetHashCode()
```

#### Returns

Type: `int`

### &#x20;GetType Inherited

> [!NOTE]
>
> Inherited from `object`

#### Syntax

```csharp theme={"dark"}
public System.Type GetType()
```

#### Returns

Type: `System.Type`

### &#x20;MemberwiseClone Inherited

> [!NOTE]
>
> Inherited from `object`

#### Syntax

```csharp theme={"dark"}
protected internal object MemberwiseClone()
```

#### Returns

Type: `object`

### &#x20;Parse

Parses a .http file content into a structured model.

#### Syntax

```csharp theme={"dark"}
public CloudNimble.Breakdance.DotHttp.Models.DotHttpFile Parse(string content, string filePath)
```

#### Parameters

| Name | Type | Description |
| - | - | - |
| `content` | `string` | The content of the .http file. |
| `filePath` | `string` | The file path for reference in the model. |

#### Returns

Type: `CloudNimble.Breakdance.DotHttp.Models.DotHttpFile`
A [DotHttpFile](https://easyaf.nimbleapps.cloud/breakdance/api-reference/CloudNimble/Breakdance/DotHttp/Models/DotHttpFile.md) containing the parsed requests, variables, and any parse errors.

#### Exceptions

| Exception | Description |
| - | - |
| `ArgumentNullException` | Thrown when *filePath* is null. |

#### Examples

```csharp theme={"dark"}
var parser = new DotHttpFileParser();
var content = File.ReadAllText("api.http");
var file = parser.Parse(content, "api.http");
```

### &#x20;ReferenceEquals Inherited

> [!NOTE]
>
> Inherited from `object`

#### Syntax

```csharp theme={"dark"}
public static bool ReferenceEquals(object objA, object objB)
```

#### Parameters

| Name | Type | Description |
| - | - | - |
| `objA` | `object?` | - |
| `objB` | `object?` | - |

#### Returns

Type: `bool`

### &#x20;ToString Inherited Virtual

> [!NOTE]
>
> Inherited from `object`

#### Syntax

```csharp theme={"dark"}
public virtual string ToString()
```

#### Returns

Type: `string?`


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