List of usage examples for android.os Bundle Bundle
public Bundle()
From source file:fr.julienvermet.bugdroid.ui.BugCommentsFragment.java
public static BugCommentsFragment newInstance(Bug bug) { BugCommentsFragment fragment = new BugCommentsFragment(); Bundle args = new Bundle(); args.putSerializable(BUG, bug);/*from w w w .j av a 2 s . c o m*/ fragment.setArguments(args); return fragment; }
From source file:eu.codeplumbers.cosi.wizards.firstrun.ConnectFragment.java
public static ConnectFragment create(String key) { Bundle args = new Bundle(); args.putString(ARG_KEY, key);/*from w w w . jav a 2 s .c om*/ ConnectFragment fragment = new ConnectFragment(); fragment.setArguments(args); return fragment; }
From source file:com.brennasoft.facebookdashclockextension.fbclient.NotificationsRequest.java
public NotificationsResponse execute(Session session) { NotificationsResponse notificationsResponse = new NotificationsResponse(); if (session.isOpened()) { Bundle parameters = new Bundle(); parameters.putString("q", q); Request request = new Request(session, "/fql", parameters, HttpMethod.GET); Response response = request.executeAndWait(); FacebookRequestError error = response.getError(); if (error == null) { notificationsResponse = parseResponse(response); }/*w w w . j a va 2 s. c om*/ } return notificationsResponse; }
From source file:cn.bidaround.ytcore.kaixin.KaixinUtil.java
/** * &?URL???key-value??/*from w ww .java 2s . c o m*/ * * @param s * &?URL? * @return key-value?? */ @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])); } } } return params; }
From source file:com.groupme.sdk.util.HttpUtilsTest.java
public void testEncodeParams() { Bundle params = new Bundle(); params.putString("format", "json"); params.putString("key", "thisisatestkey"); params.putString("foo", "bar"); String expected = "foo=bar&key=thisisatestkey&format=json"; String encodedParams = HttpUtils.encodeParams(params); assertEquals(expected, encodedParams); Bundle nullParams = null;/*ww w .ja va 2 s. c o m*/ String encodedNull = HttpUtils.encodeParams(nullParams); assertEquals("", encodedNull); }
From source file:au.com.wallaceit.reddinator.TabCommentsFragment.java
static TabCommentsFragment init(boolean load) { TabCommentsFragment commentsTab = new TabCommentsFragment(); Bundle args = new Bundle(); args.putBoolean("load", load); commentsTab.setArguments(args);/* ww w . j a v a 2 s . c o m*/ return commentsTab; }
From source file:com.royclarkson.springagram.GalleryPhotoListFragment.java
public static GalleryPhotoListFragment newInstance(String galleryPhotosUrl) { GalleryPhotoListFragment fragment = new GalleryPhotoListFragment(); Bundle args = new Bundle(); args.putString(ARG_GALLERY_PHOTOS_URI, galleryPhotosUrl); fragment.setArguments(args);//from w ww. j a va 2 s . c o m return fragment; }
From source file:com.ds.kaixin.Util.java
/** * &URLkey-value//from w w w .j a v a2 s.co m * * @param s * &URL * @return key-value */ 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])); } } } return params; }
From source file:com.firebase.ui.auth.provider.FacebookProvider.java
public static IDPProviderParcel createFacebookParcel(String applicationId) { Bundle extra = new Bundle(); extra.putString(APPLICATION_ID, applicationId); return new IDPProviderParcel(FacebookAuthProvider.PROVIDER_ID, extra); }
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);/* w w w. j a va 2 s . co m*/ return pageFragment; }