Symfony\Component\Form\FormRegistryInterface::getType
Returns a form type by name.
This methods registers the type extensions from the form extensions.
Signature
public function getType(string
$name )
Parameters
$name
— string- The name of the type
Returns
- ResolvedFormTypeInterface
- The type
Errors/Exceptions
-
UnexpectedTypeException
- if the passed name is not a string
-
InvalidArgumentException
- if the type can not be retrieved from any extension