@java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.pubsub.v1.DeleteSubscriptionRequest)) { return super.equals(obj); } com.google.pubsub.v1.DeleteSubscriptionRequest other = (com.google.pubsub.v1.DeleteSubscriptionRequest) obj; boolean result = true; result = result && getSubscription().equals(other.getSubscription()); 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) + SUBSCRIPTION_FIELD_NUMBER; hash = (53 * hash) + getSubscription().hashCode(); hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; }
/** * * * <pre> * The subscription to delete. * Format is `projects/{project}/subscriptions/{sub}`. * </pre> * * <code>string subscription = 1;</code> */ public Builder clearSubscription() { subscription_ = getDefaultInstance().getSubscription(); onChanged(); return this; } /**
public Builder mergeFrom(com.google.pubsub.v1.DeleteSubscriptionRequest other) { if (other == com.google.pubsub.v1.DeleteSubscriptionRequest.getDefaultInstance()) return this; if (!other.getSubscription().isEmpty()) { subscription_ = other.subscription_; onChanged(); } this.mergeUnknownFields(other.unknownFields); onChanged(); return this; }
@Test @SuppressWarnings("all") public void deleteSubscriptionTest() { Empty expectedResponse = Empty.newBuilder().build(); mockSubscriber.addResponse(expectedResponse); ProjectSubscriptionName subscription = ProjectSubscriptionName.of("[PROJECT]", "[SUBSCRIPTION]"); client.deleteSubscription(subscription); List<GeneratedMessageV3> actualRequests = mockSubscriber.getRequests(); Assert.assertEquals(1, actualRequests.size()); DeleteSubscriptionRequest actualRequest = (DeleteSubscriptionRequest) actualRequests.get(0); Assert.assertEquals( subscription, ProjectSubscriptionName.parse(actualRequest.getSubscription())); Assert.assertTrue( channelProvider.isHeaderSent( ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), GaxGrpcProperties.getDefaultApiClientHeaderPattern())); }
@java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.pubsub.v1.DeleteSubscriptionRequest)) { return super.equals(obj); } com.google.pubsub.v1.DeleteSubscriptionRequest other = (com.google.pubsub.v1.DeleteSubscriptionRequest) obj; boolean result = true; result = result && getSubscription() .equals(other.getSubscription()); return result; }
@java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.pubsub.v1.DeleteSubscriptionRequest)) { return super.equals(obj); } com.google.pubsub.v1.DeleteSubscriptionRequest other = (com.google.pubsub.v1.DeleteSubscriptionRequest) obj; boolean result = true; result = result && getSubscription().equals(other.getSubscription()); 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) + getDescriptorForType().hashCode(); hash = (37 * hash) + SUBSCRIPTION_FIELD_NUMBER; hash = (53 * hash) + getSubscription().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) + SUBSCRIPTION_FIELD_NUMBER; hash = (53 * hash) + getSubscription().hashCode(); hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; }
/** * <code>optional string subscription = 1;</code> * * <pre> * The subscription to delete. * </pre> */ public Builder clearSubscription() { subscription_ = getDefaultInstance().getSubscription(); onChanged(); return this; } /**
/** * <pre> * The subscription to delete. * </pre> * * <code>optional string subscription = 1;</code> */ public Builder clearSubscription() { subscription_ = getDefaultInstance().getSubscription(); onChanged(); return this; } /**
public Builder mergeFrom(com.google.pubsub.v1.DeleteSubscriptionRequest other) { if (other == com.google.pubsub.v1.DeleteSubscriptionRequest.getDefaultInstance()) return this; if (!other.getSubscription().isEmpty()) { subscription_ = other.subscription_; onChanged(); } onChanged(); return this; }
/** * * * <pre> * The subscription to delete. * Format is `projects/{project}/subscriptions/{sub}`. * </pre> * * <code>string subscription = 1;</code> */ public Builder clearSubscription() { subscription_ = getDefaultInstance().getSubscription(); onChanged(); return this; } /**
public Builder mergeFrom(com.google.pubsub.v1.DeleteSubscriptionRequest other) { if (other == com.google.pubsub.v1.DeleteSubscriptionRequest.getDefaultInstance()) return this; if (!other.getSubscription().isEmpty()) { subscription_ = other.subscription_; onChanged(); } onChanged(); return this; }
public Builder mergeFrom(com.google.pubsub.v1.DeleteSubscriptionRequest other) { if (other == com.google.pubsub.v1.DeleteSubscriptionRequest.getDefaultInstance()) return this; if (!other.getSubscription().isEmpty()) { subscription_ = other.subscription_; onChanged(); } this.mergeUnknownFields(other.unknownFields); onChanged(); return this; }