I want to add a List<CustomObject> into a Bundle object.
This CustomObject implements the Parcelable interface. I've noticed that the Bundle object has a class that is hidden that allowed me to pass a List of objects.
/** {@hide} */
@UnsupportedAppUsage
public void putParcelableList(String key, List<? extends Parcelable> value) {
unparcel();
mMap.put(key, value);
mFlags &= ~FLAG_HAS_FDS_KNOWN;
}
However as we can see is hidden. How can I pass a List of CustomObjects? or how can I transform a list into an ArrayList using Kotlin?