title: Java Generic Wildcard Constructor not accepting objects?
body: <p>I have a RandomizedWrapper class. This class contains a constructor that accepts a list:</p>
  <pre><code>public class RandomizedWrapper{
  
     final int upperBound = 100;
     final List&lt;RandomizerEntry&lt;?&gt;&gt; randomizeList;
     Map&lt;Integer, RandomizerEntry&lt;?&gt;&gt; randomizerMap;
  
  /**
   * Construct a new RandomizedWrapper instance
   * 
   * @param randomizeList - A list containing all randomizable objects
   */
  public RandomizedWrapper(final List&lt;RandomizerEntry&lt;?&gt;&gt; randomizeList) {
      
      this.randomizeList = randomizeList;
      this.randomizerMap = new HashMap&lt;&gt;();
     }
  }
  </code></pre>
  <p>I want to create a new instance of this RandomizedWrapper class. I do via the following code:</p>
  <pre><code>    List&lt;RandomizerEntry&lt;ItemStack&gt;&gt; randomizerList = new ArrayList&lt;&gt;();
  
      //stuff here
  
      RandomizedWrapper wrapper = new RandomizedWrapper(randomizerList);//error
  </code></pre>
  <p>When I attempt to create this new object, I run into the following error:</p>
  <pre><code>The constructor RandomizedWrapper(List&lt;RandomizerEntry&lt;ItemStack&gt;&gt;) is undefined
  </code></pre>
  <p>This makes no sense. I very clearly have a constructor in the RandomizedWrapper class that accepts a <code>List&lt;RandomizerEntry&lt;?&gt;&gt;</code> wildcards. A proposed solution by the compiler says &quot;<code>create a constructor that accepts this argument</code>&quot;. I click that, just to see what happens, and it tells me &quot;<code>This constructor already exists</code>&quot;.</p>
  <p>Does anyone understand whats going on here? Why can't I instantiate this object?</p>