Code example for Parcel

Methods: writeBundlewriteInt

0
    } 
 
    @Override 
    public void writeToParcel(Parcel dest, int flags) {
      super.writeToParcel(dest, flags);
      dest.writeInt(isDialogShowing ? 1 : 0);
      dest.writeBundle(dialogBundle);
    } 
 
    @SuppressWarnings({"hiding", "unused"}) 
    public static final Creator<SavedState> CREATOR = new Creator<SavedState>() {
      @Override 
      public SavedState createFromParcel(Parcel in) { 
        return new SavedState(in); 
      } 
 
      @Override 
      public SavedState[] newArray(int size) { 
        return new SavedState[size]; 
      } 
    };