1 |
<?php |
2 |
|
3 |
/** |
4 |
* This file contains the DesignPattern::Facade class. |
5 |
* |
6 |
* @author Andreas Motl <andreas.motl@ilo.de> |
7 |
* @package org.netfrag.glib |
8 |
* @name DesignPattern::Facade |
9 |
* |
10 |
*/ |
11 |
|
12 |
|
13 |
/** |
14 |
* <b>Cvs-Log:</b> |
15 |
* |
16 |
* <pre> |
17 |
* $Id: Facade.php,v 1.9 2003/03/11 01:43:01 joko Exp $ |
18 |
* |
19 |
* $Log: Facade.php,v $ |
20 |
* Revision 1.9 2003/03/11 01:43:01 joko |
21 |
* + fixed metadata for phpDocumentor |
22 |
* |
23 |
* Revision 1.8 2003/03/11 01:22:26 joko |
24 |
* + fixed metadata for phpDocumentor |
25 |
* |
26 |
* Revision 1.7 2003/03/10 23:30:27 joko |
27 |
* + fixed metadata for phpDocumentor |
28 |
* |
29 |
* Revision 1.6 2003/03/10 23:25:04 joko |
30 |
* + fixed metadata for phpDocumentor |
31 |
* |
32 |
* Revision 1.5 2003/03/10 22:31:56 joko |
33 |
* + fixed metadata for phpDocumentor |
34 |
* |
35 |
* Revision 1.4 2003/03/05 23:16:48 joko |
36 |
* updated docu - phpDocumentor is very strict about its 'blocks'... |
37 |
* |
38 |
* Revision 1.3 2003/03/05 17:28:43 joko |
39 |
* updated docu (phpDocumentor testing....) |
40 |
* |
41 |
* Revision 1.2 2003/03/05 17:02:22 joko |
42 |
* updated docu (phpDocumentor testing....) |
43 |
* |
44 |
* Revision 1.1 2003/03/03 21:56:01 joko |
45 |
* + initial commit |
46 |
* just a skeleton by now... |
47 |
* </pre> |
48 |
* |
49 |
*/ |
50 |
|
51 |
|
52 |
/** |
53 |
* Load required modules: |
54 |
* |
55 |
*/ |
56 |
loadModule('Class::Logger'); |
57 |
|
58 |
|
59 |
/** |
60 |
* --- An attempt to implement some software design patterns... The FacadePattern |
61 |
* |
62 |
* @link http://c2.com/cgi-bin/wiki?FacadePattern |
63 |
* Intent: Provide a unified interface to a set of interfaces in a subsystem. |
64 |
* Facade defines a higher-level interface that makes the subsystem easier to use. |
65 |
* This can be used to simplify a number of complicated object interactions into a single interface. |
66 |
* |
67 |
* |
68 |
* @author Andreas Motl <andreas.motl@ilo.de> |
69 |
* @copyright (c) 2003 - All Rights reserved. |
70 |
* @link http://www.netfrag.org/~joko/ |
71 |
* |
72 |
* @license GNU LGPL (GNU Lesser General Public License) |
73 |
* @link http://www.gnu.org/licenses/lgpl.txt |
74 |
* |
75 |
* @package org.netfrag.glib |
76 |
* @subpackage DesignPattern |
77 |
* @name DesignPattern::Facade |
78 |
* |
79 |
* @todo this: |
80 |
* o xyz |
81 |
* o bla, bli, blub |
82 |
* |
83 |
*/ |
84 |
class DesignPattern_Facade extends Class_Logger { |
85 |
|
86 |
var $_about; |
87 |
var $_container; |
88 |
|
89 |
function constructor() { |
90 |
parent::constructor(); |
91 |
//loadModule('Data::Container'); |
92 |
$this->_container = php::mkComponent('Data::Container'); |
93 |
} |
94 |
|
95 |
function perform() { |
96 |
$this->_abstract_method('perform', 'DesignPattern::Facade'); |
97 |
} |
98 |
|
99 |
function about() { |
100 |
$this->_about = |
101 |
<<<ABOUT |
102 |
* --- DesignPattern::Facade |
103 |
* --- http://cvs.netfrag.org/nfo/php/libs/org.netfrag.glib/DesignPattern/Facade.php |
104 |
* |
105 |
* http://c2.com/cgi-bin/wiki?FacadePattern says... |
106 |
* Intent: Provide a unified interface to a set of interfaces in a subsystem. |
107 |
* Facade defines a higher-level interface that makes the subsystem easier to use. |
108 |
* This can be used to simplify a number of complicated object interactions into a single interface. |
109 |
* http://www.fluffycat.com/java/patterns.html says... |
110 |
* One class has a method that performs a complex process calling several other classes. |
111 |
ABOUT; |
112 |
} |
113 |
|
114 |
} |
115 |
|
116 |
?> |