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

## matchers.convenience namespace

## Classes

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

Class

</th><th>

Description

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

[And](./case-definition-dsl.matchers.convenience.and.md)

</td><td>

Matches all of the provided matchers. Useful for combining restrictions provided by different matchers, or creating new matchers without needing plugins.

For best results, wrap the And matcher in a WithExample matcher.

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

[ChangeLogLevel](./case-definition-dsl.matchers.convenience.changeloglevel.md)

</td><td>

Alters the ContractCase log level below this matcher. Useful for debugging.

This has no effect on matching.

Note that this log level matcher will be saved into the contract, so it will also affect the log level during verification. Usually you will want to remove the use of this matcher before saving the contract.

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

[NamedMatch](./case-definition-dsl.matchers.convenience.namedmatch.md)

</td><td>

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

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

[ReferenceMatch](./case-definition-dsl.matchers.convenience.referencematch.md)

</td><td>

Matches a named matcher created with [matchers.convenience.NamedMatch](./case-definition-dsl.matchers.convenience.namedmatch.md)<!-- -->.

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

[StateVariable](./case-definition-dsl.matchers.convenience.statevariable.md)

</td><td>

Matches the content of a variable that comes from a state. See [state definitions](https://case.contract-testing.io/docs/defining-contracts/state-definitions) and [state handlers](https://case.contract-testing.io/docs/reference/state-handlers) for more details.

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

[WithExample](./case-definition-dsl.matchers.convenience.withexample.md)

</td><td>

Adds an example to the provided matcher. Useful when you have a complicated set of constraints and ContractCase can't figure out what the best example should be.

Note that providing any example will override examples provided further down the tree.

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