@Test public void testParceable() { Parcel parcel = Parcel.obtain(); References<Foo> toParcel = new References<>(Foo.class, new long[]{1,2,3}); toParcel.writeToParcel(parcel, 0); parcel.setDataPosition(0); References fromParcel = References.CREATOR.createFromParcel(parcel); assertEquals(toParcel, fromParcel); }
@SuppressWarnings("unchecked") @Override public void writeToParcel(Parcel parcel, int flags) { parcel.writeInt(ids.length); if (ids.length > 0) { for (int i = 0; i < ids.length; i++) { parcel.writeLong(ids[i]); } parcel.writeString(type.getName()); } }
References implements Parcelable, Iterable<Reference<T>> { @SuppressWarnings("unchecked") @Override public void writeToParcel(Parcel parcel, int flags) { parcel.writeInt(ids.length); if (ids.length > 0) { for (int i = 0; i < ids.length; i++) { parcel.writeLong(ids[i]); } parcel.writeString(type.getName()); } } }
References implements Parcelable, Iterable<Reference<T>> { @SuppressWarnings("unchecked") @Override public void writeToParcel(Parcel parcel, int flags) { parcel.writeInt(ids.length); if (ids.length > 0) { for (int i = 0; i < ids.length; i++) { parcel.writeLong(ids[i]); } parcel.writeString(type.getName()); } } References();  References(Class<? extends T> type, long[] ids); }
References implements Parcelable, Iterable<Reference<T>> { @SuppressWarnings("unchecked") @Override public void writeToParcel(Parcel parcel, int flags) { parcel.writeInt(ids.length); if (ids.length > 0) { for (int i = 0; i < ids.length; i++) { parcel.writeLong(ids[i]); } parcel.writeString(type.getName()); } } References();  References(Class<? extends T> type, long[] ids); int size(); @Override boolean equals(Object o); @Override int hashCode(); @Override Iterator<Reference<T>> iterator(); @Override int describeContents(); @SuppressWarnings("unchecked") @Override void writeToParcel(Parcel parcel, int flags); static References<S> from(List<S> propoids); }
References implements Parcelable, Iterable<Reference<T>> { @SuppressWarnings("unchecked") @Override public void writeToParcel(Parcel parcel, int flags) { parcel.writeInt(ids.length); if (ids.length > 0) { for (int i = 0; i < ids.length; i++) { parcel.writeLong(ids[i]); } parcel.writeString(type.getName()); } } References();  References(Class<? extends T> type, long[] ids); int size(); @Override boolean equals(Object o); @Override int hashCode(); @Override Iterator<Reference<T>> iterator(); @Override int describeContents(); @SuppressWarnings("unchecked") @Override void writeToParcel(Parcel parcel, int flags); static References<S> from(List<S> propoids); @SuppressWarnings("rawtypes")
	static final Parcelable.Creator<References> CREATOR; }