title: Java: For each loop , Iteration over extended objects
body: <p>My Question might be very simple, </p>
  
  <p>I have a class <code>Result</code> with some inner fields , setters and getters. </p>
  
  <p>Additionally, i have class <code>Special1Result</code> which extends <code>Result</code> and includes several more fields and <code>Special2Result</code> with some more data.</p>
  
  <p>In different class <code>Dispatcher</code>, i have written the following method:</p>
  
  <p><code>processResults(List&lt;? extends Result&gt; results)</code>, which is only familiar with <code>Result</code> (I need this method to query if there is specific field in the extended Result object - i am using annotations).</p>
  
  <p>So i have decided to use the extended for-each loop: <code>for (Result res : results) {}</code></p>
  
  <p>So what is my question ? i am trying to find over the web how to write this for loop for extended objects, e.g. something like this <code>for (? extends Results res: results){}</code></p>
  
  <p>Is it possible? How is the correct way to write it? </p>