title: Writing/reading an ArrayList of Parcelable objects
body: <p>I have a class called <code>ClassA</code> which contains a <code>List</code> of <code>ClassB</code> objects. Both classes implement <code>Parcelable</code>.</p>
  
  <p>I am trying to create the read/write methods for this list in <code>ClassA</code> and am having trouble. For example I tried:</p>
  
  <pre><code>@Override
  public void writeToParcel(Parcel dest, int flags) {
      dest.writeList(mClassBList);
  }
  </code></pre>
  
  <p>but then</p>
  
  <pre><code>private ClassA(Parcel in) { 
      mClassBList = in.readList();
  }
  </code></pre>
  
  <p>throws an error because it needs all these extra arguments.</p>
  
  <p>How do I correctly read/write this <code>List</code>?</p>