> For the complete documentation index, see [llms.txt](https://dustinsimon.gitbook.io/encapsulation/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://dustinsimon.gitbook.io/encapsulation/changelog/changelog.md).

# Changelog

<details>

<summary>v2.0 (PHP 8)</summary>

* PHP 8.1 is required
* Only inner objects of AbstractEncapsulation will be deep-cloned
* Change return type of Container::search to `string|int|false`
* Fixed typos in documentation

</details>

<details>

<summary>v1.2.2</summary>

* Fix: Type of previous exception parameter

</details>

<details>

<summary>v1.2.1</summary>

* Add more documentation
* Add IteratorTrait
* Add JsonSerializableTrait
* Fix: ImmutableContainer was mutable via splice()-method
* Fix: Immutable encapsulations were not clonable
* Fix: IntersectionCalculation::getDifference was intended to be static

</details>

<details>

<summary>v1.2 (Immutable Encapsulations)</summary>

* Add immutable encapsulations
* `AbstractEncapsulation::add` can now add values to an inner container

</details>

<details>

<summary>v1.1.1</summary>

* Fix: Object difference with missing field

</details>

<details>

<summary>v1.1 (Intersection Calculation)</summary>

* Encapsulations now need to implement the abstract constructor from `AbstractEncapsulation`
* Add intersection calculation for encapsulations&#x20;
* `ObjectMapping` can no longer be created via constructor
* Objects created from encapsulations like `Container` will be created via `static` instead of `self`

</details>

<details>

<summary>v1.0 (First release)</summary>

* First release
* Create encapsulation package

</details>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://dustinsimon.gitbook.io/encapsulation/changelog/changelog.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
