本文整理了Java中android.os.Bundle.putStringArrayList()
方法的一些代码示例,展示了Bundle.putStringArrayList()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Bundle.putStringArrayList()
方法的具体详情如下:
包路径:android.os.Bundle
类名称:Bundle
方法名:putStringArrayList
暂无
代码示例来源:origin: androidannotations/androidannotations
public I stringArrayListArg(String key, ArrayList<String> value) {
args.putStringArrayList(key, value);
return (I) this;
}
代码示例来源:origin: ogaclejapan/SmartTabLayout
/**
* Inserts an ArrayList<String> value into the mapping of this Bundle, replacing
* any existing value for the given key. Either key or value may be null.
*
* @param key a String, or null
* @param value an ArrayList<String> object, or null
*/
public Bundler putStringArrayList(String key, ArrayList<String> value) {
bundle.putStringArrayList(key, value);
return this;
}
代码示例来源:origin: ogaclejapan/SmartTabLayout
/**
* Inserts an ArrayList<String> value into the mapping of this Bundle, replacing
* any existing value for the given key. Either key or value may be null.
*
* @param key a String, or null
* @param value an ArrayList<String> object, or null
*/
public Bundler putStringArrayList(String key, ArrayList<String> value) {
bundle.putStringArrayList(key, value);
return this;
}
代码示例来源:origin: facebook/facebook-android-sdk
/**
* Sets an array of string values in the object.
* @param key The key for the value.
* @param value The value.
* @return The builder.
*/
public E putStringArrayList(final String key, @Nullable final ArrayList<String> value) {
this.bundle.putStringArrayList(key, value);
return (E) this;
}
代码示例来源:origin: commonsguy/cw-omnibus
@Override
protected void onSaveInstanceState(Bundle outState) {
super.onSaveInstanceState(outState);
outState.putStringArrayList(KEY_MIDDLE_CONTENTS, middleContents);
}
代码示例来源:origin: commonsguy/cw-omnibus
@Override
protected void onSaveInstanceState(Bundle outState) {
super.onSaveInstanceState(outState);
outState.putStringArrayList(KEY_MIDDLE_CONTENTS, middleContents);
}
代码示例来源:origin: commonsguy/cw-omnibus
@Override
public void onSaveInstanceState(Bundle state) {
adapter.onSaveInstanceState(state);
state.putStringArrayList(STATE_ITEMS, items);
}
代码示例来源:origin: facebook/facebook-android-sdk
private static Bundle create(
SharePhotoContent photoContent,
List<String> imageUrls,
boolean dataErrorsFatal) {
Bundle params = createBaseParameters(photoContent, dataErrorsFatal);
params.putStringArrayList(ShareConstants.LEGACY_PHOTOS, new ArrayList<>(imageUrls));
return params;
}
代码示例来源:origin: facebook/facebook-android-sdk
private static Bundle create(
SharePhotoContent photoContent,
List<String> imageUrls,
boolean dataErrorsFatal) {
Bundle params = createBaseParameters(photoContent, dataErrorsFatal);
params.putStringArrayList(ShareConstants.PHOTOS, new ArrayList<>(imageUrls));
return params;
}
代码示例来源:origin: robolectric/robolectric
@Implementation
protected WebBackForwardList saveState(Bundle outState) {
if (history.size() > 0) {
outState.putStringArrayList(HISTORY_KEY, history);
}
return new BackForwardList(history);
}
代码示例来源:origin: commonsguy/cw-omnibus
public static SimpleListFragment newInstance(ArrayList<String> contents) {
SimpleListFragment result=new SimpleListFragment();
Bundle args=new Bundle();
args.putStringArrayList(KEY_CONTENTS, contents);
result.setArguments(args);
return(result);
}
代码示例来源:origin: commonsguy/cw-omnibus
void onSaveInstanceState(Bundle state) {
for (int i=0;i<PAGE_COUNT;i++) {
PageController holder=
(PageController)pager.findViewHolderForAdapterPosition(i);
if (holder!=null) {
buffers.set(i, holder.getText());
}
}
state.putStringArrayList(STATE_BUFFERS, buffers);
}
代码示例来源:origin: commonsguy/cw-omnibus
void onSaveInstanceState(Bundle state) {
for (int i=0;i<PAGE_COUNT;i++) {
PageController holder=
(PageController)pager.findViewHolderForAdapterPosition(i);
if (holder!=null) {
buffers.set(i, holder.getText());
}
}
state.putStringArrayList(STATE_BUFFERS, buffers);
}
代码示例来源:origin: commonsguy/cw-omnibus
public static SimpleListFragment newInstance(ArrayList<String> contents) {
SimpleListFragment result=new SimpleListFragment();
Bundle args=new Bundle();
args.putStringArrayList(KEY_CONTENTS, contents);
result.setArguments(args);
return(result);
}
代码示例来源:origin: commonsguy/cw-omnibus
void onSaveInstanceState(Bundle state) {
for (int i=0;i<PAGE_COUNT;i++) {
PageController holder=
(PageController)pager.findViewHolderForAdapterPosition(i);
if (holder!=null) {
buffers.set(i, holder.getText());
}
}
state.putStringArrayList(STATE_BUFFERS, buffers);
}
代码示例来源:origin: facebook/facebook-android-sdk
public static void putDeclinedPermissions(Bundle bundle, Collection<String> value) {
Validate.notNull(bundle, "bundle");
Validate.notNull(value, "value");
bundle.putStringArrayList(DECLINED_PERMISSIONS_KEY, new ArrayList<String>(value));
}
代码示例来源:origin: facebook/facebook-android-sdk
public static void putPermissions(Bundle bundle, Collection<String> value) {
Validate.notNull(bundle, "bundle");
Validate.notNull(value, "value");
bundle.putStringArrayList(PERMISSIONS_KEY, new ArrayList<String>(value));
}
代码示例来源:origin: commonsguy/cw-omnibus
@Override
public void onSaveInstanceState(Bundle state) {
super.onSaveInstanceState(state);
state.putInt(STATE_CHOICE_MODE, getListView().getChoiceMode());
state.putStringArrayList(STATE_MODEL, words);
}
代码示例来源:origin: commonsguy/cw-omnibus
@Override
public void onSaveInstanceState(Bundle state) {
super.onSaveInstanceState(state);
if (!sv.isIconified()) {
state.putCharSequence(STATE_QUERY, sv.getQuery());
}
state.putStringArrayList(STATE_MODEL, words);
}
代码示例来源:origin: robolectric/robolectric
@Test
public void stringArrayList() {
ArrayList<String> list = new ArrayList<>();
list.add("a");
bundle.putStringArrayList("foo", new ArrayList<>(list));
assertThat(bundle.getStringArrayList("foo")).isEqualTo(list);
assertThat(bundle.getStringArrayList("bar")).isNull();
}
内容来源于网络,如有侵权,请联系作者删除!