Esempio n. 1
0
 /**
  * Constructor
  *
  * @param array $array
  * @param Dump  $dumper
  */
 public function __construct(array $array, Dump $dumper)
 {
     $this->setMaxKeyLength(0);
     $this->array = array();
     foreach ($array as $key => $value) {
         $dumpedKey = $dumper->getDump($key, null, Dump::FORMAT_SHORT);
         $this->array[$dumpedKey] = $value;
         $this->setIfMaxKeyLength(strlen($dumpedKey));
     }
     $this->keys = array_keys($this->array);
     $this->pointer = 0;
 }