“BadParcelableException: ClassNotFoundException when unmarshalling <myclass>” while using Parcel.read method that has a ClassLoader as argument
问题 Given a custom class org.example.app.MyClass implements Parcelable , I want to write a List<MyClass> to a Parcel. I did the marshalling with List<MyClass> myclassList = ... parcel.writeList(myclassList); whenever I try to unmarshall the class with List<MyClass> myclassList = new ArrayList<MyClass>(); parcel.readList(myclassList, null); there is an "BadParcelableException: ClassNotFoundException when unmarshalling org.example.app.MyClass" exception. What is wrong here? Why is the class not