PHP Класс Pheasant\Database\Mysqli\ResultIterator

Наследование: implements SeekableIterator, implements Countable
Показать файл Открыть проект

Открытые методы

Метод Описание
__construct ( MySQLi_Result $result ) Constructor
__destruct ( ) Destructor Frees the Result object
count ( ) Returns the number of rows in the result
current ( ) : array Returns the row that matches the current position
key ( ) : integer Returns the current position
next ( ) Moves the internal pointer one step forward
rewind ( ) Rewinds the internal pointer
seek ( $position ) Seeks to a particular position in the result, offset is from 0.
setHydrator ( $callback ) Sets a hydrator
toArray ( )
valid ( ) : boolean Returns true if the current position is valid, false otherwise.

Приватные методы

Метод Описание
_fetch ( ) Template for fetching the array

Описание методов

__construct() публичный Метод

Constructor
public __construct ( MySQLi_Result $result )
$result MySQLi_Result

__destruct() публичный Метод

Destructor Frees the Result object
public __destruct ( )

count() публичный Метод

Returns the number of rows in the result
public count ( )

current() публичный Метод

Returns the row that matches the current position
public current ( ) : array
Результат array

key() публичный Метод

Returns the current position
public key ( ) : integer
Результат integer

next() публичный Метод

Moves the internal pointer one step forward
public next ( )

rewind() публичный Метод

Rewinds the internal pointer
public rewind ( )

seek() публичный Метод

Seeks to a particular position in the result, offset is from 0.
public seek ( $position )

setHydrator() публичный Метод

Sets a hydrator
public setHydrator ( $callback )

toArray() публичный Метод

public toArray ( )

valid() публичный Метод

Returns true if the current position is valid, false otherwise.
public valid ( ) : boolean
Результат boolean