Example usage for android.os Parcel writeTypedList

List of usage examples for android.os Parcel writeTypedList

Introduction

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

Prototype

public final <T extends Parcelable> void writeTypedList(List<T> val) 

Source Link

Document

Flatten a List containing a particular object type into the parcel, at the current dataPosition() and growing dataCapacity() if needed.

Usage

From source file:com.richtodd.android.quiltdesign.block.PaperPiecedBlock.java

@Override
public void writeToParcel(Parcel out, int flags) {
    out.writeInt(m_dirty ? -1 : 0);//from ww  w  .  ja  va  2  s . c om
    out.writeFloat(m_width);
    out.writeFloat(m_height);
    out.writeInt(m_backgroundColor);
    out.writeTypedList(m_pieces);
}

From source file:com.lugia.timetable.Subject.java

@Override
public void writeToParcel(Parcel dest, int flags) {
    dest.writeString(mSubjectCode);//from   ww  w.j av  a 2  s . com
    dest.writeString(mSubjectDescription);
    dest.writeString(mLectureSection);
    dest.writeString(mTutorialSection);

    dest.writeInt(mCreditHours);
    dest.writeInt(mColor);

    dest.writeTypedList(mSchedule);
    dest.writeTypedList(mEvent);
}

From source file:com.cas.model.Module.java

public void writeToParcel(Parcel dest, int flags) {
    dest.writeInt(id);/*from   www  .ja v  a2s.com*/
    dest.writeString(url);
    dest.writeString(name);
    dest.writeString(description);
    dest.writeInt(visible);
    dest.writeString(modicon);
    dest.writeString(modname);
    dest.writeString(modplural);
    dest.writeInt(availablefrom);
    dest.writeInt(availableuntil);
    dest.writeInt(indent);
    dest.writeTypedList(contents);
}

From source file:cx.ring.model.CallContact.java

@Override
public void writeToParcel(Parcel dest, int flags) {
    dest.writeLong(id);//from  w  ww.  j  av a2 s .c om
    dest.writeString(key);
    dest.writeString(mDisplayName);
    dest.writeLong(photo_id);
    dest.writeTypedList(phones);
    dest.writeString(mEmail);
    dest.writeByte((byte) (isUser ? 1 : 0));
    dest.writeByte(stared ? (byte) 1 : (byte) 0);
}

From source file:com.scvngr.levelup.core.net.LevelUpResponse.java

@Override
public void writeToParcel(final Parcel dest, final int flags) {
    super.writeToParcel(dest, flags);
    dest.writeString(mStatus.name());//from   ww w  . j  a v a2 s  .  co  m
    dest.writeTypedList(mServerErrors);
    dest.writeSerializable(mServerErrorReadError);
    dest.writeParcelable(mOriginalResponse, flags);
}

From source file:com.adrguides.model.Guide.java

@Override
public void writeToParcel(Parcel parcel, int i) {
    parcel.writeString(getAddress());/* www . j a v  a  2  s .  c  om*/
    parcel.writeString(getTitle());
    parcel.writeString(getDescription());
    parcel.writeString(getAuthor());
    parcel.writeString(getKeywords());
    parcel.writeString(getLanguage());
    parcel.writeString(getCountry());
    parcel.writeString(getVariant());
    parcel.writeTypedList(getPlaces());
    parcel.writeInt(isStored() ? 1 : 0);
}

From source file:edu.umich.flowfence.common.QMDetails.java

@Override
public void writeToParcel(Parcel dest, int flags) {
    // This space will be filled in with the final size of the object, minus this header.
    final int headerPos = dest.dataPosition();
    dest.writeInt(0);/* ww w .  ja v  a 2  s  . c o m*/
    final int startPos = dest.dataPosition();
    // Special handling for completely null objects - leave length at zero.
    if (ObjectUtils.firstNonNull(descriptor, resultType, paramInfo, requiredTaints, optionalTaints) == null) {
        if (localLOGV) {
            Log.v(TAG, "Null case, writing size 0");
        }
        return;
    }
    QMDescriptor.writeToParcel(descriptor, dest, flags);
    dest.writeString(resultType);
    dest.writeTypedList(paramInfo);
    TaintSet.writeToParcel(requiredTaints, dest, flags);
    TaintSet.writeToParcel(optionalTaints, dest, flags);

    final int endPos = dest.dataPosition();
    dest.setDataPosition(headerPos);
    dest.writeInt(endPos - startPos);
    dest.setDataPosition(endPos);
    if (localLOGV) {
        Log.v(TAG, "Total size: " + (endPos - startPos));
    }
}

From source file:edu.umich.oasis.common.SodaDetails.java

@Override
public void writeToParcel(Parcel dest, int flags) {
    // This space will be filled in with the final size of the object, minus this header.
    final int headerPos = dest.dataPosition();
    dest.writeInt(0);/*  w w w  .  j  av  a2 s  . c  o m*/
    final int startPos = dest.dataPosition();
    // Special handling for completely null objects - leave length at zero.
    if (ObjectUtils.firstNonNull(descriptor, resultType, paramInfo, requiredTaints, optionalTaints) == null) {
        if (localLOGV) {
            Log.v(TAG, "Null case, writing size 0");
        }
        return;
    }
    SodaDescriptor.writeToParcel(descriptor, dest, flags);
    dest.writeString(resultType);
    dest.writeTypedList(paramInfo);
    TaintSet.writeToParcel(requiredTaints, dest, flags);
    TaintSet.writeToParcel(optionalTaints, dest, flags);

    final int endPos = dest.dataPosition();
    dest.setDataPosition(headerPos);
    dest.writeInt(endPos - startPos);
    dest.setDataPosition(endPos);
    if (localLOGV) {
        Log.v(TAG, "Total size: " + (endPos - startPos));
    }
}

From source file:com.nestlabs.sdk.Camera.java

@Override
public void writeToParcel(Parcel dest, int flags) {
    super.writeToParcel(dest, flags);
    Utils.writeBoolean(dest, mIsStreaming);
    Utils.writeBoolean(dest, mIsAudioInputEnabled);
    dest.writeString(mLastIsOnlineChange);
    Utils.writeBoolean(dest, mIsVideoHistoryEnabled);
    dest.writeString(mWebUrl);//from   w  w  w.j  av  a  2 s . c  o  m
    dest.writeString(mAppUrl);
    Utils.writeBoolean(dest, mIsPublicShareEnabled);
    dest.writeTypedList(mActivityZones);
    dest.writeString(mPublicShareUrl);
    dest.writeString(mSnapshotUrl);
    mLastEvent.writeToParcel(dest, flags);
}

From source file:it_minds.dk.eindberetningmobil_android.models.DrivingReport.java

@Override
public void writeToParcel(Parcel dest, int flags) {
    dest.writeString(this.Uuid);
    dest.writeString(this.purpose);
    dest.writeString(this.orgLocation);
    dest.writeString(this.Rate);
    dest.writeString(this.extraDescription);
    dest.writeByte(haveEditedDistance ? (byte) 1 : (byte) 0);
    dest.writeByte(startedAtHome ? (byte) 1 : (byte) 0);
    dest.writeByte(endedAtHome ? (byte) 1 : (byte) 0);
    dest.writeByte(fourKMRule ? (byte) 1 : (byte) 0);
    dest.writeSerializable(this.startTime);
    dest.writeSerializable(this.endTime);
    dest.writeDouble(this.distanceInMeters);
    dest.writeTypedList(gpsPoints);
    dest.writeDouble(this.homeToBorderDistance);
}