当前位置: 首页>>代码示例>>Java>>正文


Java Parcel.writeParcelable方法代码示例

本文整理汇总了Java中android.os.Parcel.writeParcelable方法的典型用法代码示例。如果您正苦于以下问题:Java Parcel.writeParcelable方法的具体用法?Java Parcel.writeParcelable怎么用?Java Parcel.writeParcelable使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在android.os.Parcel的用法示例。


在下文中一共展示了Parcel.writeParcelable方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: writeToParcel

import android.os.Parcel; //导入方法依赖的package包/类
@Override
public void writeToParcel(Parcel dest, int flags) {
    dest.writeInt(this.mode);
    dest.writeInt(this.installFlags);
    dest.writeInt(this.installLocation);
    dest.writeLong(this.sizeBytes);
    dest.writeString(this.appPackageName);
    dest.writeParcelable(this.appIcon, flags);
    dest.writeString(this.appLabel);
    dest.writeLong(this.appIconLastModified);
    dest.writeParcelable(this.originatingUri, flags);
    dest.writeParcelable(this.referrerUri, flags);
    dest.writeString(this.abiOverride);
    dest.writeString(this.volumeUuid);
    dest.writeStringArray(this.grantedRuntimePermissions);
}
 
开发者ID:codehz,项目名称:container,代码行数:17,代码来源:SessionParams.java

示例2: writeToParcel

import android.os.Parcel; //导入方法依赖的package包/类
@Override
public void writeToParcel(Parcel dest, int flags) {
	String[] toSend = new String[] {
			this.videoTitle,
			this.gameTitle,
			this.previewUrl,
			this.videoId,
			this.channelName,
			this.displayName,
			this.recordedAtString,
			String.valueOf(this.views),
			String.valueOf(this.length),
			String.valueOf(this.isBroadcast)
	};

	dest.writeStringArray(toSend);
	dest.writeParcelable(channelInfo, flags);
}
 
开发者ID:SebastianRask,项目名称:Pocket-Plays-for-Twitch,代码行数:19,代码来源:VideoOnDemand.java

示例3: writeToEntropyPool

import android.os.Parcel; //导入方法依赖的package包/类
@Override
protected void writeToEntropyPool(DataOutputStream out) throws IOException {
	super.writeToEntropyPool(out);
	out.writeInt(android.os.Process.myPid());
	out.writeInt(android.os.Process.myTid());
	out.writeInt(android.os.Process.myUid());
	if (Build.FINGERPRINT != null) out.writeUTF(Build.FINGERPRINT);
	if (Build.SERIAL != null) out.writeUTF(Build.SERIAL);
	ContentResolver contentResolver = appContext.getContentResolver();
	String id = Settings.Secure.getString(contentResolver, ANDROID_ID);
	if (id != null) out.writeUTF(id);
	Parcel parcel = Parcel.obtain();
	WifiManager wm =
			(WifiManager) appContext.getSystemService(WIFI_SERVICE);
	List<WifiConfiguration> configs = wm.getConfiguredNetworks();
	if (configs != null) {
		for (WifiConfiguration config : configs)
			parcel.writeParcelable(config, 0);
	}
	BluetoothAdapter bt = BluetoothAdapter.getDefaultAdapter();
	if (bt != null) {
		for (BluetoothDevice device : bt.getBondedDevices())
			parcel.writeParcelable(device, 0);
	}
	out.write(parcel.marshall());
	parcel.recycle();
}
 
开发者ID:rafjordao,项目名称:Nird2,代码行数:28,代码来源:AndroidSecureRandomProvider.java

示例4: writeToParcel

import android.os.Parcel; //导入方法依赖的package包/类
@Override public void writeToParcel(Parcel dest, int flags) {
    dest.writeLong(this.id);
    dest.writeParcelable(this.user, flags);
    dest.writeString(this.url);
    dest.writeString(this.body);
    dest.writeString(this.bodyHtml);
    dest.writeString(this.htmlUrl);
    dest.writeLong(this.createdAt != null ? this.createdAt.getTime() : -1);
    dest.writeLong(this.updatedAt != null ? this.updatedAt.getTime() : -1);
    dest.writeInt(this.position);
    dest.writeInt(this.line);
    dest.writeString(this.path);
    dest.writeString(this.commitId);
    dest.writeString(this.repoId);
    dest.writeString(this.login);
    dest.writeString(this.gistId);
    dest.writeString(this.issueId);
    dest.writeString(this.pullRequestId);
    dest.writeParcelable(this.reactions, flags);
}
 
开发者ID:duyp,项目名称:mvvm-template,代码行数:21,代码来源:CommentEvent.java

示例5: writeToParcel

import android.os.Parcel; //导入方法依赖的package包/类
@Override
public void writeToParcel(Parcel dest, int flags) {
    dest.writeString(this.mDisplayName);
    dest.writeByte(this.mStarred ? (byte) 1 : (byte) 0);
    dest.writeParcelable(this.mPhoto, flags);
    dest.writeParcelable(this.mThumbnail, flags);
    dest.writeStringList(this.mEmails);
    dest.writeStringList(this.mPhoneNumbers);
}
 
开发者ID:broakenmedia,项目名称:MultiContactPicker,代码行数:10,代码来源:ContactResult.java

示例6: writeToParcel

import android.os.Parcel; //导入方法依赖的package包/类
@Override
public void writeToParcel(Parcel dest, int flags) {
    dest.writeString(this.id);
    dest.writeString(this.name);
    dest.writeString(this.label);
    dest.writeParcelable(this.uploader, flags);
    dest.writeString(this.contentType);
    dest.writeString(this.state);
    dest.writeLong(this.size);
    dest.writeInt(this.downloadCout);
    dest.writeLong(this.createdAt != null ? this.createdAt.getTime() : -1);
    dest.writeLong(this.updatedAt != null ? this.updatedAt.getTime() : -1);
    dest.writeString(this.downloadUrl);
}
 
开发者ID:ThirtyDegreesRay,项目名称:OpenHub,代码行数:15,代码来源:ReleaseAsset.java

示例7: writeToParcel

import android.os.Parcel; //导入方法依赖的package包/类
@Override
public void writeToParcel(Parcel dest, int flags) {
    dest.writeParcelable(this.sysDTO, flags);
    dest.writeTypedList(this.weatherDTOs);
    dest.writeParcelable(this.mainDTO, flags);
    dest.writeParcelable(this.windDTO, flags);
    dest.writeString(this.id);
    dest.writeString(this.cityName);
    dest.writeString(this.lastUpdateTime);
    dest.writeTypedList(this.fiveDaysCityDTOs);
    dest.writeByte(this.isCurrentLocation ? (byte) 1 : (byte) 0);
    dest.writeInt(this.cursorIndex);
}
 
开发者ID:farukydnn,项目名称:WeatherPlus,代码行数:14,代码来源:CityWeatherModelView.java

示例8: writeToParcel

import android.os.Parcel; //导入方法依赖的package包/类
@Override
public void writeToParcel(Parcel dest, int flags) {
    dest.writeParcelable(this.originItem, flags);
    dest.writeParcelable(this.destinationItem, flags);
    dest.writeParcelable(this.originLatLng, flags);
    dest.writeParcelable(this.destinationLatLng, flags);
}
 
开发者ID:aliumujib,项目名称:Nibo,代码行数:8,代码来源:NiboSelectedOriginDestination.java

示例9: writeToParcel

import android.os.Parcel; //导入方法依赖的package包/类
@Override
public void writeToParcel(Parcel dest, int flags) {
    dest.writeInt(type);
    dest.writeByte((byte) (isNull ? 1 : 0));

    if(!isNull){
        dest.writeParcelable(owner, flags);
    }
}
 
开发者ID:PhoenixDevTeam,项目名称:Phoenix-for-VK,代码行数:10,代码来源:ParcelableOwnerWrapper.java

示例10: writeToParcel

import android.os.Parcel; //导入方法依赖的package包/类
@Override
public void writeToParcel(Parcel dest, int flags) {
	dest.writeInt(taskId);
	dest.writeParcelable(baseIntent, flags);
	dest.writeParcelable(baseActivity, flags);
	dest.writeParcelable(topActivity, flags);
}
 
开发者ID:7763sea,项目名称:VirtualHook,代码行数:8,代码来源:AppTaskInfo.java

示例11: writeToParcel

import android.os.Parcel; //导入方法依赖的package包/类
@Override
public void writeToParcel(Parcel out, int flags) {
    super.writeToParcel(out, flags);
    out.writeInt(position);
    out.writeParcelable(adapterState, flags);
}
 
开发者ID:youngkaaa,项目名称:YViewPagerDemo,代码行数:7,代码来源:YViewPager.java

示例12: writeToParcel

import android.os.Parcel; //导入方法依赖的package包/类
public void writeToParcel(final Parcel out, final int flags) {
    super.writeToParcel(out, flags);
    out.writeParcelable(this.action, 0);
    out.writeString(this.previewPropertyName);
}
 
开发者ID:eviltnan,项目名称:kognitivo,代码行数:6,代码来源:ShareOpenGraphContent.java

示例13: writeToParcel

import android.os.Parcel; //导入方法依赖的package包/类
@Override
public void writeToParcel(Parcel parcel, int i) {
    parcel.writeParcelable(status_distribution, i);
    parcel.writeSerializable(score_distribution_map);
    parcel.writeSerializable(favourite_genres_map);
}
 
开发者ID:wax911,项目名称:anitrend-app,代码行数:7,代码来源:UserStats.java

示例14: writeToParcel

import android.os.Parcel; //导入方法依赖的package包/类
@Override
public void writeToParcel(Parcel dest, int flags) {
    dest.writeString(this.url);
    dest.writeParcelable(this.mBounds, 0);
}
 
开发者ID:yangchaojiang,项目名称:ZoomPreviewPicture,代码行数:6,代码来源:ThumbViewInfo.java

示例15: writeToParcel

import android.os.Parcel; //导入方法依赖的package包/类
@Override
public void writeToParcel(Parcel dest, int flags) {
    dest.writeByte(this.error ? (byte) 1 : (byte) 0);
    dest.writeParcelable(this.results, flags);
    dest.writeStringList(this.category);
}
 
开发者ID:fendoudebb,项目名称:PlayAndroid,代码行数:7,代码来源:DailyData.java


注:本文中的android.os.Parcel.writeParcelable方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。