Public Member Functions | Protected Attributes

Zend_Db_Table_Rowset_Abstract Class Reference

Inheritance diagram for Zend_Db_Table_Rowset_Abstract:
Zend_Db_Table_Rowset

Public Member Functions

 __construct (array $config)
 __sleep ()
 __wakeup ()
 init ()
 isConnected ()
 getTable ()
 setTable (Zend_Db_Table_Abstract $table)
 getTableClass ()
 rewind ()
 current ()
 key ()
 next ()
 valid ()
 count ()
 seek ($position)
 offsetExists ($offset)
 offsetGet ($offset)
 offsetSet ($offset, $value)
 offsetUnset ($offset)
 getRow ($position, $seek=false)
 toArray ()

Protected Attributes

 $_data = array()
 $_table
 $_connected = true
 $_tableClass
 $_rowClass = 'Zend_Db_Table_Row'
 $_pointer = 0
 $_count
 $_rows = array()
 $_stored = false
 $_readOnly = false

Detailed Description

Definition at line 30 of file Abstract.php.


Constructor & Destructor Documentation

__construct ( array $  config )

Constructor.

Parameters:
array$config

Definition at line 105 of file Abstract.php.


Member Function Documentation

__sleep (  )

Store data, class names, and state in serialized object

Returns:
array

Definition at line 139 of file Abstract.php.

__wakeup (  )

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.

Returns:
void

Definition at line 152 of file Abstract.php.

count (  )

Returns the number of elements in the collection.

Implements Countable::count()

Returns:
int

Definition at line 307 of file Abstract.php.

current (  )

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

Returns:
Zend_Db_Table_Row_Abstract current element from the collection

Definition at line 242 of file Abstract.php.

getRow ( position,
seek = false 
)

Returns a Zend_Db_Table_Row from a known position into the Iterator

Parameters:
int$positionthe position of the row expected
bool$seekwether or not seek the iterator to that position after
Returns:
Zend_Db_Table_Row
Exceptions:
Zend_Db_Table_Rowset_Exception

Definition at line 386 of file Abstract.php.

getTable (  )

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

Returns:
Zend_Db_Table_Abstract

Definition at line 183 of file Abstract.php.

getTableClass (  )

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

Returns:
string

Definition at line 217 of file Abstract.php.

init (  )

Initialize object

Called from __construct() as final step of object instantiation.

Returns:
void

Definition at line 164 of file Abstract.php.

isConnected (  )

Return the connected state of the rowset.

Returns:
boolean

Definition at line 173 of file Abstract.php.

key (  )

Return the identifying key of the current element. Similar to the key() function for arrays in PHP. Required by interface Iterator.

Returns:
int

Definition at line 271 of file Abstract.php.

next (  )

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

Returns:
void

Definition at line 283 of file Abstract.php.

offsetExists ( offset )

Check if an offset exists Required by the ArrayAccess implementation

Parameters:
string$offset
Returns:
boolean

Definition at line 338 of file Abstract.php.

offsetGet ( offset )

Get the row for the given offset Required by the ArrayAccess implementation

Parameters:
string$offset
Returns:
Zend_Db_Table_Row_Abstract

Definition at line 350 of file Abstract.php.

offsetSet ( offset,
value 
)

Does nothing Required by the ArrayAccess implementation

Parameters:
string$offset
mixed$value

Definition at line 364 of file Abstract.php.

offsetUnset ( offset )

Does nothing Required by the ArrayAccess implementation

Parameters:
string$offset

Definition at line 374 of file Abstract.php.

rewind (  )

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

Returns:
Zend_Db_Table_Rowset_Abstract Fluent interface.

Definition at line 229 of file Abstract.php.

seek ( position )

Take the Iterator to position $position Required by interface SeekableIterator.

Parameters:
int$positionthe position to seek to
Returns:
Zend_Db_Table_Rowset_Abstract
Exceptions:
Zend_Db_Table_Rowset_Exception

Definition at line 320 of file Abstract.php.

setTable ( Zend_Db_Table_Abstract table )

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

Parameters:
Zend_Db_Table_Abstract$table
Returns:
boolean
Exceptions:
Zend_Db_Table_Row_Exception

Definition at line 196 of file Abstract.php.

toArray (  )

Returns all data as an array.

Updates the $_data property with current row object values.

Returns:
array

Definition at line 409 of file Abstract.php.

valid (  )

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.

Returns:
bool False if there's nothing more to iterate over

Definition at line 295 of file Abstract.php.


The documentation for this class was generated from the following file: