---
url: /api/kiln/interfaces/System.md
---
[Kiln API](../../index.md) / [kiln](../index.md) / System

# Interface: System

A query plus a function. Schedule it with `app.add(Phase, system)`.

## Properties

| Property | Modifier | Type |
| ------ | ------ | ------ |
|  `[$system]` | `readonly` | `true` |
|  `id` | `readonly` | `number` |
|  `form` | `readonly` | `SystemForm` |
|  `query` | `readonly` | [`QueryList`](../type-aliases/QueryList.md) | `NamedQueries` | `null` |
|  `fn` | `readonly` | (...`args`) => `void` |
|  `options` | `readonly` | [`SystemOptions`](SystemOptions.md) |
|  `name` | `readonly` | `string` |

## Methods

### named()

```ts
named(name): this;
```

Sets the name used in errors and `kiln describe`.

#### Parameters

| Parameter | Type |
| ------ | ------ |
| `name` | `string` |

#### Returns

`this`

***

### after()

```ts
after(...systems): SystemEntry;
```

Runs this system after the given systems in the same phase.

#### Parameters

| Parameter | Type |
| ------ | ------ |
| ...`systems` | `System`\[] |

#### Returns

[`SystemEntry`](SystemEntry.md)

***

### before()

```ts
before(...systems): SystemEntry;
```

Runs this system before the given systems in the same phase.

#### Parameters

| Parameter | Type |
| ------ | ------ |
| ...`systems` | `System`\[] |

#### Returns

[`SystemEntry`](SystemEntry.md)
