set name
@param string $name
@return Controller
@throws \InvalidArgumentException
13272
public function setName($name)
    {
        $this->validateName($name);

        if (!$this->name) {
            $this->name = $name;
        } elseif ($this->name !== $name) {
            $this->setAliases([$name]);
        }
        return $this;
    }
523270
public function setName($name)
    {
        if (is_string($name) === true) {
            $this->name = $name;
        } else {
            $msg = "The 'name' argument must be a string, '" . gettype($name) . "' given.";
            throw new InvalidArgumentException($msg);
        }
    }
973453
public function setController($controller, $name = null)
    {
        $controller = $this->app->normalizeClassName($controller, 'Controller');

        return $this->add($controller, $name);
    }
450970
function setName($name)
    {
        if ($this->name !== null)
            throw new \Exception(sprintf(
                "Event with name (%s) are immutable. can`t set name (%s)."
                , $this->name, \Poirot\Std\flatten($name)
            ));

        $this->name = (string) $name;
        return $this;
    }
70250
public function setDriver($name)
    {
        $class = '\\Samurai\\Onikiri\\Driver\\' . ucfirst($name) . 'Driver';
        if (! class_exists($class)) throw new \InvalidArgumentException("No such driver. -> {$name}");
        
        $driver = new $class();
        $this->driver = $driver;
    }
719184
public function setName($name, $isEmpty = NULL)
	{
		if ($name !== NULL && !is_string($name)) {
			throw new InvalidArgumentException(sprintf('Name must be string or NULL, %s given.', gettype($name)));
		}

		$this->name = $name;
		$this->isEmpty = $isEmpty === NULL ? isset(static::$emptyElements[$name]) : (bool)$isEmpty;

		return $this;
	}
1245948
public function setName($name)
    {
        //Check for invalid cookie name (from PHP source code)
        if (preg_match("/[=,; \t\r\n\013\014]/", $name)) {
            throw new InvalidArgumentException(sprintf('The cookie name "%s" contains invalid characters.', $name));
        }

        //Check for empty cookie name
        if (empty($name)) {
            throw new InvalidArgumentException('The cookie name cannot be empty.');
        }

        $this->_name = $name;
        return $this;
    }
332147
public function setName($name) {
        if ($name !== null && ! $this->argumentsParser->isOptionName($name)) {
            throw new InvalidOptionNameException(s(
                'A option name must have this format: "--option", got: "%s"', $name
            ));
        }

        $this->name = $name;

        return $this;
    }
1167060
public function setName($name)
  {
    $allowedValues = $this->getNameAllowableValues();
    if (!is_null($name) && !in_array($name, $allowedValues)) {
      throw new \InvalidArgumentException(
        sprintf(
          "Invalid value for 'name', must be one of '%s'",
          implode("', '", $allowedValues)
        )
      );
    }
    $this->container['name'] = $name;

    return $this;
  }
510308
public function setName($name)
    {
        $this->name = $name;
        if (isset($_FILES) && array_key_exists($name, $_FILES)) {
            $this->setValue($_FILES[$name]);
        }
        return $this;
    }
1082395
public function setName($name) {
    if (($pos = mb_strrpos($name,'.')) !== FALSE) {
      $this->name = mb_substr($name, 0, $pos);
      $this->extension = mb_substr($name, $pos+1);
    } else {
      $this->name = $name;
    }
    
    return $this;
  }
628721
public function setName($name)
    {
        if (in_array($name, Statistics::asArray())) {
            $this->name = $name;
        } else {
            $msg = "The name argument must be a value from the Statistics enumeration, '" . $name . "' given.";
            throw new InvalidArgumentException($msg);
        }
    }
683823
public function setName($name) {
        if ($this->frozen) throw new RuntimeException('Configuration of "'.get_class($this).'" is frozen');

        $this->validateName($name);
        $this->name = $name;

        if ($name === '') {
            $this->aliases = [];                                    // a default command cannot have aliases
        }
        else {
            $this->aliases = array_diff($this->aliases, [$name]);   // remove overlapping aliases
        }
        return $this;
    }
297357
public function & SetControllerName ($controllerName) {
		/** @var $this \MvcCore\Request */
		$this->controllerName = $controllerName;
		$routerClass = self::$routerClass;
		$router = & $routerClass::GetInstance();
		$this->params[$router::URL_PARAM_CONTROLLER] = $controllerName;
		
		return $this;
	}
192629
function setName($name)
    {
        $selfCurrName = $this->getName();

        if ($name == $selfCurrName)
            // Nothing To Do!!!
            return $this;


        # Change Route Name:
        $this->name = (string) $name;


        ## Change Name of Nested Routes:
        #
        /** @var iRoute $route */
        foreach($this->_priorityQueue() as $route) {
            $nestedName    = $route->getName();
            $nestedNewName = $name. substr($nestedName, strlen($selfCurrName));

            $route->setName($nestedNewName);

            $nr = $this->routesAdd[$nestedName];
            $nr->setName($nestedNewName);

            unset( $this->routesAdd[$nestedName] );
            $this->routesAdd[$nestedNewName] = $nr;
        }


        return $this;
    }
879887
public function setName($name)
    {
        if (strpos(self::PATH_SEPARATOR, $name) !== false) {
            throw new \InvalidArgumentException(
                'Invalid character "' . self::PATH_SEPARATOR . '" in resource name.'
            );
        }

        $this->name = $name;
    }
1207557
public function setName($name)
    {
        if (in_array($name, MathEnumeration::asArray())) {
            $this->name = $name;
        } else {
            $msg = "${name} is not a valid QTI Math constant.";
            throw new InvalidArgumentException($msg);
        }
    }