Db/Table/Rowset.php

Show: PublicProtectedPrivateinherited
Table of Contents
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-2012 Zend Technologies USA Inc. (http://www.zend.com)  
License
New BSD License  
Package
Zend_Db  
Subpackage
Table  
Version
$Id: Rowset.php 24593 2012-01-05 20:35:02Z matthew $  

\Zend_Db_Table_Rowset

Package: Zend\Db\Table
Reference concrete class that extends Zend_Db_Table_Rowset_Abstract.

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

Parent(s)
\Zend_Db_Table_Rowset_Abstract
Category
Zend  
Copyright
Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)  
License
New BSD License  

Properties

>VPropertyprotectedboolean $_connected = true
inherited
Connected is true if we have a reference to a live Zend_Db_Table_Abstract object.
Inherited from: \Zend_Db_Table_Rowset_Abstract::$$_connected

This is false after the Rowset has been deserialized.

Default valuetrueDetails
Type
boolean
Inherited_from
\Zend_Db_Table_Rowset_Abstract::$$_connected  
>VPropertyprotectedinteger $_count
inherited
How many data rows there are.
Inherited from: \Zend_Db_Table_Rowset_Abstract::$$_count
Details
Type
integer
Inherited_from
\Zend_Db_Table_Rowset_Abstract::$$_count  
>VPropertyprotectedarray $_data = array()
inherited
The original data for each row.
Inherited from: \Zend_Db_Table_Rowset_Abstract::$$_data
Default valuearray()Details
Type
array
Inherited_from
\Zend_Db_Table_Rowset_Abstract::$$_data  
>VPropertyprotectedinteger $_pointer = 0
inherited
Iterator pointer.
Inherited from: \Zend_Db_Table_Rowset_Abstract::$$_pointer
Default value0Details
Type
integer
Inherited_from
\Zend_Db_Table_Rowset_Abstract::$$_pointer  
>VPropertyprotectedboolean $_readOnly = false
Default valuefalseDetails
Type
boolean
Inherited_from
\Zend_Db_Table_Rowset_Abstract::$$_readOnly  
>VPropertyprotectedstring $_rowClass = 'Zend_Db_Table_Row'
inherited
Zend_Db_Table_Row_Abstract class name.
Inherited from: \Zend_Db_Table_Rowset_Abstract::$$_rowClass
Default value'Zend_Db_Table_Row'Details
Type
string
Inherited_from
\Zend_Db_Table_Rowset_Abstract::$$_rowClass  
>VPropertyprotectedarray $_rows = array()
inherited
Collection of instantiated Zend_Db_Table_Row objects.
Inherited from: \Zend_Db_Table_Rowset_Abstract::$$_rows
Default valuearray()Details
Type
array
Inherited_from
\Zend_Db_Table_Rowset_Abstract::$$_rows  
>VPropertyprotectedboolean $_stored = false
Default valuefalseDetails
Type
boolean
Inherited_from
\Zend_Db_Table_Rowset_Abstract::$$_stored  
>VPropertyprotected\Zend_Db_Table_Abstract $_table
inherited
Zend_Db_Table_Abstract object.
Inherited from: \Zend_Db_Table_Rowset_Abstract::$$_table
>VPropertyprotectedstring $_tableClass
inherited
Zend_Db_Table_Abstract class name.
Inherited from: \Zend_Db_Table_Rowset_Abstract::$$_tableClass
Details
Type
string
Inherited_from
\Zend_Db_Table_Rowset_Abstract::$$_tableClass  

Methods

methodpublic__construct(array $config) : void
inherited

Constructor.

Inherited from: \Zend_Db_Table_Rowset_Abstract::__construct()
Parameters
NameTypeDescription
$configarray
methodpublic__sleep() : array
inherited

Store data, class names, and state in serialized object

Inherited from: \Zend_Db_Table_Rowset_Abstract::__sleep()
Returns
TypeDescription
array
methodpublic__wakeup() : void
inherited

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
NameTypeDescription
$position
methodpubliccount() : int
inherited

Returns the number of elements in the collection.

Inherited from: \Zend_Db_Table_Rowset_Abstract::count()

Implements Countable::count()

Returns
TypeDescription
int
methodpubliccurrent() : \Zend_Db_Table_Row_Abstract
inherited

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
TypeDescription
\Zend_Db_Table_Row_Abstractcurrent element from the collection
methodpublicgetRow(int $position, bool $seek = false) : \Zend_Db_Table_Row
inherited

Returns a Zend_Db_Table_Row from a known position into the Iterator

Inherited from: \Zend_Db_Table_Rowset_Abstract::getRow()
Parameters
NameTypeDescription
$positionint

the position of the row expected

$seekbool

wether or not seek the iterator to that position after

Returns
TypeDescription
\Zend_Db_Table_Row
Throws
ExceptionDescription
\Zend_Db_Table_Rowset_Exception
methodpublicgetTable() : \Zend_Db_Table_Abstract
inherited

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

Inherited from: \Zend_Db_Table_Rowset_Abstract::getTable()
Returns
TypeDescription
\Zend_Db_Table_Abstract
methodpublicgetTableClass() : string
inherited

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

Inherited from: \Zend_Db_Table_Rowset_Abstract::getTableClass()
Returns
TypeDescription
string
methodpublicinit() : void
inherited

Initialize object

Inherited from: \Zend_Db_Table_Rowset_Abstract::init()

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

methodpublicisConnected() : boolean
inherited

Return the connected state of the rowset.

Inherited from: \Zend_Db_Table_Rowset_Abstract::isConnected()
Returns
TypeDescription
boolean
methodpublickey() : int
inherited

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
TypeDescription
int
methodpublicnext() : void
inherited

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
inherited

Check if an offset exists Required by the ArrayAccess implementation

Inherited from: \Zend_Db_Table_Rowset_Abstract::offsetExists()
Parameters
NameTypeDescription
$offsetstring
Returns
TypeDescription
boolean
methodpublicoffsetGet(string $offset) : \Zend_Db_Table_Row_Abstract
inherited

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

Inherited from: \Zend_Db_Table_Rowset_Abstract::offsetGet()
Parameters
NameTypeDescription
$offsetstring
Returns
TypeDescription
\Zend_Db_Table_Row_Abstract
methodpublicoffsetSet(string $offset, mixed $value) : void
inherited

Does nothing Required by the ArrayAccess implementation

Inherited from: \Zend_Db_Table_Rowset_Abstract::offsetSet()
Parameters
NameTypeDescription
$offsetstring
$valuemixed
methodpublicoffsetUnset(string $offset) : void
inherited

Does nothing Required by the ArrayAccess implementation

Inherited from: \Zend_Db_Table_Rowset_Abstract::offsetUnset()
Parameters
NameTypeDescription
$offsetstring
methodpublicrewind() : \Zend_Db_Table_Rowset_Abstract
inherited

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
TypeDescription
\Zend_Db_Table_Rowset_AbstractFluent interface.
methodpublicseek(int $position) : \Zend_Db_Table_Rowset_Abstract
inherited

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

Inherited from: \Zend_Db_Table_Rowset_Abstract::seek()
Parameters
NameTypeDescription
$positionint

the position to seek to

Returns
TypeDescription
\Zend_Db_Table_Rowset_Abstract
Throws
ExceptionDescription
\Zend_Db_Table_Rowset_Exception
methodpublicsetTable(\Zend_Db_Table_Abstract $table) : boolean
inherited

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
NameTypeDescription
$table\Zend_Db_Table_Abstract
Returns
TypeDescription
boolean
Throws
ExceptionDescription
\Zend_Db_Table_Row_Exception
methodpublictoArray() : array
inherited

Returns all data as an array.

Inherited from: \Zend_Db_Table_Rowset_Abstract::toArray()

Updates the $_data property with current row object values.

Returns
TypeDescription
array
methodpublicvalid() : bool
inherited

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
TypeDescription
boolFalse if there's nothing more to iterate over
Documentation was generated by phpDocumentor 2.0.0a12.