• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Apps Bundle

You can think of bundles as persistable dictionaries.

The primary use of a bundle is to save the state of an activity in onSaveInstanceState(Bundle) so you can restore the activity again in onCreate(Bundle).

The secondary use of a bundle (when put inside a message) is in asynchronous and/or inter-process communication.
 
A Bundle is a HashTable or Map, if you know the terms from other languagens.

Is basically a array, where you define something to be the index (could be a string) and something to be the data.

If you set two datas on the same index, the second will overwrite the first.

Do the notepad tutorial( Notepad Tutorial | Android Developers ), there you will learn how to work with bundles.
 
Back
Top Bottom