public function offsetSet($key, $newval)
    {
        if ($def = in_array($key, array_keys($this->keys))) {
            parent::offsetSet($key, $newval);
        } else {
            throw new UnexpectedValueException($key.' is not defined in metadata definition '.get_class($this).'.');
        }
    }
public function offsetSet($key, $newval)
    {
        if ($def = in_array($key, array_keys($this->keys))) {
            parent::offsetSet($key, $newval);
        } else {
            throw new UnexpectedValueException($key.' is not defined in metadata definition '.get_class($this).'.');
        }
    }
public function offsetSet ( $ key , $ newval ) { if ( $ def = in_array ( $ key , array_keys ( $ this -> keys ) ) ) { parent :: offsetSet ( $ key , $ newval ) ; } else { throw new UnexpectedValueException ( $ key . ' is not defined in metadata definition ' . get_class ( $ this ) . '.' ) ; } }
Do not allow to set more definitions.

@param mixed $key
@param mixed $newval
@return void
Do not allow to set more definitions .