Class DataObjectSet_Iterator
An Iterator for a DataObjectSet
-
DataObjectSet_Iterator
implements
Iterator
Methods summary
public
|
|
protected
DataObject
|
#
prepareItem( DataObject $item )
Prepare an item taken from the internal array for output by this iterator.
Ensures that it is an object.
Prepare an item taken from the internal array for output by this iterator.
Ensures that it is an object.
Parameters
- $item
- DataObject $item Item to prepare
Returns
|
public
DataObject
|
#
current( )
Return the current object of the iterator.
Return the current object of the iterator.
Returns
Implementation of
|
public
mixed
|
#
key( )
Return the key of the current object of the iterator.
Return the key of the current object of the iterator.
Returns
mixed mixed
Implementation of
|
public
DataObject
|
#
next( )
Return the next item in this set.
Return the next item in this set.
Returns
Implementation of
|
public
DataObject
|
#
rewind( )
Rewind the iterator to the beginning of the set.
Rewind the iterator to the beginning of the set.
Returns
Implementation of
|
public
boolean
|
#
valid( )
Check the iterator is pointing to a valid item in the set.
Check the iterator is pointing to a valid item in the set.
Returns
boolean boolean
Implementation of
|
public
DataObject
|
#
peekNext( )
Return the next item in this set without progressing the iterator.
Return the next item in this set without progressing the iterator.
Returns
|
public
DataObject
|
#
peekPrev( )
Return the prvious item in this set, without affecting the iterator.
Return the prvious item in this set, without affecting the iterator.
Returns
|
public
DataObject|boolean
|
#
getOffset( integer $offset )
Return the object in this set offset by $offset from the iterator
pointer.
Return the object in this set offset by $offset from the iterator
pointer.
Parameters
- $offset
- int $offset The offset.
Returns
DataObject|booleanDataObject of offset item, or boolean FALSE if not found
|
Magic methods summary
[Raise a SilverStripe Framework issue/bug](https://github.com/silverstripe/silverstripe-framework/issues/new)
- [Raise a SilverStripe CMS issue/bug](https://github.com/silverstripe/silverstripe-cms/issues/new)
- Please use the
Silverstripe Forums to ask development related questions.
-