<!-- 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)

## matchers.base.AnyMatcherWithExample class

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`

**Signature:**

```typescript
export declare abstract class AnyMatcherWithExample extends AnyMatcher
```

**Extends:** AnyMatcher

## Constructors

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

Constructor

</th><th>

Modifiers

</th><th>

Description

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

[(constructor)(matcherType, example)](./case-definition-dsl.matchers.base.anymatcherwithexample._constructor_.md)

</td><td>

</td><td>

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.

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

## Methods

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

Method

</th><th>

Modifiers

</th><th>

Description

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

[toJSON()](./case-definition-dsl.matchers.base.anymatcherwithexample.tojson.md)

</td><td>

</td><td>

For non-TypeScript implementations (see `AnyMatcher.toJSON`<!-- -->)

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