public function setRequirements()
    {
        if (!isset($this->options['requirements']) || $this->options['requirements'] === null) {
            return $this;
        }

        $requirements = $this->options['requirements'];

        if (!is_array($requirements)) {
            $requirements = [$requirements];
        }

        foreach ($requirements as $constraint) {
            $this->requirements[] = $constraint;
        }

        unset($this->options['requirements']);

        return $this;
    }
public function setRequirements()
    {
        if (!isset($this->options['requirements']) || $this->options['requirements'] === null) {
            return $this;
        }

        $requirements = $this->options['requirements'];

        if (!is_array($requirements)) {
            $requirements = [$requirements];
        }

        foreach ($requirements as $constraint) {
            $this->requirements[] = $constraint;
        }

        unset($this->options['requirements']);

        return $this;
    }
public function setRequirements ( ) { if ( ! isset ( $ this -> options [ 'requirements' ] ) || $ this -> options [ 'requirements' ] === null ) { return $ this ; } $ requirements = $ this -> options [ 'requirements' ] ; if ( ! is_array ( $ requirements ) ) { $ requirements = [ $ requirements ] ; } foreach ( $ requirements as $ constraint ) { $ this -> requirements [ ] = $ constraint ; } unset ( $ this -> options [ 'requirements' ] ) ; return $ this ; }
Set requirements.
Set requirements .