diff --git a/language/oop5/final.xml b/language/oop5/final.xml index 3b1cb45fe9..be9b924185 100644 --- a/language/oop5/final.xml +++ b/language/oop5/final.xml @@ -1,10 +1,11 @@ - + Final Keyword PHP 5 introduces the final keyword, which prevents child classes from - overriding a method by prefixing the definition with final. + overriding a method by prefixing the definition with final. If the class + itself is being defined final then it cannot be extended. @@ -33,6 +34,29 @@ class ChildClass extends BaseClass { + + Final class example + + +]]> + +