public function setType($fieldIndex, $type): self
    {
        $this->checkFieldIndex($fieldIndex);
        if (is_string($fieldIndex)) {
            $fieldIndex = $this->namesHash[$fieldIndex];
        }

        $this->converters[$fieldIndex] = $this->converterFactory->getConverterForTypeSpecification($type);

        return $this;
    }