lib/components/rest/ParamBehavior.php
public function beforeRun($event)
    {
        foreach ($this->owner->params() as $param) {
            $value = $this->getParam($param);
            if (isset($value)) {
                $this->owner->{$param} = $value;
            }
        }
        foreach ($this->owner->requiredParams as $param) {
            if (!isset($this->owner->{$param})) {
                throw new InvalidParamException("The parameter '{$param}' is required for this object type.");
                $event->isValid = false;

                return false;
            }
        }
    }
public function beforeRun($event)
    {
        foreach ($this->owner->params() as $param) {
            $value = $this->getParam($param);
            if (isset($value)) {
                $this->owner->{$param} = $value;
            }
        }
        foreach ($this->owner->requiredParams as $param) {
            if (!isset($this->owner->{$param})) {
                throw new InvalidParamException("The parameter '{$param}' is required for this object type.");
                $event->isValid = false;

                return false;
            }
        }
    }
public function beforeRun ( $ event ) { foreach ( $ this -> owner -> params ( ) as $ param ) { $ value = $ this -> getParam ( $ param ) ; if ( isset ( $ value ) ) { $ this -> owner -> { $ param } = $ value ; } } foreach ( $ this -> owner -> requiredParams as $ param ) { if ( ! isset ( $ this -> owner -> { $ param } ) ) { throw new InvalidParamException ( "The parameter '{$param}' is required for this object type." ) ; $ event -> isValid = false ; return false ; } } }
[[@doctodo method_description:beforeRun]].

@param [[@doctodo param_type:event]] $event [[@doctodo param_description:event]]

@throws InvalidParamException [[@doctodo exception_description:InvalidParamException]]
@return [[@doctodo return_type:beforeRun]] [[@doctodo return_description:beforeRun]]
[[ @doctodo method_description : beforeRun ]] .