<!-- 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; [base](./case-definition-dsl.matchers.base.md) &gt; [AnyMatcherWithExample](./case-definition-dsl.matchers.base.anymatcherwithexample.md) &gt; [(constructor)](./case-definition-dsl.matchers.base.anymatcherwithexample._constructor_.md)

## matchers.base.AnyMatcherWithExample.(constructor)

The base class for all Test Equivalence Matchers that have examples provided. Extend this if your matcher knows what the example will be. Otherwise, use `matchers.AnyMatcher`

Only use a type prefixed with `_case:` if you wish to create a special case for a matching behaviour that is already provided by a core ContractCase matcher.

**Signature:**

```typescript
constructor(matcherType: string, example: unknown);
```

## Parameters

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

Parameter

</th><th>

Type

</th><th>

Description

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

matcherType

</td><td>

string

</td><td>

The type string for this matcher (see [Extending ContractCase](https://case.contract-testing.io/docs/reference/plugin-framework) for a description of these strings).

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

example

</td><td>

unknown

</td><td>

The data that will be used as the example for this matcher

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