public function offsetSet($offset, $value) { // just to make sure the listKey exists $this->getListByKey(); if (is_null($offset)) { $this->info[$this->listKey][] = $value; } else { $this->info[$this->listKey][$offset] = $value; } }