Documentation

CachingIterator extends CachingIterator
in package
implements Countable uses SmartObject

Smarter caching iterator.

Table of Contents

Interfaces

Countable

Properties

$empty  : bool
$even  : bool
$first  : bool
$last  : bool
$nextKey  : mixed
$nextValue  : mixed
$odd  : bool
$counter  : int

Methods

__call()  : mixed
__callStatic()  : mixed
__construct()  : mixed
__get()  : mixed
__isset()  : bool
__set()  : void
__unset()  : void
count()  : int
Returns the count of elements.
getCounter()  : int
Returns the counter.
getNextKey()  : mixed
Returns the next key.
getNextValue()  : mixed
Returns the next element.
isEmpty()  : bool
Is the iterator empty?
isEven()  : bool
Is the counter even?
isFirst()  : bool
Is the current element the first one?
isLast()  : bool
Is the current element the last one?
isOdd()  : bool
Is the counter odd?
next()  : void
Forwards to the next element.
rewind()  : void
Rewinds the Iterator.

Properties

Methods

__call()

public __call(string $name, array<string|int, mixed> $args) : mixed
Parameters
$name : string
$args : array<string|int, mixed>
Tags
throws
MemberAccessException

__callStatic()

public static __callStatic(string $name, array<string|int, mixed> $args) : mixed
Parameters
$name : string
$args : array<string|int, mixed>
Tags
throws
MemberAccessException

__construct()

public __construct(iterable<string|int, mixed>|stdClass $iterable) : mixed
Parameters
$iterable : iterable<string|int, mixed>|stdClass

__isset()

public __isset(string $name) : bool
Parameters
$name : string
Return values
bool

__set()

public __set(string $name, mixed $value) : void
Parameters
$name : string
$value : mixed
Tags
throws
MemberAccessException

if the property is not defined or is read-only

count()

Returns the count of elements.

public count() : int
Return values
int

getCounter()

Returns the counter.

public getCounter() : int
Return values
int

getNextValue()

Returns the next element.

public getNextValue() : mixed

isEmpty()

Is the iterator empty?

public isEmpty() : bool
Return values
bool

isEven()

Is the counter even?

public isEven() : bool
Return values
bool

isFirst()

Is the current element the first one?

public isFirst([int|null $gridWidth = null ]) : bool
Parameters
$gridWidth : int|null = null
Return values
bool

isLast()

Is the current element the last one?

public isLast([int|null $gridWidth = null ]) : bool
Parameters
$gridWidth : int|null = null
Return values
bool

isOdd()

Is the counter odd?

public isOdd() : bool
Return values
bool

        
On this page

Search results