Valinor/docs/pages
Romain Canon f232cc0636 feat!: introduce constructor for custom date formats
A new constructor can be registered to declare which format(s) are
supported during the mapping of a date object. By default, any valid
timestamp or ATOM-formatted value will be accepted.

```php
(new \CuyZ\Valinor\MapperBuilder())
    // Both COOKIE and ATOM formats will be accepted
    ->registerConstructor(
        new \CuyZ\Valinor\Mapper\Object\DateTimeFormatConstructor(DATE_COOKIE, DATE_ATOM)
    )
    ->mapper()
    ->map(DateTimeInterface::class, 'Monday, 08-Nov-1971 13:37:42 UTC');
```

The previously very opinionated behaviour has been removed, but can be
temporarily used to help with the migration.

```php
(new \CuyZ\Valinor\MapperBuilder())
    ->registerConstructor(
        new \CuyZ\Valinor\Mapper\Object\BackwardCompatibilityDateTimeConstructor()
    )
    ->mapper()
    ->map(DateTimeInterface::class, 'Monday, 08-Nov-1971 13:37:42 UTC');
```
2022-09-01 12:24:24 +02:00
..
img doc: add Open Graph meta tags 2022-06-12 16:37:58 +02:00
mapping feat: introduce attribute DynamicConstructor 2022-08-30 15:15:41 +02:00
other feat!: introduce constructor for custom date formats 2022-09-01 12:24:24 +02:00
stylesheets doc: change some settings and adjust logos 2022-06-10 23:33:28 +02:00
changelog.md release: version 0.13.0 2022-07-31 17:23:28 +02:00
credits.md doc: introduce mkdocs as a static documentation generator 2022-06-10 17:32:07 +02:00
getting-started.md doc: introduce mkdocs as a static documentation generator 2022-06-10 17:32:07 +02:00
index.md doc: remove badges from documentation index 2022-06-11 12:48:35 +02:00
message-customization.md feat: allow to declare parameter for message 2022-07-26 19:23:44 +02:00
robots.txt doc: improve documentation building process 2022-06-22 11:15:26 +02:00
source.md doc: introduce mkdocs as a static documentation generator 2022-06-10 17:32:07 +02:00
validation.md feat!: rework messages body and parameters features 2022-07-25 22:05:31 +02:00