Example usage for android.os Parcel readParcelable

List of usage examples for android.os Parcel readParcelable

Introduction

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

Prototype

@SuppressWarnings("unchecked")
public final <T extends Parcelable> T readParcelable(ClassLoader loader) 

Source Link

Document

Read and return a new Parcelable from the parcel.

Usage

From source file:io.bunnyblue.noticedog.app.notifications.Notification.java

public Notification(Parcel in) {
    this.expandedInboxText = new ArrayList();
    this.people = new ArrayList();
    this.actions = new ArrayList();
    this.packageName = in.readString();
    this.id = in.readInt();
    this.tag = in.readString();
    this.key = in.readString();
    this.when = in.readLong();
    this.smallIcon = in.readInt();
    this.largeIcon = (Bitmap) in.readParcelable(Bitmap.class.getClassLoader());
    this.tickerText = in.readString();
    this.contentTitle = in.readString();
    this.contentText = in.readString();
    this.contentInfoText = in.readString();
    this.expandedLargeIconBig = (Bitmap) in.readParcelable(Bitmap.class.getClassLoader());
    this.expandedContentTitle = in.readString();
    this.expandedContentText = in.readString();
    in.readStringList(this.expandedInboxText);
    in.readList(this.people, Uri.class.getClassLoader());
    this.picture = (Bitmap) in.readParcelable(Bitmap.class.getClassLoader());
    this.priority = in.readInt();
    this.pendingLaunchIntent = (PendingIntent) in.readParcelable(PendingIntent.class.getClassLoader());
    in.readList(this.actions, Action.class.getClassLoader());
}

From source file:org.droid2droid.internal.AbstractRemoteAndroidImpl.java

/** Send transactions to remote cloud. */
@Override/*from   w w  w .j a va2  s .  c  o  m*/
public int bindOID(int connid, int serviceConnectionOID, Intent intent, int flags, ComponentName[] name,
        long timeout) throws RemoteException {
    if (D)
        Log.d(TAG_CLIENT_BIND, PREFIX_LOG + "BindOID...");
    Parcel data = Parcel.obtain();
    Parcel reply = Parcel.obtain();
    try {

        data.writeInt(serviceConnectionOID);
        NormalizeIntent.writeIntent(intent, data, 0);
        data.writeInt(flags);
        transactRemoteAndroid(connid, BIND_OID, data, reply, 0, timeout);
        if (D)
            Log.d(TAG_CLIENT_BIND, PREFIX_LOG + "BindOID ok");
        name[0] = (ComponentName) reply.readParcelable(ComponentName.class.getClassLoader());
        return reply.readInt();
    } finally {
        if (data != null)
            data.recycle();
        if (reply != null)
            reply.recycle();
    }
}

From source file:com.tlongdev.bktf.model.Item.java

protected Item(Parcel source) {
    defindex = source.readInt();//from w ww .j a  v  a  2 s  .c  o m
    name = source.readString();
    //noinspection WrongConstant
    quality = source.readInt();
    tradable = source.readByte() != 0;
    craftable = source.readByte() != 0;
    australium = source.readByte() != 0;
    priceIndex = source.readInt();
    weaponWear = source.readInt();
    price = source.readParcelable(Price.class.getClassLoader());
}

From source file:com.nestapi.lib.API.Structure.java

private Structure(Parcel in) {
    mStructureID = in.readString();/*w  w  w  . j  a  v  a 2s .c  o  m*/
    in.readStringList(mThermostatIDs = new ArrayList<>());
    in.readStringList(mSmokeCOAlarms = new ArrayList<>());
    mName = in.readString();
    mCountryCode = in.readString();
    mPeakPeriodStartTime = in.readString();
    mPeakPeriodEndTime = in.readString();
    mTimeZone = in.readString();
    mAwayState = (AwayState) in.readSerializable();
    mETA = in.readParcelable(ETA.class.getClassLoader());
}

From source file:com.vk.sdkweb.api.model.VKApiUserFull.java

public VKApiUserFull(Parcel in) {
    super(in);/* w w  w .  ja v a  2 s  .  c  om*/
    this.activity = in.readString();
    this.status_audio = in.readParcelable(VKApiAudio.class.getClassLoader());
    this.bdate = in.readString();
    this.city = in.readParcelable(VKApiCity.class.getClassLoader());
    this.country = in.readParcelable(VKApiCountry.class.getClassLoader());
    this.last_seen = in.readLong();
    this.universities = in.readParcelable(VKList.class.getClassLoader());
    this.schools = in.readParcelable(VKList.class.getClassLoader());
    this.smoking = in.readInt();
    this.alcohol = in.readInt();
    this.political = in.readInt();
    this.life_main = in.readInt();
    this.people_main = in.readInt();
    this.inspired_by = in.readString();
    this.langs = in.createStringArray();
    this.religion = in.readString();
    this.facebook = in.readString();
    this.facebook_name = in.readString();
    this.livejournal = in.readString();
    this.skype = in.readString();
    this.site = in.readString();
    this.twitter = in.readString();
    this.instagram = in.readString();
    this.mobile_phone = in.readString();
    this.home_phone = in.readString();
    this.screen_name = in.readString();
    this.activities = in.readString();
    this.interests = in.readString();
    this.movies = in.readString();
    this.tv = in.readString();
    this.books = in.readString();
    this.games = in.readString();
    this.about = in.readString();
    this.quotes = in.readString();
    this.can_post = in.readByte() != 0;
    this.can_see_all_posts = in.readByte() != 0;
    this.can_write_private_message = in.readByte() != 0;
    this.wall_comments = in.readByte() != 0;
    this.is_banned = in.readByte() != 0;
    this.is_deleted = in.readByte() != 0;
    this.wall_default_owner = in.readByte() != 0;
    this.verified = in.readByte() != 0;
    this.sex = in.readInt();
    this.counters = in.readParcelable(Counters.class.getClassLoader());
    this.relation = in.readInt();
    this.relatives = in.readParcelable(VKList.class.getClassLoader());
    this.blacklisted_by_me = in.readByte() != 0;
}

From source file:com.eTilbudsavis.etasdk.model.Offer.java

private Offer(Parcel in) {
    this.mErn = in.readString();
    this.mHeading = in.readString();
    this.mDescription = in.readString();
    this.mCatalogPage = in.readInt();
    this.mPricing = in.readParcelable(Pricing.class.getClassLoader());
    this.mQuantity = in.readParcelable(Quantity.class.getClassLoader());
    this.mImages = in.readParcelable(Images.class.getClassLoader());
    this.mLinks = in.readParcelable(Links.class.getClassLoader());
    long tmpMRunFrom = in.readLong();
    this.mRunFrom = tmpMRunFrom == -1 ? null : new Date(tmpMRunFrom);
    long tmpMRunTill = in.readLong();
    this.mRunTill = tmpMRunTill == -1 ? null : new Date(tmpMRunTill);
    this.mDealerUrl = in.readString();
    this.mDealerId = in.readString();
    this.mStoreUrl = in.readString();
    this.mStoreId = in.readString();
    this.mCatalogUrl = in.readString();
    this.mCatalogId = in.readString();
    this.mCatalog = in.readParcelable(Catalog.class.getClassLoader());
    this.mDealer = in.readParcelable(Dealer.class.getClassLoader());
    this.mStore = in.readParcelable(Store.class.getClassLoader());
}

From source file:com.vk.sdk.api.model.VKApiPost.java

/**
 * Creates a Post instance from Parcel./*from w ww . jav  a2s.  co  m*/
 */
public VKApiPost(Parcel in) {
    this.id = in.readInt();
    this.to_id = in.readInt();
    this.from_id = in.readInt();
    this.date = in.readLong();
    this.text = in.readString();
    this.reply_owner_id = in.readInt();
    this.reply_post_id = in.readInt();
    this.friends_only = in.readByte() != 0;
    this.comments_count = in.readInt();
    this.can_post_comment = in.readByte() != 0;
    this.likes_count = in.readInt();
    this.user_likes = in.readByte() != 0;
    this.can_like = in.readByte() != 0;
    this.can_publish = in.readByte() != 0;
    this.reposts_count = in.readInt();
    this.user_reposted = in.readByte() != 0;
    this.post_type = in.readString();
    this.attachments = in.readParcelable(VKAttachments.class.getClassLoader());
    this.geo = in.readParcelable(VKApiPlace.class.getClassLoader());
    this.signer_id = in.readInt();
}

From source file:com.facebook.login.LoginClient.java

public LoginClient(Parcel source) {
    Object[] o = source.readParcelableArray(LoginMethodHandler.class.getClassLoader());
    handlersToTry = new LoginMethodHandler[o.length];
    for (int i = 0; i < o.length; ++i) {
        handlersToTry[i] = (LoginMethodHandler) o[i];
        handlersToTry[i].setLoginClient(this);
    }//  w  w  w.  ja v  a2s  .  c om
    currentHandler = source.readInt();
    pendingRequest = source.readParcelable(Request.class.getClassLoader());
    loggingExtras = Utility.readStringMapFromParcel(source);
}

From source file:com.vk.sdk.api.model.VKApiUserFull.java

public VKApiUserFull(Parcel in) {
    super(in);/*from   w  w w.j  av  a 2 s  . c o m*/
    this.activity = in.readString();
    this.status_audio = in.readParcelable(VKApiAudio.class.getClassLoader());
    this.bdate = in.readString();
    this.city = in.readParcelable(VKApiCity.class.getClassLoader());
    this.country = in.readParcelable(VKApiCountry.class.getClassLoader());
    this.last_seen = in.readLong();
    this.universities = in.readParcelable(VKList.class.getClassLoader());
    this.schools = in.readParcelable(VKList.class.getClassLoader());
    this.smoking = in.readInt();
    this.alcohol = in.readInt();
    this.political = in.readInt();
    this.life_main = in.readInt();
    this.people_main = in.readInt();
    this.inspired_by = in.readString();
    this.langs = in.createStringArray();
    this.religion = in.readString();
    this.facebook = in.readString();
    this.facebook_name = in.readString();
    this.livejournal = in.readString();
    this.skype = in.readString();
    this.site = in.readString();
    this.twitter = in.readString();
    this.instagram = in.readString();
    this.mobile_phone = in.readString();
    this.home_phone = in.readString();
    this.screen_name = in.readString();
    this.activities = in.readString();
    this.interests = in.readString();
    this.movies = in.readString();
    this.tv = in.readString();
    this.books = in.readString();
    this.games = in.readString();
    this.about = in.readString();
    this.quotes = in.readString();
    this.can_post = in.readByte() != 0;
    this.can_see_all_posts = in.readByte() != 0;
    this.can_write_private_message = in.readByte() != 0;
    this.wall_comments = in.readByte() != 0;
    this.is_banned = in.readByte() != 0;
    this.is_deleted = in.readByte() != 0;
    this.wall_default_owner = in.readByte() != 0;
    this.verified = in.readByte() != 0;
    this.sex = in.readInt();
    this.counters = in.readParcelable(Counters.class.getClassLoader());
    this.occupation = in.readParcelable(Occupation.class.getClassLoader());
    this.relation = in.readInt();
    this.relatives = in.readParcelable(VKList.class.getClassLoader());
    this.blacklisted_by_me = in.readByte() != 0;
}

From source file:org.alfresco.mobile.android.api.services.impl.onpremise.OnPremiseWorkflowServiceImpl.java

public OnPremiseWorkflowServiceImpl(Parcel o) {
    super((AlfrescoSession) o.readParcelable(RepositorySessionImpl.class.getClassLoader()));
}