當前位置: 首頁>>代碼示例>>Java>>正文


Java Parcel.readBundle方法代碼示例

本文整理匯總了Java中android.os.Parcel.readBundle方法的典型用法代碼示例。如果您正苦於以下問題:Java Parcel.readBundle方法的具體用法?Java Parcel.readBundle怎麽用?Java Parcel.readBundle使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在android.os.Parcel的用法示例。


在下文中一共展示了Parcel.readBundle方法的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: readFromParcel

import android.os.Parcel; //導入方法依賴的package包/類
private void readFromParcel(Parcel source) {
    what = source.readInt();
    arg1 = source.readInt();
    arg2 = source.readInt();
    str = source.readString();
    presenter = source.readString();
    if (source.readInt() != 0) {
        obj = source.readParcelable(getClass().getClassLoader());
    }
    if (source.readInt() != 0) {
        objs = source.readParcelableArray(getClass().getClassLoader());
    }
    data = source.readBundle();
    replyTo = Messenger.readMessengerOrNullFromParcel(source);
    sendingUid = source.readInt();
}
 
開發者ID:imliujun,項目名稱:LJFramework,代碼行數:17,代碼來源:MVPMessage.java

示例2: FragmentState

import android.os.Parcel; //導入方法依賴的package包/類
public FragmentState(Parcel in) {
    boolean z;
    boolean z2 = true;
    this.mClassName = in.readString();
    this.mIndex = in.readInt();
    this.mFromLayout = in.readInt() != 0;
    this.mFragmentId = in.readInt();
    this.mContainerId = in.readInt();
    this.mTag = in.readString();
    if (in.readInt() != 0) {
        z = true;
    } else {
        z = false;
    }
    this.mRetainInstance = z;
    if (in.readInt() == 0) {
        z2 = false;
    }
    this.mDetached = z2;
    this.mArguments = in.readBundle();
    this.mSavedFragmentState = in.readBundle();
}
 
開發者ID:JackChan1999,項目名稱:letv,代碼行數:23,代碼來源:FragmentState.java

示例3: MediaDescriptionCompat

import android.os.Parcel; //導入方法依賴的package包/類
private MediaDescriptionCompat(Parcel in) {
    this.mMediaId = in.readString();
    this.mTitle = (CharSequence) TextUtils.CHAR_SEQUENCE_CREATOR.createFromParcel(in);
    this.mSubtitle = (CharSequence) TextUtils.CHAR_SEQUENCE_CREATOR.createFromParcel(in);
    this.mDescription = (CharSequence) TextUtils.CHAR_SEQUENCE_CREATOR.createFromParcel(in);
    this.mIcon = (Bitmap) in.readParcelable(null);
    this.mIconUri = (Uri) in.readParcelable(null);
    this.mExtras = in.readBundle();
    this.mMediaUri = (Uri) in.readParcelable(null);
}
 
開發者ID:JackChan1999,項目名稱:boohee_v5.6,代碼行數:11,代碼來源:MediaDescriptionCompat.java

示例4: VideoViewSaveState

import android.os.Parcel; //導入方法依賴的package包/類
public VideoViewSaveState(Parcel source) {
    super(source);
    // Android has two different classloaders: the framework classloader (which knows how to load Android classes)
    // and the APK classloader (which knows how to load your code).
    // The APK classloader has the framework classloader set as its parent, meaning it can also load Android classes.
    mVideoViewStateBundle = source.readBundle(getClass().getClassLoader());
}
 
開發者ID:xinpianchang,項目名稱:NSMPlayer-Android,代碼行數:8,代碼來源:VMovieVideoView.java

示例5: PermissionComponent

import android.os.Parcel; //導入方法依賴的package包/類
protected PermissionComponent(Parcel src) {
    info = src.readParcelable(ActivityInfo.class.getClassLoader());
    className = src.readString();
    metaData = src.readBundle(Bundle.class.getClassLoader());
    int N = src.readInt();
    intents = new ArrayList<>(N);
    while (N-- > 0) {
        intents.add(new IntentInfo(src));
    }
}
 
開發者ID:coding-dream,項目名稱:TPlayer,代碼行數:11,代碼來源:VPackage.java

示例6: readFromParcel

import android.os.Parcel; //導入方法依賴的package包/類
public static Parcelable readFromParcel(Parcel parcel, Class<?> parcelableType, String key) {
    parcel.setDataPosition(0);

    Bundle bundle = parcel.readBundle();
    bundle.setClassLoader(parcelableType.getClassLoader());
    
    Parcelable unparceledInstance = bundle.getParcelable(key);
    return unparceledInstance;
}
 
開發者ID:weiwenqiang,項目名稱:GitHub,代碼行數:10,代碼來源:ParcelUtils.java

示例7: readSerializableMap

import android.os.Parcel; //導入方法依賴的package包/類
public static <T extends Serializable> Map<String, T> readSerializableMap(Parcel parcel) {
    Map<String, T> map = new ArrayMap<>();
    Bundle bundle = parcel.readBundle(Parcelables.class.getClassLoader());
    for (String key : bundle.keySet()) {
        @SuppressWarnings("unchecked")
        T serializable = (T) bundle.getSerializable(key);
        map.put(key, serializable);
    }
    return map;
}
 
開發者ID:Datatellit,項目名稱:xlight_android_native,代碼行數:11,代碼來源:Parcelables.java

示例8: RssFeed

import android.os.Parcel; //導入方法依賴的package包/類
public RssFeed(Parcel source) {
	
	Bundle data = source.readBundle();
	title = data.getString("title");
	link = data.getString("link");
	description = data.getString("description");
	language = data.getString("language");
	rssItems = data.getParcelableArrayList("rssItems");
	
}
 
開發者ID:sfilmak,項目名稱:MakiLite,代碼行數:11,代碼來源:RssFeed.java

示例9: PlaybackStateCompat

import android.os.Parcel; //導入方法依賴的package包/類
private PlaybackStateCompat(Parcel in) {
    this.mState = in.readInt();
    this.mPosition = in.readLong();
    this.mSpeed = in.readFloat();
    this.mUpdateTime = in.readLong();
    this.mBufferedPosition = in.readLong();
    this.mActions = in.readLong();
    this.mErrorMessage = (CharSequence) TextUtils.CHAR_SEQUENCE_CREATOR.createFromParcel(in);
    this.mCustomActions = in.createTypedArrayList(CustomAction.CREATOR);
    this.mActiveItemId = in.readLong();
    this.mExtras = in.readBundle();
}
 
開發者ID:JackChan1999,項目名稱:boohee_v5.6,代碼行數:13,代碼來源:PlaybackStateCompat.java

示例10: onTransact

import android.os.Parcel; //導入方法依賴的package包/類
@Override
protected boolean onTransact(int code, Parcel data, Parcel reply, int flags)
		throws RemoteException {
	
	if(code == ServiceContext.TRANSACT_BUNDLE_SENDER) {
		Bundle bundle = data.readBundle();
		Bundle result = onReceiver(bundle);
		reply.writeBundle(result);
	}
	
	return true;
}
 
開發者ID:devyok,項目名稱:DroidIPC,代碼行數:13,代碼來源:BundleReceiver.java

示例11: MagicKey

import android.os.Parcel; //導入方法依賴的package包/類
public MagicKey(final Parcel in) {
    in.readStringList(mParamList);

    for (int i = 0, n = in.readInt(); i < n; i++) {
        mTypeList.add(in.readInt());
    }

    mBundle = in.readBundle(getClass().getClassLoader());
}
 
開發者ID:PhoenixDevTeam,項目名稱:Phoenix-for-VK,代碼行數:10,代碼來源:MagicKey.java

示例12: LogcatReaderLoader

import android.os.Parcel; //導入方法依賴的package包/類
private LogcatReaderLoader(Parcel in) {
    this.recordingMode = in.readInt() == 1;
    this.multiple = in.readInt() == 1;
    Bundle bundle = in.readBundle();
    for (String key : bundle.keySet()) {
        lastLines.put(key, bundle.getString(key));
    }
}
 
開發者ID:tranleduy2000,項目名稱:javaide,代碼行數:9,代碼來源:LogcatReaderLoader.java

示例13: RouterRequest

import android.os.Parcel; //導入方法依賴的package包/類
protected RouterRequest(Parcel in) {
    uri = in.readParcelable(Uri.class.getClassLoader());
    bundle = in.readBundle();
    requestCode = in.readInt();
    optionsCompat = in.readBundle();
    isIntercepted = in.readByte() != 0;
}
 
開發者ID:qkcoder,項目名稱:Assembler,代碼行數:8,代碼來源:RouterRequest.java

示例14: SavedState

import android.os.Parcel; //導入方法依賴的package包/類
SavedState(Parcel source) {
    super(source);
    isDialogShowing = source.readInt() == 1;
    dialogBundle = source.readBundle();
}
 
開發者ID:weiwenqiang,項目名稱:GitHub,代碼行數:6,代碼來源:MaterialDialogPreference.java

示例15: SavedState

import android.os.Parcel; //導入方法依賴的package包/類
public SavedState(Parcel source) {
    super(source);
    dialogBundle = source.readBundle(getClass().getClassLoader());
}
 
開發者ID:KnIfER,項目名稱:wangyi-Lyric-Parser,代碼行數:5,代碼來源:FilePickerPreference.java


注:本文中的android.os.Parcel.readBundle方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。