public function getType(string $type): Type
    {
        if (isset($this->types[$type])) {
            return $this->types[$type];
        }

        $instance = $this->createType($type);
        $this->addType($instance);
        $this->types[$type] = $instance;

        return $instance;
    }