Class P4A_Data_Source

Description

P4A - PHP For Applications.

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License version 2 as published by the Free Software Foundation.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA

To contact the authors write to:
CreaLabs
Via Medail, 32
10144 Torino (Italy)
Web: http://www.crealabs.it
E-mail: info@crealabs.it

The latest version of p4a can be obtained from: http://p4a.sourceforge.net

Located in /p4a/objects/data_source.php (line 39)

P4A_Object
   |
   --P4A_Data_Source
Direct descendents
Class Description
 class P4A_Array_Source P4A - PHP For Applications.
 class P4A_DB_Source P4A - PHP For Applications.
Variable Summary
 mixed $fields
 mixed $_fields
 mixed $_limit
 mixed $_num_pages
 mixed $_num_rows
 mixed $_offset
 mixed $_page_limit
 mixed $_pk
 mixed $_pointer
Method Summary
 P4A_Data_Source P4A_Data_Source (mixed $name)
 void deleteRow ()
 void exportAsCSV ([mixed $filename = ""], [mixed $separator = ','], [mixed $fields_names = null])
 void exportToCSV ([mixed $filename = ""], [mixed $separator = ','], [mixed $fields_names = null])
 void firstPage ()
 void firstRow ()
 void getAll (mixed $from, mixed $count)
 void getAsCSV ([mixed $separator = ','], [mixed $fields_names = null])
 integer getNumPage ()
 integer getNumPages ()
 void getNumRows ()
 void getOffset ()
 void getPageLimit ()
 void getPk ()
 void getPkRow (mixed $pk)
 void getPkValues ()
 void getRowNumber ()
 void isNew ()
 void lastPage ()
 void lastRow ()
 void load ()
 void newRow ()
 void nextPage ()
 void nextRow ()
 array page ([mixed $num_page = null], [mixed $move_pointer = true])
 void prevPage ()
 void prevRow ()
 void row ([mixed $num_row = NULL], [mixed $move_pointer = TRUE])
 void setPageLimit (mixed $page_limit)
 void setPk (mixed $pk)
Variables
mixed $fields = NULL (line 57)

Redefined in descendants as:
mixed $_fields = NULL (line 52)
mixed $_is_read_only = FALSE (line 54)
mixed $_is_sortable = TRUE (line 55)
mixed $_limit = NULL (line 45)
mixed $_num_pages = NULL (line 49)
mixed $_num_rows = NULL (line 48)
mixed $_offset = NULL (line 46)
mixed $_page_limit = 10 (line 50)
mixed $_pk = NULL (line 43)

Redefined in descendants as:
mixed $_pointer = NULL (line 41)

Inherited Variables

Inherited from P4A_Object

P4A_Object::$_id
P4A_Object::$_map_actions
P4A_Object::$_name
P4A_Object::$_objects
P4A_Object::$_parent_id
Methods
Constructor P4A_Data_Source (line 59)
P4A_Data_Source P4A_Data_Source (mixed $name)
deleteRow (line 360)
void deleteRow ()

Redefined in descendants as:
exportAsCSV (line 342)
void exportAsCSV ([mixed $filename = ""], [mixed $separator = ','], [mixed $fields_names = null])
exportToCSV (line 337)
void exportToCSV ([mixed $filename = ""], [mixed $separator = ','], [mixed $fields_names = null])
firstPage (line 246)
void firstPage ()
firstRow (line 103)
void firstRow ()
getAll (line 89)
void getAll (mixed $from, mixed $count)

Redefined in descendants as:
getAsCSV (line 300)
void getAsCSV ([mixed $separator = ','], [mixed $fields_names = null])
getNumPage (line 197)

Returns the number of the current page

  • access: public
integer getNumPage ()
getNumPages (line 176)

Returns the number of pages in the data source

  • access: public
integer getNumPages ()
getNumRows (line 93)
void getNumRows ()

Redefined in descendants as:
getOffset (line 155)
void getOffset ()
getPageLimit (line 166)
void getPageLimit ()
getPk (line 274)
void getPk ()
getPkRow (line 295)
void getPkRow (mixed $pk)

Redefined in descendants as:
getPkValues (line 279)
void getPkValues ()
getRowNumber (line 98)
void getRowNumber ()
isNew (line 80)
void isNew ()
lastPage (line 263)
void lastPage ()
lastRow (line 142)
void lastRow ()
load (line 64)
void load ()

Redefined in descendants as:
newRow (line 72)
void newRow ()
nextPage (line 257)
void nextPage ()
nextRow (line 129)
void nextRow ()
page (line 214)

Returns a page of date (some rows)

  • access: public
array page ([mixed $num_page = null], [mixed $move_pointer = true])
prevPage (line 251)
void prevPage ()
prevRow (line 116)
void prevRow ()
row (line 68)
void row ([mixed $num_row = NULL], [mixed $move_pointer = TRUE])

Redefined in descendants as:
setPageLimit (line 161)
void setPageLimit (mixed $page_limit)
setPk (line 269)
void setPk (mixed $pk)

Inherited Methods

Inherited From P4A_Object

 P4A_Object::actionHandler()
 P4A_Object::build()
 P4A_Object::destroy()
 P4A_Object::errorHandler()
 P4A_Object::getId()
 P4A_Object::getName()
 P4A_Object::getObjectType()
 P4A_Object::getParentID()
 P4A_Object::implementMethod()
 P4A_Object::intercept()
 P4A_Object::isActionTriggered()
 P4A_Object::p4a_object()
 P4A_Object::setName()
 P4A_Object::setParentID()
 P4A_Object::void()

Documentation generated on Fri, 26 May 2006 12:43:05 +0200 by phpDocumentor 1.3.0RC5