Documentation

SortableIterator
in package
implements IteratorAggregate

SortableIterator applies a sort on a given Iterator.

Tags
author

Fabien Potencier fabien@symfony.com

Table of Contents

Interfaces

IteratorAggregate

Constants

SORT_BY_ACCESSED_TIME  = 3
SORT_BY_CHANGED_TIME  = 4
SORT_BY_MODIFIED_TIME  = 5
SORT_BY_NAME  = 1
SORT_BY_TYPE  = 2

Properties

$iterator  : mixed
$sort  : mixed

Methods

__construct()  : mixed
Constructor.
getIterator()  : mixed

Constants

Properties

Methods

__construct()

Constructor.

public __construct(Traversable $iterator, int|callable $sort) : mixed
Parameters
$iterator : Traversable

The Iterator to filter

$sort : int|callable

The sort type (SORT_BY_NAME, SORT_BY_TYPE, or a PHP callback)

Tags
throws
InvalidArgumentException

        
On this page

Search results