public function setScope($scope)
    {
        if (in_array($scope, $this->scopes) === false) {
            throw Exception\Scope::invalidScope($scope, $this->scopes);
        }

        $this->scope = $scope;

        return $this;
    }
public function setScope($scope)
    {
        if (in_array($scope, $this->scopes) === false) {
            throw Exception\Scope::invalidScope($scope, $this->scopes);
        }

        $this->scope = $scope;

        return $this;
    }
public function setScope ( $ scope ) { if ( in_array ( $ scope , $ this -> scopes ) === false ) { throw Exception \ Scope :: invalidScope ( $ scope , $ this -> scopes ) ; } $ this -> scope = $ scope ; return $ this ; }
Set the current scope

@param  string $scope    (See ScopeInterface::SCOPE_*)

@return $this

@throws Exception\Scope  When the scope does not exists
Set the current scope