mediaEntity = $media_entity; $this->file = $file; $this->form = $form; $this->formState = $form_state; $this->element = $element; } /** * Get the media entity. * * @return \Drupal\media_entity\MediaInterface * A media entity. */ public function getMediaEntity() { return $this->mediaEntity; } /** * Set the media entity. * * @param \Drupal\media_entity\MediaInterface $media_entity * The updated media entity. */ public function setMediaEntity(MediaInterface $media_entity) { $this->mediaEntity = $media_entity; } /** * Get the file for the media entity. * * @return \Drupal\file\FileInterface * The file that will be used for the media entity. */ public function getFile() { return $this->file; } /** * Get the form that contains the Dropzone element. * * @return array * The form that contains the Dropzone element. */ public function getForm() { return $this->form; } /** * Get the form state. * * @return \Drupal\Core\Form\FormStateInterface * The current formstate. */ public function getFormState() { return $this->formState; } /** * Set the form state. * * @param \Drupal\Core\Form\FormStateInterface $form_state * The updated form state. */ public function setFormState(FormStateInterface $form_state) { $this->formState = $form_state; } /** * Get the Dropzone form element. * * @return array * The dropzone element. */ public function getElement() { return $this->element; } /** * Set the Dropzone form element. * * @param array $element * The updated form element. */ public function setElement(array $element) { $this->element = $element; } }