1 /* 2 * Copyright 2020 Google LLC 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * https://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 // Generated by the protocol buffer compiler. DO NOT EDIT! 17 // source: google/cloud/compute/v1/compute.proto 18 19 package com.google.cloud.compute.v1; 20 21 /** 22 * 23 * 24 * <pre> 25 * </pre> 26 * 27 * Protobuf type {@code google.cloud.compute.v1.HTTPHealthCheck} 28 */ 29 public final class HTTPHealthCheck extends com.google.protobuf.GeneratedMessageV3 30 implements 31 // @@protoc_insertion_point(message_implements:google.cloud.compute.v1.HTTPHealthCheck) 32 HTTPHealthCheckOrBuilder { 33 private static final long serialVersionUID = 0L; 34 // Use HTTPHealthCheck.newBuilder() to construct. HTTPHealthCheck(com.google.protobuf.GeneratedMessageV3.Builder<?> builder)35 private HTTPHealthCheck(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) { 36 super(builder); 37 } 38 HTTPHealthCheck()39 private HTTPHealthCheck() { 40 host_ = ""; 41 portName_ = ""; 42 portSpecification_ = ""; 43 proxyHeader_ = ""; 44 requestPath_ = ""; 45 response_ = ""; 46 } 47 48 @java.lang.Override 49 @SuppressWarnings({"unused"}) newInstance(UnusedPrivateParameter unused)50 protected java.lang.Object newInstance(UnusedPrivateParameter unused) { 51 return new HTTPHealthCheck(); 52 } 53 54 @java.lang.Override getUnknownFields()55 public final com.google.protobuf.UnknownFieldSet getUnknownFields() { 56 return this.unknownFields; 57 } 58 getDescriptor()59 public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { 60 return com.google.cloud.compute.v1.Compute 61 .internal_static_google_cloud_compute_v1_HTTPHealthCheck_descriptor; 62 } 63 64 @java.lang.Override 65 protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()66 internalGetFieldAccessorTable() { 67 return com.google.cloud.compute.v1.Compute 68 .internal_static_google_cloud_compute_v1_HTTPHealthCheck_fieldAccessorTable 69 .ensureFieldAccessorsInitialized( 70 com.google.cloud.compute.v1.HTTPHealthCheck.class, 71 com.google.cloud.compute.v1.HTTPHealthCheck.Builder.class); 72 } 73 74 /** 75 * 76 * 77 * <pre> 78 * Specifies how a port is selected for health checking. Can be one of the following values: USE_FIXED_PORT: Specifies a port number explicitly using the port field in the health check. Supported by backend services for pass-through load balancers and backend services for proxy load balancers. Also supported in legacy HTTP health checks for target pools. The health check supports all backends supported by the backend service provided the backend can be health checked. For example, GCE_VM_IP network endpoint groups, GCE_VM_IP_PORT network endpoint groups, and instance group backends. USE_NAMED_PORT: Not supported. USE_SERVING_PORT: Provides an indirect method of specifying the health check port by referring to the backend service. Only supported by backend services for proxy load balancers. Not supported by target pools. Not supported by backend services for pass-through load balancers. Supports all backends that can be health checked; for example, GCE_VM_IP_PORT network endpoint groups and instance group backends. For GCE_VM_IP_PORT network endpoint group backends, the health check uses the port number specified for each endpoint in the network endpoint group. For instance group backends, the health check uses the port number determined by looking up the backend service's named port in the instance group's list of named ports. 79 * </pre> 80 * 81 * Protobuf enum {@code google.cloud.compute.v1.HTTPHealthCheck.PortSpecification} 82 */ 83 public enum PortSpecification implements com.google.protobuf.ProtocolMessageEnum { 84 /** 85 * 86 * 87 * <pre> 88 * A value indicating that the enum field is not set. 89 * </pre> 90 * 91 * <code>UNDEFINED_PORT_SPECIFICATION = 0;</code> 92 */ 93 UNDEFINED_PORT_SPECIFICATION(0), 94 /** 95 * 96 * 97 * <pre> 98 * The port number in the health check's port is used for health checking. Applies to network endpoint group and instance group backends. 99 * </pre> 100 * 101 * <code>USE_FIXED_PORT = 190235748;</code> 102 */ 103 USE_FIXED_PORT(190235748), 104 /** 105 * 106 * 107 * <pre> 108 * Not supported. 109 * </pre> 110 * 111 * <code>USE_NAMED_PORT = 349300671;</code> 112 */ 113 USE_NAMED_PORT(349300671), 114 /** 115 * 116 * 117 * <pre> 118 * For network endpoint group backends, the health check uses the port number specified on each endpoint in the network endpoint group. For instance group backends, the health check uses the port number specified for the backend service's named port defined in the instance group's named ports. 119 * </pre> 120 * 121 * <code>USE_SERVING_PORT = 362637516;</code> 122 */ 123 USE_SERVING_PORT(362637516), 124 UNRECOGNIZED(-1), 125 ; 126 127 /** 128 * 129 * 130 * <pre> 131 * A value indicating that the enum field is not set. 132 * </pre> 133 * 134 * <code>UNDEFINED_PORT_SPECIFICATION = 0;</code> 135 */ 136 public static final int UNDEFINED_PORT_SPECIFICATION_VALUE = 0; 137 /** 138 * 139 * 140 * <pre> 141 * The port number in the health check's port is used for health checking. Applies to network endpoint group and instance group backends. 142 * </pre> 143 * 144 * <code>USE_FIXED_PORT = 190235748;</code> 145 */ 146 public static final int USE_FIXED_PORT_VALUE = 190235748; 147 /** 148 * 149 * 150 * <pre> 151 * Not supported. 152 * </pre> 153 * 154 * <code>USE_NAMED_PORT = 349300671;</code> 155 */ 156 public static final int USE_NAMED_PORT_VALUE = 349300671; 157 /** 158 * 159 * 160 * <pre> 161 * For network endpoint group backends, the health check uses the port number specified on each endpoint in the network endpoint group. For instance group backends, the health check uses the port number specified for the backend service's named port defined in the instance group's named ports. 162 * </pre> 163 * 164 * <code>USE_SERVING_PORT = 362637516;</code> 165 */ 166 public static final int USE_SERVING_PORT_VALUE = 362637516; 167 getNumber()168 public final int getNumber() { 169 if (this == UNRECOGNIZED) { 170 throw new java.lang.IllegalArgumentException( 171 "Can't get the number of an unknown enum value."); 172 } 173 return value; 174 } 175 176 /** 177 * @param value The numeric wire value of the corresponding enum entry. 178 * @return The enum associated with the given numeric wire value. 179 * @deprecated Use {@link #forNumber(int)} instead. 180 */ 181 @java.lang.Deprecated valueOf(int value)182 public static PortSpecification valueOf(int value) { 183 return forNumber(value); 184 } 185 186 /** 187 * @param value The numeric wire value of the corresponding enum entry. 188 * @return The enum associated with the given numeric wire value. 189 */ forNumber(int value)190 public static PortSpecification forNumber(int value) { 191 switch (value) { 192 case 0: 193 return UNDEFINED_PORT_SPECIFICATION; 194 case 190235748: 195 return USE_FIXED_PORT; 196 case 349300671: 197 return USE_NAMED_PORT; 198 case 362637516: 199 return USE_SERVING_PORT; 200 default: 201 return null; 202 } 203 } 204 205 public static com.google.protobuf.Internal.EnumLiteMap<PortSpecification> internalGetValueMap()206 internalGetValueMap() { 207 return internalValueMap; 208 } 209 210 private static final com.google.protobuf.Internal.EnumLiteMap<PortSpecification> 211 internalValueMap = 212 new com.google.protobuf.Internal.EnumLiteMap<PortSpecification>() { 213 public PortSpecification findValueByNumber(int number) { 214 return PortSpecification.forNumber(number); 215 } 216 }; 217 getValueDescriptor()218 public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { 219 if (this == UNRECOGNIZED) { 220 throw new java.lang.IllegalStateException( 221 "Can't get the descriptor of an unrecognized enum value."); 222 } 223 return getDescriptor().getValues().get(ordinal()); 224 } 225 getDescriptorForType()226 public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { 227 return getDescriptor(); 228 } 229 getDescriptor()230 public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { 231 return com.google.cloud.compute.v1.HTTPHealthCheck.getDescriptor().getEnumTypes().get(0); 232 } 233 234 private static final PortSpecification[] VALUES = values(); 235 valueOf( com.google.protobuf.Descriptors.EnumValueDescriptor desc)236 public static PortSpecification valueOf( 237 com.google.protobuf.Descriptors.EnumValueDescriptor desc) { 238 if (desc.getType() != getDescriptor()) { 239 throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); 240 } 241 if (desc.getIndex() == -1) { 242 return UNRECOGNIZED; 243 } 244 return VALUES[desc.getIndex()]; 245 } 246 247 private final int value; 248 PortSpecification(int value)249 private PortSpecification(int value) { 250 this.value = value; 251 } 252 253 // @@protoc_insertion_point(enum_scope:google.cloud.compute.v1.HTTPHealthCheck.PortSpecification) 254 } 255 256 /** 257 * 258 * 259 * <pre> 260 * Specifies the type of proxy header to append before sending data to the backend, either NONE or PROXY_V1. The default is NONE. 261 * </pre> 262 * 263 * Protobuf enum {@code google.cloud.compute.v1.HTTPHealthCheck.ProxyHeader} 264 */ 265 public enum ProxyHeader implements com.google.protobuf.ProtocolMessageEnum { 266 /** 267 * 268 * 269 * <pre> 270 * A value indicating that the enum field is not set. 271 * </pre> 272 * 273 * <code>UNDEFINED_PROXY_HEADER = 0;</code> 274 */ 275 UNDEFINED_PROXY_HEADER(0), 276 /** <code>NONE = 2402104;</code> */ 277 NONE(2402104), 278 /** <code>PROXY_V1 = 334352940;</code> */ 279 PROXY_V1(334352940), 280 UNRECOGNIZED(-1), 281 ; 282 283 /** 284 * 285 * 286 * <pre> 287 * A value indicating that the enum field is not set. 288 * </pre> 289 * 290 * <code>UNDEFINED_PROXY_HEADER = 0;</code> 291 */ 292 public static final int UNDEFINED_PROXY_HEADER_VALUE = 0; 293 /** <code>NONE = 2402104;</code> */ 294 public static final int NONE_VALUE = 2402104; 295 /** <code>PROXY_V1 = 334352940;</code> */ 296 public static final int PROXY_V1_VALUE = 334352940; 297 getNumber()298 public final int getNumber() { 299 if (this == UNRECOGNIZED) { 300 throw new java.lang.IllegalArgumentException( 301 "Can't get the number of an unknown enum value."); 302 } 303 return value; 304 } 305 306 /** 307 * @param value The numeric wire value of the corresponding enum entry. 308 * @return The enum associated with the given numeric wire value. 309 * @deprecated Use {@link #forNumber(int)} instead. 310 */ 311 @java.lang.Deprecated valueOf(int value)312 public static ProxyHeader valueOf(int value) { 313 return forNumber(value); 314 } 315 316 /** 317 * @param value The numeric wire value of the corresponding enum entry. 318 * @return The enum associated with the given numeric wire value. 319 */ forNumber(int value)320 public static ProxyHeader forNumber(int value) { 321 switch (value) { 322 case 0: 323 return UNDEFINED_PROXY_HEADER; 324 case 2402104: 325 return NONE; 326 case 334352940: 327 return PROXY_V1; 328 default: 329 return null; 330 } 331 } 332 internalGetValueMap()333 public static com.google.protobuf.Internal.EnumLiteMap<ProxyHeader> internalGetValueMap() { 334 return internalValueMap; 335 } 336 337 private static final com.google.protobuf.Internal.EnumLiteMap<ProxyHeader> internalValueMap = 338 new com.google.protobuf.Internal.EnumLiteMap<ProxyHeader>() { 339 public ProxyHeader findValueByNumber(int number) { 340 return ProxyHeader.forNumber(number); 341 } 342 }; 343 getValueDescriptor()344 public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { 345 if (this == UNRECOGNIZED) { 346 throw new java.lang.IllegalStateException( 347 "Can't get the descriptor of an unrecognized enum value."); 348 } 349 return getDescriptor().getValues().get(ordinal()); 350 } 351 getDescriptorForType()352 public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { 353 return getDescriptor(); 354 } 355 getDescriptor()356 public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { 357 return com.google.cloud.compute.v1.HTTPHealthCheck.getDescriptor().getEnumTypes().get(1); 358 } 359 360 private static final ProxyHeader[] VALUES = values(); 361 valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc)362 public static ProxyHeader valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { 363 if (desc.getType() != getDescriptor()) { 364 throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); 365 } 366 if (desc.getIndex() == -1) { 367 return UNRECOGNIZED; 368 } 369 return VALUES[desc.getIndex()]; 370 } 371 372 private final int value; 373 ProxyHeader(int value)374 private ProxyHeader(int value) { 375 this.value = value; 376 } 377 378 // @@protoc_insertion_point(enum_scope:google.cloud.compute.v1.HTTPHealthCheck.ProxyHeader) 379 } 380 381 private int bitField0_; 382 public static final int HOST_FIELD_NUMBER = 3208616; 383 384 @SuppressWarnings("serial") 385 private volatile java.lang.Object host_ = ""; 386 /** 387 * 388 * 389 * <pre> 390 * The value of the host header in the HTTP health check request. If left empty (default value), the host header is set to the destination IP address to which health check packets are sent. The destination IP address depends on the type of load balancer. For details, see: https://cloud.google.com/load-balancing/docs/health-check-concepts#hc-packet-dest 391 * </pre> 392 * 393 * <code>optional string host = 3208616;</code> 394 * 395 * @return Whether the host field is set. 396 */ 397 @java.lang.Override hasHost()398 public boolean hasHost() { 399 return ((bitField0_ & 0x00000001) != 0); 400 } 401 /** 402 * 403 * 404 * <pre> 405 * The value of the host header in the HTTP health check request. If left empty (default value), the host header is set to the destination IP address to which health check packets are sent. The destination IP address depends on the type of load balancer. For details, see: https://cloud.google.com/load-balancing/docs/health-check-concepts#hc-packet-dest 406 * </pre> 407 * 408 * <code>optional string host = 3208616;</code> 409 * 410 * @return The host. 411 */ 412 @java.lang.Override getHost()413 public java.lang.String getHost() { 414 java.lang.Object ref = host_; 415 if (ref instanceof java.lang.String) { 416 return (java.lang.String) ref; 417 } else { 418 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 419 java.lang.String s = bs.toStringUtf8(); 420 host_ = s; 421 return s; 422 } 423 } 424 /** 425 * 426 * 427 * <pre> 428 * The value of the host header in the HTTP health check request. If left empty (default value), the host header is set to the destination IP address to which health check packets are sent. The destination IP address depends on the type of load balancer. For details, see: https://cloud.google.com/load-balancing/docs/health-check-concepts#hc-packet-dest 429 * </pre> 430 * 431 * <code>optional string host = 3208616;</code> 432 * 433 * @return The bytes for host. 434 */ 435 @java.lang.Override getHostBytes()436 public com.google.protobuf.ByteString getHostBytes() { 437 java.lang.Object ref = host_; 438 if (ref instanceof java.lang.String) { 439 com.google.protobuf.ByteString b = 440 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 441 host_ = b; 442 return b; 443 } else { 444 return (com.google.protobuf.ByteString) ref; 445 } 446 } 447 448 public static final int PORT_FIELD_NUMBER = 3446913; 449 private int port_ = 0; 450 /** 451 * 452 * 453 * <pre> 454 * The TCP port number to which the health check prober sends packets. The default value is 80. Valid values are 1 through 65535. 455 * </pre> 456 * 457 * <code>optional int32 port = 3446913;</code> 458 * 459 * @return Whether the port field is set. 460 */ 461 @java.lang.Override hasPort()462 public boolean hasPort() { 463 return ((bitField0_ & 0x00000002) != 0); 464 } 465 /** 466 * 467 * 468 * <pre> 469 * The TCP port number to which the health check prober sends packets. The default value is 80. Valid values are 1 through 65535. 470 * </pre> 471 * 472 * <code>optional int32 port = 3446913;</code> 473 * 474 * @return The port. 475 */ 476 @java.lang.Override getPort()477 public int getPort() { 478 return port_; 479 } 480 481 public static final int PORT_NAME_FIELD_NUMBER = 41534345; 482 483 @SuppressWarnings("serial") 484 private volatile java.lang.Object portName_ = ""; 485 /** 486 * 487 * 488 * <pre> 489 * Not supported. 490 * </pre> 491 * 492 * <code>optional string port_name = 41534345;</code> 493 * 494 * @return Whether the portName field is set. 495 */ 496 @java.lang.Override hasPortName()497 public boolean hasPortName() { 498 return ((bitField0_ & 0x00000004) != 0); 499 } 500 /** 501 * 502 * 503 * <pre> 504 * Not supported. 505 * </pre> 506 * 507 * <code>optional string port_name = 41534345;</code> 508 * 509 * @return The portName. 510 */ 511 @java.lang.Override getPortName()512 public java.lang.String getPortName() { 513 java.lang.Object ref = portName_; 514 if (ref instanceof java.lang.String) { 515 return (java.lang.String) ref; 516 } else { 517 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 518 java.lang.String s = bs.toStringUtf8(); 519 portName_ = s; 520 return s; 521 } 522 } 523 /** 524 * 525 * 526 * <pre> 527 * Not supported. 528 * </pre> 529 * 530 * <code>optional string port_name = 41534345;</code> 531 * 532 * @return The bytes for portName. 533 */ 534 @java.lang.Override getPortNameBytes()535 public com.google.protobuf.ByteString getPortNameBytes() { 536 java.lang.Object ref = portName_; 537 if (ref instanceof java.lang.String) { 538 com.google.protobuf.ByteString b = 539 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 540 portName_ = b; 541 return b; 542 } else { 543 return (com.google.protobuf.ByteString) ref; 544 } 545 } 546 547 public static final int PORT_SPECIFICATION_FIELD_NUMBER = 51590597; 548 549 @SuppressWarnings("serial") 550 private volatile java.lang.Object portSpecification_ = ""; 551 /** 552 * 553 * 554 * <pre> 555 * Specifies how a port is selected for health checking. Can be one of the following values: USE_FIXED_PORT: Specifies a port number explicitly using the port field in the health check. Supported by backend services for pass-through load balancers and backend services for proxy load balancers. Also supported in legacy HTTP health checks for target pools. The health check supports all backends supported by the backend service provided the backend can be health checked. For example, GCE_VM_IP network endpoint groups, GCE_VM_IP_PORT network endpoint groups, and instance group backends. USE_NAMED_PORT: Not supported. USE_SERVING_PORT: Provides an indirect method of specifying the health check port by referring to the backend service. Only supported by backend services for proxy load balancers. Not supported by target pools. Not supported by backend services for pass-through load balancers. Supports all backends that can be health checked; for example, GCE_VM_IP_PORT network endpoint groups and instance group backends. For GCE_VM_IP_PORT network endpoint group backends, the health check uses the port number specified for each endpoint in the network endpoint group. For instance group backends, the health check uses the port number determined by looking up the backend service's named port in the instance group's list of named ports. 556 * Check the PortSpecification enum for the list of possible values. 557 * </pre> 558 * 559 * <code>optional string port_specification = 51590597;</code> 560 * 561 * @return Whether the portSpecification field is set. 562 */ 563 @java.lang.Override hasPortSpecification()564 public boolean hasPortSpecification() { 565 return ((bitField0_ & 0x00000008) != 0); 566 } 567 /** 568 * 569 * 570 * <pre> 571 * Specifies how a port is selected for health checking. Can be one of the following values: USE_FIXED_PORT: Specifies a port number explicitly using the port field in the health check. Supported by backend services for pass-through load balancers and backend services for proxy load balancers. Also supported in legacy HTTP health checks for target pools. The health check supports all backends supported by the backend service provided the backend can be health checked. For example, GCE_VM_IP network endpoint groups, GCE_VM_IP_PORT network endpoint groups, and instance group backends. USE_NAMED_PORT: Not supported. USE_SERVING_PORT: Provides an indirect method of specifying the health check port by referring to the backend service. Only supported by backend services for proxy load balancers. Not supported by target pools. Not supported by backend services for pass-through load balancers. Supports all backends that can be health checked; for example, GCE_VM_IP_PORT network endpoint groups and instance group backends. For GCE_VM_IP_PORT network endpoint group backends, the health check uses the port number specified for each endpoint in the network endpoint group. For instance group backends, the health check uses the port number determined by looking up the backend service's named port in the instance group's list of named ports. 572 * Check the PortSpecification enum for the list of possible values. 573 * </pre> 574 * 575 * <code>optional string port_specification = 51590597;</code> 576 * 577 * @return The portSpecification. 578 */ 579 @java.lang.Override getPortSpecification()580 public java.lang.String getPortSpecification() { 581 java.lang.Object ref = portSpecification_; 582 if (ref instanceof java.lang.String) { 583 return (java.lang.String) ref; 584 } else { 585 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 586 java.lang.String s = bs.toStringUtf8(); 587 portSpecification_ = s; 588 return s; 589 } 590 } 591 /** 592 * 593 * 594 * <pre> 595 * Specifies how a port is selected for health checking. Can be one of the following values: USE_FIXED_PORT: Specifies a port number explicitly using the port field in the health check. Supported by backend services for pass-through load balancers and backend services for proxy load balancers. Also supported in legacy HTTP health checks for target pools. The health check supports all backends supported by the backend service provided the backend can be health checked. For example, GCE_VM_IP network endpoint groups, GCE_VM_IP_PORT network endpoint groups, and instance group backends. USE_NAMED_PORT: Not supported. USE_SERVING_PORT: Provides an indirect method of specifying the health check port by referring to the backend service. Only supported by backend services for proxy load balancers. Not supported by target pools. Not supported by backend services for pass-through load balancers. Supports all backends that can be health checked; for example, GCE_VM_IP_PORT network endpoint groups and instance group backends. For GCE_VM_IP_PORT network endpoint group backends, the health check uses the port number specified for each endpoint in the network endpoint group. For instance group backends, the health check uses the port number determined by looking up the backend service's named port in the instance group's list of named ports. 596 * Check the PortSpecification enum for the list of possible values. 597 * </pre> 598 * 599 * <code>optional string port_specification = 51590597;</code> 600 * 601 * @return The bytes for portSpecification. 602 */ 603 @java.lang.Override getPortSpecificationBytes()604 public com.google.protobuf.ByteString getPortSpecificationBytes() { 605 java.lang.Object ref = portSpecification_; 606 if (ref instanceof java.lang.String) { 607 com.google.protobuf.ByteString b = 608 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 609 portSpecification_ = b; 610 return b; 611 } else { 612 return (com.google.protobuf.ByteString) ref; 613 } 614 } 615 616 public static final int PROXY_HEADER_FIELD_NUMBER = 160374142; 617 618 @SuppressWarnings("serial") 619 private volatile java.lang.Object proxyHeader_ = ""; 620 /** 621 * 622 * 623 * <pre> 624 * Specifies the type of proxy header to append before sending data to the backend, either NONE or PROXY_V1. The default is NONE. 625 * Check the ProxyHeader enum for the list of possible values. 626 * </pre> 627 * 628 * <code>optional string proxy_header = 160374142;</code> 629 * 630 * @return Whether the proxyHeader field is set. 631 */ 632 @java.lang.Override hasProxyHeader()633 public boolean hasProxyHeader() { 634 return ((bitField0_ & 0x00000010) != 0); 635 } 636 /** 637 * 638 * 639 * <pre> 640 * Specifies the type of proxy header to append before sending data to the backend, either NONE or PROXY_V1. The default is NONE. 641 * Check the ProxyHeader enum for the list of possible values. 642 * </pre> 643 * 644 * <code>optional string proxy_header = 160374142;</code> 645 * 646 * @return The proxyHeader. 647 */ 648 @java.lang.Override getProxyHeader()649 public java.lang.String getProxyHeader() { 650 java.lang.Object ref = proxyHeader_; 651 if (ref instanceof java.lang.String) { 652 return (java.lang.String) ref; 653 } else { 654 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 655 java.lang.String s = bs.toStringUtf8(); 656 proxyHeader_ = s; 657 return s; 658 } 659 } 660 /** 661 * 662 * 663 * <pre> 664 * Specifies the type of proxy header to append before sending data to the backend, either NONE or PROXY_V1. The default is NONE. 665 * Check the ProxyHeader enum for the list of possible values. 666 * </pre> 667 * 668 * <code>optional string proxy_header = 160374142;</code> 669 * 670 * @return The bytes for proxyHeader. 671 */ 672 @java.lang.Override getProxyHeaderBytes()673 public com.google.protobuf.ByteString getProxyHeaderBytes() { 674 java.lang.Object ref = proxyHeader_; 675 if (ref instanceof java.lang.String) { 676 com.google.protobuf.ByteString b = 677 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 678 proxyHeader_ = b; 679 return b; 680 } else { 681 return (com.google.protobuf.ByteString) ref; 682 } 683 } 684 685 public static final int REQUEST_PATH_FIELD_NUMBER = 229403605; 686 687 @SuppressWarnings("serial") 688 private volatile java.lang.Object requestPath_ = ""; 689 /** 690 * 691 * 692 * <pre> 693 * The request path of the HTTP health check request. The default value is /. 694 * </pre> 695 * 696 * <code>optional string request_path = 229403605;</code> 697 * 698 * @return Whether the requestPath field is set. 699 */ 700 @java.lang.Override hasRequestPath()701 public boolean hasRequestPath() { 702 return ((bitField0_ & 0x00000020) != 0); 703 } 704 /** 705 * 706 * 707 * <pre> 708 * The request path of the HTTP health check request. The default value is /. 709 * </pre> 710 * 711 * <code>optional string request_path = 229403605;</code> 712 * 713 * @return The requestPath. 714 */ 715 @java.lang.Override getRequestPath()716 public java.lang.String getRequestPath() { 717 java.lang.Object ref = requestPath_; 718 if (ref instanceof java.lang.String) { 719 return (java.lang.String) ref; 720 } else { 721 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 722 java.lang.String s = bs.toStringUtf8(); 723 requestPath_ = s; 724 return s; 725 } 726 } 727 /** 728 * 729 * 730 * <pre> 731 * The request path of the HTTP health check request. The default value is /. 732 * </pre> 733 * 734 * <code>optional string request_path = 229403605;</code> 735 * 736 * @return The bytes for requestPath. 737 */ 738 @java.lang.Override getRequestPathBytes()739 public com.google.protobuf.ByteString getRequestPathBytes() { 740 java.lang.Object ref = requestPath_; 741 if (ref instanceof java.lang.String) { 742 com.google.protobuf.ByteString b = 743 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 744 requestPath_ = b; 745 return b; 746 } else { 747 return (com.google.protobuf.ByteString) ref; 748 } 749 } 750 751 public static final int RESPONSE_FIELD_NUMBER = 196547649; 752 753 @SuppressWarnings("serial") 754 private volatile java.lang.Object response_ = ""; 755 /** 756 * 757 * 758 * <pre> 759 * Creates a content-based HTTP health check. In addition to the required HTTP 200 (OK) status code, you can configure the health check to pass only when the backend sends this specific ASCII response string within the first 1024 bytes of the HTTP response body. For details, see: https://cloud.google.com/load-balancing/docs/health-check-concepts#criteria-protocol-http 760 * </pre> 761 * 762 * <code>optional string response = 196547649;</code> 763 * 764 * @return Whether the response field is set. 765 */ 766 @java.lang.Override hasResponse()767 public boolean hasResponse() { 768 return ((bitField0_ & 0x00000040) != 0); 769 } 770 /** 771 * 772 * 773 * <pre> 774 * Creates a content-based HTTP health check. In addition to the required HTTP 200 (OK) status code, you can configure the health check to pass only when the backend sends this specific ASCII response string within the first 1024 bytes of the HTTP response body. For details, see: https://cloud.google.com/load-balancing/docs/health-check-concepts#criteria-protocol-http 775 * </pre> 776 * 777 * <code>optional string response = 196547649;</code> 778 * 779 * @return The response. 780 */ 781 @java.lang.Override getResponse()782 public java.lang.String getResponse() { 783 java.lang.Object ref = response_; 784 if (ref instanceof java.lang.String) { 785 return (java.lang.String) ref; 786 } else { 787 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 788 java.lang.String s = bs.toStringUtf8(); 789 response_ = s; 790 return s; 791 } 792 } 793 /** 794 * 795 * 796 * <pre> 797 * Creates a content-based HTTP health check. In addition to the required HTTP 200 (OK) status code, you can configure the health check to pass only when the backend sends this specific ASCII response string within the first 1024 bytes of the HTTP response body. For details, see: https://cloud.google.com/load-balancing/docs/health-check-concepts#criteria-protocol-http 798 * </pre> 799 * 800 * <code>optional string response = 196547649;</code> 801 * 802 * @return The bytes for response. 803 */ 804 @java.lang.Override getResponseBytes()805 public com.google.protobuf.ByteString getResponseBytes() { 806 java.lang.Object ref = response_; 807 if (ref instanceof java.lang.String) { 808 com.google.protobuf.ByteString b = 809 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 810 response_ = b; 811 return b; 812 } else { 813 return (com.google.protobuf.ByteString) ref; 814 } 815 } 816 817 private byte memoizedIsInitialized = -1; 818 819 @java.lang.Override isInitialized()820 public final boolean isInitialized() { 821 byte isInitialized = memoizedIsInitialized; 822 if (isInitialized == 1) return true; 823 if (isInitialized == 0) return false; 824 825 memoizedIsInitialized = 1; 826 return true; 827 } 828 829 @java.lang.Override writeTo(com.google.protobuf.CodedOutputStream output)830 public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { 831 if (((bitField0_ & 0x00000001) != 0)) { 832 com.google.protobuf.GeneratedMessageV3.writeString(output, 3208616, host_); 833 } 834 if (((bitField0_ & 0x00000002) != 0)) { 835 output.writeInt32(3446913, port_); 836 } 837 if (((bitField0_ & 0x00000004) != 0)) { 838 com.google.protobuf.GeneratedMessageV3.writeString(output, 41534345, portName_); 839 } 840 if (((bitField0_ & 0x00000008) != 0)) { 841 com.google.protobuf.GeneratedMessageV3.writeString(output, 51590597, portSpecification_); 842 } 843 if (((bitField0_ & 0x00000010) != 0)) { 844 com.google.protobuf.GeneratedMessageV3.writeString(output, 160374142, proxyHeader_); 845 } 846 if (((bitField0_ & 0x00000040) != 0)) { 847 com.google.protobuf.GeneratedMessageV3.writeString(output, 196547649, response_); 848 } 849 if (((bitField0_ & 0x00000020) != 0)) { 850 com.google.protobuf.GeneratedMessageV3.writeString(output, 229403605, requestPath_); 851 } 852 getUnknownFields().writeTo(output); 853 } 854 855 @java.lang.Override getSerializedSize()856 public int getSerializedSize() { 857 int size = memoizedSize; 858 if (size != -1) return size; 859 860 size = 0; 861 if (((bitField0_ & 0x00000001) != 0)) { 862 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3208616, host_); 863 } 864 if (((bitField0_ & 0x00000002) != 0)) { 865 size += com.google.protobuf.CodedOutputStream.computeInt32Size(3446913, port_); 866 } 867 if (((bitField0_ & 0x00000004) != 0)) { 868 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(41534345, portName_); 869 } 870 if (((bitField0_ & 0x00000008) != 0)) { 871 size += 872 com.google.protobuf.GeneratedMessageV3.computeStringSize(51590597, portSpecification_); 873 } 874 if (((bitField0_ & 0x00000010) != 0)) { 875 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(160374142, proxyHeader_); 876 } 877 if (((bitField0_ & 0x00000040) != 0)) { 878 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(196547649, response_); 879 } 880 if (((bitField0_ & 0x00000020) != 0)) { 881 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(229403605, requestPath_); 882 } 883 size += getUnknownFields().getSerializedSize(); 884 memoizedSize = size; 885 return size; 886 } 887 888 @java.lang.Override equals(final java.lang.Object obj)889 public boolean equals(final java.lang.Object obj) { 890 if (obj == this) { 891 return true; 892 } 893 if (!(obj instanceof com.google.cloud.compute.v1.HTTPHealthCheck)) { 894 return super.equals(obj); 895 } 896 com.google.cloud.compute.v1.HTTPHealthCheck other = 897 (com.google.cloud.compute.v1.HTTPHealthCheck) obj; 898 899 if (hasHost() != other.hasHost()) return false; 900 if (hasHost()) { 901 if (!getHost().equals(other.getHost())) return false; 902 } 903 if (hasPort() != other.hasPort()) return false; 904 if (hasPort()) { 905 if (getPort() != other.getPort()) return false; 906 } 907 if (hasPortName() != other.hasPortName()) return false; 908 if (hasPortName()) { 909 if (!getPortName().equals(other.getPortName())) return false; 910 } 911 if (hasPortSpecification() != other.hasPortSpecification()) return false; 912 if (hasPortSpecification()) { 913 if (!getPortSpecification().equals(other.getPortSpecification())) return false; 914 } 915 if (hasProxyHeader() != other.hasProxyHeader()) return false; 916 if (hasProxyHeader()) { 917 if (!getProxyHeader().equals(other.getProxyHeader())) return false; 918 } 919 if (hasRequestPath() != other.hasRequestPath()) return false; 920 if (hasRequestPath()) { 921 if (!getRequestPath().equals(other.getRequestPath())) return false; 922 } 923 if (hasResponse() != other.hasResponse()) return false; 924 if (hasResponse()) { 925 if (!getResponse().equals(other.getResponse())) return false; 926 } 927 if (!getUnknownFields().equals(other.getUnknownFields())) return false; 928 return true; 929 } 930 931 @java.lang.Override hashCode()932 public int hashCode() { 933 if (memoizedHashCode != 0) { 934 return memoizedHashCode; 935 } 936 int hash = 41; 937 hash = (19 * hash) + getDescriptor().hashCode(); 938 if (hasHost()) { 939 hash = (37 * hash) + HOST_FIELD_NUMBER; 940 hash = (53 * hash) + getHost().hashCode(); 941 } 942 if (hasPort()) { 943 hash = (37 * hash) + PORT_FIELD_NUMBER; 944 hash = (53 * hash) + getPort(); 945 } 946 if (hasPortName()) { 947 hash = (37 * hash) + PORT_NAME_FIELD_NUMBER; 948 hash = (53 * hash) + getPortName().hashCode(); 949 } 950 if (hasPortSpecification()) { 951 hash = (37 * hash) + PORT_SPECIFICATION_FIELD_NUMBER; 952 hash = (53 * hash) + getPortSpecification().hashCode(); 953 } 954 if (hasProxyHeader()) { 955 hash = (37 * hash) + PROXY_HEADER_FIELD_NUMBER; 956 hash = (53 * hash) + getProxyHeader().hashCode(); 957 } 958 if (hasRequestPath()) { 959 hash = (37 * hash) + REQUEST_PATH_FIELD_NUMBER; 960 hash = (53 * hash) + getRequestPath().hashCode(); 961 } 962 if (hasResponse()) { 963 hash = (37 * hash) + RESPONSE_FIELD_NUMBER; 964 hash = (53 * hash) + getResponse().hashCode(); 965 } 966 hash = (29 * hash) + getUnknownFields().hashCode(); 967 memoizedHashCode = hash; 968 return hash; 969 } 970 parseFrom(java.nio.ByteBuffer data)971 public static com.google.cloud.compute.v1.HTTPHealthCheck parseFrom(java.nio.ByteBuffer data) 972 throws com.google.protobuf.InvalidProtocolBufferException { 973 return PARSER.parseFrom(data); 974 } 975 parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)976 public static com.google.cloud.compute.v1.HTTPHealthCheck parseFrom( 977 java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) 978 throws com.google.protobuf.InvalidProtocolBufferException { 979 return PARSER.parseFrom(data, extensionRegistry); 980 } 981 parseFrom( com.google.protobuf.ByteString data)982 public static com.google.cloud.compute.v1.HTTPHealthCheck parseFrom( 983 com.google.protobuf.ByteString data) 984 throws com.google.protobuf.InvalidProtocolBufferException { 985 return PARSER.parseFrom(data); 986 } 987 parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)988 public static com.google.cloud.compute.v1.HTTPHealthCheck parseFrom( 989 com.google.protobuf.ByteString data, 990 com.google.protobuf.ExtensionRegistryLite extensionRegistry) 991 throws com.google.protobuf.InvalidProtocolBufferException { 992 return PARSER.parseFrom(data, extensionRegistry); 993 } 994 parseFrom(byte[] data)995 public static com.google.cloud.compute.v1.HTTPHealthCheck parseFrom(byte[] data) 996 throws com.google.protobuf.InvalidProtocolBufferException { 997 return PARSER.parseFrom(data); 998 } 999 parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)1000 public static com.google.cloud.compute.v1.HTTPHealthCheck parseFrom( 1001 byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) 1002 throws com.google.protobuf.InvalidProtocolBufferException { 1003 return PARSER.parseFrom(data, extensionRegistry); 1004 } 1005 parseFrom(java.io.InputStream input)1006 public static com.google.cloud.compute.v1.HTTPHealthCheck parseFrom(java.io.InputStream input) 1007 throws java.io.IOException { 1008 return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); 1009 } 1010 parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)1011 public static com.google.cloud.compute.v1.HTTPHealthCheck parseFrom( 1012 java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) 1013 throws java.io.IOException { 1014 return com.google.protobuf.GeneratedMessageV3.parseWithIOException( 1015 PARSER, input, extensionRegistry); 1016 } 1017 parseDelimitedFrom( java.io.InputStream input)1018 public static com.google.cloud.compute.v1.HTTPHealthCheck parseDelimitedFrom( 1019 java.io.InputStream input) throws java.io.IOException { 1020 return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); 1021 } 1022 parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)1023 public static com.google.cloud.compute.v1.HTTPHealthCheck parseDelimitedFrom( 1024 java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) 1025 throws java.io.IOException { 1026 return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( 1027 PARSER, input, extensionRegistry); 1028 } 1029 parseFrom( com.google.protobuf.CodedInputStream input)1030 public static com.google.cloud.compute.v1.HTTPHealthCheck parseFrom( 1031 com.google.protobuf.CodedInputStream input) throws java.io.IOException { 1032 return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); 1033 } 1034 parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)1035 public static com.google.cloud.compute.v1.HTTPHealthCheck parseFrom( 1036 com.google.protobuf.CodedInputStream input, 1037 com.google.protobuf.ExtensionRegistryLite extensionRegistry) 1038 throws java.io.IOException { 1039 return com.google.protobuf.GeneratedMessageV3.parseWithIOException( 1040 PARSER, input, extensionRegistry); 1041 } 1042 1043 @java.lang.Override newBuilderForType()1044 public Builder newBuilderForType() { 1045 return newBuilder(); 1046 } 1047 newBuilder()1048 public static Builder newBuilder() { 1049 return DEFAULT_INSTANCE.toBuilder(); 1050 } 1051 newBuilder(com.google.cloud.compute.v1.HTTPHealthCheck prototype)1052 public static Builder newBuilder(com.google.cloud.compute.v1.HTTPHealthCheck prototype) { 1053 return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); 1054 } 1055 1056 @java.lang.Override toBuilder()1057 public Builder toBuilder() { 1058 return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); 1059 } 1060 1061 @java.lang.Override newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)1062 protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { 1063 Builder builder = new Builder(parent); 1064 return builder; 1065 } 1066 /** 1067 * 1068 * 1069 * <pre> 1070 * </pre> 1071 * 1072 * Protobuf type {@code google.cloud.compute.v1.HTTPHealthCheck} 1073 */ 1074 public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder> 1075 implements 1076 // @@protoc_insertion_point(builder_implements:google.cloud.compute.v1.HTTPHealthCheck) 1077 com.google.cloud.compute.v1.HTTPHealthCheckOrBuilder { getDescriptor()1078 public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { 1079 return com.google.cloud.compute.v1.Compute 1080 .internal_static_google_cloud_compute_v1_HTTPHealthCheck_descriptor; 1081 } 1082 1083 @java.lang.Override 1084 protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()1085 internalGetFieldAccessorTable() { 1086 return com.google.cloud.compute.v1.Compute 1087 .internal_static_google_cloud_compute_v1_HTTPHealthCheck_fieldAccessorTable 1088 .ensureFieldAccessorsInitialized( 1089 com.google.cloud.compute.v1.HTTPHealthCheck.class, 1090 com.google.cloud.compute.v1.HTTPHealthCheck.Builder.class); 1091 } 1092 1093 // Construct using com.google.cloud.compute.v1.HTTPHealthCheck.newBuilder() Builder()1094 private Builder() {} 1095 Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)1096 private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { 1097 super(parent); 1098 } 1099 1100 @java.lang.Override clear()1101 public Builder clear() { 1102 super.clear(); 1103 bitField0_ = 0; 1104 host_ = ""; 1105 port_ = 0; 1106 portName_ = ""; 1107 portSpecification_ = ""; 1108 proxyHeader_ = ""; 1109 requestPath_ = ""; 1110 response_ = ""; 1111 return this; 1112 } 1113 1114 @java.lang.Override getDescriptorForType()1115 public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { 1116 return com.google.cloud.compute.v1.Compute 1117 .internal_static_google_cloud_compute_v1_HTTPHealthCheck_descriptor; 1118 } 1119 1120 @java.lang.Override getDefaultInstanceForType()1121 public com.google.cloud.compute.v1.HTTPHealthCheck getDefaultInstanceForType() { 1122 return com.google.cloud.compute.v1.HTTPHealthCheck.getDefaultInstance(); 1123 } 1124 1125 @java.lang.Override build()1126 public com.google.cloud.compute.v1.HTTPHealthCheck build() { 1127 com.google.cloud.compute.v1.HTTPHealthCheck result = buildPartial(); 1128 if (!result.isInitialized()) { 1129 throw newUninitializedMessageException(result); 1130 } 1131 return result; 1132 } 1133 1134 @java.lang.Override buildPartial()1135 public com.google.cloud.compute.v1.HTTPHealthCheck buildPartial() { 1136 com.google.cloud.compute.v1.HTTPHealthCheck result = 1137 new com.google.cloud.compute.v1.HTTPHealthCheck(this); 1138 if (bitField0_ != 0) { 1139 buildPartial0(result); 1140 } 1141 onBuilt(); 1142 return result; 1143 } 1144 buildPartial0(com.google.cloud.compute.v1.HTTPHealthCheck result)1145 private void buildPartial0(com.google.cloud.compute.v1.HTTPHealthCheck result) { 1146 int from_bitField0_ = bitField0_; 1147 int to_bitField0_ = 0; 1148 if (((from_bitField0_ & 0x00000001) != 0)) { 1149 result.host_ = host_; 1150 to_bitField0_ |= 0x00000001; 1151 } 1152 if (((from_bitField0_ & 0x00000002) != 0)) { 1153 result.port_ = port_; 1154 to_bitField0_ |= 0x00000002; 1155 } 1156 if (((from_bitField0_ & 0x00000004) != 0)) { 1157 result.portName_ = portName_; 1158 to_bitField0_ |= 0x00000004; 1159 } 1160 if (((from_bitField0_ & 0x00000008) != 0)) { 1161 result.portSpecification_ = portSpecification_; 1162 to_bitField0_ |= 0x00000008; 1163 } 1164 if (((from_bitField0_ & 0x00000010) != 0)) { 1165 result.proxyHeader_ = proxyHeader_; 1166 to_bitField0_ |= 0x00000010; 1167 } 1168 if (((from_bitField0_ & 0x00000020) != 0)) { 1169 result.requestPath_ = requestPath_; 1170 to_bitField0_ |= 0x00000020; 1171 } 1172 if (((from_bitField0_ & 0x00000040) != 0)) { 1173 result.response_ = response_; 1174 to_bitField0_ |= 0x00000040; 1175 } 1176 result.bitField0_ |= to_bitField0_; 1177 } 1178 1179 @java.lang.Override clone()1180 public Builder clone() { 1181 return super.clone(); 1182 } 1183 1184 @java.lang.Override setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)1185 public Builder setField( 1186 com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { 1187 return super.setField(field, value); 1188 } 1189 1190 @java.lang.Override clearField(com.google.protobuf.Descriptors.FieldDescriptor field)1191 public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { 1192 return super.clearField(field); 1193 } 1194 1195 @java.lang.Override clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)1196 public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { 1197 return super.clearOneof(oneof); 1198 } 1199 1200 @java.lang.Override setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value)1201 public Builder setRepeatedField( 1202 com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { 1203 return super.setRepeatedField(field, index, value); 1204 } 1205 1206 @java.lang.Override addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)1207 public Builder addRepeatedField( 1208 com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { 1209 return super.addRepeatedField(field, value); 1210 } 1211 1212 @java.lang.Override mergeFrom(com.google.protobuf.Message other)1213 public Builder mergeFrom(com.google.protobuf.Message other) { 1214 if (other instanceof com.google.cloud.compute.v1.HTTPHealthCheck) { 1215 return mergeFrom((com.google.cloud.compute.v1.HTTPHealthCheck) other); 1216 } else { 1217 super.mergeFrom(other); 1218 return this; 1219 } 1220 } 1221 mergeFrom(com.google.cloud.compute.v1.HTTPHealthCheck other)1222 public Builder mergeFrom(com.google.cloud.compute.v1.HTTPHealthCheck other) { 1223 if (other == com.google.cloud.compute.v1.HTTPHealthCheck.getDefaultInstance()) return this; 1224 if (other.hasHost()) { 1225 host_ = other.host_; 1226 bitField0_ |= 0x00000001; 1227 onChanged(); 1228 } 1229 if (other.hasPort()) { 1230 setPort(other.getPort()); 1231 } 1232 if (other.hasPortName()) { 1233 portName_ = other.portName_; 1234 bitField0_ |= 0x00000004; 1235 onChanged(); 1236 } 1237 if (other.hasPortSpecification()) { 1238 portSpecification_ = other.portSpecification_; 1239 bitField0_ |= 0x00000008; 1240 onChanged(); 1241 } 1242 if (other.hasProxyHeader()) { 1243 proxyHeader_ = other.proxyHeader_; 1244 bitField0_ |= 0x00000010; 1245 onChanged(); 1246 } 1247 if (other.hasRequestPath()) { 1248 requestPath_ = other.requestPath_; 1249 bitField0_ |= 0x00000020; 1250 onChanged(); 1251 } 1252 if (other.hasResponse()) { 1253 response_ = other.response_; 1254 bitField0_ |= 0x00000040; 1255 onChanged(); 1256 } 1257 this.mergeUnknownFields(other.getUnknownFields()); 1258 onChanged(); 1259 return this; 1260 } 1261 1262 @java.lang.Override isInitialized()1263 public final boolean isInitialized() { 1264 return true; 1265 } 1266 1267 @java.lang.Override mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)1268 public Builder mergeFrom( 1269 com.google.protobuf.CodedInputStream input, 1270 com.google.protobuf.ExtensionRegistryLite extensionRegistry) 1271 throws java.io.IOException { 1272 if (extensionRegistry == null) { 1273 throw new java.lang.NullPointerException(); 1274 } 1275 try { 1276 boolean done = false; 1277 while (!done) { 1278 int tag = input.readTag(); 1279 switch (tag) { 1280 case 0: 1281 done = true; 1282 break; 1283 case 25668930: 1284 { 1285 host_ = input.readStringRequireUtf8(); 1286 bitField0_ |= 0x00000001; 1287 break; 1288 } // case 25668930 1289 case 27575304: 1290 { 1291 port_ = input.readInt32(); 1292 bitField0_ |= 0x00000002; 1293 break; 1294 } // case 27575304 1295 case 332274762: 1296 { 1297 portName_ = input.readStringRequireUtf8(); 1298 bitField0_ |= 0x00000004; 1299 break; 1300 } // case 332274762 1301 case 412724778: 1302 { 1303 portSpecification_ = input.readStringRequireUtf8(); 1304 bitField0_ |= 0x00000008; 1305 break; 1306 } // case 412724778 1307 case 1282993138: 1308 { 1309 proxyHeader_ = input.readStringRequireUtf8(); 1310 bitField0_ |= 0x00000010; 1311 break; 1312 } // case 1282993138 1313 case 1572381194: 1314 { 1315 response_ = input.readStringRequireUtf8(); 1316 bitField0_ |= 0x00000040; 1317 break; 1318 } // case 1572381194 1319 case 1835228842: 1320 { 1321 requestPath_ = input.readStringRequireUtf8(); 1322 bitField0_ |= 0x00000020; 1323 break; 1324 } // case 1835228842 1325 default: 1326 { 1327 if (!super.parseUnknownField(input, extensionRegistry, tag)) { 1328 done = true; // was an endgroup tag 1329 } 1330 break; 1331 } // default: 1332 } // switch (tag) 1333 } // while (!done) 1334 } catch (com.google.protobuf.InvalidProtocolBufferException e) { 1335 throw e.unwrapIOException(); 1336 } finally { 1337 onChanged(); 1338 } // finally 1339 return this; 1340 } 1341 1342 private int bitField0_; 1343 1344 private java.lang.Object host_ = ""; 1345 /** 1346 * 1347 * 1348 * <pre> 1349 * The value of the host header in the HTTP health check request. If left empty (default value), the host header is set to the destination IP address to which health check packets are sent. The destination IP address depends on the type of load balancer. For details, see: https://cloud.google.com/load-balancing/docs/health-check-concepts#hc-packet-dest 1350 * </pre> 1351 * 1352 * <code>optional string host = 3208616;</code> 1353 * 1354 * @return Whether the host field is set. 1355 */ hasHost()1356 public boolean hasHost() { 1357 return ((bitField0_ & 0x00000001) != 0); 1358 } 1359 /** 1360 * 1361 * 1362 * <pre> 1363 * The value of the host header in the HTTP health check request. If left empty (default value), the host header is set to the destination IP address to which health check packets are sent. The destination IP address depends on the type of load balancer. For details, see: https://cloud.google.com/load-balancing/docs/health-check-concepts#hc-packet-dest 1364 * </pre> 1365 * 1366 * <code>optional string host = 3208616;</code> 1367 * 1368 * @return The host. 1369 */ getHost()1370 public java.lang.String getHost() { 1371 java.lang.Object ref = host_; 1372 if (!(ref instanceof java.lang.String)) { 1373 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 1374 java.lang.String s = bs.toStringUtf8(); 1375 host_ = s; 1376 return s; 1377 } else { 1378 return (java.lang.String) ref; 1379 } 1380 } 1381 /** 1382 * 1383 * 1384 * <pre> 1385 * The value of the host header in the HTTP health check request. If left empty (default value), the host header is set to the destination IP address to which health check packets are sent. The destination IP address depends on the type of load balancer. For details, see: https://cloud.google.com/load-balancing/docs/health-check-concepts#hc-packet-dest 1386 * </pre> 1387 * 1388 * <code>optional string host = 3208616;</code> 1389 * 1390 * @return The bytes for host. 1391 */ getHostBytes()1392 public com.google.protobuf.ByteString getHostBytes() { 1393 java.lang.Object ref = host_; 1394 if (ref instanceof String) { 1395 com.google.protobuf.ByteString b = 1396 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 1397 host_ = b; 1398 return b; 1399 } else { 1400 return (com.google.protobuf.ByteString) ref; 1401 } 1402 } 1403 /** 1404 * 1405 * 1406 * <pre> 1407 * The value of the host header in the HTTP health check request. If left empty (default value), the host header is set to the destination IP address to which health check packets are sent. The destination IP address depends on the type of load balancer. For details, see: https://cloud.google.com/load-balancing/docs/health-check-concepts#hc-packet-dest 1408 * </pre> 1409 * 1410 * <code>optional string host = 3208616;</code> 1411 * 1412 * @param value The host to set. 1413 * @return This builder for chaining. 1414 */ setHost(java.lang.String value)1415 public Builder setHost(java.lang.String value) { 1416 if (value == null) { 1417 throw new NullPointerException(); 1418 } 1419 host_ = value; 1420 bitField0_ |= 0x00000001; 1421 onChanged(); 1422 return this; 1423 } 1424 /** 1425 * 1426 * 1427 * <pre> 1428 * The value of the host header in the HTTP health check request. If left empty (default value), the host header is set to the destination IP address to which health check packets are sent. The destination IP address depends on the type of load balancer. For details, see: https://cloud.google.com/load-balancing/docs/health-check-concepts#hc-packet-dest 1429 * </pre> 1430 * 1431 * <code>optional string host = 3208616;</code> 1432 * 1433 * @return This builder for chaining. 1434 */ clearHost()1435 public Builder clearHost() { 1436 host_ = getDefaultInstance().getHost(); 1437 bitField0_ = (bitField0_ & ~0x00000001); 1438 onChanged(); 1439 return this; 1440 } 1441 /** 1442 * 1443 * 1444 * <pre> 1445 * The value of the host header in the HTTP health check request. If left empty (default value), the host header is set to the destination IP address to which health check packets are sent. The destination IP address depends on the type of load balancer. For details, see: https://cloud.google.com/load-balancing/docs/health-check-concepts#hc-packet-dest 1446 * </pre> 1447 * 1448 * <code>optional string host = 3208616;</code> 1449 * 1450 * @param value The bytes for host to set. 1451 * @return This builder for chaining. 1452 */ setHostBytes(com.google.protobuf.ByteString value)1453 public Builder setHostBytes(com.google.protobuf.ByteString value) { 1454 if (value == null) { 1455 throw new NullPointerException(); 1456 } 1457 checkByteStringIsUtf8(value); 1458 host_ = value; 1459 bitField0_ |= 0x00000001; 1460 onChanged(); 1461 return this; 1462 } 1463 1464 private int port_; 1465 /** 1466 * 1467 * 1468 * <pre> 1469 * The TCP port number to which the health check prober sends packets. The default value is 80. Valid values are 1 through 65535. 1470 * </pre> 1471 * 1472 * <code>optional int32 port = 3446913;</code> 1473 * 1474 * @return Whether the port field is set. 1475 */ 1476 @java.lang.Override hasPort()1477 public boolean hasPort() { 1478 return ((bitField0_ & 0x00000002) != 0); 1479 } 1480 /** 1481 * 1482 * 1483 * <pre> 1484 * The TCP port number to which the health check prober sends packets. The default value is 80. Valid values are 1 through 65535. 1485 * </pre> 1486 * 1487 * <code>optional int32 port = 3446913;</code> 1488 * 1489 * @return The port. 1490 */ 1491 @java.lang.Override getPort()1492 public int getPort() { 1493 return port_; 1494 } 1495 /** 1496 * 1497 * 1498 * <pre> 1499 * The TCP port number to which the health check prober sends packets. The default value is 80. Valid values are 1 through 65535. 1500 * </pre> 1501 * 1502 * <code>optional int32 port = 3446913;</code> 1503 * 1504 * @param value The port to set. 1505 * @return This builder for chaining. 1506 */ setPort(int value)1507 public Builder setPort(int value) { 1508 1509 port_ = value; 1510 bitField0_ |= 0x00000002; 1511 onChanged(); 1512 return this; 1513 } 1514 /** 1515 * 1516 * 1517 * <pre> 1518 * The TCP port number to which the health check prober sends packets. The default value is 80. Valid values are 1 through 65535. 1519 * </pre> 1520 * 1521 * <code>optional int32 port = 3446913;</code> 1522 * 1523 * @return This builder for chaining. 1524 */ clearPort()1525 public Builder clearPort() { 1526 bitField0_ = (bitField0_ & ~0x00000002); 1527 port_ = 0; 1528 onChanged(); 1529 return this; 1530 } 1531 1532 private java.lang.Object portName_ = ""; 1533 /** 1534 * 1535 * 1536 * <pre> 1537 * Not supported. 1538 * </pre> 1539 * 1540 * <code>optional string port_name = 41534345;</code> 1541 * 1542 * @return Whether the portName field is set. 1543 */ hasPortName()1544 public boolean hasPortName() { 1545 return ((bitField0_ & 0x00000004) != 0); 1546 } 1547 /** 1548 * 1549 * 1550 * <pre> 1551 * Not supported. 1552 * </pre> 1553 * 1554 * <code>optional string port_name = 41534345;</code> 1555 * 1556 * @return The portName. 1557 */ getPortName()1558 public java.lang.String getPortName() { 1559 java.lang.Object ref = portName_; 1560 if (!(ref instanceof java.lang.String)) { 1561 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 1562 java.lang.String s = bs.toStringUtf8(); 1563 portName_ = s; 1564 return s; 1565 } else { 1566 return (java.lang.String) ref; 1567 } 1568 } 1569 /** 1570 * 1571 * 1572 * <pre> 1573 * Not supported. 1574 * </pre> 1575 * 1576 * <code>optional string port_name = 41534345;</code> 1577 * 1578 * @return The bytes for portName. 1579 */ getPortNameBytes()1580 public com.google.protobuf.ByteString getPortNameBytes() { 1581 java.lang.Object ref = portName_; 1582 if (ref instanceof String) { 1583 com.google.protobuf.ByteString b = 1584 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 1585 portName_ = b; 1586 return b; 1587 } else { 1588 return (com.google.protobuf.ByteString) ref; 1589 } 1590 } 1591 /** 1592 * 1593 * 1594 * <pre> 1595 * Not supported. 1596 * </pre> 1597 * 1598 * <code>optional string port_name = 41534345;</code> 1599 * 1600 * @param value The portName to set. 1601 * @return This builder for chaining. 1602 */ setPortName(java.lang.String value)1603 public Builder setPortName(java.lang.String value) { 1604 if (value == null) { 1605 throw new NullPointerException(); 1606 } 1607 portName_ = value; 1608 bitField0_ |= 0x00000004; 1609 onChanged(); 1610 return this; 1611 } 1612 /** 1613 * 1614 * 1615 * <pre> 1616 * Not supported. 1617 * </pre> 1618 * 1619 * <code>optional string port_name = 41534345;</code> 1620 * 1621 * @return This builder for chaining. 1622 */ clearPortName()1623 public Builder clearPortName() { 1624 portName_ = getDefaultInstance().getPortName(); 1625 bitField0_ = (bitField0_ & ~0x00000004); 1626 onChanged(); 1627 return this; 1628 } 1629 /** 1630 * 1631 * 1632 * <pre> 1633 * Not supported. 1634 * </pre> 1635 * 1636 * <code>optional string port_name = 41534345;</code> 1637 * 1638 * @param value The bytes for portName to set. 1639 * @return This builder for chaining. 1640 */ setPortNameBytes(com.google.protobuf.ByteString value)1641 public Builder setPortNameBytes(com.google.protobuf.ByteString value) { 1642 if (value == null) { 1643 throw new NullPointerException(); 1644 } 1645 checkByteStringIsUtf8(value); 1646 portName_ = value; 1647 bitField0_ |= 0x00000004; 1648 onChanged(); 1649 return this; 1650 } 1651 1652 private java.lang.Object portSpecification_ = ""; 1653 /** 1654 * 1655 * 1656 * <pre> 1657 * Specifies how a port is selected for health checking. Can be one of the following values: USE_FIXED_PORT: Specifies a port number explicitly using the port field in the health check. Supported by backend services for pass-through load balancers and backend services for proxy load balancers. Also supported in legacy HTTP health checks for target pools. The health check supports all backends supported by the backend service provided the backend can be health checked. For example, GCE_VM_IP network endpoint groups, GCE_VM_IP_PORT network endpoint groups, and instance group backends. USE_NAMED_PORT: Not supported. USE_SERVING_PORT: Provides an indirect method of specifying the health check port by referring to the backend service. Only supported by backend services for proxy load balancers. Not supported by target pools. Not supported by backend services for pass-through load balancers. Supports all backends that can be health checked; for example, GCE_VM_IP_PORT network endpoint groups and instance group backends. For GCE_VM_IP_PORT network endpoint group backends, the health check uses the port number specified for each endpoint in the network endpoint group. For instance group backends, the health check uses the port number determined by looking up the backend service's named port in the instance group's list of named ports. 1658 * Check the PortSpecification enum for the list of possible values. 1659 * </pre> 1660 * 1661 * <code>optional string port_specification = 51590597;</code> 1662 * 1663 * @return Whether the portSpecification field is set. 1664 */ hasPortSpecification()1665 public boolean hasPortSpecification() { 1666 return ((bitField0_ & 0x00000008) != 0); 1667 } 1668 /** 1669 * 1670 * 1671 * <pre> 1672 * Specifies how a port is selected for health checking. Can be one of the following values: USE_FIXED_PORT: Specifies a port number explicitly using the port field in the health check. Supported by backend services for pass-through load balancers and backend services for proxy load balancers. Also supported in legacy HTTP health checks for target pools. The health check supports all backends supported by the backend service provided the backend can be health checked. For example, GCE_VM_IP network endpoint groups, GCE_VM_IP_PORT network endpoint groups, and instance group backends. USE_NAMED_PORT: Not supported. USE_SERVING_PORT: Provides an indirect method of specifying the health check port by referring to the backend service. Only supported by backend services for proxy load balancers. Not supported by target pools. Not supported by backend services for pass-through load balancers. Supports all backends that can be health checked; for example, GCE_VM_IP_PORT network endpoint groups and instance group backends. For GCE_VM_IP_PORT network endpoint group backends, the health check uses the port number specified for each endpoint in the network endpoint group. For instance group backends, the health check uses the port number determined by looking up the backend service's named port in the instance group's list of named ports. 1673 * Check the PortSpecification enum for the list of possible values. 1674 * </pre> 1675 * 1676 * <code>optional string port_specification = 51590597;</code> 1677 * 1678 * @return The portSpecification. 1679 */ getPortSpecification()1680 public java.lang.String getPortSpecification() { 1681 java.lang.Object ref = portSpecification_; 1682 if (!(ref instanceof java.lang.String)) { 1683 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 1684 java.lang.String s = bs.toStringUtf8(); 1685 portSpecification_ = s; 1686 return s; 1687 } else { 1688 return (java.lang.String) ref; 1689 } 1690 } 1691 /** 1692 * 1693 * 1694 * <pre> 1695 * Specifies how a port is selected for health checking. Can be one of the following values: USE_FIXED_PORT: Specifies a port number explicitly using the port field in the health check. Supported by backend services for pass-through load balancers and backend services for proxy load balancers. Also supported in legacy HTTP health checks for target pools. The health check supports all backends supported by the backend service provided the backend can be health checked. For example, GCE_VM_IP network endpoint groups, GCE_VM_IP_PORT network endpoint groups, and instance group backends. USE_NAMED_PORT: Not supported. USE_SERVING_PORT: Provides an indirect method of specifying the health check port by referring to the backend service. Only supported by backend services for proxy load balancers. Not supported by target pools. Not supported by backend services for pass-through load balancers. Supports all backends that can be health checked; for example, GCE_VM_IP_PORT network endpoint groups and instance group backends. For GCE_VM_IP_PORT network endpoint group backends, the health check uses the port number specified for each endpoint in the network endpoint group. For instance group backends, the health check uses the port number determined by looking up the backend service's named port in the instance group's list of named ports. 1696 * Check the PortSpecification enum for the list of possible values. 1697 * </pre> 1698 * 1699 * <code>optional string port_specification = 51590597;</code> 1700 * 1701 * @return The bytes for portSpecification. 1702 */ getPortSpecificationBytes()1703 public com.google.protobuf.ByteString getPortSpecificationBytes() { 1704 java.lang.Object ref = portSpecification_; 1705 if (ref instanceof String) { 1706 com.google.protobuf.ByteString b = 1707 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 1708 portSpecification_ = b; 1709 return b; 1710 } else { 1711 return (com.google.protobuf.ByteString) ref; 1712 } 1713 } 1714 /** 1715 * 1716 * 1717 * <pre> 1718 * Specifies how a port is selected for health checking. Can be one of the following values: USE_FIXED_PORT: Specifies a port number explicitly using the port field in the health check. Supported by backend services for pass-through load balancers and backend services for proxy load balancers. Also supported in legacy HTTP health checks for target pools. The health check supports all backends supported by the backend service provided the backend can be health checked. For example, GCE_VM_IP network endpoint groups, GCE_VM_IP_PORT network endpoint groups, and instance group backends. USE_NAMED_PORT: Not supported. USE_SERVING_PORT: Provides an indirect method of specifying the health check port by referring to the backend service. Only supported by backend services for proxy load balancers. Not supported by target pools. Not supported by backend services for pass-through load balancers. Supports all backends that can be health checked; for example, GCE_VM_IP_PORT network endpoint groups and instance group backends. For GCE_VM_IP_PORT network endpoint group backends, the health check uses the port number specified for each endpoint in the network endpoint group. For instance group backends, the health check uses the port number determined by looking up the backend service's named port in the instance group's list of named ports. 1719 * Check the PortSpecification enum for the list of possible values. 1720 * </pre> 1721 * 1722 * <code>optional string port_specification = 51590597;</code> 1723 * 1724 * @param value The portSpecification to set. 1725 * @return This builder for chaining. 1726 */ setPortSpecification(java.lang.String value)1727 public Builder setPortSpecification(java.lang.String value) { 1728 if (value == null) { 1729 throw new NullPointerException(); 1730 } 1731 portSpecification_ = value; 1732 bitField0_ |= 0x00000008; 1733 onChanged(); 1734 return this; 1735 } 1736 /** 1737 * 1738 * 1739 * <pre> 1740 * Specifies how a port is selected for health checking. Can be one of the following values: USE_FIXED_PORT: Specifies a port number explicitly using the port field in the health check. Supported by backend services for pass-through load balancers and backend services for proxy load balancers. Also supported in legacy HTTP health checks for target pools. The health check supports all backends supported by the backend service provided the backend can be health checked. For example, GCE_VM_IP network endpoint groups, GCE_VM_IP_PORT network endpoint groups, and instance group backends. USE_NAMED_PORT: Not supported. USE_SERVING_PORT: Provides an indirect method of specifying the health check port by referring to the backend service. Only supported by backend services for proxy load balancers. Not supported by target pools. Not supported by backend services for pass-through load balancers. Supports all backends that can be health checked; for example, GCE_VM_IP_PORT network endpoint groups and instance group backends. For GCE_VM_IP_PORT network endpoint group backends, the health check uses the port number specified for each endpoint in the network endpoint group. For instance group backends, the health check uses the port number determined by looking up the backend service's named port in the instance group's list of named ports. 1741 * Check the PortSpecification enum for the list of possible values. 1742 * </pre> 1743 * 1744 * <code>optional string port_specification = 51590597;</code> 1745 * 1746 * @return This builder for chaining. 1747 */ clearPortSpecification()1748 public Builder clearPortSpecification() { 1749 portSpecification_ = getDefaultInstance().getPortSpecification(); 1750 bitField0_ = (bitField0_ & ~0x00000008); 1751 onChanged(); 1752 return this; 1753 } 1754 /** 1755 * 1756 * 1757 * <pre> 1758 * Specifies how a port is selected for health checking. Can be one of the following values: USE_FIXED_PORT: Specifies a port number explicitly using the port field in the health check. Supported by backend services for pass-through load balancers and backend services for proxy load balancers. Also supported in legacy HTTP health checks for target pools. The health check supports all backends supported by the backend service provided the backend can be health checked. For example, GCE_VM_IP network endpoint groups, GCE_VM_IP_PORT network endpoint groups, and instance group backends. USE_NAMED_PORT: Not supported. USE_SERVING_PORT: Provides an indirect method of specifying the health check port by referring to the backend service. Only supported by backend services for proxy load balancers. Not supported by target pools. Not supported by backend services for pass-through load balancers. Supports all backends that can be health checked; for example, GCE_VM_IP_PORT network endpoint groups and instance group backends. For GCE_VM_IP_PORT network endpoint group backends, the health check uses the port number specified for each endpoint in the network endpoint group. For instance group backends, the health check uses the port number determined by looking up the backend service's named port in the instance group's list of named ports. 1759 * Check the PortSpecification enum for the list of possible values. 1760 * </pre> 1761 * 1762 * <code>optional string port_specification = 51590597;</code> 1763 * 1764 * @param value The bytes for portSpecification to set. 1765 * @return This builder for chaining. 1766 */ setPortSpecificationBytes(com.google.protobuf.ByteString value)1767 public Builder setPortSpecificationBytes(com.google.protobuf.ByteString value) { 1768 if (value == null) { 1769 throw new NullPointerException(); 1770 } 1771 checkByteStringIsUtf8(value); 1772 portSpecification_ = value; 1773 bitField0_ |= 0x00000008; 1774 onChanged(); 1775 return this; 1776 } 1777 1778 private java.lang.Object proxyHeader_ = ""; 1779 /** 1780 * 1781 * 1782 * <pre> 1783 * Specifies the type of proxy header to append before sending data to the backend, either NONE or PROXY_V1. The default is NONE. 1784 * Check the ProxyHeader enum for the list of possible values. 1785 * </pre> 1786 * 1787 * <code>optional string proxy_header = 160374142;</code> 1788 * 1789 * @return Whether the proxyHeader field is set. 1790 */ hasProxyHeader()1791 public boolean hasProxyHeader() { 1792 return ((bitField0_ & 0x00000010) != 0); 1793 } 1794 /** 1795 * 1796 * 1797 * <pre> 1798 * Specifies the type of proxy header to append before sending data to the backend, either NONE or PROXY_V1. The default is NONE. 1799 * Check the ProxyHeader enum for the list of possible values. 1800 * </pre> 1801 * 1802 * <code>optional string proxy_header = 160374142;</code> 1803 * 1804 * @return The proxyHeader. 1805 */ getProxyHeader()1806 public java.lang.String getProxyHeader() { 1807 java.lang.Object ref = proxyHeader_; 1808 if (!(ref instanceof java.lang.String)) { 1809 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 1810 java.lang.String s = bs.toStringUtf8(); 1811 proxyHeader_ = s; 1812 return s; 1813 } else { 1814 return (java.lang.String) ref; 1815 } 1816 } 1817 /** 1818 * 1819 * 1820 * <pre> 1821 * Specifies the type of proxy header to append before sending data to the backend, either NONE or PROXY_V1. The default is NONE. 1822 * Check the ProxyHeader enum for the list of possible values. 1823 * </pre> 1824 * 1825 * <code>optional string proxy_header = 160374142;</code> 1826 * 1827 * @return The bytes for proxyHeader. 1828 */ getProxyHeaderBytes()1829 public com.google.protobuf.ByteString getProxyHeaderBytes() { 1830 java.lang.Object ref = proxyHeader_; 1831 if (ref instanceof String) { 1832 com.google.protobuf.ByteString b = 1833 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 1834 proxyHeader_ = b; 1835 return b; 1836 } else { 1837 return (com.google.protobuf.ByteString) ref; 1838 } 1839 } 1840 /** 1841 * 1842 * 1843 * <pre> 1844 * Specifies the type of proxy header to append before sending data to the backend, either NONE or PROXY_V1. The default is NONE. 1845 * Check the ProxyHeader enum for the list of possible values. 1846 * </pre> 1847 * 1848 * <code>optional string proxy_header = 160374142;</code> 1849 * 1850 * @param value The proxyHeader to set. 1851 * @return This builder for chaining. 1852 */ setProxyHeader(java.lang.String value)1853 public Builder setProxyHeader(java.lang.String value) { 1854 if (value == null) { 1855 throw new NullPointerException(); 1856 } 1857 proxyHeader_ = value; 1858 bitField0_ |= 0x00000010; 1859 onChanged(); 1860 return this; 1861 } 1862 /** 1863 * 1864 * 1865 * <pre> 1866 * Specifies the type of proxy header to append before sending data to the backend, either NONE or PROXY_V1. The default is NONE. 1867 * Check the ProxyHeader enum for the list of possible values. 1868 * </pre> 1869 * 1870 * <code>optional string proxy_header = 160374142;</code> 1871 * 1872 * @return This builder for chaining. 1873 */ clearProxyHeader()1874 public Builder clearProxyHeader() { 1875 proxyHeader_ = getDefaultInstance().getProxyHeader(); 1876 bitField0_ = (bitField0_ & ~0x00000010); 1877 onChanged(); 1878 return this; 1879 } 1880 /** 1881 * 1882 * 1883 * <pre> 1884 * Specifies the type of proxy header to append before sending data to the backend, either NONE or PROXY_V1. The default is NONE. 1885 * Check the ProxyHeader enum for the list of possible values. 1886 * </pre> 1887 * 1888 * <code>optional string proxy_header = 160374142;</code> 1889 * 1890 * @param value The bytes for proxyHeader to set. 1891 * @return This builder for chaining. 1892 */ setProxyHeaderBytes(com.google.protobuf.ByteString value)1893 public Builder setProxyHeaderBytes(com.google.protobuf.ByteString value) { 1894 if (value == null) { 1895 throw new NullPointerException(); 1896 } 1897 checkByteStringIsUtf8(value); 1898 proxyHeader_ = value; 1899 bitField0_ |= 0x00000010; 1900 onChanged(); 1901 return this; 1902 } 1903 1904 private java.lang.Object requestPath_ = ""; 1905 /** 1906 * 1907 * 1908 * <pre> 1909 * The request path of the HTTP health check request. The default value is /. 1910 * </pre> 1911 * 1912 * <code>optional string request_path = 229403605;</code> 1913 * 1914 * @return Whether the requestPath field is set. 1915 */ hasRequestPath()1916 public boolean hasRequestPath() { 1917 return ((bitField0_ & 0x00000020) != 0); 1918 } 1919 /** 1920 * 1921 * 1922 * <pre> 1923 * The request path of the HTTP health check request. The default value is /. 1924 * </pre> 1925 * 1926 * <code>optional string request_path = 229403605;</code> 1927 * 1928 * @return The requestPath. 1929 */ getRequestPath()1930 public java.lang.String getRequestPath() { 1931 java.lang.Object ref = requestPath_; 1932 if (!(ref instanceof java.lang.String)) { 1933 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 1934 java.lang.String s = bs.toStringUtf8(); 1935 requestPath_ = s; 1936 return s; 1937 } else { 1938 return (java.lang.String) ref; 1939 } 1940 } 1941 /** 1942 * 1943 * 1944 * <pre> 1945 * The request path of the HTTP health check request. The default value is /. 1946 * </pre> 1947 * 1948 * <code>optional string request_path = 229403605;</code> 1949 * 1950 * @return The bytes for requestPath. 1951 */ getRequestPathBytes()1952 public com.google.protobuf.ByteString getRequestPathBytes() { 1953 java.lang.Object ref = requestPath_; 1954 if (ref instanceof String) { 1955 com.google.protobuf.ByteString b = 1956 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 1957 requestPath_ = b; 1958 return b; 1959 } else { 1960 return (com.google.protobuf.ByteString) ref; 1961 } 1962 } 1963 /** 1964 * 1965 * 1966 * <pre> 1967 * The request path of the HTTP health check request. The default value is /. 1968 * </pre> 1969 * 1970 * <code>optional string request_path = 229403605;</code> 1971 * 1972 * @param value The requestPath to set. 1973 * @return This builder for chaining. 1974 */ setRequestPath(java.lang.String value)1975 public Builder setRequestPath(java.lang.String value) { 1976 if (value == null) { 1977 throw new NullPointerException(); 1978 } 1979 requestPath_ = value; 1980 bitField0_ |= 0x00000020; 1981 onChanged(); 1982 return this; 1983 } 1984 /** 1985 * 1986 * 1987 * <pre> 1988 * The request path of the HTTP health check request. The default value is /. 1989 * </pre> 1990 * 1991 * <code>optional string request_path = 229403605;</code> 1992 * 1993 * @return This builder for chaining. 1994 */ clearRequestPath()1995 public Builder clearRequestPath() { 1996 requestPath_ = getDefaultInstance().getRequestPath(); 1997 bitField0_ = (bitField0_ & ~0x00000020); 1998 onChanged(); 1999 return this; 2000 } 2001 /** 2002 * 2003 * 2004 * <pre> 2005 * The request path of the HTTP health check request. The default value is /. 2006 * </pre> 2007 * 2008 * <code>optional string request_path = 229403605;</code> 2009 * 2010 * @param value The bytes for requestPath to set. 2011 * @return This builder for chaining. 2012 */ setRequestPathBytes(com.google.protobuf.ByteString value)2013 public Builder setRequestPathBytes(com.google.protobuf.ByteString value) { 2014 if (value == null) { 2015 throw new NullPointerException(); 2016 } 2017 checkByteStringIsUtf8(value); 2018 requestPath_ = value; 2019 bitField0_ |= 0x00000020; 2020 onChanged(); 2021 return this; 2022 } 2023 2024 private java.lang.Object response_ = ""; 2025 /** 2026 * 2027 * 2028 * <pre> 2029 * Creates a content-based HTTP health check. In addition to the required HTTP 200 (OK) status code, you can configure the health check to pass only when the backend sends this specific ASCII response string within the first 1024 bytes of the HTTP response body. For details, see: https://cloud.google.com/load-balancing/docs/health-check-concepts#criteria-protocol-http 2030 * </pre> 2031 * 2032 * <code>optional string response = 196547649;</code> 2033 * 2034 * @return Whether the response field is set. 2035 */ hasResponse()2036 public boolean hasResponse() { 2037 return ((bitField0_ & 0x00000040) != 0); 2038 } 2039 /** 2040 * 2041 * 2042 * <pre> 2043 * Creates a content-based HTTP health check. In addition to the required HTTP 200 (OK) status code, you can configure the health check to pass only when the backend sends this specific ASCII response string within the first 1024 bytes of the HTTP response body. For details, see: https://cloud.google.com/load-balancing/docs/health-check-concepts#criteria-protocol-http 2044 * </pre> 2045 * 2046 * <code>optional string response = 196547649;</code> 2047 * 2048 * @return The response. 2049 */ getResponse()2050 public java.lang.String getResponse() { 2051 java.lang.Object ref = response_; 2052 if (!(ref instanceof java.lang.String)) { 2053 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 2054 java.lang.String s = bs.toStringUtf8(); 2055 response_ = s; 2056 return s; 2057 } else { 2058 return (java.lang.String) ref; 2059 } 2060 } 2061 /** 2062 * 2063 * 2064 * <pre> 2065 * Creates a content-based HTTP health check. In addition to the required HTTP 200 (OK) status code, you can configure the health check to pass only when the backend sends this specific ASCII response string within the first 1024 bytes of the HTTP response body. For details, see: https://cloud.google.com/load-balancing/docs/health-check-concepts#criteria-protocol-http 2066 * </pre> 2067 * 2068 * <code>optional string response = 196547649;</code> 2069 * 2070 * @return The bytes for response. 2071 */ getResponseBytes()2072 public com.google.protobuf.ByteString getResponseBytes() { 2073 java.lang.Object ref = response_; 2074 if (ref instanceof String) { 2075 com.google.protobuf.ByteString b = 2076 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 2077 response_ = b; 2078 return b; 2079 } else { 2080 return (com.google.protobuf.ByteString) ref; 2081 } 2082 } 2083 /** 2084 * 2085 * 2086 * <pre> 2087 * Creates a content-based HTTP health check. In addition to the required HTTP 200 (OK) status code, you can configure the health check to pass only when the backend sends this specific ASCII response string within the first 1024 bytes of the HTTP response body. For details, see: https://cloud.google.com/load-balancing/docs/health-check-concepts#criteria-protocol-http 2088 * </pre> 2089 * 2090 * <code>optional string response = 196547649;</code> 2091 * 2092 * @param value The response to set. 2093 * @return This builder for chaining. 2094 */ setResponse(java.lang.String value)2095 public Builder setResponse(java.lang.String value) { 2096 if (value == null) { 2097 throw new NullPointerException(); 2098 } 2099 response_ = value; 2100 bitField0_ |= 0x00000040; 2101 onChanged(); 2102 return this; 2103 } 2104 /** 2105 * 2106 * 2107 * <pre> 2108 * Creates a content-based HTTP health check. In addition to the required HTTP 200 (OK) status code, you can configure the health check to pass only when the backend sends this specific ASCII response string within the first 1024 bytes of the HTTP response body. For details, see: https://cloud.google.com/load-balancing/docs/health-check-concepts#criteria-protocol-http 2109 * </pre> 2110 * 2111 * <code>optional string response = 196547649;</code> 2112 * 2113 * @return This builder for chaining. 2114 */ clearResponse()2115 public Builder clearResponse() { 2116 response_ = getDefaultInstance().getResponse(); 2117 bitField0_ = (bitField0_ & ~0x00000040); 2118 onChanged(); 2119 return this; 2120 } 2121 /** 2122 * 2123 * 2124 * <pre> 2125 * Creates a content-based HTTP health check. In addition to the required HTTP 200 (OK) status code, you can configure the health check to pass only when the backend sends this specific ASCII response string within the first 1024 bytes of the HTTP response body. For details, see: https://cloud.google.com/load-balancing/docs/health-check-concepts#criteria-protocol-http 2126 * </pre> 2127 * 2128 * <code>optional string response = 196547649;</code> 2129 * 2130 * @param value The bytes for response to set. 2131 * @return This builder for chaining. 2132 */ setResponseBytes(com.google.protobuf.ByteString value)2133 public Builder setResponseBytes(com.google.protobuf.ByteString value) { 2134 if (value == null) { 2135 throw new NullPointerException(); 2136 } 2137 checkByteStringIsUtf8(value); 2138 response_ = value; 2139 bitField0_ |= 0x00000040; 2140 onChanged(); 2141 return this; 2142 } 2143 2144 @java.lang.Override setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields)2145 public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { 2146 return super.setUnknownFields(unknownFields); 2147 } 2148 2149 @java.lang.Override mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields)2150 public final Builder mergeUnknownFields( 2151 final com.google.protobuf.UnknownFieldSet unknownFields) { 2152 return super.mergeUnknownFields(unknownFields); 2153 } 2154 2155 // @@protoc_insertion_point(builder_scope:google.cloud.compute.v1.HTTPHealthCheck) 2156 } 2157 2158 // @@protoc_insertion_point(class_scope:google.cloud.compute.v1.HTTPHealthCheck) 2159 private static final com.google.cloud.compute.v1.HTTPHealthCheck DEFAULT_INSTANCE; 2160 2161 static { 2162 DEFAULT_INSTANCE = new com.google.cloud.compute.v1.HTTPHealthCheck(); 2163 } 2164 getDefaultInstance()2165 public static com.google.cloud.compute.v1.HTTPHealthCheck getDefaultInstance() { 2166 return DEFAULT_INSTANCE; 2167 } 2168 2169 private static final com.google.protobuf.Parser<HTTPHealthCheck> PARSER = 2170 new com.google.protobuf.AbstractParser<HTTPHealthCheck>() { 2171 @java.lang.Override 2172 public HTTPHealthCheck parsePartialFrom( 2173 com.google.protobuf.CodedInputStream input, 2174 com.google.protobuf.ExtensionRegistryLite extensionRegistry) 2175 throws com.google.protobuf.InvalidProtocolBufferException { 2176 Builder builder = newBuilder(); 2177 try { 2178 builder.mergeFrom(input, extensionRegistry); 2179 } catch (com.google.protobuf.InvalidProtocolBufferException e) { 2180 throw e.setUnfinishedMessage(builder.buildPartial()); 2181 } catch (com.google.protobuf.UninitializedMessageException e) { 2182 throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); 2183 } catch (java.io.IOException e) { 2184 throw new com.google.protobuf.InvalidProtocolBufferException(e) 2185 .setUnfinishedMessage(builder.buildPartial()); 2186 } 2187 return builder.buildPartial(); 2188 } 2189 }; 2190 parser()2191 public static com.google.protobuf.Parser<HTTPHealthCheck> parser() { 2192 return PARSER; 2193 } 2194 2195 @java.lang.Override getParserForType()2196 public com.google.protobuf.Parser<HTTPHealthCheck> getParserForType() { 2197 return PARSER; 2198 } 2199 2200 @java.lang.Override getDefaultInstanceForType()2201 public com.google.cloud.compute.v1.HTTPHealthCheck getDefaultInstanceForType() { 2202 return DEFAULT_INSTANCE; 2203 } 2204 } 2205