title: Calling all the getters from an entity
body: <p>After using: <br></p>
  
  <pre><code>$queryResult = 
      $this
          -&gt;getDoctrine()
          -&gt;getRepository('EtecsaAppBundle:Paralizacion')
          -&gt;createQueryBuilder('e')
          -&gt;getQuery();
          -&gt;setDQL($myOwnQuery)
          -&gt;getResult();
  </code></pre>
  
  <p>I have an array of entities for which I want to use all their property getters. I'm doing this like this:</p>
  
  <pre><code>foreach ($queryResult as $index =&gt; $itemEntity)
  {
      $objWorksheet-&gt;SetCellValue('A'. ($index + 17 ), $index + 1);
      // ... The itemEntity class has entity relationships associations 
      $objWorksheet-&gt;SetCellValue('B'. ($index + 17 ), $itemEntity-&gt;getSomeRelatedProperty()-&gt;getSomeProperty());
      // ... it also has properties with several types (date, string, etc)
      $objWorksheet-&gt;SetCellValue('C'. ($index + 17 ), $itemEntity-&gt;getSomeProperty));
      // Also some of the values obtained from his respective getter require some processing
      $objWorksheet-&gt;SetCellValue('D'. ($index + 17 ), getProcessedValue($itemEntity-&gt;getSomeSpecificProperty));
  }
  </code></pre>
  
  <p>The letter used in SetCellValue function will also increase. I'm putting this as an example.
  Is there a way to dynamically call all the getters of the entity, so I don't have to call them one by one? Something like this for example:</p>
  
  <pre><code>foreach ($queryResult as $index =&gt; $itemEntity)
  {
      $columnLetter = 'A';
      $objWorksheet-&gt;SetCellValue($columnLetter++ . ($index + 17 ), $index + 1);
  
      arrayOfGetters = getArrayOfGetters(itemEntity);
      foreach (arrayOfGetters as $getterMethod)
      {
          // properties that reference an entity relationship association would have the __ToString function
          $objWorksheet-&gt;SetCellValue($columnLetter++ . ($index + 17 ), /* get value of getterMethod */);
      }
  }
  </code></pre>