doctrine / doctrine/DoctrineORMModule

How to register custom Hydration strategies?

Open
#732 1 comment 0 reactions 0 assignees View on GitHub
Question
Dominant language
PHP
Stars
438
Forks
227
PR merge metrics
No merged PRs in 30d

Description

I'd like to use php8.1 built in enums in doctrine backed entities.
According to https://www.doctrine-project.org/projects/doctrine-laminas-hydrator/en/3.3/enum-strategy.html#using-enums-with-php-8-1 I need to create and register a custom hydration strategy for each enum I want to use.

Is there any configuration key where I can easily register them or do I have to use a Delegator on the DoctrineHydrator?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.