Snippets pulled from Android source: #1 - All the putExtra methods instantiate a new Bundle when the Intent receives its first extra, to contain all extras going into it.
public Intent putExtra(String name, Bundle value) { if (mExtras == null) { mExtras = new Bundle(); } mExtras.putBundle(name, value); return this; } #2 - Looks to be the case. A new instance of Bundle is created with the contained extras. public Bundle getExtras() { return (mExtras != null) ? new Bundle(mExtras) : null; } On Aug 12, 12:34 am, sukumar bhashyam <bhashyam.suku...@gmail.com> wrote: > hi, > > Please help me in clarifying below query.... > > #1. Any Data( Bundle) passed into Intent.putExtras is going to create a new > copy of Bundle instance or its going to have reference to the Bundle > passed?. > > #2 Same query with get, Any call made to Intent.getExtras is going to new > Instance of Bundle or reference to extras in Intent?. > > Regards, > Sukumar. -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en