note 125784 added to language.oop5.interfaces
| From: | fakhar_anwar123 at hotmail dot com | Date: | Sat, 06 Feb 2021 21:10:24 +0000 |
| Subject: | note 125784 added to language.oop5.interfaces | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-219165@lists.php.net to get a copy of this message | ||
To conform to Interface Segregation Principle in (SOLID), PHP must allow to assign Object of Class
into specific Interface variable.
For example, if i want to segregate (expose) the functionality of a class into two different
interfaces (the class implements two different interfaces), and from client-code i want to use
specific interface to access specific function implemented by the class then i must be able to get
only that specific interface context (of the class) in interface variable
See P-15 and after taht p-13 in the link below. That is a very powerful and basic feature (Interface
Segregation Principle)
https://www.codeproject.com/Articles/18743/Interfaces-in-C-For-Beginners
----
Server IP: 45.112.84.4
Probable Submitter: 45.91.159.166 (proxied: 115.186.190.82)
----
Manual Page -- http://php.net/manual/en/language.oop5.interfaces.php
Edit -- https://master.php.net/note/edit/125784
Del: integrated -- https://master.php.net/note/delete/125784/integrated
Del: useless -- https://master.php.net/note/delete/125784/useless
Del: bad code -- https://master.php.net/note/delete/125784/bad+code
Del: spam -- https://master.php.net/note/delete/125784/spam
Del: non-english -- https://master.php.net/note/delete/125784/non-english
Del: in docs -- https://master.php.net/note/delete/125784/in+docs
Del: other reasons-- https://master.php.net/note/delete/125784
Reject -- https://master.php.net/note/reject/125784
Search -- https://master.php.net/manage/user-notes.php