Android examples for android.os:Bundle
intercept String Param from Bundle
import android.content.Intent; import android.os.Bundle; import android.os.Parcelable; public class Main{ public static String interceptStringParam(Bundle savedInstanceState, Intent intent, String paramName) { String ret = null;//from w ww. j av a 2 s. co m if (savedInstanceState != null) { ret = savedInstanceState.getString(paramName); } else { if (intent != null) { Bundle incomming = intent.getExtras(); if (incomming != null) { ret = incomming.getString(paramName); } } } return ret; } }