@java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + INDEX_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getIndex()); if (hasStatus()) { hash = (37 * hash) + STATUS_FIELD_NUMBER; hash = (53 * hash) + getStatus().hashCode(); } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; }
@java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.bigtable.v2.MutateRowsResponse.Entry)) { return super.equals(obj); } com.google.bigtable.v2.MutateRowsResponse.Entry other = (com.google.bigtable.v2.MutateRowsResponse.Entry) obj; boolean result = true; result = result && (getIndex() == other.getIndex()); result = result && (hasStatus() == other.hasStatus()); if (hasStatus()) { result = result && getStatus().equals(other.getStatus()); } result = result && unknownFields.equals(other.unknownFields); return result; }
private void handleEntries(Iterable<MutateRowsResponse.Entry> entries) { for (MutateRowsResponse.Entry entry : entries) { int index = (int) entry.getIndex(); if (index >= getRequestCount()) { LOG.error("Got extra status: %s", entry); continue; } SettableFuture<MutateRowResponse> future = futures.get(index); if (future == null) { LOG.warn("Could not find a future for index %d.", index); continue; } Status status = entry.getStatus(); if (status.getCode() == io.grpc.Status.Code.OK.value()) { future.set(MutateRowResponse.getDefaultInstance()); } else { future.setException(toException(status)); } } }
@java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.bigtable.v2.MutateRowsResponse.Entry)) { return super.equals(obj); } com.google.bigtable.v2.MutateRowsResponse.Entry other = (com.google.bigtable.v2.MutateRowsResponse.Entry) obj; boolean result = true; result = result && (getIndex() == other.getIndex()); result = result && (hasStatus() == other.hasStatus()); if (hasStatus()) { result = result && getStatus() .equals(other.getStatus()); } return result; }
@java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.bigtable.v2.MutateRowsResponse.Entry)) { return super.equals(obj); } com.google.bigtable.v2.MutateRowsResponse.Entry other = (com.google.bigtable.v2.MutateRowsResponse.Entry) obj; boolean result = true; result = result && (getIndex() == other.getIndex()); result = result && (hasStatus() == other.hasStatus()); if (hasStatus()) { result = result && getStatus().equals(other.getStatus()); } result = result && unknownFields.equals(other.unknownFields); return result; }
@java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + INDEX_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getIndex()); if (hasStatus()) { hash = (37 * hash) + STATUS_FIELD_NUMBER; hash = (53 * hash) + getStatus().hashCode(); } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; }
@java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + INDEX_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getIndex()); if (hasStatus()) { hash = (37 * hash) + STATUS_FIELD_NUMBER; hash = (53 * hash) + getStatus().hashCode(); } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; }
/** * Adds the content of the message to the {@link #results}. */ public void onMessage(MutateRowsResponse message) { for (Entry entry : message.getEntriesList()) { int index = (int) entry.getIndex(); // Sanity check to make sure that the index returned from the server is valid. if (index >= mapToOriginalIndex.length || index < 0) { messageIsInvalid = true; break; } // Set the result. results[mapToOriginalIndex[index]] = entry.getStatus(); } }
public Builder mergeFrom(com.google.bigtable.v2.MutateRowsResponse.Entry other) { if (other == com.google.bigtable.v2.MutateRowsResponse.Entry.getDefaultInstance()) return this; if (other.getIndex() != 0L) { setIndex(other.getIndex()); } if (other.hasStatus()) { mergeStatus(other.getStatus()); } this.mergeUnknownFields(other.unknownFields); onChanged(); return this; }
public Builder mergeFrom(com.google.bigtable.v2.MutateRowsResponse.Entry other) { if (other == com.google.bigtable.v2.MutateRowsResponse.Entry.getDefaultInstance()) return this; if (other.getIndex() != 0L) { setIndex(other.getIndex()); } if (other.hasStatus()) { mergeStatus(other.getStatus()); } onChanged(); return this; }
private static Set<Integer> getIndexes(List<Entry> entries) { Set<Integer> indexes = new HashSet<>(entries.size()); for (Entry entry : entries) { indexes.add((int) entry.getIndex()); } return indexes; }
public Builder mergeFrom(com.google.bigtable.v2.MutateRowsResponse.Entry other) { if (other == com.google.bigtable.v2.MutateRowsResponse.Entry.getDefaultInstance()) return this; if (other.getIndex() != 0L) { setIndex(other.getIndex()); } if (other.hasStatus()) { mergeStatus(other.getStatus()); } this.mergeUnknownFields(other.unknownFields); onChanged(); return this; }