Check if the name is valid.

@param string $name The name to check.
@return boolean
328855
protected function isNameValid($name)
    {
        if (is_string($name) === false) {
            return false;
        }

        $match = preg_match(self::PATTERN_VALIDATE_NAME, $name);
        if ($name === '' || $match === false || $match <= 0) {
            return false;
        } else {
            return true;
        }
    }
80394
public function has(string $name): bool
	{
		return isset($this->headers[$this->normalizeName($name)]);
	}
882907
public function headerExists($name)
    {
        $name = strtolower($name);
        if(isset($this->_headers[$name])) {
            return true;
        } else {
            return false;
        }
    }
1072544
public function is($name)
    {
        foreach ($this->roles as $role) {
            if ($role->name == $name || $role->slug == $name || $role->id == $name) {
                return true;
            }
        }

        return false;
    }
238066
private function checkName(&$name)
    {
        if (! is_string($name)) {
            throw new InvalidTypeException(
                'The tag type must be a string, ' . gettype($name) . ' is given.'
            );
        }

        $name = strtolower(trim($name));
    }
817739
protected function nameAccepted($name) {
		if ($this->nameValidator) {
			if (is_callable($this->nameValidator)) {
				$res = call_user_func($this->nameValidator, $name);
				return $res;
			}
			if (preg_match($this->nameValidator, '') !== false) {
				return preg_match($this->nameValidator, $name);
			}
		}
		return true;
	}
1326934
public function has($name)
    {
        $key = mb_strtolower($name);
        foreach ($this->cookies as $cookie) {
            if (mb_strtolower($cookie->getName()) === $key) {
                return true;
            }
        }

        return false;
    }
627474
protected function nameAccepted($name) {
		if ($this->nameValidator) {
			if (function_exists($this->nameValidator)) {
				$f = $this->nameValidator;
				return $f($name);
			}
			return preg_match($this->nameValidator, $name);
		}
		return true;
	}
1054647
public function hasParameter(string $name): bool
    {
        return isset($this->parameters[$name]) || array_key_exists($name, $this->parameters);
    }
118969
private static function validateName(string $name) : string
  {
    if (empty($name) || preg_match("/[=,; \t\r\n\013\014]/", $name)) {
      throw new \InvalidArgumentException(sprintf('Invalid name \'%s\'.', $name));
    }

    return $name;
  }
842301
public function has($name)
    {
        $checker = $this->_classes['checker'];
        return isset($this->_handlers[$name]) || $checker::has($name);
    }
794605
public function has($name)
    {
        /** @var Setting $setting */
        $setting = $this->repo->findOneBy(['name.name' => $name]);

        if ($setting) {
            return true;
        }

        return false;
    }
842208
public static function has($name) {
		if(empty($name)) {
			throw new InvalidArgumentException('Domain name can not be empty!');
		}
		if(!\App::$domain->has($name)) {
			return false;
		}
		$domain = \App::$domain->get($name);
		if(!$domain instanceof Domain) {
			return false;
		}
		return true;
	}
721335
public static function has(string $name)
    {
        $names = Imi::parseDotRule($name);
        if (isset($names[0]))
        {
            $first = array_shift($names);
            if(isset(static::$configs[$first]))
            {
                return null !== static::$configs[$first]->get($names, null);
            }
            else
            {
                return false;
            }
        }
        else
        {
            return false;
        }
    }
738627
protected function validateName($name = null)
    {
        if (null == $name) {
            $name = $this->name;
        }

        if (strlen($name) > OBJECT_NAME_LIMIT) {
            throw new Exceptions\InvalidObjectName();
        }
    }
84012
public function __isset( string $name ) {
		return (bool) $this->$name ?? $this->_attributes[ $name ] ?? FALSE;
	}
645934
public function isValid( $name, $value = null )
    {
        if( !isset( $this->enums[$name] ) ) {
            return false;
        } elseif( $value === null ) {
            return true;
        }
        return !isset( $value ) || in_array( $value, $this->enums[$name] );
    }