title: Symfony2 - get entity object in PRE_SUBMIT event
body: <p>I have a form and <code>PRE_SUBMIT</code> event added. </p>
  
  <pre><code>$builder-&gt;addEventListener(FormEvents::PRE_SUBMIT, array($this, 'onPreSubmit'));
  </code></pre>
  
  <p>Now when I dump form data in the event I get an array and not an object. </p>
  
  <pre><code>public function onPreSubmit(FormEvent $event)
  {
      $form = $event-&gt;getForm();
      /** @var Offer $offer */
      $offer = $event-&gt;getData();
  
      var_dump($offer);
      die;
  }
  </code></pre>
  
  <p>Here in the event I would like to check the state field of entity which is not in the form and depending on state add some constraints to certain fields. </p>
  
  <p>The array does not contain <code>id</code> of an entity...</p>
  
  <p>P.S. I would use <code>SUBMIT</code> to get an entity object, but in this case <code>SUBMIT</code> event is too late to add the constraints.</p>