SubmitButtonTypeInterface
extends
FormTypeInterface
in
A type that should be converted into a {@link SubmitButton} instance.
Tags
Table of Contents
- buildForm() : mixed
- Builds the form.
- buildView() : mixed
- Builds the form view.
- configureOptions() : mixed
- Configures the options for this type.
- finishView() : mixed
- Finishes the form view.
- getBlockPrefix() : string
- Returns the prefix of the template block name for this type.
- getParent() : string|null
- Returns the name of the parent type.
Methods
buildForm()
Builds the form.
public
buildForm(FormBuilderInterface $builder, array<string, mixed> $options) : mixed
This method is called for each type in the hierarchy starting from the top most type. Type extensions can further modify the form.
Parameters
- $builder : FormBuilderInterface
- $options : array<string, mixed>
Tags
Return values
mixed —buildView()
Builds the form view.
public
buildView(FormView $view, FormInterface $form, array<string, mixed> $options) : mixed
This method is called for each type in the hierarchy starting from the top most type. Type extensions can further modify the view.
A view of a form is built before the views of the child forms are built. This means that you cannot access child views in this method. If you need to do so, move your logic to instead.
Parameters
- $view : FormView
- $form : FormInterface
- $options : array<string, mixed>
Tags
Return values
mixed —configureOptions()
Configures the options for this type.
public
configureOptions(OptionsResolver $resolver) : mixed
Parameters
- $resolver : OptionsResolver
Return values
mixed —finishView()
Finishes the form view.
public
finishView(FormView $view, FormInterface $form, array<string, mixed> $options) : mixed
This method gets called for each type in the hierarchy starting from the top most type. Type extensions can further modify the view.
When this method is called, views of the form's children have already been built and finished and can be accessed. You should only implement such logic in this method that actually accesses child views. For everything else you are recommended to implement instead.
Parameters
- $view : FormView
- $form : FormInterface
- $options : array<string, mixed>
Tags
Return values
mixed —getBlockPrefix()
Returns the prefix of the template block name for this type.
public
getBlockPrefix() : string
The block prefix defaults to the underscored short class name with the "Type" suffix removed (e.g. "UserProfileType" => "user_profile").
Return values
string —The prefix of the template block name
getParent()
Returns the name of the parent type.
public
getParent() : string|null
Return values
string|null —The name of the parent type if any, null otherwise