public function getIterator()
    {
        $chars = array();

        for ($i = 0, $l = $this->getLength(); $i < $l; $i++)
        {
            $chars[] = $this[$i];
        }

        return new \ArrayIterator($chars);
    }
public function getIterator()
    {
        $chars = array();

        for ($i = 0, $l = $this->getLength(); $i < $l; $i++)
        {
            $chars[] = $this[$i];
        }

        return new \ArrayIterator($chars);
    }
public function getIterator ( ) { $ chars = array ( ) ; for ( $ i = 0 , $ l = $ this -> getLength ( ) ; $ i < $ l ; $ i ++ ) { $ chars [ ] = $ this [ $ i ] ; } return new \ ArrayIterator ( $ chars ) ; }
IteratorAggregate interface method.

@see http://php.net/manual/en/class.iteratoraggregate.php

@return \ArrayIterator
IteratorAggregate interface method .