Java Code Examples for android.os.Parcel#readParcelableList()

The following examples show how to use android.os.Parcel#readParcelableList() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: NotificationChannelGroup.java    From android_9.0.0_r45 with Apache License 2.0 6 votes vote down vote up
/**
 * @hide
 */
protected NotificationChannelGroup(Parcel in) {
    if (in.readByte() != 0) {
        mId = in.readString();
    } else {
        mId = null;
    }
    mName = TextUtils.CHAR_SEQUENCE_CREATOR.createFromParcel(in);
    if (in.readByte() != 0) {
        mDescription = in.readString();
    } else {
        mDescription = null;
    }
    in.readParcelableList(mChannels, NotificationChannel.class.getClassLoader());
    mBlocked = in.readBoolean();
}
 
Example 2
Source File: NineGridView.java    From NineGridView with Apache License 2.0 6 votes vote down vote up
private SavedViewState(Parcel source)
{
    super(source);
    singleImageSize = source.readInt();
    singleImageRatio = source.readFloat();
    spaceSize = source.readInt();
    columnCount = source.readInt();
    rawCount = source.readInt();
    maxNum = source.readInt();
    isEditMode = source.readByte() == (byte) 1;
    icAddMoreResId = source.readInt();
    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.Q)
    {
        dataList = source.readParcelableList(dataList, NineGridView.class.getClassLoader());
    } else
    {
        dataList = source.readArrayList(NineGridBean.class.getClassLoader());
    }
    icDeleteResId = source.readInt();
    ratioDelete = source.readFloat();
}
 
Example 3
Source File: ClientTransaction.java    From AndroidComponentPlugin with Apache License 2.0 5 votes vote down vote up
/** Read from Parcel. */
private ClientTransaction(Parcel in) {
    mClient = (IApplicationThread) in.readStrongBinder();
    final boolean readActivityToken = in.readBoolean();
    if (readActivityToken) {
        mActivityToken = in.readStrongBinder();
    }
    mLifecycleStateRequest = in.readParcelable(getClass().getClassLoader());
    final boolean readActivityCallbacks = in.readBoolean();
    if (readActivityCallbacks) {
        mActivityCallbacks = new ArrayList<>();
        in.readParcelableList(mActivityCallbacks, getClass().getClassLoader());
    }
}
 
Example 4
Source File: ClientTransaction.java    From android_9.0.0_r45 with Apache License 2.0 5 votes vote down vote up
/** Read from Parcel. */
private ClientTransaction(Parcel in) {
    mClient = (IApplicationThread) in.readStrongBinder();
    final boolean readActivityToken = in.readBoolean();
    if (readActivityToken) {
        mActivityToken = in.readStrongBinder();
    }
    mLifecycleStateRequest = in.readParcelable(getClass().getClassLoader());
    final boolean readActivityCallbacks = in.readBoolean();
    if (readActivityCallbacks) {
        mActivityCallbacks = new ArrayList<>();
        in.readParcelableList(mActivityCallbacks, getClass().getClassLoader());
    }
}
 
Example 5
Source File: PictureInPictureParams.java    From android_9.0.0_r45 with Apache License 2.0 5 votes vote down vote up
/** {@hide} */
PictureInPictureParams(Parcel in) {
    if (in.readInt() != 0) {
        mAspectRatio = new Rational(in.readInt(), in.readInt());
    }
    if (in.readInt() != 0) {
        mUserActions = new ArrayList<>();
        in.readParcelableList(mUserActions, RemoteAction.class.getClassLoader());
    }
    if (in.readInt() != 0) {
        mSourceRectHint = Rect.CREATOR.createFromParcel(in);
    }
}
 
Example 6
Source File: PictureInPictureArgs.java    From android_9.0.0_r45 with Apache License 2.0 5 votes vote down vote up
private PictureInPictureArgs(Parcel in) {
    if (in.readInt() != 0) {
        mAspectRatio = new Rational(in.readInt(), in.readInt());
    }
    if (in.readInt() != 0) {
        mUserActions = new ArrayList<>();
        in.readParcelableList(mUserActions, RemoteAction.class.getClassLoader());
    }
    if (in.readInt() != 0) {
        mSourceRectHint = Rect.CREATOR.createFromParcel(in);
    }
}
 
Example 7
Source File: FillRequest.java    From android_9.0.0_r45 with Apache License 2.0 5 votes vote down vote up
private FillRequest(@NonNull Parcel parcel) {
    mId = parcel.readInt();
    mContexts = new ArrayList<>();
    parcel.readParcelableList(mContexts, null);

    mClientState = parcel.readBundle();
    mFlags = parcel.readInt();
}
 
Example 8
Source File: BluetoothDeviceFilter.java    From android_9.0.0_r45 with Apache License 2.0 4 votes vote down vote up
private static List<ParcelUuid> readUuids(Parcel in) {
    return in.readParcelableList(new ArrayList<>(), ParcelUuid.class.getClassLoader());
}
 
Example 9
Source File: AssociationRequest.java    From android_9.0.0_r45 with Apache License 2.0 4 votes vote down vote up
private AssociationRequest(Parcel in) {
    this(
        in.readByte() != 0,
        in.readParcelableList(new ArrayList<>(), AssociationRequest.class.getClassLoader()));
}