# Example

> Class yii\template\Example.

[API reference](/docs/api/index.md) › [Extension template](/docs/extensions/template/reference/index.md) › Example

| final class | `yii\template\Example` |
| --- | --- |
| Source | [`src/Example.php`](https://github.com/yii2-extensions/template/blob/main/src/Example.php#L7) |

## Methods

| Method | Description | Defined by |
| --- | --- | --- |
| [`getExample()`](#method-getExample) |  | `Example` |

## Method details

### getExample() <span id="method-getExample"></span>

```php
public function getExample(bool $legacy = false): bool
```

**Parameters**

| Parameter | Type | Description |
| --- | --- | --- |
| `$legacy` | `bool` |  |

**Returns**

`bool`