1 |
<?php |
<?php |
|
|
|
2 |
/** |
/** |
3 |
|
* This file contains the DesignPattern::RemoteProxy class |
4 |
|
* |
5 |
|
* @author Andreas Motl <andreas.motl@ilo.de> |
6 |
|
* @package org.netfrag.glib |
7 |
|
* @name DesignPattern::RemoteProxy |
8 |
|
* @filesource |
9 |
|
* |
10 |
|
* |
11 |
|
* <b>Cvs-Log:</b> |
12 |
|
* |
13 |
|
* <pre> |
14 |
* ------------------------------------------------------------------------- |
* ------------------------------------------------------------------------- |
15 |
* $Id$ |
* $Id$ |
16 |
* ------------------------------------------------------------------------- |
* ------------------------------------------------------------------------- |
17 |
* $Log$ |
* $Log$ |
18 |
|
* Revision 1.4 2003/03/05 16:32:19 joko |
19 |
|
* updated docu (phpDocumentor testing....) |
20 |
|
* |
21 |
|
* Revision 1.3 2003/03/05 16:10:17 joko |
22 |
|
* updated docu (phpDocumentor testing....) |
23 |
|
* |
24 |
* Revision 1.2 2003/03/05 12:14:02 joko |
* Revision 1.2 2003/03/05 12:14:02 joko |
25 |
* renamed method |
* renamed method |
26 |
* constructor argument expansion |
* constructor argument expansion |
112 |
* Revision 1.1 2002/10/09 00:51:39 cvsjoko |
* Revision 1.1 2002/10/09 00:51:39 cvsjoko |
113 |
* + new |
* + new |
114 |
* ------------------------------------------------------------------------- |
* ------------------------------------------------------------------------- |
115 |
|
* </pre> |
116 |
|
* |
117 |
*/ |
*/ |
118 |
|
|
119 |
|
|
120 |
|
|
121 |
|
|
122 |
/** |
/** |
123 |
|
* Load required modules: |
124 |
* |
* |
125 |
|
*/ |
126 |
|
loadModule('DesignPattern::Proxy'); |
127 |
|
|
128 |
|
|
129 |
|
/** |
130 |
* Data::Driver::Proxy -- Multiple stage data fetching and caching |
* Data::Driver::Proxy -- Multiple stage data fetching and caching |
131 |
* |
* |
132 |
* |
* |
141 |
* |
* |
142 |
* Multiple stage data fetching and caching: |
* Multiple stage data fetching and caching: |
143 |
* |
* |
144 |
|
* <pre> |
145 |
|
* |
146 |
* DATA, ... |
* DATA, ... |
147 |
* ... also refered to as data, should be handled as |
* ... also refered to as data, should be handled as |
148 |
* something called data. |
* something called data. |
185 |
* o Data::Driver::PEAR::DB |
* o Data::Driver::PEAR::DB |
186 |
* x Data::Driver::PEAR::Tree (via Data::Lift) |
* x Data::Driver::PEAR::Tree (via Data::Lift) |
187 |
* |
* |
188 |
*/ |
* </pre> |
189 |
|
* |
190 |
/** |
* |
191 |
* Todo: |
* An attempt to implement some software design patterns |
192 |
|
* --- RemoteProxyPattern |
193 |
|
* |
194 |
|
* @link http://c2.com/cgi-bin/wiki?ProxyPattern |
195 |
|
* |
196 |
|
* @author Andreas Motl <andreas.motl@ilo.de> |
197 |
|
* @link http://www.netfrag.org/~joko/ |
198 |
|
* |
199 |
|
* @copyright (c) 2003 - All Rights reserved. |
200 |
|
* @license GNU LGPL (GNU Lesser General Public License) |
201 |
|
* @link http://www.gnu.org/licenses/lgpl.txt |
202 |
|
* |
203 |
|
* @package org.netfrag.glib |
204 |
|
* @name DesignPattern::RemoteProxy |
205 |
|
* |
206 |
|
* |
207 |
|
* @todo |
208 |
|
* <pre> |
209 |
* x extend options to en-/disable caching via a) session and/or b) database |
* x extend options to en-/disable caching via a) session and/or b) database |
210 |
* o make feature available via runtime setter-method to these options |
* o make feature available via runtime setter-method to these options |
211 |
* o use PEAR::Cache for caching purposes!!! |
* o use PEAR::Cache for caching purposes!!! |
213 |
* o make database connection more flexible to make possible |
* o make database connection more flexible to make possible |
214 |
* to have different (probably named) proxy databases (besides a "main database") |
* to have different (probably named) proxy databases (besides a "main database") |
215 |
* o rename this to Data::Proxy? or split into Data::Query, Data::Result and Data::Wrapper? |
* o rename this to Data::Proxy? or split into Data::Query, Data::Result and Data::Wrapper? |
216 |
|
* </pre> |
217 |
* |
* |
218 |
*/ |
*/ |
|
|
|
|
/** |
|
|
* Load required modules: |
|
|
* |
|
|
*/ |
|
|
loadModule('DesignPattern::Proxy'); |
|
|
|
|
219 |
class DesignPattern_RemoteProxy extends DesignPattern_Proxy { |
class DesignPattern_RemoteProxy extends DesignPattern_Proxy { |
220 |
|
|
221 |
var $objectId; |
var $objectId; |