title: JMS Serializer cannot serialize Entity with interface
body: <p>I am trying to develop a Symfony2 API using the FOSRestBundle but I am stuck with an error regarding the serialization of one of my Doctrine entity (I'm using the JMS Serializer bundle for serialization).</p>
  
  <p>The error message is the following : "<strong>Resources are not supported in serialized data</strong>"</p>
  
  <p>The serialization worked until I made my entity implement a custom interface :</p>
  
  <pre><code>/**
   * Quotation
   *
   * @ORM\Table(name="quotation")
   * @ORM\Entity
   */
  class Quotation implements FileStorageInterface
  {
      // content
  }
  </code></pre>
  
  <p>And the interface :</p>
  
  <pre><code>interface FileStorageInterface
  {
      public function getFile();
  
      public function setFile($file);
  }
  </code></pre>
  
  <p>I searched online but couldn't find anything about serializing an entity implementing an interface. So if anyone has an idea on how to solve this, I would gladly accept it.</p>