Drupal 8  8.0.2
AccountForm Class Reference
Inheritance diagram for AccountForm:

Public Member Functions

 __construct (EntityManagerInterface $entity_manager, LanguageManagerInterface $language_manager, QueryFactory $entity_query)
 
 alterPreferredLangcodeDescription (array $element)
 
 syncUserLangcode ($entity_type_id, UserInterface $user, array &$form, FormStateInterface &$form_state)
 
 submitForm (array &$form, FormStateInterface $form_state)
 
- Public Member Functions inherited from ContentEntityForm
 __construct (EntityManagerInterface $entity_manager)
 
 form (array $form, FormStateInterface $form_state)
 
 submitForm (array &$form, FormStateInterface $form_state)
 
 getFormLangcode (FormStateInterface $form_state)
 
 isDefaultFormLangcode (FormStateInterface $form_state)
 
 getFormDisplay (FormStateInterface $form_state)
 
 setFormDisplay (EntityFormDisplayInterface $form_display, FormStateInterface $form_state)
 
 updateFormLangcode ($entity_type_id, EntityInterface $entity, array $form, FormStateInterface $form_state)
 
 updateChangedTime (EntityInterface $entity)
 
- Public Member Functions inherited from EntityForm
 setOperation ($operation)
 
 getBaseFormId ()
 
 getFormId ()
 
 buildForm (array $form, FormStateInterface $form_state)
 
 form (array $form, FormStateInterface $form_state)
 
 processForm ($element, FormStateInterface $form_state, $form)
 
 afterBuild (array $element, FormStateInterface $form_state)
 
 submitForm (array &$form, FormStateInterface $form_state)
 
 save (array $form, FormStateInterface $form_state)
 
 buildEntity (array $form, FormStateInterface $form_state)
 
 getEntity ()
 
 setEntity (EntityInterface $entity)
 
 getEntityFromRouteMatch (RouteMatchInterface $route_match, $entity_type_id)
 
 getOperation ()
 
 setModuleHandler (ModuleHandlerInterface $module_handler)
 
 setEntityManager (EntityManagerInterface $entity_manager)
 
 setEntityTypeManager (EntityTypeManagerInterface $entity_type_manager)
 
- Public Member Functions inherited from EntityFormInterface
 setStringTranslation (TranslationInterface $string_translation)
 
- Public Member Functions inherited from ContentEntityFormInterface
 validateForm (array &$form, FormStateInterface $form_state)
 

Static Public Member Functions

static create (ContainerInterface $container)
 
- Static Public Member Functions inherited from ContentEntityForm
static create (ContainerInterface $container)
 

Protected Member Functions

 getEditedFieldNames (FormStateInterface $form_state)
 
 flagViolations (EntityConstraintViolationListInterface $violations, array $form, FormStateInterface $form_state)
 
- Protected Member Functions inherited from ContentEntityForm
 getEditedFieldNames (FormStateInterface $form_state)
 
 init (FormStateInterface $form_state)
 
 initFormLangcodes (FormStateInterface $form_state)
 
 copyFormValuesToEntity (EntityInterface $entity, array $form, FormStateInterface $form_state)
 
- Protected Member Functions inherited from EntityForm
 init (FormStateInterface $form_state)
 
 actionsElement (array $form, FormStateInterface $form_state)
 
 actions (array $form, FormStateInterface $form_state)
 
 copyFormValuesToEntity (EntityInterface $entity, array $form, FormStateInterface $form_state)
 
 prepareEntity ()
 
 prepareInvokeAll ($hook, FormStateInterface $form_state)
 

Protected Attributes

 $languageManager
 
 $entityQuery
 
- Protected Attributes inherited from ContentEntityForm
 $entityManager
 
- Protected Attributes inherited from EntityForm
 $operation
 
 $moduleHandler
 
 $entityManager
 
 $entityTypeManager
 
 $entity
 

Detailed Description

Form controller for the user account forms.

Constructor & Destructor Documentation

__construct ( EntityManagerInterface  $entity_manager,
LanguageManagerInterface  $language_manager,
QueryFactory  $entity_query 
)

Constructs a new EntityForm object.

Parameters
\Drupal\Core\Entity\EntityManagerInterface$entity_managerThe entity manager.
\Drupal\Core\Language\LanguageManagerInterface$language_managerThe language manager.
\Drupal\Core\Entity\Query\QueryFactory$entity_queryThe entity query factory.

References Drupal\entityQuery(), and Drupal\languageManager().

Here is the call graph for this function:

Member Function Documentation

alterPreferredLangcodeDescription ( array  $element)

Alters the preferred language widget description.

Parameters
array$elementThe preferred language form element.
Returns
array The preferred language form element.

References t().

Here is the call graph for this function:

static create ( ContainerInterface  $container)
static

{}

flagViolations ( EntityConstraintViolationListInterface  $violations,
array  $form,
FormStateInterface  $form_state 
)
protected

{}

References EntityConstraintViolationListInterface\getByFields(), and FormStateInterface\setErrorByName().

Here is the call graph for this function:

getEditedFieldNames ( FormStateInterface  $form_state)
protected

{}

submitForm ( array &  $form,
FormStateInterface  $form_state 
)

{Form submission handler.

Parameters
array$formAn associative array containing the structure of the form.
\Drupal\Core\Form\FormStateInterface$form_stateThe current state of the form.
}

Implements FormInterface.

References EntityForm\getEntity().

Here is the call graph for this function:

syncUserLangcode (   $entity_type_id,
UserInterface  $user,
array &  $form,
FormStateInterface $form_state 
)

Synchronizes preferred language and entity language.

Parameters
string$entity_type_idThe entity type identifier.
\Drupal\user\UserInterface$userThe entity updated with the submitted values.
array$formThe complete form array.
\Drupal\Core\Form\FormStateInterface$form_stateThe current state of the form.

References TranslatableInterface\getUntranslated().

Here is the call graph for this function:


The documentation for this class was generated from the following file: