From a2e6c2ac93d442cf277d686f34bb0f5004560805 Mon Sep 17 00:00:00 2001 From: Yonel Ceruto Date: Thu, 7 Mar 2019 15:14:37 -0500 Subject: [PATCH] Documenting the new method addNormalizer in OptionsResolver component --- components/options_resolver.rst | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/components/options_resolver.rst b/components/options_resolver.rst index 4b2526872d6..ca3b1baf6e1 100644 --- a/components/options_resolver.rst +++ b/components/options_resolver.rst @@ -437,6 +437,14 @@ if you need to use other options during normalization:: } } +.. versionadded:: 4.3 + + To normalize a new allowed value in sub-classes that is being normalized + in parent classes use :method:`Symfony\\Component\\OptionsResolver\\OptionsResolver::addNormalizer`. + This way, the ``$value`` argument will receive the previously normalized + value, otherwise you can prepend the new normalizer by passing ``true`` as + third argument. + Default Values that Depend on another Option ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~