/** * @param Configuration $configuration * @return FormBuilder */ public static function create(Configuration $configuration) { /** @var FormBuilder $formBuilder */ $formBuilder = \TYPO3\CMS\Form\Utility\FormUtility::getObjectManager()->get(FormBuilder::class); $formBuilder->setConfiguration($configuration); return $formBuilder; }
/** * @param FormBuilder $formBuilder * @return CompatibilityLayerUtility */ public static function create(FormBuilder $formBuilder) { /** @var CompatibilityLayerUtility $compatibilityService */ $compatibilityService = \TYPO3\CMS\Form\Utility\FormUtility::getObjectManager()->get(CompatibilityLayerUtility::class); $compatibilityService->setFormBuilder($formBuilder); return $compatibilityService; }
/** * @param Configuration $configuration * @return FormBuilder */ public static function create(Configuration $configuration) { /** @var FormBuilder $formBuilder */ $formUtility = FormUtility::getObjectManager()->get(FormUtility::class); $formUtility->setConfiguration($configuration); return $formUtility; }
/** * Extends a given default ControllerContext. * * @param \TYPO3\CMS\Extbase\Mvc\Controller\ControllerContext * @return ControllerContext */ public static function extend(\TYPO3\CMS\Extbase\Mvc\Controller\ControllerContext $source) { $controllerContext = \TYPO3\CMS\Form\Utility\FormUtility::getObjectManager()->get(ControllerContext::class); $propertyNames = ObjectAccess::getGettableProperties($source); foreach ($propertyNames as $propertyName => $propertyValue) { ObjectAccess::setProperty($controllerContext, $propertyName, $propertyValue); } return $controllerContext; }
/** * @param FormBuilder $formBuilder * @param Element $element * @param array $userDefinedTypoScript * @return ElementBuilder */ public static function create(FormBuilder $formBuilder, Element $element, array $userDefinedTypoScript) { /** @var ElementBuilder $elementBuilder */ $elementBuilder = \TYPO3\CMS\Form\Utility\FormUtility::getObjectManager()->get(ElementBuilder::class); $elementBuilder->setFormBuilder($formBuilder); $elementBuilder->setElement($element); $elementBuilder->setUserConfiguredElementTyposcript($userDefinedTypoScript); return $elementBuilder; }
/** * @return Configuration */ public static function create() { return \TYPO3\CMS\Form\Utility\FormUtility::getObjectManager()->get(Configuration::class); }