title: Generics in java.util.ArrayList
body: <p>I've opened java.util.ArrayList source code, and I can't understand one thing: why elementData[] array is of type Object if ArrayList is parametrized?</p>
  
  <pre><code>public class ArrayList&lt;E&gt; extends ... {
    .........
    private transient Object[] elementData;
    .........
    public boolean add(E e) {/*More code*/}
  }
  </code></pre>
  
  <p><strong>Question</strong>: Why don't define elementData as:</p>
  
  <pre><code>private transient E[] elementData
  </code></pre>
  
  <p>*what advantages and disadvantages?</p>