Class WFPagedCreoleQuery

Description

Implements interfaces:

A WFPagedData implementation for a Creole query.

Sorting support: The sortKeys should be the acutal SQL token to use in the order by clause (ie "table.column") with +/- prepended.

Located in /framework/WFPagination.php (line 927)


	
			
Variable Summary
Method Summary
WFPagedCreoleQuery __construct (string $sql, object A $connection, [boolean $countQueryRowsMode = false])
void itemCount ()
void itemsAtIndex ( $startIndex,  $numItems,  $sortKeys)
void setPopulateObjects (string $peerName)
Variables
mixed $baseSQL (line 929)
  • access: protected
mixed $connection (line 930)
  • access: protected
mixed $countQueryRowsMode (line 931)
  • access: protected
mixed $populateObjectsCallback (line 932)
  • access: protected
Methods
Constructor __construct (line 943)

Create a WFPagedCreoleQuery paged query.

WFPagedCreoleQuery __construct (string $sql, object A $connection, [boolean $countQueryRowsMode = false])
  • string $sql: The SQL query desired, WITHOUT "order by" or "limit/offset" clauses.
  • object A $connection: Creole connection.
  • boolean $countQueryRowsMode: Should the itemCount() function count the rows in the normal query, or just replace the select rows with count(*)? Default: false Most queries can leave this as the default. Aggregate queries and/or queries with having clauses may return improper row counts unless this is set to true.
itemCount (line 965)
void itemCount ()

Implementation of:
WFPagedData::itemCount()
Get the total number of items in the paged data.
itemsAtIndex (line 994)
void itemsAtIndex ( $startIndex,  $numItems,  $sortKeys)
  • $startIndex
  • $numItems
  • $sortKeys

Implementation of:
WFPagedData::itemsAtIndex()
Get a page of the managed items.
setPopulateObjects (line 960)

By default, WFPagedCreoleQuery returns an associative array of selected columns.

If you are using a creole query load Propel objects with a custom query (ie something too complex for criteria) but you still want propel objects returned, call this function with your peer name. Note that your query should contain the proper select columns as Criteria would set them up, ie the result of TourPeer::getFieldNames(BasePeer::TYPE_COLNAME)

void setPopulateObjects (string $peerName)
  • string $peerName: The propel peer name used to call populateObjects.

Documentation generated on Thu, 17 Apr 2008 13:52:00 -0400 by phpDocumentor 1.4.1