From 70204c39065c32512f8de21b921b03eca1c7c164 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gr=C3=A9goire=20Paris?= <postmaster@greg0ire.fr> Date: Mon, 26 Feb 2018 23:32:50 +0100 Subject: [PATCH] Add note about named constructors --- index.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/index.md b/index.md index 65ca8e6..e3a69c3 100644 --- a/index.md +++ b/index.md @@ -194,9 +194,13 @@ class BetterArticle return new self(new ArticleContent($content)); } } - ``` +Note: +- On peut faire plusieurs constructeurs nommés +- On peut passer le constructeur en privé pour encourager l'utilisation des + constructeurs nommés. + --- # Emoji test -- GitLab