<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [@contract-case/case-definition-dsl](./case-definition-dsl.md) &gt; [matchers](./case-definition-dsl.matchers.md) &gt; [convenience](./case-definition-dsl.matchers.convenience.md) &gt; [NamedMatch](./case-definition-dsl.matchers.convenience.namedmatch.md) &gt; [(constructor)](./case-definition-dsl.matchers.convenience.namedmatch._constructor_.md)

## matchers.convenience.NamedMatch.(constructor)

Saves the matcher below it with a unique name that can be used with lookups in tests after this one. Lookups can be made with [matchers.convenience.ReferenceMatch](./case-definition-dsl.matchers.convenience.referencematch.md)<!-- -->.

**Signature:**

```typescript
constructor(name: string, child: AnyMatcherOrData);
```

## Parameters

<table><thead><tr><th>

Parameter

</th><th>

Type

</th><th>

Description

</th></tr></thead>
<tbody><tr><td>

name

</td><td>

string

</td><td>

The name you can use to lookup this matcher later

</td></tr>
<tr><td>

child

</td><td>

AnyMatcherOrData

</td><td>

The content of this named match. If omitted or undefined, the content will be looked up in a previously named match

</td></tr>
</tbody></table>
