Home | History | Annotate | Download | only in os

Lines Matching defs:parcel

50      * data are stored as a Parcel containing a Bundle.  When the data
53 /* package */ Parcel mParcelledData = null;
73 * Constructs a Bundle whose data is stored as a Parcel. The data
76 * @param parcelledData a Parcel containing a Bundle
78 Bundle(Parcel parcelledData) {
82 /* package */ Bundle(Parcel parcelledData, int length) {
117 mParcelledData = Parcel.obtain();
208 * If the underlying data are stored as a Parcel, unparcel them
1608 public Bundle createFromParcel(Parcel in) {
1629 * Writes the Bundle contents to a Parcel, typically in order for
1631 * @param parcel The parcel to copy this bundle to.
1633 public void writeToParcel(Parcel parcel, int flags) {
1634 final boolean oldAllowFds = parcel.pushAllowFds(mAllowFds);
1638 parcel.writeInt(length);
1639 parcel.writeInt(0x4C444E42); // 'B' 'N' 'D' 'L'
1640 parcel.appendFrom(mParcelledData, 0, length);
1642 parcel.writeInt(-1); // dummy, will hold length
1643 parcel.writeInt(0x4C444E42); // 'B' 'N' 'D' 'L'
1645 int oldPos = parcel.dataPosition();
1646 parcel.writeMapInternal(mMap);
1647 int newPos = parcel.dataPosition();
1650 parcel.setDataPosition(oldPos - 8);
1652 parcel.writeInt(length);
1653 parcel.setDataPosition(newPos);
1656 parcel.restoreAllowFds(oldAllowFds);
1661 * Reads the Parcel contents into this Bundle, typically in order for
1663 * @param parcel The parcel to overwrite this bundle from.
1665 public void readFromParcel(Parcel parcel) {
1666 int length = parcel.readInt();
1668 throw new RuntimeException("Bad length in parcel: " + length);
1670 readFromParcelInner(parcel, length);
1673 void readFromParcelInner(Parcel parcel, int length) {
1674 int magic = parcel.readInt();
1682 // Advance within this Parcel
1683 int offset = parcel.dataPosition();
1684 parcel.setDataPosition(offset + length);
1686 Parcel p = Parcel.obtain();
1688 p.appendFrom(parcel, offset, length);