PHP Class RedBeanPHP\Cursor\PDOCursor

Used by the BeanCollection to fetch one bean at a time. The PDO Cursor is used by Query Writers to support retrieval of large bean collections. For instance, this class is used to implement the findCollection()/BeanCollection functionality.
Author: Gabor de Mooij and the RedBeanPHP Community
Inheritance: implements RedBeanPHP\Cursor
Show file Open project: gabordemooij/redbean

Protected Properties

Property Type Description
$fetchStyle string
$res PDOStatement

Public Methods

Method Description
__construct ( PDOStatement $res, string $fetchStyle ) : void Constructor, creates a new instance of a PDO Database Cursor.
close ( )
getNextItem ( )

Method Details

__construct() public method

Constructor, creates a new instance of a PDO Database Cursor.
public __construct ( PDOStatement $res, string $fetchStyle ) : void
$res PDOStatement the PDO statement
$fetchStyle string fetch style constant to use
return void

close() public method

See also: Cursor::close
public close ( )

getNextItem() public method

See also: Cursor::getNextItem
public getNextItem ( )

Property Details

$fetchStyle protected property

protected string $fetchStyle
return string

$res protected property

protected PDOStatement $res
return PDOStatement