下面列出了android.os.Parcel#readDouble ( ) 实例代码,或者点击链接到github查看源代码,也可以在右侧发表评论。
public BaiduAddress(Parcel s) {
this.id = s.readLong();
this.address = s.readString();
this.city = s.readString();
this.created = new Date(s.readLong());
this.disable = s.readInt();
long t = s.readLong();
this.favoritedTime = t == 0 ? null : new Date(t);
this.hasCaterDetails = s.readInt();
this.isPano = s.readInt();
this.latitude = s.readDouble();
this.longitude = s.readDouble();
this.name = s.readString();
this.searchKeyWord = s.readString();
this.phoneNum = s.readString();
this.postCode = s.readString();
this.type = s.readInt();
this.uid = s.readString();
this.remark = s.readString();
this.sid = s.readString();
this.timestamp = s.readLong();
this.recyle = s.readInt();
this.synced = s.readInt() == 1;
}
private ParcelablePOI(Parcel source) {
poiName = source.readString();
fullName = source.readString();
osmType = source.readString();
poiClassName = source.readString();
poiClassType = source.readString();
id = source.readLong();
lat = source.readDouble();
lon = source.readDouble();
//read tags Map
final int N = source.readInt();
for (int i = 0; i < N; i++) {
String key = source.readString();
String value = source.readString();
tags.put(key, value);
}
}
public MashProfile(Parcel p) {
name = p.readString();
version = p.readInt();
grainTemp = p.readDouble();
mashSteps = new ArrayList<MashStep>();
p.readTypedList(mashSteps, MashStep.CREATOR);
// Beer XML 1.0 Optional Fields ===================================
// ================================================================
tunTemp = p.readDouble();
spargeTemp = p.readDouble();
pH = p.readDouble();
tunWeight = p.readDouble();
tunSpecificHeat = p.readDouble();
notes = p.readString();
equipAdj = (p.readInt() > 0 ? true : false);
// Custom Fields ==================================================
// ================================================================
id = p.readLong();
ownerId = p.readLong();
mashType = p.readString();
spargeType = p.readString();
// Don't read recipe because it recurses.
}
private Movie(Parcel in) {
id = in.readInt();
title = in.readString();
description = in.readString();
cardImage = in.readString();
backgroundImage = in.readString();
videoUrl = in.readString();
contentType = in.readString();
live = in.readInt() == 1;
width = in.readInt();
height = in.readInt();
audioChannelConfig = in.readString();
purchasePrice = in.readString();
rentalPrice = in.readString();
ratingStyle = in.readInt();
ratingScore = in.readDouble();
productionYear = in.readInt();
duration = in.readInt();
}
@Override
public AddressData createFromParcel(Parcel in) {
//noinspection ConstantConditions
return new AddressData(in.readDouble(),
in.readDouble(),
in.readString());
}
public Movie(Parcel in) {
mId = in.readInt();
mPosterPath = in.readString();
mOverview = in.readString();
mTitle = in.readString();
mReleasedDate = in.readString();
mVoteAverage = in.readDouble();
boolean[] values = new boolean[1];
in.readBooleanArray(values);
mIsFavourite = values[0];
}
/**
* Creates a Place instance from Parcel.
*/
public VKApiPlace(Parcel in) {
this.id = in.readInt();
this.title = in.readString();
this.latitude = in.readDouble();
this.longitude = in.readDouble();
this.created = in.readLong();
this.checkins = in.readInt();
this.updated = in.readLong();
this.country_id = in.readInt();
this.city_id = in.readInt();
this.address = in.readString();
}
protected Draft(Parcel in) {
this.id = in.readInt();
this.uid = in.readString();
this.content = in.readString();
this.photoList = new ArrayList<Photo>();
in.readList(this.photoList, Photo.class.getClassLoader());
this.latitude = in.readDouble();
this.longitude = in.readDouble();
this.isEnableGeo = in.readByte() != 0;
this.isLocation = in.readByte() != 0;
this.addrStr = in.readString();
this.menuId = in.readInt();
this.groupId = in.readString();
this.groupName = in.readString();
}
private PaymentServices(Parcel in) {
id = in.readInt();
short_name = in.readString();
name = in.readString();
if(types==null)
types = new ArrayList<PaymentType>();
in.readList(types, PaymentType.class.getClassLoader());
price = in.readDouble();
currency=in.readString();
taxRate=in.readDouble();
sign= in.readString();
service_id= in.readString();
inapp_secret= in.readString();
}
protected Waypoint(Parcel in) {
location = in.readParcelable(Coordination.class.getClassLoader());
index = in.readInt();
interpolation = in.readDouble();
}
private PitchDifference(Parcel in) {
Tuning tuning = MainActivity.getCurrentTuning();
closest = tuning.findNote(in.readString());
deviation = in.readDouble();
}
private Point(Parcel in) {
latitude = in.readDouble();
longitude = in.readDouble();
}
public void readFromParcel(Parcel in)
{
x = in.readDouble();
y = in.readDouble();
}
private static Double readDoubleIfNotNull(Parcel parcel) {
return parcel.readByte() == 0 ? null : parcel.readDouble();
}
protected LatLong(Parcel in) {
latitude = in.readDouble();
longitude = in.readDouble();
}
protected NiboSelectedPlace(Parcel in) {
latitude = in.readDouble();
longitude = in.readDouble();
placeId = in.readString();
placeAddress = in.readString();
}
private Point(Parcel in) {
latitude = in.readDouble();
longitude = in.readDouble();
}
private LabelledGeoPoint(final Parcel in) {
super(in.readDouble(), in.readDouble(), in.readDouble());
this.setLabel(in.readString());
}
/**
* Constructor called from {@link #CREATOR}
*/
private GridItemRecord(Parcel in) {
column = in.readInt();
heightRatio = in.readDouble();
isHeaderFooter = in.readByte() == 1;
}
@Override
public DoubleParcelableAdapter createFromParcel(Parcel source) {
return new DoubleParcelableAdapter(source.readDouble());
}