NOTE: For Version 3 of the AWS SDK for PHP, please see the V3 User Guide and V3 API Reference.

# Class ChunkedIterator

Pulls out chunks from an inner iterator and yields the chunks as arrays

  IteratorIterator implements Iterator, Traversable, OuterIterator
  Guzzle\Iterator\ChunkedIterator

Namespace: Guzzle\Iterator
Located at Guzzle/Iterator/ChunkedIterator.php

## Methods summary

- `public` `__construct ( Traversable $iterator, int $chunkSize )`
- `public` `rewind ( )`
- `public` `next ( )`
- `public` `current ( )`
- `public` `valid ( )`

## Methods detail

# `public`
`__construct( `Traversable` $iterator, integer $chunkSize )`

#### Parameters

$iterator
  ``Traversable``
  $iterator Traversable iterator
$chunkSize
  `integer`
  $chunkSize Size to make each chunk

#### Throws

``InvalidArgumentException``

#### Overrides

`IteratorIterator::__construct`
# `public`
`rewind( )`

#### Overrides

`IteratorIterator::rewind`
# `public`
`next( )`

#### Overrides

`IteratorIterator::next`
# `public`
`current( )`

#### Overrides

`IteratorIterator::current`
# `public`
`valid( )`

#### Overrides

`IteratorIterator::valid`

### Methods inherited from IteratorIterator

`getInnerIterator()`, `key()`

### Magic methods summary

## Properties summary

`protected integer` | $chunkSize | # Size of each chunk
`protected array` | $chunk | # Current chunk