protected function createType($typeName)
    {
        if (isset($this->typeCache[$typeName])) {
            return clone $this->typeCache[$typeName];
        }


        if (!$this->hasExtension($typeName)) {
            $class = $this->typeToClassName($typeName);
            $this->typeCache[$typeName] = new $class();
            return clone $this->typeCache[$typeName];
        }

        $this->typeCache[$typeName] = $this->callExtension($typeName, [$typeName, $this]);

        return clone $this->typeCache[$typeName]->setName($typeName);
    }
protected function createType($typeName)
    {
        if (isset($this->typeCache[$typeName])) {
            return clone $this->typeCache[$typeName];
        }


        if (!$this->hasExtension($typeName)) {
            $class = $this->typeToClassName($typeName);
            $this->typeCache[$typeName] = new $class();
            return clone $this->typeCache[$typeName];
        }

        $this->typeCache[$typeName] = $this->callExtension($typeName, [$typeName, $this]);

        return clone $this->typeCache[$typeName]->setName($typeName);
    }
protected function createType ( $ typeName ) { if ( isset ( $ this -> typeCache [ $ typeName ] ) ) { return clone $ this -> typeCache [ $ typeName ] ; } if ( ! $ this -> hasExtension ( $ typeName ) ) { $ class = $ this -> typeToClassName ( $ typeName ) ; $ this -> typeCache [ $ typeName ] = new $ class ( ) ; return clone $ this -> typeCache [ $ typeName ] ; } $ this -> typeCache [ $ typeName ] = $ this -> callExtension ( $ typeName , [ $ typeName , $ this ] ) ; return clone $ this -> typeCache [ $ typeName ] -> setName ( $ typeName ) ; }
Creates a type by a name

@param string $typeName

@return AbstractType
Creates a type by a name