List of usage examples for android.os Bundle putString
public void putString(@Nullable String key, @Nullable String value)
From source file:Main.java
public static Bundle decodeUrl(String s) { Bundle params = new Bundle(); if (s != null) { String array[] = s.split("&"); for (String parameter : array) { String v[] = parameter.split("="); if (v.length == 2) { params.putString(URLDecoder.decode(v[0]), URLDecoder.decode(v[1])); }/*from w ww.j a v a2 s. c om*/ } } return params; }
From source file:br.liveo.ndrawer.ui.fragment.MainFragment12.java
public static MainFragment12 newInstance(String text) { MainFragment12 mFragment = new MainFragment12(); Bundle mBundle = new Bundle(); mBundle.putString(TEXT_FRAGMENT, text); mFragment.setArguments(mBundle);/* w w w. j a v a2s .c o m*/ return mFragment; }
From source file:com.ymt.demo1.plates.news.FileNoticeFragment.java
/** * get instance//from ww w .j av a 2 s. c om */ public static FileNoticeFragment newInstance(String news_type_id_in) { FileNoticeFragment newsContentFragment = new FileNoticeFragment(); Bundle args = new Bundle(); args.putString("news_type_id", news_type_id_in); newsContentFragment.setArguments(args); return newsContentFragment; }
From source file:com.microsoft.onedrive.apiexplorer.DeltaFragment.java
/** * Create a new instance of ItemFragment * @param item the item//from w w w.j av a2s . c om * @return The fragment */ static DeltaFragment newInstance(final Item item) { final DeltaFragment fragment = new DeltaFragment(); final Bundle args = new Bundle(); args.putString(ARG_ITEM_ID, item.id); args.putString(ARG_ITEM_NAME_ID, item.name); fragment.setArguments(args); return fragment; }
From source file:com.facebook.login.LoginLogger.java
static Bundle newAuthorizationLoggingBundle(String authLoggerId) { // We want to log all parameters for all events, to ensure stability of columns across // different event types. Bundle bundle = new Bundle(); bundle.putLong(EVENT_PARAM_TIMESTAMP, System.currentTimeMillis()); bundle.putString(EVENT_PARAM_AUTH_LOGGER_ID, authLoggerId); bundle.putString(EVENT_PARAM_METHOD, ""); bundle.putString(EVENT_PARAM_LOGIN_RESULT, ""); bundle.putString(EVENT_PARAM_ERROR_MESSAGE, ""); bundle.putString(EVENT_PARAM_ERROR_CODE, ""); bundle.putString(EVENT_PARAM_EXTRAS, ""); return bundle; }
From source file:com.ronnyml.sweetplayer.fragments.CommonFragment.java
public static CommonFragment newInstance(int position, String screen) { CommonFragment fragment = new CommonFragment(); Bundle args = new Bundle(); args.putInt(Constants.POSITION, position); args.putString(Constants.SCREEN, screen); fragment.setArguments(args);//w ww. j ava2 s . com return fragment; }
From source file:Main.java
/** * Load the exif tags into the passed Bundle * * @param filepath/* w ww . j a v a2 s. c om*/ * @param out * @return true if exif tags are loaded correctly */ public static boolean loadAttributes(final String filepath, Bundle out) { ExifInterface e; try { e = new ExifInterface(filepath); } catch (IOException e1) { e1.printStackTrace(); return false; } for (String tag : EXIF_TAGS) { out.putString(tag, e.getAttribute(tag)); } return true; }
From source file:com.miz.mizuu.fragments.FanartSearchFragment.java
public static FanartSearchFragment newInstance(String tmdbId, String json, String baseUrl) { FanartSearchFragment pageFragment = new FanartSearchFragment(); Bundle b = new Bundle(); b.putString("tmdbId", tmdbId); b.putString("json", json); b.putString("baseUrl", baseUrl); pageFragment.setArguments(b);// ww w . ja v a 2 s . c o m return pageFragment; }
From source file:Main.java
@SuppressWarnings("deprecation") public static Bundle decodeUrl(String s) { Bundle params = new Bundle(); if (s != null) { String array[] = s.split("&"); for (String parameter : array) { String v[] = parameter.split("="); if (v.length > 1) { params.putString(v[0], URLDecoder.decode(v[1])); }//from ww w .j a v a 2 s .c om } } return params; }
From source file:com.royclarkson.springagram.PhotoListFragment.java
public static PhotoListFragment newInstance(String photosUrl) { PhotoListFragment fragment = new PhotoListFragment(); Bundle args = new Bundle(); args.putString(ARG_PHOTO_LIST_URL, photosUrl); fragment.setArguments(args);//from w w w.j a v a 2 s .co m return fragment; }