Pinq\Iterators\Generators\GroupedIterator::initializeGenerator PHP Method

initializeGenerator() protected method

protected initializeGenerator ( Pinq\Iterators\Generators\IGenerator $innerIterator )
$innerIterator Pinq\Iterators\Generators\IGenerator
    protected function initializeGenerator(IGenerator $innerIterator)
    {
        $groupedMap = (new OrderedMap($innerIterator))->groupBy($this->groupKeyFunction);
        return new ProjectionIterator($groupedMap, null, $this->traversableFactory);
    }