note 115529 added to language.oop5.interfaces
| From: | williebegoode at att dot net | Date: | Sun, 10 Aug 2014 10:42:30 +0000 |
| Subject: | note 115529 added to language.oop5.interfaces | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-200165@lists.php.net to get a copy of this message | ||
In their book on Design Patterns, Erich Gamma and his associates (AKA: "The Gang of Four")
use the term "interface" and "abstract class" interchangeably. In working with
PHP and design patterns, the interface, while clearly a "contract" of what to include in
an implementation is also a helpful guide for both re-use and making changes. As long as the
implemented changes follow the interface (whether it is an interface or abstract class with abstract
methods), large complex programs can be safely updated without having to re-code an entire program
or module.
In PHP coding with object interfaces (as a keyword) and "interfaces" in the more general
context of use that includes both object interfaces and abstract classes, the purpose of "loose
binding" (loosely bound objects) for ease of change and re-use is a helpful way to think about
both uses of the term "interface." The focus shifts from "contractual" to
"loose binding" for the purpose of cooperative development and re-use.
----
Server IP: 72.52.91.14
Probable Submitter: 32.208.9.227
----
Manual Page -- http://php.net/manual/en/language.oop5.interfaces.php
Edit -- https://master.php.net/note/edit/115529
Del: integrated -- https://master.php.net/note/delete/115529/integrated
Del: useless -- https://master.php.net/note/delete/115529/useless
Del: bad code -- https://master.php.net/note/delete/115529/bad+code
Del: spam -- https://master.php.net/note/delete/115529/spam
Del: non-english -- https://master.php.net/note/delete/115529/non-english
Del: in docs -- https://master.php.net/note/delete/115529/in+docs
Del: other reasons-- https://master.php.net/note/delete/115529
Reject -- https://master.php.net/note/reject/115529
Search -- https://master.php.net/manage/user-notes.php