title: What is the point of overloaded Convenience Factory Methods for Collections in Java 9
body: <p>Java 9 comes with <a href="http://openjdk.java.net/jeps/269">convenience factory methods</a> for creating immutable lists. Finally a list creation is as simple as:</p>
  
  <pre><code>List&lt;String&gt; list = List.of("foo", "bar");
  </code></pre>
  
  <p>But there are 12 overloaded versions of this method, 11 with 0 to 10 elements, and one with var args.</p>
  
  <pre><code>static &lt;E&gt; List&lt;E&gt;  of(E... elements)
  </code></pre>
  
  <p>Same is the case with <code>Set</code> and <code>Map</code>.</p>
  
  <p>Since there is a var args method, what is the point of having extra 11 methods?</p>
  
  <p>What I think is that var-args create an array, so the other 11 methods can skip creation of an extra object and in most cases 0 - 10 elements will do. Is there any other reason for this?</p>