title: Can I simplify this Java Generics Hierarchy
body: <p>Sometimes in my code I'd like to refer to (what I think of as) the implicit type in a generics heirarchy (basically the type implied by the first ? in the following).  </p>
  
  <pre><code>public class Foo&lt;BAR extends Bar&lt;?&gt;&gt; {
    public void t(BAR x) {
      List l = new ArrayList();
      Object baz = x.makeBaz(null);
      l.add(baz);
      x.setBazList(l);
    }
  }
  
  public interface Bar&lt;BAZ extends Number&gt; {
    public BAZ makeBaz(Object arg1);
    public List&lt;BAZ&gt; getBazList();
    public void setBazList(List&lt;BAZ&gt; baz);
  }
  </code></pre>
  
  <p>For example in the above code would it be possible to replace the lines</p>
  
  <pre><code>    List l = new ArrayList();
      Object baz = x.makeBaz(null);
  </code></pre>
  
  <p>with something using generics?</p>
  
  <p>I would prefer to avoid having to write:</p>
  
  <pre><code>public class Foo&lt;BAZ extends Number, BAR extends Bar&lt;BAZ&gt;&gt; {
    public void t(BAR x) {
      List&lt;BAZ&gt; l = new ArrayList&lt;BAZ&gt;();
      BAZ baz = x.makeBaz(null);
      l.add(baz);
    }
  }
  </code></pre>
  
  <p>since it feels unnatural to force this on the declaration of any derived classes.</p>
  
  <p>I know the above is a bit contrived, but it's a lot simpler than trying to show the actual code I'm looking at.</p>