@java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.pubsub.v1.StreamingPullRequest)) { return super.equals(obj); } com.google.pubsub.v1.StreamingPullRequest other = (com.google.pubsub.v1.StreamingPullRequest) obj; boolean result = true; result = result && getSubscription().equals(other.getSubscription()); result = result && getAckIdsList().equals(other.getAckIdsList()); result = result && getModifyDeadlineSecondsList().equals(other.getModifyDeadlineSecondsList()); result = result && getModifyDeadlineAckIdsList().equals(other.getModifyDeadlineAckIdsList()); result = result && (getStreamAckDeadlineSeconds() == other.getStreamAckDeadlineSeconds()); result = result && unknownFields.equals(other.unknownFields); return result; }
@java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { getSerializedSize(); if (!getSubscriptionBytes().isEmpty()) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, subscription_); } for (int i = 0; i < ackIds_.size(); i++) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, ackIds_.getRaw(i)); } if (getModifyDeadlineSecondsList().size() > 0) { output.writeUInt32NoTag(26); output.writeUInt32NoTag(modifyDeadlineSecondsMemoizedSerializedSize); } for (int i = 0; i < modifyDeadlineSeconds_.size(); i++) { output.writeInt32NoTag(modifyDeadlineSeconds_.get(i)); } for (int i = 0; i < modifyDeadlineAckIds_.size(); i++) { com.google.protobuf.GeneratedMessageV3.writeString( output, 4, modifyDeadlineAckIds_.getRaw(i)); } if (streamAckDeadlineSeconds_ != 0) { output.writeInt32(5, streamAckDeadlineSeconds_); } unknownFields.writeTo(output); }
@java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + SUBSCRIPTION_FIELD_NUMBER; hash = (53 * hash) + getSubscription().hashCode(); if (getAckIdsCount() > 0) { hash = (37 * hash) + ACK_IDS_FIELD_NUMBER; hash = (53 * hash) + getAckIdsList().hashCode(); } if (getModifyDeadlineSecondsCount() > 0) { hash = (37 * hash) + MODIFY_DEADLINE_SECONDS_FIELD_NUMBER; hash = (53 * hash) + getModifyDeadlineSecondsList().hashCode(); } if (getModifyDeadlineAckIdsCount() > 0) { hash = (37 * hash) + MODIFY_DEADLINE_ACK_IDS_FIELD_NUMBER; hash = (53 * hash) + getModifyDeadlineAckIdsList().hashCode(); } hash = (37 * hash) + STREAM_ACK_DEADLINE_SECONDS_FIELD_NUMBER; hash = (53 * hash) + getStreamAckDeadlineSeconds(); hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; }
if (!getModifyDeadlineSecondsList().isEmpty()) { size += 1; size += com.google.protobuf.CodedOutputStream.computeInt32SizeNoTag(dataSize);
Iterator<Integer> seconds = request.getModifyDeadlineSecondsList().iterator(); while (ackIds.hasNext() && seconds.hasNext()) { addReceivedModifyAckDeadline(new ModifyAckDeadline(ackIds.next(), seconds.next()));
@java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.pubsub.v1.StreamingPullRequest)) { return super.equals(obj); } com.google.pubsub.v1.StreamingPullRequest other = (com.google.pubsub.v1.StreamingPullRequest) obj; boolean result = true; result = result && getSubscription().equals(other.getSubscription()); result = result && getAckIdsList().equals(other.getAckIdsList()); result = result && getModifyDeadlineSecondsList().equals(other.getModifyDeadlineSecondsList()); result = result && getModifyDeadlineAckIdsList().equals(other.getModifyDeadlineAckIdsList()); result = result && (getStreamAckDeadlineSeconds() == other.getStreamAckDeadlineSeconds()); result = result && unknownFields.equals(other.unknownFields); return result; }
@java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { getSerializedSize(); if (!getSubscriptionBytes().isEmpty()) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, subscription_); } for (int i = 0; i < ackIds_.size(); i++) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, ackIds_.getRaw(i)); } if (getModifyDeadlineSecondsList().size() > 0) { output.writeUInt32NoTag(26); output.writeUInt32NoTag(modifyDeadlineSecondsMemoizedSerializedSize); } for (int i = 0; i < modifyDeadlineSeconds_.size(); i++) { output.writeInt32NoTag(modifyDeadlineSeconds_.get(i)); } for (int i = 0; i < modifyDeadlineAckIds_.size(); i++) { com.google.protobuf.GeneratedMessageV3.writeString( output, 4, modifyDeadlineAckIds_.getRaw(i)); } if (streamAckDeadlineSeconds_ != 0) { output.writeInt32(5, streamAckDeadlineSeconds_); } unknownFields.writeTo(output); }
if (!getModifyDeadlineSecondsList().isEmpty()) { size += 1; size += com.google.protobuf.CodedOutputStream.computeInt32SizeNoTag(dataSize);
@java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + SUBSCRIPTION_FIELD_NUMBER; hash = (53 * hash) + getSubscription().hashCode(); if (getAckIdsCount() > 0) { hash = (37 * hash) + ACK_IDS_FIELD_NUMBER; hash = (53 * hash) + getAckIdsList().hashCode(); } if (getModifyDeadlineSecondsCount() > 0) { hash = (37 * hash) + MODIFY_DEADLINE_SECONDS_FIELD_NUMBER; hash = (53 * hash) + getModifyDeadlineSecondsList().hashCode(); } if (getModifyDeadlineAckIdsCount() > 0) { hash = (37 * hash) + MODIFY_DEADLINE_ACK_IDS_FIELD_NUMBER; hash = (53 * hash) + getModifyDeadlineAckIdsList().hashCode(); } hash = (37 * hash) + STREAM_ACK_DEADLINE_SECONDS_FIELD_NUMBER; hash = (53 * hash) + getStreamAckDeadlineSeconds(); hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; }