ContentEntityFormInterface::validateForm

public ContentEntityFormInterface::validateForm(array &$form, FormStateInterface $form_state)

Note that extending classes should not override this method to add entity validation logic, but define further validation constraints using the entity validation API and/or provide a new validation constraint if necessary. This is the only way to ensure that the validation logic is correctly applied independently of form submissions; e.g., for REST requests. For more information about entity validation, see https://www.drupal.org/node/2015613.

Return value

\Drupal\Core\Entity\ContentEntityTypeInterface The built entity.

Overrides FormInterface::validateForm

File

core/lib/Drupal/Core/Entity/ContentEntityFormInterface.php, line 76

Class

ContentEntityFormInterface
Defines a common interface for content entity form classes.

Namespace

Drupal\Core\Entity

Code

public function validateForm(array &$form, FormStateInterface $form_state);
doc_Drupal
2016-10-29 08:57:19
Comments
Leave a Comment

Please login to continue.