/[cvs]/nfo/php/libs/org.netfrag.glib/DataSource/Adapter/phpHtmlLib/DataSource.php
ViewVC logotype

Contents of /nfo/php/libs/org.netfrag.glib/DataSource/Adapter/phpHtmlLib/DataSource.php

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.3 - (show annotations)
Thu Oct 7 14:13:12 2004 UTC (19 years, 10 months ago) by jonen
Branch: MAIN
CVS Tags: HEAD
Changes since 1.2: +9 -1 lines
+ updates related to DataList-filters which are mapped to backend now (page-control!)

1 <?php
2 /**
3 * This file contains the DataSource::Adapter::phpHtmlLib::DataListSource
4 * adapter class that inherits from the DataListSource.
5 *
6 * @author Andreas Motl <andreas.motl@ilo.de>
7 * @package org.netfrag.glib
8 * @name DataSource::Adapter::phpHtmlLib::DataListSource
9 *
10 */
11
12 /**
13 * <b>Cvs-Log:</b>
14 *
15 * <pre>
16 * $Id: DataSource.php,v 1.2 2004/05/06 17:08:22 jonen Exp $
17 *
18 * $Log: DataSource.php,v $
19 * Revision 1.2 2004/05/06 17:08:22 jonen
20 * bugfix related to new phphtmllib-v2.4.1 of Apr 01, 2004
21 *
22 * Revision 1.1 2003/03/27 01:21:30 jonen
23 * + renamed
24 *
25 * Revision 1.3 2003/03/11 01:22:26 joko
26 * + fixed metadata for phpDocumentor
27 *
28 * Revision 1.2 2003/03/05 18:54:45 joko
29 * updated docu - phpDocumentor is very strict about its 'blocks'...
30 *
31 * Revision 1.1 2003/03/05 12:06:23 joko
32 * + initial commit
33 * </pre>
34 *
35 */
36
37
38
39 /**
40 * This file contains the DataSource::Adapter::phpHtmlLib::DataListSource
41 * adapter class that inherits from the DataListSource.
42 *
43 * @author Andreas Motl <andreas.motl@ilo.de>
44 * @copyright (c) 2003 - All Rights reserved.
45 * @license GNU LGPL (GNU Lesser General Public License)
46 *
47 * @link http://www.netfrag.org/~joko/
48 * @link http://www.gnu.org/licenses/lgpl.txt
49 *
50 * @package org.netfrag.glib
51 * @subpackage DataSource
52 * @name DataSource::Adapter::phpHtmlLib::DataListSource
53 *
54 */
55 class DataSource_Adapter_phpHtmlLib_DataSource extends MemoryDataSource {
56
57 /**
58 * The constructor.
59 *
60 * @param DesignPattern::Proxy - a Proxy instance
61 *
62 */
63 function DataSource_Adapter_phpHtmlLib_DataSource(&$proxy) {
64
65 if (!isset($proxy)) {
66 user_error("Please pass Proxy instance to the Adapter!");
67 return;
68 }
69
70 $this->_proxy = &$proxy;
71
72 // tracing
73 //$this->trace_payload('DataSource_Adapter_phpHtmlLib_DataListSource', $proxy);
74
75 // transfer data to "memory"
76 //$this->_memory = &$payload;
77
78 //return 1;
79
80 }
81
82 function fetch($force = 0) {
83 $this->_result = $this->_proxy->get_result();
84 $this->_query_params["num_total_rows"] = $this->_proxy->get_result_count();
85 if (!sizeof($this->_result) || $force) {
86 $this->_result = $this->_proxy->query_data();
87 }
88 return $this->propagate();
89 }
90
91 function propagate() {
92 return $this->handle_result();
93 }
94
95
96
97 function get_header() {
98 $this->fetch();
99 $this->read_labels_from_result();
100 return $this->get_labels();
101 }
102
103 function do_prequery() {
104 }
105
106 function do_query() {
107 return $this->fetch();
108 }
109
110 function get_total_rows() {
111 return $this->_proxy->get_result_count();
112 }
113
114 }
115
116 ?>

MailToCvsAdmin">MailToCvsAdmin
ViewVC Help
Powered by ViewVC 1.1.26 RSS 2.0 feed