Returns the complete name of a class

@param string $defaultNS
@param string $name
@return string
541844
public static function getClassNameWithNS($defaultNS, $name) {
		if (\strpos ( $name, "\\" ) === false) {
			$name = $defaultNS . "\\" . $name;
		}
		return $name;
	}
26775
protected function buildClassNameFromName($name)
	{
		$class_name_parts = explode(' ', $name);

		return count($class_name_parts) == 1 ? $name : implode('', array_map('ucfirst', $class_name_parts));
	}
26492
public static function fromNCNameAndDefault( $qname, $resolver, $defaultNs )
	{
		$qn = \lyquidity\xml\qname( $qname, $resolver->getNamespaces() );
		if ( ! $qn )
		{
			if ( strpos( $qname, ":" ) )
			{
				$prefix = strstr( $qname, ":", true );

				// Look to see if the default namespace is relevant
				$types = SchemaTypes::getInstance();
				$schemas = $types->getProcessedSchemas();
				if ( isset( $schemas[ $prefix ] ) )
				{
					$qn = \lyquidity\xml\qname( $qname, $schemas );
				}
				else
				{
					$namespace = $resolver->lookupNamespace( $prefix );
					if ( ! $namespace )
					{
						throw XPath2Exception::withErrorCodeAndParams( "XPST0081", Resources::XPST0081, array( $qname, "xs:QName" ) );
					}
				}
			}

			if ( ! $qn )
			{
				throw XPath2Exception::withErrorCodeAndParams( "FORG0001", Resources::FORG0001, array( $qname, "xs:QName" ) );
			}
		}

		if ( empty( $qn->prefix ) )
		{
			return QNameValue::fromParts( "", $qn->localName, $defaultNs, $resolver );
		}

		if ( empty( $qn->namespaceURI ) )
		{
			throw XPath2Exception::withErrorCodeAndParam( "XPST0081", Resources::XPST0081, $qn->prefix );
		}

		$pattern = NameValue::$ncName;
		if ( ! preg_match( "/" . NameValue::$ncName . "/u", $qn->localName ) )
		{
			throw XPath2Exception::withErrorCodeAndParams( "FORG0001", Resources::FORG0001, array( $qname, "xs:QName" ) );
		}

		// The prefix may defined with a local namespace:
		//
		// <el xmlns:z="http://example.com">z:qn</el>
		//
		// This qn will not be comparable with another qn with another definition in the parent
		//
		// <root xmlns:t="http://example.com">
		//   <el>t:qn</el>
		// <root>
		// To make the q names comparable make sure the prefix is that of the namespace defined in the parent if there is one
		// This can be done by removing the prefix from the list of namespaces.  If there is a parent namespace it will still
		// be in the list and can be located and the prefix changed accordingly.

		$namespaces = $resolver->getNamespaces();
		unset( $namespaces[ $qn->prefix ] );
		foreach ( $namespaces as $prefix => $namespace )
		{
			if ( $namespace == $qn->namespaceURI )
			{
				$qn->prefix = $prefix;
				break;
			}
		}
		return QNameValue::fromParts( $qn->prefix, $qn->localName, $qn->namespaceURI, $resolver );
	}
1191315
private static function _extractClassName($cls)
    {
        $tokens = preg_split("/\\\\/", $cls);
        $size   = sizeof($tokens);
        if ($size < 2) {
            return $cls;
        }
        return $tokens[$size-1];
    }
197127
public function header($name, $default = NULL) {
    if (isset($this->headers[$name])) {
      return $this->headers[$name];
    }
    return $default;
  }
1041958
public static function getFQCLNFromNameObject(
        PhpParser\Node\Name $class_name,
        Aliases $aliases
    ) {
        /** @var string|null */
        $resolved_name = $class_name->getAttribute('resolvedName');

        if ($resolved_name) {
            return $resolved_name;
        }

        if ($class_name instanceof PhpParser\Node\Name\FullyQualified) {
            return implode('\\', $class_name->parts);
        }

        if (in_array($class_name->parts[0], ['self', 'static', 'parent'], true)) {
            return $class_name->parts[0];
        }

        return Type::getFQCLNFromString(
            implode('\\', $class_name->parts),
            $aliases
        );
    }
1056593
public function getByBasenameOrDefault($name, $default=null)
    {
        return $this->where(function(File $f) use($name)
        {
            return $f->getBasename() == $name;
        })->singleOrDefault($default);
    }
989197
protected function getClassname($name)
    {
        $result = implode(' ', explode('/', $name));
        $result = implode(' ', explode('-', $result));

        $result = ucwords($result);

        // replace non letter or digits by empty string
        $result = preg_replace('/[^\\pL\d]+/u', '', $result);

        // trim
        $result = trim($result, '-');

        // transliterate
        $result = iconv('UTF-8', 'US-ASCII//TRANSLIT', $result);

        // remove unwanted characters
        $result = preg_replace('/[^-\w]+/', '', $result);

        return $result;
    }
1346014
private function getValue($ref, $name, $default = null)
    {
        $refName = \is_object($ref) ? ClassLookup::getClass($ref) : $ref;

        if (isset($this->configuration[$refName][$name])) {
            return $this->configuration[$refName][$name];
        }

        if (false === \is_callable($default)) {
            return $default;
        }

        $page = \is_string($ref) ? new $refName() : $ref;
        $result = $default($page);
        unset($page);

        $this->configuration[$refName][$name] = $result;

        return $result;
    }
872260
public static function normalizeClassname(string $name): string
    {
        $name = self::normalizeReservedKeywords($name, 'Type');

        return ucfirst(self::camelCase($name, '{[^a-z0-9]+}i'));
    }
1276845
protected function createClassName(string $name): string
    {
        $result = str_replace('_', ' ', $name);

        return str_replace(' ', '', ucwords($result));
    }
660627
public function getClassName(string $name) : string
    {
        $name = str_replace("/", "\\", $name);
        $name = explode("\\", $name);
        $name = array_pop($name);
        $name = $this->removeNoneAlpherNumeric($name);
        return $name;
    }
872231
protected function parseName(string $name, string $default = self::DEFAULT_NAMESPACE): array
    {
        if ($this->hasHintInformation($name)) {
            return $this->parseNamespaceSegments($name);
        }

        return [$default, $name];
    }
440847
public function getHeader($name, $default = null)
    {
        if (!$this->request) {
            return $this->getRequest()->getHeader($name);
        }
        return parent::getHeader($name, $default);
    }
157996
protected function getEndpointClassName(string $name) : string {
        $className = sprintf(
            '%s\\%s\\%s',
            'idOS',
            'Endpoint',
            ucfirst($name)
        );

        if (! class_exists($className)) {
            throw new \RuntimeException(
                sprintf(
                    'Invalid endpoint name "%s" (%s)',
                    $name,
                    $className
                )
            );
        }

        return $className;
    }
1225022
public function get(string $name, $default = null)
    {
        $key = strtolower($name);
        if (!array_key_exists($key, $this->headers)) {
            return $default;
        }

        return $this->headers[$key]->getValuesAsString();
    }
418375
public function getSection($name, $default = '')
    {

        if ($this->getSectionCollection()->has($name)) {

            return $this->getSectionCollection()->get($name);
        }

        return $default;
    }