title: Error while working with List<? extends DefaultMutableTreeNodel>
body: <pre><code>public void findClassNodesMatching(String lowerCaseSearchText, List&lt;? extends DefaultMutableTreeNode&gt; foundNodes) {
      findClassNodesMatching(lowerCaseSearchText, (DefaultMutableTreeNode) getRoot(), foundNodes);
  }
  
  private void findClassNodesMatching(String lowerCaseSearchText, DefaultMutableTreeNode node, List&lt;? extends DefaultMutableTreeNode&gt; foundNodes) {
      String nodeLabel = node.toString().toLowerCase();
      if (nodeLabel.indexOf(lowerCaseSearchText) &gt;= 0) {
          foundNodes.add(node);
      }
  }
  </code></pre>
  
  <p><strong>Why does this code give an error</strong> </p>
  
  <blockquote>
    <p>The method add(capture#2-of ? extends DefaultMutableTreeNode) in the
    type List is not
    applicable for the arguments (DefaultMutableTreeNode)</p>
  </blockquote>
  
  <p><strong>The error is at the line of</strong> <code>foundNodes.add(node);</code></p>