PHP Class Jackalope\Query\Row
The \Traversable interface enables the implementation to be addressed with
foreach. Rows have to implement either \RecursiveIterator or
\Iterator.
The iterator is similar to
getValues() with keys being the column
names and the values the corresponding entry in that column for this row.
Mostra file
Open project: jackalope/jackalope
Class Usage Examples
Protected Properties
Public Methods
Method |
Description |
|
__construct ( Jackalope\FactoryInterface $factory, ObjectManager $objectManager, array $columns ) |
Create new Row instance. |
|
current ( ) |
Implement Iterator |
|
getNode ( $selectorName = null ) |
{@inheritDoc} |
|
getPath ( $selectorName = null ) |
{@inheritDoc} |
|
getScore ( $selectorName = null ) |
{@inheritDoc} |
|
getValue ( $columnName ) |
{@inheritDoc} |
|
getValues ( ) |
{@inheritDoc} |
|
key ( ) |
Implement Iterator |
|
next ( ) |
Implement Iterator |
|
rewind ( ) |
Implement Iterator |
|
valid ( ) : boolean |
Implement Iterator |
|
Method Details
__construct()
public method
public __construct ( Jackalope\FactoryInterface $factory, ObjectManager $objectManager, array $columns ) |
$factory |
Jackalope\FactoryInterface |
the object factory |
$objectManager |
Jackalope\ObjectManager |
|
$columns |
array |
array of array with fields dcr:name and dcr:value |
public getNode ( $selectorName = null ) |
public getPath ( $selectorName = null ) |
public getScore ( $selectorName = null ) |
getValues()
public method
Property Details
$columns protected_oe property
Columns of this result row: array of array with fields dcr:name and
dcr:value
protected array $columns |
return |
array |
|
$defaultSelectorName protected_oe property
The default selector name
protected string $defaultSelectorName |
return |
string |
|
$factory protected_oe property
protected FactoryInterface,Jackalope $factory |
return |
Jackalope\FactoryInterface |
|
$objectManager protected_oe property
protected ObjectManager,Jackalope $objectManager |
return |
Jackalope\ObjectManager |
|
$path protected_oe property
The path to the node for each selector
$position protected_oe property
Which column we are on when iterating over the columns
protected int $position |
return |
integer |
|
$score protected_oe property
The score this row has for each selector
$values protected_oe property
Cached list of values extracted from columns to avoid double work.
protected array $values |
return |
array |
|