title: Can you force a generic type to be generic too?
body: <p>Suppose you have a generic class</p>
  <pre><code>class MyClass&lt;T&gt; { ... }
  </code></pre>
  <p>You can force <code>T</code> to extend or implement a class or an interface, respectively, by writing</p>
  <pre><code>class MyClass&lt;T extends ThisClassOrThisInterface&gt; { ... }
  </code></pre>
  <p>You can even make this construction fully parametric, by abstracting on <code>ThisClassOrThisInterface</code>, namely</p>
  <pre><code>class MyClass&lt;U, T extends U&gt; { ... }
  </code></pre>
  <p><strong>My question is</strong>: Is there a way to force <code>T</code> to be a parameterized type? For instance, in a way that</p>
  <pre><code>class AnotherClass extends MyClass&lt;List&lt;?&gt;&gt;
  </code></pre>
  <p>shall be fine, because <code>List</code> is a generic type, but</p>
  <pre><code>class AnotherClass extends MyClass&lt;Object&gt;
  </code></pre>
  <p>shall not, because <code>Object</code> cannot be parameterized over any type.</p>
  <hr />
  <p>I was trying to understand how much you can play with generics. In particular, I was trying to implement the following class (pretend that <code>&lt;T&lt;?&gt;&gt;</code> forces <code>T</code> to be a generic type):</p>
  <pre><code>class MyClass&lt;T&lt;?&gt;&gt; {
  
      &lt;A&gt; Function&lt;A, T&lt;A&gt;&gt; myMethod() { ... }
  
  }
  </code></pre>