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