src/Form/Model/Attribute/Accessor/Type.php
public function setType(?string $type)
    {
        if (null !== $type && $this->getTypes() && !in_array($type, $this->getTypes(), true)) {
            throw new DomainException('Type does not exist.');
        }

        $this->type = $type;

        return $this;
    }
public function setType(?string $type)
    {
        if (null !== $type && $this->getTypes() && !in_array($type, $this->getTypes(), true)) {
            throw new DomainException('Type does not exist.');
        }

        $this->type = $type;

        return $this;
    }
Set type

@param string $type
@return object