# DiffOp

> Represents the operation applied to a single line of an edit script produced by PHPForge\Diff\DifferInterface.

[API reference](/docs/api/index.md) › [Diff](/docs/extensions/diff/reference/index.md) › DiffOp

| enum | `PHPForge\Diff\DiffOp` |
| --- | --- |
| Source | [`src/DiffOp.php`](https://github.com/php-forge/diff/blob/main/src/DiffOp.php#L10) |

Represents the operation applied to a single line of an edit script produced by [`DifferInterface`](/docs/extensions/diff/reference/differinterface/index.md).

## Cases

| Case | Value | Description |
| --- | --- | --- |
| <span id="case-Add"></span>`Add` |  | The line is present only in the new input and is added. |
| <span id="case-Context"></span>`Context` |  | The line is present in both inputs and is kept. |
| <span id="case-Remove"></span>`Remove` |  | The line is present only in the old input and is removed. |