API Documentation

Db/Table/Rowset.php

Zend Framework

LICENSE

This source file is subject to the new BSD license that is bundled with this package in the file LICENSE.txt. It is also available through the world-wide-web at this URL: http://framework.zend.com/license/new-bsd If you did not receive a copy of the license and are unable to obtain it through the world-wide-web, please send an email to license@zend.com so we can send you a copy immediately.

category
Zend  
copyright
Copyright (c) 2005-2011 Zend Technologies USA Inc. (http://www.zend.com)  
license
New BSD License  
package
Zend_Db  
subpackage
Table  
version
$Id: Rowset.php 23775 2011-03-01 17:25:24Z ralph $  

\Zend_Db_Table_Rowset

Reference concrete class that extends Zend_Db_Table_Rowset_Abstract.

Developers may also create their own classes that extend the abstract class.

Extends from
\Zend_Db_Table_Rowset_Abstract
category
Zend  
copyright
Copyright (c) 2005-2011 Zend Technologies USA Inc. (http://www.zend.com)  
license
New BSD License  
package
Zend_Db  
subpackage
Table  

Methods

methodpublic__construct( array $config ) : void

Constructor.

Inherited from: \Zend_Db_Table_Rowset_Abstract::__construct()
Parameters
Name Type Description
$config array
methodpublic__sleep( ) : array

Store data, class names, and state in serialized object

Inherited from: \Zend_Db_Table_Rowset_Abstract::__sleep()
Returns
Type Description
array
methodpublic__wakeup( ) : void

Setup to do on wakeup.

Inherited from: \Zend_Db_Table_Rowset_Abstract::__wakeup()

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

methodprotected_loadAndReturnRow(  $position ) : void
Parameters
Name Type Description
$position
methodpubliccount( ) : int

Returns the number of elements in the collection.

Inherited from: \Zend_Db_Table_Rowset_Abstract::count()

Implements Countable::count()

Returns
Type Description
int
methodpubliccurrent( ) : \Zend_Db_Table_Row_Abstract

Return the current element.

Inherited from: \Zend_Db_Table_Rowset_Abstract::current()

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

Returns
Type Description
\Zend_Db_Table_Row_Abstract current element from the collection
methodpublicgetRow( int $position, bool $seek = false ) : \Zend_Db_Table_Row

Returns a Zend_Db_Table_Row from a known position into the Iterator

Inherited from: \Zend_Db_Table_Rowset_Abstract::getRow()
Parameters
Name Type Description
$position int the position of the row expected
$seek bool wether or not seek the iterator to that position after
Returns
Type Description
\Zend_Db_Table_Row
Throws
Exception Description
\Zend_Db_Table_Rowset_Exception
methodpublicgetTable( ) : \Zend_Db_Table_Abstract

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

Inherited from: \Zend_Db_Table_Rowset_Abstract::getTable()
Returns
Type Description
\Zend_Db_Table_Abstract
methodpublicgetTableClass( ) : string

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

Inherited from: \Zend_Db_Table_Rowset_Abstract::getTableClass()
Returns
Type Description
string
methodpublicinit( ) : void

Initialize object

Inherited from: \Zend_Db_Table_Rowset_Abstract::init()

Called from {@link __construct()} as final step of object instantiation.

methodpublicisConnected( ) : boolean

Return the connected state of the rowset.

Inherited from: \Zend_Db_Table_Rowset_Abstract::isConnected()
Returns
Type Description
boolean
methodpublickey( ) : int

Return the identifying key of the current element.

Inherited from: \Zend_Db_Table_Rowset_Abstract::key()

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

Returns
Type Description
int
methodpublicnext( ) : void

Move forward to next element.

Inherited from: \Zend_Db_Table_Rowset_Abstract::next()

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

methodpublicoffsetExists( string $offset ) : boolean

Check if an offset exists Required by the ArrayAccess implementation

Inherited from: \Zend_Db_Table_Rowset_Abstract::offsetExists()
Parameters
Name Type Description
$offset string
Returns
Type Description
boolean
methodpublicoffsetGet( string $offset ) : \Zend_Db_Table_Row_Abstract

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

Inherited from: \Zend_Db_Table_Rowset_Abstract::offsetGet()
Parameters
Name Type Description
$offset string
Returns
Type Description
\Zend_Db_Table_Row_Abstract
methodpublicoffsetSet( string $offset, mixed $value ) : void

Does nothing Required by the ArrayAccess implementation

Inherited from: \Zend_Db_Table_Rowset_Abstract::offsetSet()
Parameters
Name Type Description
$offset string
$value mixed
methodpublicoffsetUnset( string $offset ) : void

Does nothing Required by the ArrayAccess implementation

Inherited from: \Zend_Db_Table_Rowset_Abstract::offsetUnset()
Parameters
Name Type Description
$offset string
methodpublicrewind( ) : \Zend_Db_Table_Rowset_Abstract

Rewind the Iterator to the first element.

Inherited from: \Zend_Db_Table_Rowset_Abstract::rewind()

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

Returns
Type Description
\Zend_Db_Table_Rowset_Abstract Fluent interface.
methodpublicseek( int $position ) : \Zend_Db_Table_Rowset_Abstract

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

Inherited from: \Zend_Db_Table_Rowset_Abstract::seek()
Parameters
Name Type Description
$position int the position to seek to
Returns
Type Description
\Zend_Db_Table_Rowset_Abstract
Throws
Exception Description
\Zend_Db_Table_Rowset_Exception
methodpublicsetTable( \Zend_Db_Table_Abstract $table ) : boolean

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

Inherited from: \Zend_Db_Table_Rowset_Abstract::setTable()
Parameters
Name Type Description
$table \Zend_Db_Table_Abstract
Returns
Type Description
boolean
Throws
Exception Description
\Zend_Db_Table_Row_Exception
methodpublictoArray( ) : array

Returns all data as an array.

Inherited from: \Zend_Db_Table_Rowset_Abstract::toArray()

Updates the $_data property with current row object values.

Returns
Type Description
array
methodpublicvalid( ) : bool

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

Inherited from: \Zend_Db_Table_Rowset_Abstract::valid()

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

Returns
Type Description
bool False if there's nothing more to iterate over
Documentation was generated by DocBlox 0.13.3.