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