All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse Maven / Gradle / Ivy

There is a newer version: 1.0.46
Show newest version
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: envoy/service/discovery/v2/hds.proto

package io.envoyproxy.envoy.service.discovery.v2;

/**
 * Protobuf type {@code envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse}
 */
public  final class HealthCheckRequestOrEndpointHealthResponse extends
    com.google.protobuf.GeneratedMessageV3 implements
    // @@protoc_insertion_point(message_implements:envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse)
    HealthCheckRequestOrEndpointHealthResponseOrBuilder {
private static final long serialVersionUID = 0L;
  // Use HealthCheckRequestOrEndpointHealthResponse.newBuilder() to construct.
  private HealthCheckRequestOrEndpointHealthResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) {
    super(builder);
  }
  private HealthCheckRequestOrEndpointHealthResponse() {
  }

  @java.lang.Override
  @SuppressWarnings({"unused"})
  protected java.lang.Object newInstance(
      UnusedPrivateParameter unused) {
    return new HealthCheckRequestOrEndpointHealthResponse();
  }

  @java.lang.Override
  public final com.google.protobuf.UnknownFieldSet
  getUnknownFields() {
    return this.unknownFields;
  }
  private HealthCheckRequestOrEndpointHealthResponse(
      com.google.protobuf.CodedInputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    this();
    if (extensionRegistry == null) {
      throw new java.lang.NullPointerException();
    }
    com.google.protobuf.UnknownFieldSet.Builder unknownFields =
        com.google.protobuf.UnknownFieldSet.newBuilder();
    try {
      boolean done = false;
      while (!done) {
        int tag = input.readTag();
        switch (tag) {
          case 0:
            done = true;
            break;
          case 10: {
            io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest.Builder subBuilder = null;
            if (requestTypeCase_ == 1) {
              subBuilder = ((io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest) requestType_).toBuilder();
            }
            requestType_ =
                input.readMessage(io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest.parser(), extensionRegistry);
            if (subBuilder != null) {
              subBuilder.mergeFrom((io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest) requestType_);
              requestType_ = subBuilder.buildPartial();
            }
            requestTypeCase_ = 1;
            break;
          }
          case 18: {
            io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse.Builder subBuilder = null;
            if (requestTypeCase_ == 2) {
              subBuilder = ((io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse) requestType_).toBuilder();
            }
            requestType_ =
                input.readMessage(io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse.parser(), extensionRegistry);
            if (subBuilder != null) {
              subBuilder.mergeFrom((io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse) requestType_);
              requestType_ = subBuilder.buildPartial();
            }
            requestTypeCase_ = 2;
            break;
          }
          default: {
            if (!parseUnknownField(
                input, unknownFields, extensionRegistry, tag)) {
              done = true;
            }
            break;
          }
        }
      }
    } catch (com.google.protobuf.InvalidProtocolBufferException e) {
      throw e.setUnfinishedMessage(this);
    } catch (java.io.IOException e) {
      throw new com.google.protobuf.InvalidProtocolBufferException(
          e).setUnfinishedMessage(this);
    } finally {
      this.unknownFields = unknownFields.build();
      makeExtensionsImmutable();
    }
  }
  public static final com.google.protobuf.Descriptors.Descriptor
      getDescriptor() {
    return io.envoyproxy.envoy.service.discovery.v2.HdsProto.internal_static_envoy_service_discovery_v2_HealthCheckRequestOrEndpointHealthResponse_descriptor;
  }

  @java.lang.Override
  protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
      internalGetFieldAccessorTable() {
    return io.envoyproxy.envoy.service.discovery.v2.HdsProto.internal_static_envoy_service_discovery_v2_HealthCheckRequestOrEndpointHealthResponse_fieldAccessorTable
        .ensureFieldAccessorsInitialized(
            io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse.class, io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse.Builder.class);
  }

  private int requestTypeCase_ = 0;
  private java.lang.Object requestType_;
  public enum RequestTypeCase
      implements com.google.protobuf.Internal.EnumLite {
    HEALTH_CHECK_REQUEST(1),
    ENDPOINT_HEALTH_RESPONSE(2),
    REQUESTTYPE_NOT_SET(0);
    private final int value;
    private RequestTypeCase(int value) {
      this.value = value;
    }
    /**
     * @deprecated Use {@link #forNumber(int)} instead.
     */
    @java.lang.Deprecated
    public static RequestTypeCase valueOf(int value) {
      return forNumber(value);
    }

    public static RequestTypeCase forNumber(int value) {
      switch (value) {
        case 1: return HEALTH_CHECK_REQUEST;
        case 2: return ENDPOINT_HEALTH_RESPONSE;
        case 0: return REQUESTTYPE_NOT_SET;
        default: return null;
      }
    }
    public int getNumber() {
      return this.value;
    }
  };

  public RequestTypeCase
  getRequestTypeCase() {
    return RequestTypeCase.forNumber(
        requestTypeCase_);
  }

  public static final int HEALTH_CHECK_REQUEST_FIELD_NUMBER = 1;
  /**
   * .envoy.service.discovery.v2.HealthCheckRequest health_check_request = 1;
   */
  public boolean hasHealthCheckRequest() {
    return requestTypeCase_ == 1;
  }
  /**
   * .envoy.service.discovery.v2.HealthCheckRequest health_check_request = 1;
   */
  public io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest getHealthCheckRequest() {
    if (requestTypeCase_ == 1) {
       return (io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest) requestType_;
    }
    return io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest.getDefaultInstance();
  }
  /**
   * .envoy.service.discovery.v2.HealthCheckRequest health_check_request = 1;
   */
  public io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrBuilder getHealthCheckRequestOrBuilder() {
    if (requestTypeCase_ == 1) {
       return (io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest) requestType_;
    }
    return io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest.getDefaultInstance();
  }

  public static final int ENDPOINT_HEALTH_RESPONSE_FIELD_NUMBER = 2;
  /**
   * .envoy.service.discovery.v2.EndpointHealthResponse endpoint_health_response = 2;
   */
  public boolean hasEndpointHealthResponse() {
    return requestTypeCase_ == 2;
  }
  /**
   * .envoy.service.discovery.v2.EndpointHealthResponse endpoint_health_response = 2;
   */
  public io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse getEndpointHealthResponse() {
    if (requestTypeCase_ == 2) {
       return (io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse) requestType_;
    }
    return io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse.getDefaultInstance();
  }
  /**
   * .envoy.service.discovery.v2.EndpointHealthResponse endpoint_health_response = 2;
   */
  public io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponseOrBuilder getEndpointHealthResponseOrBuilder() {
    if (requestTypeCase_ == 2) {
       return (io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse) requestType_;
    }
    return io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse.getDefaultInstance();
  }

  private byte memoizedIsInitialized = -1;
  @java.lang.Override
  public final boolean isInitialized() {
    byte isInitialized = memoizedIsInitialized;
    if (isInitialized == 1) return true;
    if (isInitialized == 0) return false;

    memoizedIsInitialized = 1;
    return true;
  }

  @java.lang.Override
  public void writeTo(com.google.protobuf.CodedOutputStream output)
                      throws java.io.IOException {
    if (requestTypeCase_ == 1) {
      output.writeMessage(1, (io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest) requestType_);
    }
    if (requestTypeCase_ == 2) {
      output.writeMessage(2, (io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse) requestType_);
    }
    unknownFields.writeTo(output);
  }

  @java.lang.Override
  public int getSerializedSize() {
    int size = memoizedSize;
    if (size != -1) return size;

    size = 0;
    if (requestTypeCase_ == 1) {
      size += com.google.protobuf.CodedOutputStream
        .computeMessageSize(1, (io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest) requestType_);
    }
    if (requestTypeCase_ == 2) {
      size += com.google.protobuf.CodedOutputStream
        .computeMessageSize(2, (io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse) requestType_);
    }
    size += unknownFields.getSerializedSize();
    memoizedSize = size;
    return size;
  }

  @java.lang.Override
  public boolean equals(final java.lang.Object obj) {
    if (obj == this) {
     return true;
    }
    if (!(obj instanceof io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse)) {
      return super.equals(obj);
    }
    io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse other = (io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse) obj;

    if (!getRequestTypeCase().equals(other.getRequestTypeCase())) return false;
    switch (requestTypeCase_) {
      case 1:
        if (!getHealthCheckRequest()
            .equals(other.getHealthCheckRequest())) return false;
        break;
      case 2:
        if (!getEndpointHealthResponse()
            .equals(other.getEndpointHealthResponse())) return false;
        break;
      case 0:
      default:
    }
    if (!unknownFields.equals(other.unknownFields)) return false;
    return true;
  }

  @java.lang.Override
  public int hashCode() {
    if (memoizedHashCode != 0) {
      return memoizedHashCode;
    }
    int hash = 41;
    hash = (19 * hash) + getDescriptor().hashCode();
    switch (requestTypeCase_) {
      case 1:
        hash = (37 * hash) + HEALTH_CHECK_REQUEST_FIELD_NUMBER;
        hash = (53 * hash) + getHealthCheckRequest().hashCode();
        break;
      case 2:
        hash = (37 * hash) + ENDPOINT_HEALTH_RESPONSE_FIELD_NUMBER;
        hash = (53 * hash) + getEndpointHealthResponse().hashCode();
        break;
      case 0:
      default:
    }
    hash = (29 * hash) + unknownFields.hashCode();
    memoizedHashCode = hash;
    return hash;
  }

  public static io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse parseFrom(
      java.nio.ByteBuffer data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse parseFrom(
      java.nio.ByteBuffer data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse parseFrom(
      com.google.protobuf.ByteString data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse parseFrom(
      com.google.protobuf.ByteString data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse parseFrom(byte[] data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse parseFrom(
      byte[] data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse parseFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input);
  }
  public static io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse parseFrom(
      java.io.InputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input, extensionRegistry);
  }
  public static io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse parseDelimitedFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseDelimitedWithIOException(PARSER, input);
  }
  public static io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse parseDelimitedFrom(
      java.io.InputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseDelimitedWithIOException(PARSER, input, extensionRegistry);
  }
  public static io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse parseFrom(
      com.google.protobuf.CodedInputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input);
  }
  public static io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse parseFrom(
      com.google.protobuf.CodedInputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input, extensionRegistry);
  }

  @java.lang.Override
  public Builder newBuilderForType() { return newBuilder(); }
  public static Builder newBuilder() {
    return DEFAULT_INSTANCE.toBuilder();
  }
  public static Builder newBuilder(io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse prototype) {
    return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
  }
  @java.lang.Override
  public Builder toBuilder() {
    return this == DEFAULT_INSTANCE
        ? new Builder() : new Builder().mergeFrom(this);
  }

  @java.lang.Override
  protected Builder newBuilderForType(
      com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
    Builder builder = new Builder(parent);
    return builder;
  }
  /**
   * Protobuf type {@code envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse}
   */
  public static final class Builder extends
      com.google.protobuf.GeneratedMessageV3.Builder implements
      // @@protoc_insertion_point(builder_implements:envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse)
      io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponseOrBuilder {
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return io.envoyproxy.envoy.service.discovery.v2.HdsProto.internal_static_envoy_service_discovery_v2_HealthCheckRequestOrEndpointHealthResponse_descriptor;
    }

    @java.lang.Override
    protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return io.envoyproxy.envoy.service.discovery.v2.HdsProto.internal_static_envoy_service_discovery_v2_HealthCheckRequestOrEndpointHealthResponse_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse.class, io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse.Builder.class);
    }

    // Construct using io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse.newBuilder()
    private Builder() {
      maybeForceBuilderInitialization();
    }

    private Builder(
        com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
      super(parent);
      maybeForceBuilderInitialization();
    }
    private void maybeForceBuilderInitialization() {
      if (com.google.protobuf.GeneratedMessageV3
              .alwaysUseFieldBuilders) {
      }
    }
    @java.lang.Override
    public Builder clear() {
      super.clear();
      requestTypeCase_ = 0;
      requestType_ = null;
      return this;
    }

    @java.lang.Override
    public com.google.protobuf.Descriptors.Descriptor
        getDescriptorForType() {
      return io.envoyproxy.envoy.service.discovery.v2.HdsProto.internal_static_envoy_service_discovery_v2_HealthCheckRequestOrEndpointHealthResponse_descriptor;
    }

    @java.lang.Override
    public io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse getDefaultInstanceForType() {
      return io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse.getDefaultInstance();
    }

    @java.lang.Override
    public io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse build() {
      io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse result = buildPartial();
      if (!result.isInitialized()) {
        throw newUninitializedMessageException(result);
      }
      return result;
    }

    @java.lang.Override
    public io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse buildPartial() {
      io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse result = new io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse(this);
      if (requestTypeCase_ == 1) {
        if (healthCheckRequestBuilder_ == null) {
          result.requestType_ = requestType_;
        } else {
          result.requestType_ = healthCheckRequestBuilder_.build();
        }
      }
      if (requestTypeCase_ == 2) {
        if (endpointHealthResponseBuilder_ == null) {
          result.requestType_ = requestType_;
        } else {
          result.requestType_ = endpointHealthResponseBuilder_.build();
        }
      }
      result.requestTypeCase_ = requestTypeCase_;
      onBuilt();
      return result;
    }

    @java.lang.Override
    public Builder clone() {
      return super.clone();
    }
    @java.lang.Override
    public Builder setField(
        com.google.protobuf.Descriptors.FieldDescriptor field,
        java.lang.Object value) {
      return super.setField(field, value);
    }
    @java.lang.Override
    public Builder clearField(
        com.google.protobuf.Descriptors.FieldDescriptor field) {
      return super.clearField(field);
    }
    @java.lang.Override
    public Builder clearOneof(
        com.google.protobuf.Descriptors.OneofDescriptor oneof) {
      return super.clearOneof(oneof);
    }
    @java.lang.Override
    public Builder setRepeatedField(
        com.google.protobuf.Descriptors.FieldDescriptor field,
        int index, java.lang.Object value) {
      return super.setRepeatedField(field, index, value);
    }
    @java.lang.Override
    public Builder addRepeatedField(
        com.google.protobuf.Descriptors.FieldDescriptor field,
        java.lang.Object value) {
      return super.addRepeatedField(field, value);
    }
    @java.lang.Override
    public Builder mergeFrom(com.google.protobuf.Message other) {
      if (other instanceof io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse) {
        return mergeFrom((io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse)other);
      } else {
        super.mergeFrom(other);
        return this;
      }
    }

    public Builder mergeFrom(io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse other) {
      if (other == io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse.getDefaultInstance()) return this;
      switch (other.getRequestTypeCase()) {
        case HEALTH_CHECK_REQUEST: {
          mergeHealthCheckRequest(other.getHealthCheckRequest());
          break;
        }
        case ENDPOINT_HEALTH_RESPONSE: {
          mergeEndpointHealthResponse(other.getEndpointHealthResponse());
          break;
        }
        case REQUESTTYPE_NOT_SET: {
          break;
        }
      }
      this.mergeUnknownFields(other.unknownFields);
      onChanged();
      return this;
    }

    @java.lang.Override
    public final boolean isInitialized() {
      return true;
    }

    @java.lang.Override
    public Builder mergeFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse parsedMessage = null;
      try {
        parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        parsedMessage = (io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse) e.getUnfinishedMessage();
        throw e.unwrapIOException();
      } finally {
        if (parsedMessage != null) {
          mergeFrom(parsedMessage);
        }
      }
      return this;
    }
    private int requestTypeCase_ = 0;
    private java.lang.Object requestType_;
    public RequestTypeCase
        getRequestTypeCase() {
      return RequestTypeCase.forNumber(
          requestTypeCase_);
    }

    public Builder clearRequestType() {
      requestTypeCase_ = 0;
      requestType_ = null;
      onChanged();
      return this;
    }


    private com.google.protobuf.SingleFieldBuilderV3<
        io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest, io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest.Builder, io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrBuilder> healthCheckRequestBuilder_;
    /**
     * .envoy.service.discovery.v2.HealthCheckRequest health_check_request = 1;
     */
    public boolean hasHealthCheckRequest() {
      return requestTypeCase_ == 1;
    }
    /**
     * .envoy.service.discovery.v2.HealthCheckRequest health_check_request = 1;
     */
    public io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest getHealthCheckRequest() {
      if (healthCheckRequestBuilder_ == null) {
        if (requestTypeCase_ == 1) {
          return (io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest) requestType_;
        }
        return io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest.getDefaultInstance();
      } else {
        if (requestTypeCase_ == 1) {
          return healthCheckRequestBuilder_.getMessage();
        }
        return io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest.getDefaultInstance();
      }
    }
    /**
     * .envoy.service.discovery.v2.HealthCheckRequest health_check_request = 1;
     */
    public Builder setHealthCheckRequest(io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest value) {
      if (healthCheckRequestBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        requestType_ = value;
        onChanged();
      } else {
        healthCheckRequestBuilder_.setMessage(value);
      }
      requestTypeCase_ = 1;
      return this;
    }
    /**
     * .envoy.service.discovery.v2.HealthCheckRequest health_check_request = 1;
     */
    public Builder setHealthCheckRequest(
        io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest.Builder builderForValue) {
      if (healthCheckRequestBuilder_ == null) {
        requestType_ = builderForValue.build();
        onChanged();
      } else {
        healthCheckRequestBuilder_.setMessage(builderForValue.build());
      }
      requestTypeCase_ = 1;
      return this;
    }
    /**
     * .envoy.service.discovery.v2.HealthCheckRequest health_check_request = 1;
     */
    public Builder mergeHealthCheckRequest(io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest value) {
      if (healthCheckRequestBuilder_ == null) {
        if (requestTypeCase_ == 1 &&
            requestType_ != io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest.getDefaultInstance()) {
          requestType_ = io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest.newBuilder((io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest) requestType_)
              .mergeFrom(value).buildPartial();
        } else {
          requestType_ = value;
        }
        onChanged();
      } else {
        if (requestTypeCase_ == 1) {
          healthCheckRequestBuilder_.mergeFrom(value);
        }
        healthCheckRequestBuilder_.setMessage(value);
      }
      requestTypeCase_ = 1;
      return this;
    }
    /**
     * .envoy.service.discovery.v2.HealthCheckRequest health_check_request = 1;
     */
    public Builder clearHealthCheckRequest() {
      if (healthCheckRequestBuilder_ == null) {
        if (requestTypeCase_ == 1) {
          requestTypeCase_ = 0;
          requestType_ = null;
          onChanged();
        }
      } else {
        if (requestTypeCase_ == 1) {
          requestTypeCase_ = 0;
          requestType_ = null;
        }
        healthCheckRequestBuilder_.clear();
      }
      return this;
    }
    /**
     * .envoy.service.discovery.v2.HealthCheckRequest health_check_request = 1;
     */
    public io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest.Builder getHealthCheckRequestBuilder() {
      return getHealthCheckRequestFieldBuilder().getBuilder();
    }
    /**
     * .envoy.service.discovery.v2.HealthCheckRequest health_check_request = 1;
     */
    public io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrBuilder getHealthCheckRequestOrBuilder() {
      if ((requestTypeCase_ == 1) && (healthCheckRequestBuilder_ != null)) {
        return healthCheckRequestBuilder_.getMessageOrBuilder();
      } else {
        if (requestTypeCase_ == 1) {
          return (io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest) requestType_;
        }
        return io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest.getDefaultInstance();
      }
    }
    /**
     * .envoy.service.discovery.v2.HealthCheckRequest health_check_request = 1;
     */
    private com.google.protobuf.SingleFieldBuilderV3<
        io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest, io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest.Builder, io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrBuilder> 
        getHealthCheckRequestFieldBuilder() {
      if (healthCheckRequestBuilder_ == null) {
        if (!(requestTypeCase_ == 1)) {
          requestType_ = io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest.getDefaultInstance();
        }
        healthCheckRequestBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
            io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest, io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest.Builder, io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrBuilder>(
                (io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequest) requestType_,
                getParentForChildren(),
                isClean());
        requestType_ = null;
      }
      requestTypeCase_ = 1;
      onChanged();;
      return healthCheckRequestBuilder_;
    }

    private com.google.protobuf.SingleFieldBuilderV3<
        io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse, io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse.Builder, io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponseOrBuilder> endpointHealthResponseBuilder_;
    /**
     * .envoy.service.discovery.v2.EndpointHealthResponse endpoint_health_response = 2;
     */
    public boolean hasEndpointHealthResponse() {
      return requestTypeCase_ == 2;
    }
    /**
     * .envoy.service.discovery.v2.EndpointHealthResponse endpoint_health_response = 2;
     */
    public io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse getEndpointHealthResponse() {
      if (endpointHealthResponseBuilder_ == null) {
        if (requestTypeCase_ == 2) {
          return (io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse) requestType_;
        }
        return io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse.getDefaultInstance();
      } else {
        if (requestTypeCase_ == 2) {
          return endpointHealthResponseBuilder_.getMessage();
        }
        return io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse.getDefaultInstance();
      }
    }
    /**
     * .envoy.service.discovery.v2.EndpointHealthResponse endpoint_health_response = 2;
     */
    public Builder setEndpointHealthResponse(io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse value) {
      if (endpointHealthResponseBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        requestType_ = value;
        onChanged();
      } else {
        endpointHealthResponseBuilder_.setMessage(value);
      }
      requestTypeCase_ = 2;
      return this;
    }
    /**
     * .envoy.service.discovery.v2.EndpointHealthResponse endpoint_health_response = 2;
     */
    public Builder setEndpointHealthResponse(
        io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse.Builder builderForValue) {
      if (endpointHealthResponseBuilder_ == null) {
        requestType_ = builderForValue.build();
        onChanged();
      } else {
        endpointHealthResponseBuilder_.setMessage(builderForValue.build());
      }
      requestTypeCase_ = 2;
      return this;
    }
    /**
     * .envoy.service.discovery.v2.EndpointHealthResponse endpoint_health_response = 2;
     */
    public Builder mergeEndpointHealthResponse(io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse value) {
      if (endpointHealthResponseBuilder_ == null) {
        if (requestTypeCase_ == 2 &&
            requestType_ != io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse.getDefaultInstance()) {
          requestType_ = io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse.newBuilder((io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse) requestType_)
              .mergeFrom(value).buildPartial();
        } else {
          requestType_ = value;
        }
        onChanged();
      } else {
        if (requestTypeCase_ == 2) {
          endpointHealthResponseBuilder_.mergeFrom(value);
        }
        endpointHealthResponseBuilder_.setMessage(value);
      }
      requestTypeCase_ = 2;
      return this;
    }
    /**
     * .envoy.service.discovery.v2.EndpointHealthResponse endpoint_health_response = 2;
     */
    public Builder clearEndpointHealthResponse() {
      if (endpointHealthResponseBuilder_ == null) {
        if (requestTypeCase_ == 2) {
          requestTypeCase_ = 0;
          requestType_ = null;
          onChanged();
        }
      } else {
        if (requestTypeCase_ == 2) {
          requestTypeCase_ = 0;
          requestType_ = null;
        }
        endpointHealthResponseBuilder_.clear();
      }
      return this;
    }
    /**
     * .envoy.service.discovery.v2.EndpointHealthResponse endpoint_health_response = 2;
     */
    public io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse.Builder getEndpointHealthResponseBuilder() {
      return getEndpointHealthResponseFieldBuilder().getBuilder();
    }
    /**
     * .envoy.service.discovery.v2.EndpointHealthResponse endpoint_health_response = 2;
     */
    public io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponseOrBuilder getEndpointHealthResponseOrBuilder() {
      if ((requestTypeCase_ == 2) && (endpointHealthResponseBuilder_ != null)) {
        return endpointHealthResponseBuilder_.getMessageOrBuilder();
      } else {
        if (requestTypeCase_ == 2) {
          return (io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse) requestType_;
        }
        return io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse.getDefaultInstance();
      }
    }
    /**
     * .envoy.service.discovery.v2.EndpointHealthResponse endpoint_health_response = 2;
     */
    private com.google.protobuf.SingleFieldBuilderV3<
        io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse, io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse.Builder, io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponseOrBuilder> 
        getEndpointHealthResponseFieldBuilder() {
      if (endpointHealthResponseBuilder_ == null) {
        if (!(requestTypeCase_ == 2)) {
          requestType_ = io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse.getDefaultInstance();
        }
        endpointHealthResponseBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
            io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse, io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse.Builder, io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponseOrBuilder>(
                (io.envoyproxy.envoy.service.discovery.v2.EndpointHealthResponse) requestType_,
                getParentForChildren(),
                isClean());
        requestType_ = null;
      }
      requestTypeCase_ = 2;
      onChanged();;
      return endpointHealthResponseBuilder_;
    }
    @java.lang.Override
    public final Builder setUnknownFields(
        final com.google.protobuf.UnknownFieldSet unknownFields) {
      return super.setUnknownFields(unknownFields);
    }

    @java.lang.Override
    public final Builder mergeUnknownFields(
        final com.google.protobuf.UnknownFieldSet unknownFields) {
      return super.mergeUnknownFields(unknownFields);
    }


    // @@protoc_insertion_point(builder_scope:envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse)
  }

  // @@protoc_insertion_point(class_scope:envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse)
  private static final io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse DEFAULT_INSTANCE;
  static {
    DEFAULT_INSTANCE = new io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse();
  }

  public static io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse getDefaultInstance() {
    return DEFAULT_INSTANCE;
  }

  private static final com.google.protobuf.Parser
      PARSER = new com.google.protobuf.AbstractParser() {
    @java.lang.Override
    public HealthCheckRequestOrEndpointHealthResponse parsePartialFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return new HealthCheckRequestOrEndpointHealthResponse(input, extensionRegistry);
    }
  };

  public static com.google.protobuf.Parser parser() {
    return PARSER;
  }

  @java.lang.Override
  public com.google.protobuf.Parser getParserForType() {
    return PARSER;
  }

  @java.lang.Override
  public io.envoyproxy.envoy.service.discovery.v2.HealthCheckRequestOrEndpointHealthResponse getDefaultInstanceForType() {
    return DEFAULT_INSTANCE;
  }

}





© 2015 - 2024 Weber Informatics LLC | Privacy Policy