2015-10-12 68 views

回答

0

您也可以按住此列表中的ApplicationContext的引用和獲取數據這樣 - 所以你不需要序列化/反序列化

0

如果你不想使用parcelable對象,你可以試試這:

1- By using GSON library, create jsonString from your Custom Arraylist. 
2- Send this jsonString to Fragment by using Bundle. 
3- Recieve jsonString from bundle and parse it to Custom Arraylist by using GSON Library again. 
4- You can also save it to SharedPreferences as a String. 

注意:這不是一個好方法,但容易爲您選擇。

相關問題