Abstract Class Zend_Db_Table_Rowset_Abstract

Description

Implements interfaces:

  • Iterator (internal interface)
  • Countable (internal interface)

  • copyright: Copyright (c) 2005-2007 Zend Technologies USA Inc. (http://www.zend.com)
  • abstract:
  • license: New BSD License

Located in /Db/Table/Rowset/Abstract.php (line 38)


	
			
Direct descendents
Class Description
 class Zend_Db_Table_Rowset Reference concrete class that extends Zend_Db_Table_Rowset_Abstract.
Variable Summary
 boolean $_connected
 integer $_count
 array $_data
 integer $_pointer
 string $_rowClass
 array $_rows
 boolean $_stored
 string $_tableClass
Method Summary
 Zend_Db_Table_Rowset_Abstract __construct ( $config)
 int count ()
 bool exists ()
 string getTableClass ()
 int key ()
 void next ()
 void rewind ()
 boolean setTable (Zend_Db_Table_Abstract $table)
 array toArray ()
 bool valid ()
 array __sleep ()
 void __wakeup ()
Variables
boolean $_connected = true (line 61)

Connected is true if we have a reference to a live Zend_Db_Table_Abstract object.

This is false after the Rowset has been deserialized.

  • access: protected
integer $_count (line 89)

How many data rows there are.

  • access: protected
array $_data = array() (line 45)

The original data for each row.

  • access: protected
integer $_pointer = 0 (line 82)

Iterator pointer.

  • access: protected
string $_rowClass = 'Zend_Db_Table_Row' (line 75)

Zend_Db_Table_Row_Abstract class name.

  • access: protected
array $_rows = array() (line 96)

Collection of instantiated Zend_Db_Table_Row objects.

  • access: protected
boolean $_stored = false (line 101)
  • access: protected
Zend_Db_Table_Abstract $_table (line 52)

Zend_Db_Table_Abstract object.

  • access: protected
string $_tableClass (line 68)

Zend_Db_Table_Abstract class name.

  • access: protected
Methods
Constructor __construct (line 106)

Constructor.

  • access: public
Zend_Db_Table_Rowset_Abstract __construct ( $config)
  • array $config
count (line 275)

Returns the number of elements in the collection.

Implements Countable::count()

  • access: public
int count ()

Implementation of:
Countable::count
current (line 211)

Return the current element.

Similar to the current() function for arrays in PHP Required by interface Iterator.

  • return: current element from the collection
  • access: public

Implementation of:
Iterator::current
exists (line 286)

Returns true if and only if count($this) > 0.

  • deprecated: since 0.9.3; use count() instead
  • access: public
bool exists ()
getTable (line 153)

Returns the table object, or null if this is disconnected rowset

  • access: public
Zend_Db_Table_Abstract|null getTable ()
getTableClass (line 187)

Query the class name of the Table object for which this Rowset was created.

  • access: public
string getTableClass ()
key (line 239)

Return the identifying key of the current element.

Similar to the key() function for arrays in PHP. Required by interface Iterator.

  • access: public
int key ()

Implementation of:
Iterator::key
next (line 251)

Move forward to next element.

Similar to the next() function for arrays in PHP. Required by interface Iterator.

  • access: public
void next ()

Implementation of:
Iterator::next
rewind (line 199)

Rewind the Iterator to the first element.

Similar to the reset() function for arrays in PHP. Required by interface Iterator.

  • access: public
void rewind ()

Implementation of:
Iterator::rewind
setTable (line 166)

Set the table object, to re-establish a live connection to the database for a Rowset that has been de-serialized.

  • throws: Zend_Db_Table_Row_Exception
  • access: public
boolean setTable (Zend_Db_Table_Abstract $table)
toArray (line 298)

Returns all data as an array.

Updates the $_data property with current row object values.

  • access: public
array toArray ()
valid (line 263)

Check if there is a current element after calls to rewind() or next().

Used to check if we've iterated to the end of the collection. Required by interface Iterator.

  • return: False if there's nothing more to iterate over
  • access: public
bool valid ()

Implementation of:
Iterator::valid
__sleep (line 131)

Store data, class names, and state in serialized object

  • access: public
array __sleep ()
__wakeup (line 143)

Setup to do on wakeup.

A de-serialized Rowset should not be assumed to have access to a live database connection, so set _connected = false.

  • access: public
void __wakeup ()

Documentation generated on Sun, 27 May 2007 23:19:53 -0700 by phpDocumentor 1.3.2