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


Java Parcel.readInt方法代码示例

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


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

示例1: createFromParcel

import android.os.Parcel; //导入方法依赖的package包/类
public MeshElementInfo createFromParcel(Parcel in) {
	MeshElementInfo eltInfo = new MeshElementInfo();
	int n;
	byte[] tmp;

	n = in.readInt();
	tmp = new byte[n];
	in.readByteArray(tmp);
	eltInfo.mMids = byteArrayToShortArray(tmp);

	n = in.readInt();
	eltInfo.mVmids = new int[n];
	in.readIntArray(eltInfo.mVmids);

	return eltInfo;
}
 
开发者ID:blxble,项目名称:mesh-core-on-android,代码行数:17,代码来源:MeshElementInfo.java

示例2: createFromParcel

import android.os.Parcel; //导入方法依赖的package包/类
public OpenPgpMetadata createFromParcel(final Parcel source) {
    int version = source.readInt(); // parcelableVersion
    int parcelableSize = source.readInt();
    int startPosition = source.dataPosition();

    OpenPgpMetadata vr = new OpenPgpMetadata();
    vr.filename = source.readString();
    vr.mimeType = source.readString();
    vr.modificationTime = source.readLong();
    vr.originalSize = source.readLong();
    if (version >= 2) {
        vr.charset = source.readString();
    }

    // skip over all fields added in future versions of this parcel
    source.setDataPosition(startPosition + parcelableSize);

    return vr;
}
 
开发者ID:philipwhiuk,项目名称:q-mail,代码行数:20,代码来源:OpenPgpMetadata.java

示例3: RecordSport

import android.os.Parcel; //导入方法依赖的package包/类
protected RecordSport(Parcel in) {
    boolean z = true;
    this.id = in.readInt();
    this.record_on = in.readString();
    this.duration = in.readFloat();
    this.activity_id = in.readInt();
    this.activity_name = in.readString();
    this.calory = in.readFloat();
    this.thumb_img_url = in.readString();
    this.unit_name = in.readString();
    this.mets = in.readFloat();
    if (in.readByte() == (byte) 0) {
        z = false;
    }
    this.isChecked = z;
}
 
开发者ID:JackChan1999,项目名称:boohee_v5.6,代码行数:17,代码来源:RecordSport.java

示例4: BeaconDevice

import android.os.Parcel; //导入方法依赖的package包/类
private BeaconDevice(Parcel in) {
    this.bluetoothDevice = in.readParcelable(BluetoothDevice.class.getClassLoader());
    this.rssi = in.readInt();
    this.scanRecord = in.createByteArray();
    this.deviceName = in.readString();
    this.iBeacon = in.readParcelable(IBeacon.class.getClassLoader());
    this.lastUpdatedTimeMillis = in.readLong();
}
 
开发者ID:RockyQu,项目名称:BluetoothKit,代码行数:9,代码来源:BeaconDevice.java

示例5: Repository

import android.os.Parcel; //导入方法依赖的package包/类
protected Repository(Parcel in) {
    this.id = in.readInt();
    this.name = in.readString();
    this.fullName = in.readString();
    this.repPrivate = in.readByte() != 0;
    this.htmlUrl = in.readString();
    this.description = in.readString();
    this.language = in.readString();
    this.owner = in.readParcelable(User.class.getClassLoader());
    this.defaultBranch = in.readString();
    long tmpCreatedAt = in.readLong();
    this.createdAt = tmpCreatedAt == -1 ? null : new Date(tmpCreatedAt);
    long tmpUpdatedAt = in.readLong();
    this.updatedAt = tmpUpdatedAt == -1 ? null : new Date(tmpUpdatedAt);
    long tmpPushedAt = in.readLong();
    this.pushedAt = tmpPushedAt == -1 ? null : new Date(tmpPushedAt);
    this.gitUrl = in.readString();
    this.sshUrl = in.readString();
    this.cloneUrl = in.readString();
    this.svnUrl = in.readString();
    this.size = in.readInt();
    this.stargazersCount = in.readInt();
    this.watchersCount = in.readInt();
    this.forksCount = in.readInt();
    this.openIssuesCount = in.readInt();
    this.subscribersCount = in.readInt();
    this.fork = in.readByte() != 0;
    this.parent = in.readParcelable(Repository.class.getClassLoader());
    this.permissions = in.readParcelable(RepositoryPermissions.class.getClassLoader());
    this.hasIssues = in.readByte() != 0;
    this.hasProjects = in.readByte() != 0;
    this.hasDownloads = in.readByte() != 0;
    this.hasWiki = in.readByte() != 0;
    this.hasPages = in.readByte() != 0;
    this.sinceStargazersCount = in.readInt();
    int tmpTrendingSince = in.readInt();
    this.since = tmpTrendingSince == -1 ? null : TrendingSince.values()[tmpTrendingSince];
}
 
开发者ID:ThirtyDegreesRay,项目名称:OpenHub,代码行数:39,代码来源:Repository.java

示例6: PendingResultData

import android.os.Parcel; //导入方法依赖的package包/类
protected PendingResultData(Parcel in) {
    this.mType = in.readInt();
    this.mOrderedHint = in.readByte() != 0;
    this.mInitialStickyHint = in.readByte() != 0;
    this.mToken = in.readStrongBinder();
    this.mSendingUser = in.readInt();
    this.mFlags = in.readInt();
    this.mResultCode = in.readInt();
    this.mResultData = in.readString();
    this.mResultExtras = in.readBundle();
    this.mAbortBroadcast = in.readByte() != 0;
    this.mFinished = in.readByte() != 0;
}
 
开发者ID:codehz,项目名称:container,代码行数:14,代码来源:PendingResultData.java

示例7: ActivityResult

import android.os.Parcel; //导入方法依赖的package包/类
protected ActivityResult(Parcel in) {
    super(null,
            (Uri) in.readParcelable(Uri.class.getClassLoader()),
            (Exception) in.readSerializable(),
            in.createFloatArray(),
            (Rect) in.readParcelable(Rect.class.getClassLoader()),
            in.readInt(), in.readInt());
}
 
开发者ID:l465659833,项目名称:Bigbang,代码行数:9,代码来源:CropImage.java

示例8: IncomingTextMessage

import android.os.Parcel; //导入方法依赖的package包/类
public IncomingTextMessage(Parcel in) {
  this.message              = in.readString();
  this.sender               = in.readString();
  this.senderDeviceId       = in.readInt();
  this.protocol             = in.readInt();
  this.serviceCenterAddress = in.readString();
  this.replyPathPresent     = (in.readInt() == 1);
  this.pseudoSubject        = in.readString();
  this.sentTimestampMillis  = in.readLong();
  this.groupId              = in.readString();
  this.push                 = (in.readInt() == 1);
  this.subscriptionId       = in.readInt();
  this.expiresInMillis      = in.readLong();
}
 
开发者ID:CableIM,项目名称:Cable-Android,代码行数:15,代码来源:IncomingTextMessage.java

示例9: SavedState

import android.os.Parcel; //导入方法依赖的package包/类
SavedState(Parcel in, ClassLoader loader) {
	super(in);
	if (loader == null) {
		loader = getClass().getClassLoader();
	}
	position = in.readInt();
	adapterState = in.readParcelable(loader);
	this.loader = loader;
}
 
开发者ID:fengshihao,项目名称:WebPager,代码行数:10,代码来源:CustomViewPager.java

示例10: VpnConfiguration

import android.os.Parcel; //导入方法依赖的package包/类
private VpnConfiguration(Parcel source) {
    int count = source.readInt();
    dnsServers = new InetAddress[count];
    try {
        for (int i = 0; i < count; ++i) {
            dnsServers[i] = InetAddress.getByAddress(source.createByteArray());
        }
    } catch (UnknownHostException e) {
        throw new AssertionError("Invalid address", e);
    }
}
 
开发者ID:Genymobile,项目名称:gnirehtet,代码行数:12,代码来源:VpnConfiguration.java

示例11: User

import android.os.Parcel; //导入方法依赖的package包/类
protected User(Parcel in) {
    this.id = in.readInt();
    this.name = in.readString();
    this.username = in.readString();
    this.html_url = in.readString();
    this.avatar_url = in.readString();
    this.bio = in.readString();
    this.location = in.readString();
    this.links = in.readParcelable(Links.class.getClassLoader());
    this.buckets_count = in.readInt();
    this.comments_received_count = in.readInt();
    this.followers_count = in.readInt();
    this.followings_count = in.readInt();
    this.likes_count = in.readInt();
    this.likes_received_count = in.readInt();
    this.projects_count = in.readInt();
    this.rebounds_received_count = in.readInt();
    this.shots_count = in.readInt();
    this.teams_count = in.readInt();
    this.can_upload_shot = in.readByte() != 0;
    this.type = in.readString();
    this.pro = in.readByte() != 0;
    this.buckets_url = in.readString();
    this.followers_url = in.readString();
    this.following_url = in.readString();
    this.likes_url = in.readString();
    this.projects_url = in.readString();
    this.shots_url = in.readString();
    this.teams_url = in.readString();
    this.created_at = in.readString();
    this.updated_at = in.readString();
}
 
开发者ID:HStanN,项目名称:TakeRest,代码行数:33,代码来源:User.java

示例12: ActivityResult

import android.os.Parcel; //导入方法依赖的package包/类
protected ActivityResult(Parcel in) {
  super(
      null,
      (Uri) in.readParcelable(Uri.class.getClassLoader()),
      null,
      (Uri) in.readParcelable(Uri.class.getClassLoader()),
      (Exception) in.readSerializable(),
      in.createFloatArray(),
      (Rect) in.readParcelable(Rect.class.getClassLoader()),
      (Rect) in.readParcelable(Rect.class.getClassLoader()),
      in.readInt(),
      in.readInt());
}
 
开发者ID:prashantsaini1,项目名称:android-titanium-imagecropper,代码行数:14,代码来源:CropImage.java

示例13: Entry

import android.os.Parcel; //导入方法依赖的package包/类
protected Entry(Parcel in) {
    id = in.readInt();
    name = in.readInt();
}
 
开发者ID:PhoenixDevTeam,项目名称:Phoenix-for-VK,代码行数:5,代码来源:SpinnerOption.java

示例14: Attachment

import android.os.Parcel; //导入方法依赖的package包/类
protected Attachment(final Parcel in) {
    id = in.readLong();
    claimItemId = in.readLong();
    file = new File(in.readString());
    type = Type.values()[in.readInt()];
}
 
开发者ID:PacktPublishing,项目名称:Hands-On-Android-UI-Development,代码行数:7,代码来源:Attachment.java

示例15: SavedState

import android.os.Parcel; //导入方法依赖的package包/类
private SavedState(Parcel in) {
    super(in);
    isChecked = 1 == in.readInt();
}
 
开发者ID:luongvo,项目名称:iOS-SwitchView,代码行数:5,代码来源:SwitchView.java


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