Questions tagged [parcelable]

parcelable refers to the capability of an object to be converted to a parcel, a container for reading and writing data of various type, using type specific rather than generic serialization

parcelable is defined in the Android API as as interface for classes whose instances can be written to and restored from a parcel

References

1664 questions
1
vote
1 answer

Android Intent Parcelable: Class not found when unmarshalling

I looked all answers to question "Class not found when unmarshalling" in the Stackoverflow, but I don't found solution to my situation. I tried any variants but didn't work. I get following error: Here my Classes: Class one: public class Class1…
SBotirov
  • 13,872
  • 7
  • 59
  • 81
1
vote
4 answers

NullPointerException when Passing ArrayList through Intent using Parcelable

I'm working on project and getting data from WCF services and make an ArrayList, everything is working fine. I'm successfully getting data from service. Now what I want is Passing that ArrayList through Intent to another Activity. Basically I know…
M A.
  • 949
  • 2
  • 12
  • 29
1
vote
1 answer

Parcel that I am passing is null?

I am not sure how I can construct this parcel correctly; and I am returning null when I try to add the parcel's object from my MainActivity. Sending intent: public void onClick(View v) { Intent myIntent = new…
1
vote
0 answers

onNewIntent() not being called from new intent containing a custom Parcelable Object

I have a FragmentActivity which holds a FragmentList on a second Tab. That FragmentList implements a ListView and an ArrayList of a custom Object. I then have a second activity that is called when the user wants to construct a new list item; and…
1
vote
1 answer

Is a parcelable transmitted via LocalBroadcastManager immutable?

If I send a Parcelable object to another part of my program via LocalBroadcastManager -is the Parcelable immutable then? Immutable in the sense that the received Parcelable cant affect the object that was originally transmitted. I would guess so,…
JohnyTex
  • 3,323
  • 5
  • 29
  • 52
1
vote
1 answer

Nullpointerexception when trying to get data from bundle which is not null

I'm facing a litte problem. I'm trying to pass an playlist object to my media player service. In its onStartCommand, I'm getting a Nullpointer Exception when trying to call extras.get() or extras.getParcelable(). @Override public int…
Marian Klühspies
  • 15,824
  • 16
  • 93
  • 136
1
vote
0 answers

pass specific object to other activity (Jsch)

I have a problem with passing a Object from one activity to another. I'm using the Jsch() Class because I want to make an Sftp Connection. This in my Login Activty: ServerConnect lLogin = new ServerConnect(lUser,lPass,lIP,lPort); ASYNCLogin lASYNC…
1
vote
1 answer

Saving Hashmap of arraylist in Android

I am trying to save hashmap of arraylist. I am using custom class MailMessage which is itself parcelable. How can I save the Hashmaps? I am saving/restoring map as: HashMap> emailsMap = new HashMap
Mustansar Saeed
  • 2,730
  • 2
  • 22
  • 46
1
vote
0 answers

Android : Recover data with parcelable object

-- Problem Solved -- I want to send an object present in my "Activity1" to my "Activity2". To do that, i'm using Parcelable. I have a class User which implements Parcelable. In my first activity, i create a user (for test), like this : …
deveLost
  • 1,151
  • 2
  • 20
  • 47
1
vote
1 answer

how to cast intent's extra object[] to MyClas[]

I have this code public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.offers_list); Intent callingIntent = getIntent(); if (callingIntent != null) { Bundle extras =…
Elad Benda
  • 35,076
  • 87
  • 265
  • 471
1
vote
2 answers

How to access an element of an ArrayList inside Parcelable object?

I've been running into difficulties while trying to implement Parcelable to a number of my objects. So far I have a Project class with all of the String and integer variables and another object called ParcelableProject which contains a single…
yanki
  • 375
  • 1
  • 3
  • 11
1
vote
0 answers

Starting new activity gives: Class not found when unmarshalling

I'm facing a problem when passing a list of parcelable objects to the intent of one new activity. Here's what I do: Intent intent = new Intent(context,…
1
vote
4 answers

Android - Put interface in Bundle

I'm working with ActionBarSherlock, I need to change some icons on the action bar when the user does some stuff. In order to that I have to save the action bar for later usage : private Menu actionBarMenu; ... @Override public boolean…
Mehdiway
  • 10,337
  • 8
  • 36
  • 68
1
vote
1 answer

Parceable causes Stackoverflow

There is two classes, link each other someway. Problem is having Stackoverflow exception if I implements Parceable this way: RSSFeed.java public class RSSFeed implements Parcelable { private String title; private String link; private…
reel
  • 189
  • 7
1
vote
0 answers

ClassNotFoundException unmarshalling an arraylist of parcelable objects

I'm stucked with sending an arraylist of objects to another activity. The data to send to, is retrieved via webservice called in an asynctask (SplashScreen activity). I've already followed some guidelines (i.e. Problem unmarshalling parcelables)…
user2794919
  • 11
  • 1
  • 1