class ResultSet implements Iterator, IRowContainer

Represents a result set.

Traits

Strict class for better experience.

Methods

__construct(Connection $connection, string $queryString, array $params)

No description

getConnection()

No description

getPdoStatement()

No description

string
getQueryString()

No description

array
getParameters()

No description

int|null
getColumnCount()

No description

int|null
getRowCount()

No description

float
getTime()

No description

array
normalizeRow(array $row)

Normalizes result row.

void
dump()

Displays complete result set as HTML table for debug purposes.

void
rewind()

No description

current()

No description

key()

No description

void
next()

No description

bool
valid()

No description

IRow|null
fetch()

Fetches single row object.

mixed
fetchField($column = 0)

Fetches single field.

array|null
fetchFields()

Fetches array of fields.

array
fetchPairs(string|int $key = null, string|int $value = null)

Fetches all rows as associative array.

array
fetchAll()

Fetches all rows.

array
fetchAssoc(string $path)

Fetches all rows and returns associative tree.

Details

at line 51
__construct(Connection $connection, string $queryString, array $params)

Parameters

Connection $connection
string $queryString
array $params

at line 82
Connection getConnection()

Return Value

Connection

at line 91
PDOStatement getPdoStatement()

Return Value

PDOStatement

at line 97
string getQueryString()

Return Value

string

at line 103
array getParameters()

Return Value

array

at line 109
int|null getColumnCount()

Return Value

int|null

at line 115
int|null getRowCount()

Return Value

int|null

at line 121
float getTime()

Return Value

float

at line 130
array normalizeRow(array $row)

Normalizes result row.

Parameters

array $row

Return Value

array

at line 177
void dump()

Displays complete result set as HTML table for debug purposes.

Return Value

void

at line 186
void rewind()

Return Value

void

at line 194
current()

at line 200
key()

at line 206
void next()

Return Value

void

at line 212
bool valid()

Return Value

bool

at line 228
IRow|null fetch()

Fetches single row object.

Return Value

IRow|null

at line 255
mixed fetchField($column = 0)

Fetches single field.

Parameters

$column

Return Value

mixed

at line 268
array|null fetchFields()

Fetches array of fields.

Return Value

array|null

at line 278
array fetchPairs(string|int $key = null, string|int $value = null)

Fetches all rows as associative array.

Parameters

string|int $key column name used for an array key or null for numeric index
string|int $value column name used for an array value or null for the whole row

Return Value

array

at line 287
array fetchAll()

Fetches all rows.

Return Value

array

at line 299
array fetchAssoc(string $path)

Fetches all rows and returns associative tree.

Parameters

string $path associative descriptor

Return Value

array