parcelable

Problem getting same class instance passed from one activity to another.

Hello Everyone, I am trying to pass SampleParcelable class object say sampleObj from my ClassA (current) activity to ClassB (a new one), but when i log the objects value, the object's value which i am creating in ClassA is totally different from what i get in ClassB. ClassA :- public class ClassA extends Activity { private Sample...

Parcel.readException passing an object to remote service

I wrote a remote service that the clients can log on with the usual mechanisms of IPC provided by Android and the binding seems to work. The problem arises when I go to call a method that I have to pass an object as a parameter because I get this "curious" exception: 10-19 15:09:04.601: ERROR/AndroidRuntime(2985): FATAL EXCEPTION: main ...

Android: unparceling causes out of memory exception. How to inspect objects?

Here's the setup: I have an activity with a list of items (updated from server, represented by a plain java class). The items are rendered via a custom BaseAdapter and custom View for each row. The items implement Parcelable, so that when the screen is rotated, the items are saved in the bundle as a ParcelableArrayList, then restored w...

Parcelable and inheritance in Android

I got an implementation of Parcelable working for a single class that involves no inheritance. I have problems figuring out the best way to implement the interface when it come to inheritance. Let's say I got this : public abstract class A { private int a; protected A(int a) { this.a = a; } } public class B extends A { priv...