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

## matchers.convenience.StateVariable.(constructor)

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.

**Signature:**

```typescript
constructor(name: string);
```

## 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 of the variable

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