Android examples for Android OS:Parcel
add Parcelable Resent Parcel From Small Parcel
/** //from w w w. j ava 2s. com ** Copyright (C) SAS Institute, All rights reserved. ** General Public License: http://www.opensource.org/licenses/gpl-license.php **/ //package com.java2s; import android.os.Bundle; import android.os.Parcelable; public class Main { /** * key used to extract from Bundle an boolean value, which indicates if this parcel<br> * is sent again or not by 'message-sender'.<br> * it is used when transferring a message by a few parcels<br> */ public static final String BUNDLE_SMALL_RESENT_PARCEL = "smallparcelresent"; public static Bundle addParcelableResentParcelFromSmallParcel( Parcelable parcelable, boolean isResent) { Bundle bundle = (Bundle) parcelable; bundle.putBoolean(BUNDLE_SMALL_RESENT_PARCEL, isResent); return bundle; } }