2.x
getFormElement
public function getFormElement($type, $definition, $data, $object_schema = NULL, $form_state = NULL, array $context = []) {