Example usage for android.os Parcel writeBooleanArray

List of usage examples for android.os Parcel writeBooleanArray

Introduction

In this page you can find the example usage for android.os Parcel writeBooleanArray.

Prototype

public final void writeBooleanArray(boolean[] val) 

Source Link

Usage

From source file:android.hawkencompanionapp.models.UserLoginSession.java

@Override
public void writeToParcel(Parcel dest, int flags) {
    boolean[] b = new boolean[] { mIsUserValid };

    dest.writeString(mPhpSessionId);//w  ww. j  ava  2  s . c  om
    dest.writeString(mPhpTrackingId);
    dest.writeString(mPhpAccessId);
    dest.writeBooleanArray(b);
}

From source file:com.philliphsu.clock2.alarms.Alarm.java

@Override
public void writeToParcel(Parcel dest, int flags) {
    dest.writeInt(hour());/*from w  w  w.j  av  a 2 s .c o  m*/
    dest.writeInt(minutes());
    dest.writeString(label());
    dest.writeString(ringtone());
    dest.writeInt(vibrates() ? 1 : 0);
    // Mutable fields must be written after the immutable fields,
    // because when we recreate the object, we can't initialize
    // those mutable fields until after we call build(). Values
    // in the parcel are read in the order they were written.
    dest.writeLong(getId());
    dest.writeLong(snoozingUntilMillis);
    dest.writeInt(enabled ? 1 : 0);
    dest.writeBooleanArray(recurringDays);
    dest.writeInt(ignoreUpcomingRingTime ? 1 : 0);
}