1 /* 2 * Copyright 2019 The Grafeas Authors. All rights reserved. 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 17 // Generated by the protocol buffer compiler. DO NOT EDIT! 18 // source: grafeas/v1/package.proto 19 20 package io.grafeas.v1; 21 22 /** 23 * 24 * 25 * <pre> 26 * Version contains structured information about the version of a package. 27 * </pre> 28 * 29 * Protobuf type {@code grafeas.v1.Version} 30 */ 31 public final class Version extends com.google.protobuf.GeneratedMessageV3 32 implements 33 // @@protoc_insertion_point(message_implements:grafeas.v1.Version) 34 VersionOrBuilder { 35 private static final long serialVersionUID = 0L; 36 // Use Version.newBuilder() to construct. Version(com.google.protobuf.GeneratedMessageV3.Builder<?> builder)37 private Version(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) { 38 super(builder); 39 } 40 Version()41 private Version() { 42 name_ = ""; 43 revision_ = ""; 44 kind_ = 0; 45 fullName_ = ""; 46 } 47 48 @java.lang.Override 49 @SuppressWarnings({"unused"}) newInstance(UnusedPrivateParameter unused)50 protected java.lang.Object newInstance(UnusedPrivateParameter unused) { 51 return new Version(); 52 } 53 54 @java.lang.Override getUnknownFields()55 public final com.google.protobuf.UnknownFieldSet getUnknownFields() { 56 return this.unknownFields; 57 } 58 getDescriptor()59 public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { 60 return io.grafeas.v1.Package.internal_static_grafeas_v1_Version_descriptor; 61 } 62 63 @java.lang.Override 64 protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()65 internalGetFieldAccessorTable() { 66 return io.grafeas.v1.Package.internal_static_grafeas_v1_Version_fieldAccessorTable 67 .ensureFieldAccessorsInitialized( 68 io.grafeas.v1.Version.class, io.grafeas.v1.Version.Builder.class); 69 } 70 71 /** 72 * 73 * 74 * <pre> 75 * Whether this is an ordinary package version or a sentinel MIN/MAX version. 76 * </pre> 77 * 78 * Protobuf enum {@code grafeas.v1.Version.VersionKind} 79 */ 80 public enum VersionKind implements com.google.protobuf.ProtocolMessageEnum { 81 /** 82 * 83 * 84 * <pre> 85 * Unknown. 86 * </pre> 87 * 88 * <code>VERSION_KIND_UNSPECIFIED = 0;</code> 89 */ 90 VERSION_KIND_UNSPECIFIED(0), 91 /** 92 * 93 * 94 * <pre> 95 * A standard package version. 96 * </pre> 97 * 98 * <code>NORMAL = 1;</code> 99 */ 100 NORMAL(1), 101 /** 102 * 103 * 104 * <pre> 105 * A special version representing negative infinity. 106 * </pre> 107 * 108 * <code>MINIMUM = 2;</code> 109 */ 110 MINIMUM(2), 111 /** 112 * 113 * 114 * <pre> 115 * A special version representing positive infinity. 116 * </pre> 117 * 118 * <code>MAXIMUM = 3;</code> 119 */ 120 MAXIMUM(3), 121 UNRECOGNIZED(-1), 122 ; 123 124 /** 125 * 126 * 127 * <pre> 128 * Unknown. 129 * </pre> 130 * 131 * <code>VERSION_KIND_UNSPECIFIED = 0;</code> 132 */ 133 public static final int VERSION_KIND_UNSPECIFIED_VALUE = 0; 134 /** 135 * 136 * 137 * <pre> 138 * A standard package version. 139 * </pre> 140 * 141 * <code>NORMAL = 1;</code> 142 */ 143 public static final int NORMAL_VALUE = 1; 144 /** 145 * 146 * 147 * <pre> 148 * A special version representing negative infinity. 149 * </pre> 150 * 151 * <code>MINIMUM = 2;</code> 152 */ 153 public static final int MINIMUM_VALUE = 2; 154 /** 155 * 156 * 157 * <pre> 158 * A special version representing positive infinity. 159 * </pre> 160 * 161 * <code>MAXIMUM = 3;</code> 162 */ 163 public static final int MAXIMUM_VALUE = 3; 164 getNumber()165 public final int getNumber() { 166 if (this == UNRECOGNIZED) { 167 throw new java.lang.IllegalArgumentException( 168 "Can't get the number of an unknown enum value."); 169 } 170 return value; 171 } 172 173 /** 174 * @param value The numeric wire value of the corresponding enum entry. 175 * @return The enum associated with the given numeric wire value. 176 * @deprecated Use {@link #forNumber(int)} instead. 177 */ 178 @java.lang.Deprecated valueOf(int value)179 public static VersionKind valueOf(int value) { 180 return forNumber(value); 181 } 182 183 /** 184 * @param value The numeric wire value of the corresponding enum entry. 185 * @return The enum associated with the given numeric wire value. 186 */ forNumber(int value)187 public static VersionKind forNumber(int value) { 188 switch (value) { 189 case 0: 190 return VERSION_KIND_UNSPECIFIED; 191 case 1: 192 return NORMAL; 193 case 2: 194 return MINIMUM; 195 case 3: 196 return MAXIMUM; 197 default: 198 return null; 199 } 200 } 201 internalGetValueMap()202 public static com.google.protobuf.Internal.EnumLiteMap<VersionKind> internalGetValueMap() { 203 return internalValueMap; 204 } 205 206 private static final com.google.protobuf.Internal.EnumLiteMap<VersionKind> internalValueMap = 207 new com.google.protobuf.Internal.EnumLiteMap<VersionKind>() { 208 public VersionKind findValueByNumber(int number) { 209 return VersionKind.forNumber(number); 210 } 211 }; 212 getValueDescriptor()213 public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { 214 if (this == UNRECOGNIZED) { 215 throw new java.lang.IllegalStateException( 216 "Can't get the descriptor of an unrecognized enum value."); 217 } 218 return getDescriptor().getValues().get(ordinal()); 219 } 220 getDescriptorForType()221 public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { 222 return getDescriptor(); 223 } 224 getDescriptor()225 public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { 226 return io.grafeas.v1.Version.getDescriptor().getEnumTypes().get(0); 227 } 228 229 private static final VersionKind[] VALUES = values(); 230 valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc)231 public static VersionKind valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { 232 if (desc.getType() != getDescriptor()) { 233 throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); 234 } 235 if (desc.getIndex() == -1) { 236 return UNRECOGNIZED; 237 } 238 return VALUES[desc.getIndex()]; 239 } 240 241 private final int value; 242 VersionKind(int value)243 private VersionKind(int value) { 244 this.value = value; 245 } 246 247 // @@protoc_insertion_point(enum_scope:grafeas.v1.Version.VersionKind) 248 } 249 250 public static final int EPOCH_FIELD_NUMBER = 1; 251 private int epoch_ = 0; 252 /** 253 * 254 * 255 * <pre> 256 * Used to correct mistakes in the version numbering scheme. 257 * </pre> 258 * 259 * <code>int32 epoch = 1;</code> 260 * 261 * @return The epoch. 262 */ 263 @java.lang.Override getEpoch()264 public int getEpoch() { 265 return epoch_; 266 } 267 268 public static final int NAME_FIELD_NUMBER = 2; 269 270 @SuppressWarnings("serial") 271 private volatile java.lang.Object name_ = ""; 272 /** 273 * 274 * 275 * <pre> 276 * Required only when version kind is NORMAL. The main part of the version 277 * name. 278 * </pre> 279 * 280 * <code>string name = 2;</code> 281 * 282 * @return The name. 283 */ 284 @java.lang.Override getName()285 public java.lang.String getName() { 286 java.lang.Object ref = name_; 287 if (ref instanceof java.lang.String) { 288 return (java.lang.String) ref; 289 } else { 290 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 291 java.lang.String s = bs.toStringUtf8(); 292 name_ = s; 293 return s; 294 } 295 } 296 /** 297 * 298 * 299 * <pre> 300 * Required only when version kind is NORMAL. The main part of the version 301 * name. 302 * </pre> 303 * 304 * <code>string name = 2;</code> 305 * 306 * @return The bytes for name. 307 */ 308 @java.lang.Override getNameBytes()309 public com.google.protobuf.ByteString getNameBytes() { 310 java.lang.Object ref = name_; 311 if (ref instanceof java.lang.String) { 312 com.google.protobuf.ByteString b = 313 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 314 name_ = b; 315 return b; 316 } else { 317 return (com.google.protobuf.ByteString) ref; 318 } 319 } 320 321 public static final int REVISION_FIELD_NUMBER = 3; 322 323 @SuppressWarnings("serial") 324 private volatile java.lang.Object revision_ = ""; 325 /** 326 * 327 * 328 * <pre> 329 * The iteration of the package build from the above version. 330 * </pre> 331 * 332 * <code>string revision = 3;</code> 333 * 334 * @return The revision. 335 */ 336 @java.lang.Override getRevision()337 public java.lang.String getRevision() { 338 java.lang.Object ref = revision_; 339 if (ref instanceof java.lang.String) { 340 return (java.lang.String) ref; 341 } else { 342 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 343 java.lang.String s = bs.toStringUtf8(); 344 revision_ = s; 345 return s; 346 } 347 } 348 /** 349 * 350 * 351 * <pre> 352 * The iteration of the package build from the above version. 353 * </pre> 354 * 355 * <code>string revision = 3;</code> 356 * 357 * @return The bytes for revision. 358 */ 359 @java.lang.Override getRevisionBytes()360 public com.google.protobuf.ByteString getRevisionBytes() { 361 java.lang.Object ref = revision_; 362 if (ref instanceof java.lang.String) { 363 com.google.protobuf.ByteString b = 364 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 365 revision_ = b; 366 return b; 367 } else { 368 return (com.google.protobuf.ByteString) ref; 369 } 370 } 371 372 public static final int INCLUSIVE_FIELD_NUMBER = 6; 373 private boolean inclusive_ = false; 374 /** 375 * 376 * 377 * <pre> 378 * Whether this version is specifying part of an inclusive range. Grafeas 379 * does not have the capability to specify version ranges; instead we have 380 * fields that specify start version and end versions. At times this is 381 * insufficient - we also need to specify whether the version is included in 382 * the range or is excluded from the range. This boolean is expected to be set 383 * to true when the version is included in a range. 384 * </pre> 385 * 386 * <code>bool inclusive = 6;</code> 387 * 388 * @return The inclusive. 389 */ 390 @java.lang.Override getInclusive()391 public boolean getInclusive() { 392 return inclusive_; 393 } 394 395 public static final int KIND_FIELD_NUMBER = 4; 396 private int kind_ = 0; 397 /** 398 * 399 * 400 * <pre> 401 * Required. Distinguishes between sentinel MIN/MAX versions and normal 402 * versions. 403 * </pre> 404 * 405 * <code>.grafeas.v1.Version.VersionKind kind = 4;</code> 406 * 407 * @return The enum numeric value on the wire for kind. 408 */ 409 @java.lang.Override getKindValue()410 public int getKindValue() { 411 return kind_; 412 } 413 /** 414 * 415 * 416 * <pre> 417 * Required. Distinguishes between sentinel MIN/MAX versions and normal 418 * versions. 419 * </pre> 420 * 421 * <code>.grafeas.v1.Version.VersionKind kind = 4;</code> 422 * 423 * @return The kind. 424 */ 425 @java.lang.Override getKind()426 public io.grafeas.v1.Version.VersionKind getKind() { 427 io.grafeas.v1.Version.VersionKind result = io.grafeas.v1.Version.VersionKind.forNumber(kind_); 428 return result == null ? io.grafeas.v1.Version.VersionKind.UNRECOGNIZED : result; 429 } 430 431 public static final int FULL_NAME_FIELD_NUMBER = 5; 432 433 @SuppressWarnings("serial") 434 private volatile java.lang.Object fullName_ = ""; 435 /** 436 * 437 * 438 * <pre> 439 * Human readable version string. This string is of the form 440 * <epoch>:<name>-<revision> and is only set when kind is NORMAL. 441 * </pre> 442 * 443 * <code>string full_name = 5;</code> 444 * 445 * @return The fullName. 446 */ 447 @java.lang.Override getFullName()448 public java.lang.String getFullName() { 449 java.lang.Object ref = fullName_; 450 if (ref instanceof java.lang.String) { 451 return (java.lang.String) ref; 452 } else { 453 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 454 java.lang.String s = bs.toStringUtf8(); 455 fullName_ = s; 456 return s; 457 } 458 } 459 /** 460 * 461 * 462 * <pre> 463 * Human readable version string. This string is of the form 464 * <epoch>:<name>-<revision> and is only set when kind is NORMAL. 465 * </pre> 466 * 467 * <code>string full_name = 5;</code> 468 * 469 * @return The bytes for fullName. 470 */ 471 @java.lang.Override getFullNameBytes()472 public com.google.protobuf.ByteString getFullNameBytes() { 473 java.lang.Object ref = fullName_; 474 if (ref instanceof java.lang.String) { 475 com.google.protobuf.ByteString b = 476 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 477 fullName_ = b; 478 return b; 479 } else { 480 return (com.google.protobuf.ByteString) ref; 481 } 482 } 483 484 private byte memoizedIsInitialized = -1; 485 486 @java.lang.Override isInitialized()487 public final boolean isInitialized() { 488 byte isInitialized = memoizedIsInitialized; 489 if (isInitialized == 1) return true; 490 if (isInitialized == 0) return false; 491 492 memoizedIsInitialized = 1; 493 return true; 494 } 495 496 @java.lang.Override writeTo(com.google.protobuf.CodedOutputStream output)497 public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { 498 if (epoch_ != 0) { 499 output.writeInt32(1, epoch_); 500 } 501 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { 502 com.google.protobuf.GeneratedMessageV3.writeString(output, 2, name_); 503 } 504 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(revision_)) { 505 com.google.protobuf.GeneratedMessageV3.writeString(output, 3, revision_); 506 } 507 if (kind_ != io.grafeas.v1.Version.VersionKind.VERSION_KIND_UNSPECIFIED.getNumber()) { 508 output.writeEnum(4, kind_); 509 } 510 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(fullName_)) { 511 com.google.protobuf.GeneratedMessageV3.writeString(output, 5, fullName_); 512 } 513 if (inclusive_ != false) { 514 output.writeBool(6, inclusive_); 515 } 516 getUnknownFields().writeTo(output); 517 } 518 519 @java.lang.Override getSerializedSize()520 public int getSerializedSize() { 521 int size = memoizedSize; 522 if (size != -1) return size; 523 524 size = 0; 525 if (epoch_ != 0) { 526 size += com.google.protobuf.CodedOutputStream.computeInt32Size(1, epoch_); 527 } 528 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { 529 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, name_); 530 } 531 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(revision_)) { 532 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, revision_); 533 } 534 if (kind_ != io.grafeas.v1.Version.VersionKind.VERSION_KIND_UNSPECIFIED.getNumber()) { 535 size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, kind_); 536 } 537 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(fullName_)) { 538 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, fullName_); 539 } 540 if (inclusive_ != false) { 541 size += com.google.protobuf.CodedOutputStream.computeBoolSize(6, inclusive_); 542 } 543 size += getUnknownFields().getSerializedSize(); 544 memoizedSize = size; 545 return size; 546 } 547 548 @java.lang.Override equals(final java.lang.Object obj)549 public boolean equals(final java.lang.Object obj) { 550 if (obj == this) { 551 return true; 552 } 553 if (!(obj instanceof io.grafeas.v1.Version)) { 554 return super.equals(obj); 555 } 556 io.grafeas.v1.Version other = (io.grafeas.v1.Version) obj; 557 558 if (getEpoch() != other.getEpoch()) return false; 559 if (!getName().equals(other.getName())) return false; 560 if (!getRevision().equals(other.getRevision())) return false; 561 if (getInclusive() != other.getInclusive()) return false; 562 if (kind_ != other.kind_) return false; 563 if (!getFullName().equals(other.getFullName())) return false; 564 if (!getUnknownFields().equals(other.getUnknownFields())) return false; 565 return true; 566 } 567 568 @java.lang.Override hashCode()569 public int hashCode() { 570 if (memoizedHashCode != 0) { 571 return memoizedHashCode; 572 } 573 int hash = 41; 574 hash = (19 * hash) + getDescriptor().hashCode(); 575 hash = (37 * hash) + EPOCH_FIELD_NUMBER; 576 hash = (53 * hash) + getEpoch(); 577 hash = (37 * hash) + NAME_FIELD_NUMBER; 578 hash = (53 * hash) + getName().hashCode(); 579 hash = (37 * hash) + REVISION_FIELD_NUMBER; 580 hash = (53 * hash) + getRevision().hashCode(); 581 hash = (37 * hash) + INCLUSIVE_FIELD_NUMBER; 582 hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getInclusive()); 583 hash = (37 * hash) + KIND_FIELD_NUMBER; 584 hash = (53 * hash) + kind_; 585 hash = (37 * hash) + FULL_NAME_FIELD_NUMBER; 586 hash = (53 * hash) + getFullName().hashCode(); 587 hash = (29 * hash) + getUnknownFields().hashCode(); 588 memoizedHashCode = hash; 589 return hash; 590 } 591 parseFrom(java.nio.ByteBuffer data)592 public static io.grafeas.v1.Version parseFrom(java.nio.ByteBuffer data) 593 throws com.google.protobuf.InvalidProtocolBufferException { 594 return PARSER.parseFrom(data); 595 } 596 parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)597 public static io.grafeas.v1.Version parseFrom( 598 java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) 599 throws com.google.protobuf.InvalidProtocolBufferException { 600 return PARSER.parseFrom(data, extensionRegistry); 601 } 602 parseFrom(com.google.protobuf.ByteString data)603 public static io.grafeas.v1.Version parseFrom(com.google.protobuf.ByteString data) 604 throws com.google.protobuf.InvalidProtocolBufferException { 605 return PARSER.parseFrom(data); 606 } 607 parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)608 public static io.grafeas.v1.Version parseFrom( 609 com.google.protobuf.ByteString data, 610 com.google.protobuf.ExtensionRegistryLite extensionRegistry) 611 throws com.google.protobuf.InvalidProtocolBufferException { 612 return PARSER.parseFrom(data, extensionRegistry); 613 } 614 parseFrom(byte[] data)615 public static io.grafeas.v1.Version parseFrom(byte[] data) 616 throws com.google.protobuf.InvalidProtocolBufferException { 617 return PARSER.parseFrom(data); 618 } 619 parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)620 public static io.grafeas.v1.Version parseFrom( 621 byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) 622 throws com.google.protobuf.InvalidProtocolBufferException { 623 return PARSER.parseFrom(data, extensionRegistry); 624 } 625 parseFrom(java.io.InputStream input)626 public static io.grafeas.v1.Version parseFrom(java.io.InputStream input) 627 throws java.io.IOException { 628 return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); 629 } 630 parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)631 public static io.grafeas.v1.Version parseFrom( 632 java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) 633 throws java.io.IOException { 634 return com.google.protobuf.GeneratedMessageV3.parseWithIOException( 635 PARSER, input, extensionRegistry); 636 } 637 parseDelimitedFrom(java.io.InputStream input)638 public static io.grafeas.v1.Version parseDelimitedFrom(java.io.InputStream input) 639 throws java.io.IOException { 640 return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); 641 } 642 parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)643 public static io.grafeas.v1.Version parseDelimitedFrom( 644 java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) 645 throws java.io.IOException { 646 return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( 647 PARSER, input, extensionRegistry); 648 } 649 parseFrom(com.google.protobuf.CodedInputStream input)650 public static io.grafeas.v1.Version parseFrom(com.google.protobuf.CodedInputStream input) 651 throws java.io.IOException { 652 return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); 653 } 654 parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)655 public static io.grafeas.v1.Version parseFrom( 656 com.google.protobuf.CodedInputStream input, 657 com.google.protobuf.ExtensionRegistryLite extensionRegistry) 658 throws java.io.IOException { 659 return com.google.protobuf.GeneratedMessageV3.parseWithIOException( 660 PARSER, input, extensionRegistry); 661 } 662 663 @java.lang.Override newBuilderForType()664 public Builder newBuilderForType() { 665 return newBuilder(); 666 } 667 newBuilder()668 public static Builder newBuilder() { 669 return DEFAULT_INSTANCE.toBuilder(); 670 } 671 newBuilder(io.grafeas.v1.Version prototype)672 public static Builder newBuilder(io.grafeas.v1.Version prototype) { 673 return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); 674 } 675 676 @java.lang.Override toBuilder()677 public Builder toBuilder() { 678 return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); 679 } 680 681 @java.lang.Override newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)682 protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { 683 Builder builder = new Builder(parent); 684 return builder; 685 } 686 /** 687 * 688 * 689 * <pre> 690 * Version contains structured information about the version of a package. 691 * </pre> 692 * 693 * Protobuf type {@code grafeas.v1.Version} 694 */ 695 public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder> 696 implements 697 // @@protoc_insertion_point(builder_implements:grafeas.v1.Version) 698 io.grafeas.v1.VersionOrBuilder { getDescriptor()699 public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { 700 return io.grafeas.v1.Package.internal_static_grafeas_v1_Version_descriptor; 701 } 702 703 @java.lang.Override 704 protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()705 internalGetFieldAccessorTable() { 706 return io.grafeas.v1.Package.internal_static_grafeas_v1_Version_fieldAccessorTable 707 .ensureFieldAccessorsInitialized( 708 io.grafeas.v1.Version.class, io.grafeas.v1.Version.Builder.class); 709 } 710 711 // Construct using io.grafeas.v1.Version.newBuilder() Builder()712 private Builder() {} 713 Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)714 private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { 715 super(parent); 716 } 717 718 @java.lang.Override clear()719 public Builder clear() { 720 super.clear(); 721 bitField0_ = 0; 722 epoch_ = 0; 723 name_ = ""; 724 revision_ = ""; 725 inclusive_ = false; 726 kind_ = 0; 727 fullName_ = ""; 728 return this; 729 } 730 731 @java.lang.Override getDescriptorForType()732 public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { 733 return io.grafeas.v1.Package.internal_static_grafeas_v1_Version_descriptor; 734 } 735 736 @java.lang.Override getDefaultInstanceForType()737 public io.grafeas.v1.Version getDefaultInstanceForType() { 738 return io.grafeas.v1.Version.getDefaultInstance(); 739 } 740 741 @java.lang.Override build()742 public io.grafeas.v1.Version build() { 743 io.grafeas.v1.Version result = buildPartial(); 744 if (!result.isInitialized()) { 745 throw newUninitializedMessageException(result); 746 } 747 return result; 748 } 749 750 @java.lang.Override buildPartial()751 public io.grafeas.v1.Version buildPartial() { 752 io.grafeas.v1.Version result = new io.grafeas.v1.Version(this); 753 if (bitField0_ != 0) { 754 buildPartial0(result); 755 } 756 onBuilt(); 757 return result; 758 } 759 buildPartial0(io.grafeas.v1.Version result)760 private void buildPartial0(io.grafeas.v1.Version result) { 761 int from_bitField0_ = bitField0_; 762 if (((from_bitField0_ & 0x00000001) != 0)) { 763 result.epoch_ = epoch_; 764 } 765 if (((from_bitField0_ & 0x00000002) != 0)) { 766 result.name_ = name_; 767 } 768 if (((from_bitField0_ & 0x00000004) != 0)) { 769 result.revision_ = revision_; 770 } 771 if (((from_bitField0_ & 0x00000008) != 0)) { 772 result.inclusive_ = inclusive_; 773 } 774 if (((from_bitField0_ & 0x00000010) != 0)) { 775 result.kind_ = kind_; 776 } 777 if (((from_bitField0_ & 0x00000020) != 0)) { 778 result.fullName_ = fullName_; 779 } 780 } 781 782 @java.lang.Override clone()783 public Builder clone() { 784 return super.clone(); 785 } 786 787 @java.lang.Override setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)788 public Builder setField( 789 com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { 790 return super.setField(field, value); 791 } 792 793 @java.lang.Override clearField(com.google.protobuf.Descriptors.FieldDescriptor field)794 public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { 795 return super.clearField(field); 796 } 797 798 @java.lang.Override clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)799 public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { 800 return super.clearOneof(oneof); 801 } 802 803 @java.lang.Override setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value)804 public Builder setRepeatedField( 805 com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { 806 return super.setRepeatedField(field, index, value); 807 } 808 809 @java.lang.Override addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)810 public Builder addRepeatedField( 811 com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { 812 return super.addRepeatedField(field, value); 813 } 814 815 @java.lang.Override mergeFrom(com.google.protobuf.Message other)816 public Builder mergeFrom(com.google.protobuf.Message other) { 817 if (other instanceof io.grafeas.v1.Version) { 818 return mergeFrom((io.grafeas.v1.Version) other); 819 } else { 820 super.mergeFrom(other); 821 return this; 822 } 823 } 824 mergeFrom(io.grafeas.v1.Version other)825 public Builder mergeFrom(io.grafeas.v1.Version other) { 826 if (other == io.grafeas.v1.Version.getDefaultInstance()) return this; 827 if (other.getEpoch() != 0) { 828 setEpoch(other.getEpoch()); 829 } 830 if (!other.getName().isEmpty()) { 831 name_ = other.name_; 832 bitField0_ |= 0x00000002; 833 onChanged(); 834 } 835 if (!other.getRevision().isEmpty()) { 836 revision_ = other.revision_; 837 bitField0_ |= 0x00000004; 838 onChanged(); 839 } 840 if (other.getInclusive() != false) { 841 setInclusive(other.getInclusive()); 842 } 843 if (other.kind_ != 0) { 844 setKindValue(other.getKindValue()); 845 } 846 if (!other.getFullName().isEmpty()) { 847 fullName_ = other.fullName_; 848 bitField0_ |= 0x00000020; 849 onChanged(); 850 } 851 this.mergeUnknownFields(other.getUnknownFields()); 852 onChanged(); 853 return this; 854 } 855 856 @java.lang.Override isInitialized()857 public final boolean isInitialized() { 858 return true; 859 } 860 861 @java.lang.Override mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)862 public Builder mergeFrom( 863 com.google.protobuf.CodedInputStream input, 864 com.google.protobuf.ExtensionRegistryLite extensionRegistry) 865 throws java.io.IOException { 866 if (extensionRegistry == null) { 867 throw new java.lang.NullPointerException(); 868 } 869 try { 870 boolean done = false; 871 while (!done) { 872 int tag = input.readTag(); 873 switch (tag) { 874 case 0: 875 done = true; 876 break; 877 case 8: 878 { 879 epoch_ = input.readInt32(); 880 bitField0_ |= 0x00000001; 881 break; 882 } // case 8 883 case 18: 884 { 885 name_ = input.readStringRequireUtf8(); 886 bitField0_ |= 0x00000002; 887 break; 888 } // case 18 889 case 26: 890 { 891 revision_ = input.readStringRequireUtf8(); 892 bitField0_ |= 0x00000004; 893 break; 894 } // case 26 895 case 32: 896 { 897 kind_ = input.readEnum(); 898 bitField0_ |= 0x00000010; 899 break; 900 } // case 32 901 case 42: 902 { 903 fullName_ = input.readStringRequireUtf8(); 904 bitField0_ |= 0x00000020; 905 break; 906 } // case 42 907 case 48: 908 { 909 inclusive_ = input.readBool(); 910 bitField0_ |= 0x00000008; 911 break; 912 } // case 48 913 default: 914 { 915 if (!super.parseUnknownField(input, extensionRegistry, tag)) { 916 done = true; // was an endgroup tag 917 } 918 break; 919 } // default: 920 } // switch (tag) 921 } // while (!done) 922 } catch (com.google.protobuf.InvalidProtocolBufferException e) { 923 throw e.unwrapIOException(); 924 } finally { 925 onChanged(); 926 } // finally 927 return this; 928 } 929 930 private int bitField0_; 931 932 private int epoch_; 933 /** 934 * 935 * 936 * <pre> 937 * Used to correct mistakes in the version numbering scheme. 938 * </pre> 939 * 940 * <code>int32 epoch = 1;</code> 941 * 942 * @return The epoch. 943 */ 944 @java.lang.Override getEpoch()945 public int getEpoch() { 946 return epoch_; 947 } 948 /** 949 * 950 * 951 * <pre> 952 * Used to correct mistakes in the version numbering scheme. 953 * </pre> 954 * 955 * <code>int32 epoch = 1;</code> 956 * 957 * @param value The epoch to set. 958 * @return This builder for chaining. 959 */ setEpoch(int value)960 public Builder setEpoch(int value) { 961 962 epoch_ = value; 963 bitField0_ |= 0x00000001; 964 onChanged(); 965 return this; 966 } 967 /** 968 * 969 * 970 * <pre> 971 * Used to correct mistakes in the version numbering scheme. 972 * </pre> 973 * 974 * <code>int32 epoch = 1;</code> 975 * 976 * @return This builder for chaining. 977 */ clearEpoch()978 public Builder clearEpoch() { 979 bitField0_ = (bitField0_ & ~0x00000001); 980 epoch_ = 0; 981 onChanged(); 982 return this; 983 } 984 985 private java.lang.Object name_ = ""; 986 /** 987 * 988 * 989 * <pre> 990 * Required only when version kind is NORMAL. The main part of the version 991 * name. 992 * </pre> 993 * 994 * <code>string name = 2;</code> 995 * 996 * @return The name. 997 */ getName()998 public java.lang.String getName() { 999 java.lang.Object ref = name_; 1000 if (!(ref instanceof java.lang.String)) { 1001 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 1002 java.lang.String s = bs.toStringUtf8(); 1003 name_ = s; 1004 return s; 1005 } else { 1006 return (java.lang.String) ref; 1007 } 1008 } 1009 /** 1010 * 1011 * 1012 * <pre> 1013 * Required only when version kind is NORMAL. The main part of the version 1014 * name. 1015 * </pre> 1016 * 1017 * <code>string name = 2;</code> 1018 * 1019 * @return The bytes for name. 1020 */ getNameBytes()1021 public com.google.protobuf.ByteString getNameBytes() { 1022 java.lang.Object ref = name_; 1023 if (ref instanceof String) { 1024 com.google.protobuf.ByteString b = 1025 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 1026 name_ = b; 1027 return b; 1028 } else { 1029 return (com.google.protobuf.ByteString) ref; 1030 } 1031 } 1032 /** 1033 * 1034 * 1035 * <pre> 1036 * Required only when version kind is NORMAL. The main part of the version 1037 * name. 1038 * </pre> 1039 * 1040 * <code>string name = 2;</code> 1041 * 1042 * @param value The name to set. 1043 * @return This builder for chaining. 1044 */ setName(java.lang.String value)1045 public Builder setName(java.lang.String value) { 1046 if (value == null) { 1047 throw new NullPointerException(); 1048 } 1049 name_ = value; 1050 bitField0_ |= 0x00000002; 1051 onChanged(); 1052 return this; 1053 } 1054 /** 1055 * 1056 * 1057 * <pre> 1058 * Required only when version kind is NORMAL. The main part of the version 1059 * name. 1060 * </pre> 1061 * 1062 * <code>string name = 2;</code> 1063 * 1064 * @return This builder for chaining. 1065 */ clearName()1066 public Builder clearName() { 1067 name_ = getDefaultInstance().getName(); 1068 bitField0_ = (bitField0_ & ~0x00000002); 1069 onChanged(); 1070 return this; 1071 } 1072 /** 1073 * 1074 * 1075 * <pre> 1076 * Required only when version kind is NORMAL. The main part of the version 1077 * name. 1078 * </pre> 1079 * 1080 * <code>string name = 2;</code> 1081 * 1082 * @param value The bytes for name to set. 1083 * @return This builder for chaining. 1084 */ setNameBytes(com.google.protobuf.ByteString value)1085 public Builder setNameBytes(com.google.protobuf.ByteString value) { 1086 if (value == null) { 1087 throw new NullPointerException(); 1088 } 1089 checkByteStringIsUtf8(value); 1090 name_ = value; 1091 bitField0_ |= 0x00000002; 1092 onChanged(); 1093 return this; 1094 } 1095 1096 private java.lang.Object revision_ = ""; 1097 /** 1098 * 1099 * 1100 * <pre> 1101 * The iteration of the package build from the above version. 1102 * </pre> 1103 * 1104 * <code>string revision = 3;</code> 1105 * 1106 * @return The revision. 1107 */ getRevision()1108 public java.lang.String getRevision() { 1109 java.lang.Object ref = revision_; 1110 if (!(ref instanceof java.lang.String)) { 1111 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 1112 java.lang.String s = bs.toStringUtf8(); 1113 revision_ = s; 1114 return s; 1115 } else { 1116 return (java.lang.String) ref; 1117 } 1118 } 1119 /** 1120 * 1121 * 1122 * <pre> 1123 * The iteration of the package build from the above version. 1124 * </pre> 1125 * 1126 * <code>string revision = 3;</code> 1127 * 1128 * @return The bytes for revision. 1129 */ getRevisionBytes()1130 public com.google.protobuf.ByteString getRevisionBytes() { 1131 java.lang.Object ref = revision_; 1132 if (ref instanceof String) { 1133 com.google.protobuf.ByteString b = 1134 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 1135 revision_ = b; 1136 return b; 1137 } else { 1138 return (com.google.protobuf.ByteString) ref; 1139 } 1140 } 1141 /** 1142 * 1143 * 1144 * <pre> 1145 * The iteration of the package build from the above version. 1146 * </pre> 1147 * 1148 * <code>string revision = 3;</code> 1149 * 1150 * @param value The revision to set. 1151 * @return This builder for chaining. 1152 */ setRevision(java.lang.String value)1153 public Builder setRevision(java.lang.String value) { 1154 if (value == null) { 1155 throw new NullPointerException(); 1156 } 1157 revision_ = value; 1158 bitField0_ |= 0x00000004; 1159 onChanged(); 1160 return this; 1161 } 1162 /** 1163 * 1164 * 1165 * <pre> 1166 * The iteration of the package build from the above version. 1167 * </pre> 1168 * 1169 * <code>string revision = 3;</code> 1170 * 1171 * @return This builder for chaining. 1172 */ clearRevision()1173 public Builder clearRevision() { 1174 revision_ = getDefaultInstance().getRevision(); 1175 bitField0_ = (bitField0_ & ~0x00000004); 1176 onChanged(); 1177 return this; 1178 } 1179 /** 1180 * 1181 * 1182 * <pre> 1183 * The iteration of the package build from the above version. 1184 * </pre> 1185 * 1186 * <code>string revision = 3;</code> 1187 * 1188 * @param value The bytes for revision to set. 1189 * @return This builder for chaining. 1190 */ setRevisionBytes(com.google.protobuf.ByteString value)1191 public Builder setRevisionBytes(com.google.protobuf.ByteString value) { 1192 if (value == null) { 1193 throw new NullPointerException(); 1194 } 1195 checkByteStringIsUtf8(value); 1196 revision_ = value; 1197 bitField0_ |= 0x00000004; 1198 onChanged(); 1199 return this; 1200 } 1201 1202 private boolean inclusive_; 1203 /** 1204 * 1205 * 1206 * <pre> 1207 * Whether this version is specifying part of an inclusive range. Grafeas 1208 * does not have the capability to specify version ranges; instead we have 1209 * fields that specify start version and end versions. At times this is 1210 * insufficient - we also need to specify whether the version is included in 1211 * the range or is excluded from the range. This boolean is expected to be set 1212 * to true when the version is included in a range. 1213 * </pre> 1214 * 1215 * <code>bool inclusive = 6;</code> 1216 * 1217 * @return The inclusive. 1218 */ 1219 @java.lang.Override getInclusive()1220 public boolean getInclusive() { 1221 return inclusive_; 1222 } 1223 /** 1224 * 1225 * 1226 * <pre> 1227 * Whether this version is specifying part of an inclusive range. Grafeas 1228 * does not have the capability to specify version ranges; instead we have 1229 * fields that specify start version and end versions. At times this is 1230 * insufficient - we also need to specify whether the version is included in 1231 * the range or is excluded from the range. This boolean is expected to be set 1232 * to true when the version is included in a range. 1233 * </pre> 1234 * 1235 * <code>bool inclusive = 6;</code> 1236 * 1237 * @param value The inclusive to set. 1238 * @return This builder for chaining. 1239 */ setInclusive(boolean value)1240 public Builder setInclusive(boolean value) { 1241 1242 inclusive_ = value; 1243 bitField0_ |= 0x00000008; 1244 onChanged(); 1245 return this; 1246 } 1247 /** 1248 * 1249 * 1250 * <pre> 1251 * Whether this version is specifying part of an inclusive range. Grafeas 1252 * does not have the capability to specify version ranges; instead we have 1253 * fields that specify start version and end versions. At times this is 1254 * insufficient - we also need to specify whether the version is included in 1255 * the range or is excluded from the range. This boolean is expected to be set 1256 * to true when the version is included in a range. 1257 * </pre> 1258 * 1259 * <code>bool inclusive = 6;</code> 1260 * 1261 * @return This builder for chaining. 1262 */ clearInclusive()1263 public Builder clearInclusive() { 1264 bitField0_ = (bitField0_ & ~0x00000008); 1265 inclusive_ = false; 1266 onChanged(); 1267 return this; 1268 } 1269 1270 private int kind_ = 0; 1271 /** 1272 * 1273 * 1274 * <pre> 1275 * Required. Distinguishes between sentinel MIN/MAX versions and normal 1276 * versions. 1277 * </pre> 1278 * 1279 * <code>.grafeas.v1.Version.VersionKind kind = 4;</code> 1280 * 1281 * @return The enum numeric value on the wire for kind. 1282 */ 1283 @java.lang.Override getKindValue()1284 public int getKindValue() { 1285 return kind_; 1286 } 1287 /** 1288 * 1289 * 1290 * <pre> 1291 * Required. Distinguishes between sentinel MIN/MAX versions and normal 1292 * versions. 1293 * </pre> 1294 * 1295 * <code>.grafeas.v1.Version.VersionKind kind = 4;</code> 1296 * 1297 * @param value The enum numeric value on the wire for kind to set. 1298 * @return This builder for chaining. 1299 */ setKindValue(int value)1300 public Builder setKindValue(int value) { 1301 kind_ = value; 1302 bitField0_ |= 0x00000010; 1303 onChanged(); 1304 return this; 1305 } 1306 /** 1307 * 1308 * 1309 * <pre> 1310 * Required. Distinguishes between sentinel MIN/MAX versions and normal 1311 * versions. 1312 * </pre> 1313 * 1314 * <code>.grafeas.v1.Version.VersionKind kind = 4;</code> 1315 * 1316 * @return The kind. 1317 */ 1318 @java.lang.Override getKind()1319 public io.grafeas.v1.Version.VersionKind getKind() { 1320 io.grafeas.v1.Version.VersionKind result = io.grafeas.v1.Version.VersionKind.forNumber(kind_); 1321 return result == null ? io.grafeas.v1.Version.VersionKind.UNRECOGNIZED : result; 1322 } 1323 /** 1324 * 1325 * 1326 * <pre> 1327 * Required. Distinguishes between sentinel MIN/MAX versions and normal 1328 * versions. 1329 * </pre> 1330 * 1331 * <code>.grafeas.v1.Version.VersionKind kind = 4;</code> 1332 * 1333 * @param value The kind to set. 1334 * @return This builder for chaining. 1335 */ setKind(io.grafeas.v1.Version.VersionKind value)1336 public Builder setKind(io.grafeas.v1.Version.VersionKind value) { 1337 if (value == null) { 1338 throw new NullPointerException(); 1339 } 1340 bitField0_ |= 0x00000010; 1341 kind_ = value.getNumber(); 1342 onChanged(); 1343 return this; 1344 } 1345 /** 1346 * 1347 * 1348 * <pre> 1349 * Required. Distinguishes between sentinel MIN/MAX versions and normal 1350 * versions. 1351 * </pre> 1352 * 1353 * <code>.grafeas.v1.Version.VersionKind kind = 4;</code> 1354 * 1355 * @return This builder for chaining. 1356 */ clearKind()1357 public Builder clearKind() { 1358 bitField0_ = (bitField0_ & ~0x00000010); 1359 kind_ = 0; 1360 onChanged(); 1361 return this; 1362 } 1363 1364 private java.lang.Object fullName_ = ""; 1365 /** 1366 * 1367 * 1368 * <pre> 1369 * Human readable version string. This string is of the form 1370 * <epoch>:<name>-<revision> and is only set when kind is NORMAL. 1371 * </pre> 1372 * 1373 * <code>string full_name = 5;</code> 1374 * 1375 * @return The fullName. 1376 */ getFullName()1377 public java.lang.String getFullName() { 1378 java.lang.Object ref = fullName_; 1379 if (!(ref instanceof java.lang.String)) { 1380 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 1381 java.lang.String s = bs.toStringUtf8(); 1382 fullName_ = s; 1383 return s; 1384 } else { 1385 return (java.lang.String) ref; 1386 } 1387 } 1388 /** 1389 * 1390 * 1391 * <pre> 1392 * Human readable version string. This string is of the form 1393 * <epoch>:<name>-<revision> and is only set when kind is NORMAL. 1394 * </pre> 1395 * 1396 * <code>string full_name = 5;</code> 1397 * 1398 * @return The bytes for fullName. 1399 */ getFullNameBytes()1400 public com.google.protobuf.ByteString getFullNameBytes() { 1401 java.lang.Object ref = fullName_; 1402 if (ref instanceof String) { 1403 com.google.protobuf.ByteString b = 1404 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 1405 fullName_ = b; 1406 return b; 1407 } else { 1408 return (com.google.protobuf.ByteString) ref; 1409 } 1410 } 1411 /** 1412 * 1413 * 1414 * <pre> 1415 * Human readable version string. This string is of the form 1416 * <epoch>:<name>-<revision> and is only set when kind is NORMAL. 1417 * </pre> 1418 * 1419 * <code>string full_name = 5;</code> 1420 * 1421 * @param value The fullName to set. 1422 * @return This builder for chaining. 1423 */ setFullName(java.lang.String value)1424 public Builder setFullName(java.lang.String value) { 1425 if (value == null) { 1426 throw new NullPointerException(); 1427 } 1428 fullName_ = value; 1429 bitField0_ |= 0x00000020; 1430 onChanged(); 1431 return this; 1432 } 1433 /** 1434 * 1435 * 1436 * <pre> 1437 * Human readable version string. This string is of the form 1438 * <epoch>:<name>-<revision> and is only set when kind is NORMAL. 1439 * </pre> 1440 * 1441 * <code>string full_name = 5;</code> 1442 * 1443 * @return This builder for chaining. 1444 */ clearFullName()1445 public Builder clearFullName() { 1446 fullName_ = getDefaultInstance().getFullName(); 1447 bitField0_ = (bitField0_ & ~0x00000020); 1448 onChanged(); 1449 return this; 1450 } 1451 /** 1452 * 1453 * 1454 * <pre> 1455 * Human readable version string. This string is of the form 1456 * <epoch>:<name>-<revision> and is only set when kind is NORMAL. 1457 * </pre> 1458 * 1459 * <code>string full_name = 5;</code> 1460 * 1461 * @param value The bytes for fullName to set. 1462 * @return This builder for chaining. 1463 */ setFullNameBytes(com.google.protobuf.ByteString value)1464 public Builder setFullNameBytes(com.google.protobuf.ByteString value) { 1465 if (value == null) { 1466 throw new NullPointerException(); 1467 } 1468 checkByteStringIsUtf8(value); 1469 fullName_ = value; 1470 bitField0_ |= 0x00000020; 1471 onChanged(); 1472 return this; 1473 } 1474 1475 @java.lang.Override setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields)1476 public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { 1477 return super.setUnknownFields(unknownFields); 1478 } 1479 1480 @java.lang.Override mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields)1481 public final Builder mergeUnknownFields( 1482 final com.google.protobuf.UnknownFieldSet unknownFields) { 1483 return super.mergeUnknownFields(unknownFields); 1484 } 1485 1486 // @@protoc_insertion_point(builder_scope:grafeas.v1.Version) 1487 } 1488 1489 // @@protoc_insertion_point(class_scope:grafeas.v1.Version) 1490 private static final io.grafeas.v1.Version DEFAULT_INSTANCE; 1491 1492 static { 1493 DEFAULT_INSTANCE = new io.grafeas.v1.Version(); 1494 } 1495 getDefaultInstance()1496 public static io.grafeas.v1.Version getDefaultInstance() { 1497 return DEFAULT_INSTANCE; 1498 } 1499 1500 private static final com.google.protobuf.Parser<Version> PARSER = 1501 new com.google.protobuf.AbstractParser<Version>() { 1502 @java.lang.Override 1503 public Version parsePartialFrom( 1504 com.google.protobuf.CodedInputStream input, 1505 com.google.protobuf.ExtensionRegistryLite extensionRegistry) 1506 throws com.google.protobuf.InvalidProtocolBufferException { 1507 Builder builder = newBuilder(); 1508 try { 1509 builder.mergeFrom(input, extensionRegistry); 1510 } catch (com.google.protobuf.InvalidProtocolBufferException e) { 1511 throw e.setUnfinishedMessage(builder.buildPartial()); 1512 } catch (com.google.protobuf.UninitializedMessageException e) { 1513 throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); 1514 } catch (java.io.IOException e) { 1515 throw new com.google.protobuf.InvalidProtocolBufferException(e) 1516 .setUnfinishedMessage(builder.buildPartial()); 1517 } 1518 return builder.buildPartial(); 1519 } 1520 }; 1521 parser()1522 public static com.google.protobuf.Parser<Version> parser() { 1523 return PARSER; 1524 } 1525 1526 @java.lang.Override getParserForType()1527 public com.google.protobuf.Parser<Version> getParserForType() { 1528 return PARSER; 1529 } 1530 1531 @java.lang.Override getDefaultInstanceForType()1532 public io.grafeas.v1.Version getDefaultInstanceForType() { 1533 return DEFAULT_INSTANCE; 1534 } 1535 } 1536