From 8a7f0358ca0d33e20b430c6c48423b349dccc78e Mon Sep 17 00:00:00 2001 From: Yoshi Automation Bot <44816363+yoshi-automation@users.noreply.github.com> Date: Fri, 29 Mar 2019 01:09:02 -0700 Subject: [PATCH] Regenerate language client (#4802) --- .../language/v1/AnalyzeEntitiesRequest.java | 29 +++--- .../language/v1/AnalyzeEntitiesResponse.java | 38 ++++---- .../v1/AnalyzeEntitySentimentRequest.java | 29 +++--- .../v1/AnalyzeEntitySentimentResponse.java | 38 ++++---- .../language/v1/AnalyzeSentimentRequest.java | 29 +++--- .../language/v1/AnalyzeSentimentResponse.java | 44 +++++---- .../language/v1/AnalyzeSyntaxRequest.java | 29 +++--- .../language/v1/AnalyzeSyntaxResponse.java | 53 +++++------ .../language/v1/AnnotateTextRequest.java | 74 +++++++-------- .../language/v1/AnnotateTextResponse.java | 89 ++++++++----------- .../language/v1/ClassificationCategory.java | 30 +++---- .../language/v1/ClassifyTextRequest.java | 27 +++--- .../language/v1/ClassifyTextResponse.java | 36 ++++---- .../cloud/language/v1/DependencyEdge.java | 26 +++--- .../google/cloud/language/v1/Document.java | 32 ++++--- .../com/google/cloud/language/v1/Entity.java | 57 ++++++------ .../cloud/language/v1/EntityMention.java | 35 ++++---- .../cloud/language/v1/PartOfSpeech.java | 45 +++++----- .../google/cloud/language/v1/Sentence.java | 33 ++++--- .../google/cloud/language/v1/Sentiment.java | 38 ++++---- .../google/cloud/language/v1/TextSpan.java | 26 +++--- .../com/google/cloud/language/v1/Token.java | 41 +++++---- .../v1beta2/AnalyzeEntitiesRequest.java | 29 +++--- .../v1beta2/AnalyzeEntitiesResponse.java | 38 ++++---- .../AnalyzeEntitySentimentRequest.java | 29 +++--- .../AnalyzeEntitySentimentResponse.java | 38 ++++---- .../v1beta2/AnalyzeSentimentRequest.java | 29 +++--- .../v1beta2/AnalyzeSentimentResponse.java | 44 +++++---- .../v1beta2/AnalyzeSyntaxRequest.java | 29 +++--- .../v1beta2/AnalyzeSyntaxResponse.java | 53 +++++------ .../language/v1beta2/AnnotateTextRequest.java | 74 +++++++-------- .../v1beta2/AnnotateTextResponse.java | 89 ++++++++----------- .../v1beta2/ClassificationCategory.java | 30 +++---- .../language/v1beta2/ClassifyTextRequest.java | 27 +++--- .../v1beta2/ClassifyTextResponse.java | 36 ++++---- .../language/v1beta2/DependencyEdge.java | 26 +++--- .../cloud/language/v1beta2/Document.java | 32 ++++--- .../google/cloud/language/v1beta2/Entity.java | 57 ++++++------ .../cloud/language/v1beta2/EntityMention.java | 35 ++++---- .../cloud/language/v1beta2/PartOfSpeech.java | 45 +++++----- .../cloud/language/v1beta2/Sentence.java | 33 ++++--- .../cloud/language/v1beta2/Sentiment.java | 38 ++++---- .../cloud/language/v1beta2/TextSpan.java | 26 +++--- .../google/cloud/language/v1beta2/Token.java | 41 +++++---- .../google-cloud-language/synth.metadata | 10 +-- 45 files changed, 805 insertions(+), 961 deletions(-) diff --git a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeEntitiesRequest.java b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeEntitiesRequest.java index 17ac45b85b31..f11407db0fbf 100644 --- a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeEntitiesRequest.java +++ b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeEntitiesRequest.java @@ -75,7 +75,7 @@ private AnalyzeEntitiesRequest( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -229,14 +229,13 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1.AnalyzeEntitiesRequest other = (com.google.cloud.language.v1.AnalyzeEntitiesRequest) obj; - boolean result = true; - result = result && (hasDocument() == other.hasDocument()); + if (hasDocument() != other.hasDocument()) return false; if (hasDocument()) { - result = result && getDocument().equals(other.getDocument()); + if (!getDocument().equals(other.getDocument())) return false; } - result = result && encodingType_ == other.encodingType_; - result = result && unknownFields.equals(other.unknownFields); - return result; + if (encodingType_ != other.encodingType_) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -444,35 +443,35 @@ public com.google.cloud.language.v1.AnalyzeEntitiesRequest buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -524,7 +523,7 @@ public Builder mergeFrom( return this; } - private com.google.cloud.language.v1.Document document_ = null; + private com.google.cloud.language.v1.Document document_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1.Document, com.google.cloud.language.v1.Document.Builder, @@ -783,7 +782,7 @@ public Builder clearEncodingType() { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeEntitiesResponse.java b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeEntitiesResponse.java index a0c9726c19fb..e7873bf78d76 100644 --- a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeEntitiesResponse.java +++ b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeEntitiesResponse.java @@ -53,7 +53,7 @@ private AnalyzeEntitiesResponse( break; case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { entities_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000001; } @@ -71,7 +71,7 @@ private AnalyzeEntitiesResponse( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -83,7 +83,7 @@ private AnalyzeEntitiesResponse( } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { - if (((mutable_bitField0_ & 0x00000001) == 0x00000001)) { + if (((mutable_bitField0_ & 0x00000001) != 0)) { entities_ = java.util.Collections.unmodifiableList(entities_); } this.unknownFields = unknownFields.build(); @@ -271,11 +271,10 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1.AnalyzeEntitiesResponse other = (com.google.cloud.language.v1.AnalyzeEntitiesResponse) obj; - boolean result = true; - result = result && getEntitiesList().equals(other.getEntitiesList()); - result = result && getLanguage().equals(other.getLanguage()); - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!getEntitiesList().equals(other.getEntitiesList())) return false; + if (!getLanguage().equals(other.getLanguage())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -476,7 +475,7 @@ public com.google.cloud.language.v1.AnalyzeEntitiesResponse buildPartial() { int from_bitField0_ = bitField0_; int to_bitField0_ = 0; if (entitiesBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { + if (((bitField0_ & 0x00000001) != 0)) { entities_ = java.util.Collections.unmodifiableList(entities_); bitField0_ = (bitField0_ & ~0x00000001); } @@ -492,35 +491,35 @@ public com.google.cloud.language.v1.AnalyzeEntitiesResponse buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -603,7 +602,7 @@ public Builder mergeFrom( java.util.Collections.emptyList(); private void ensureEntitiesIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { + if (!((bitField0_ & 0x00000001) != 0)) { entities_ = new java.util.ArrayList(entities_); bitField0_ |= 0x00000001; } @@ -941,10 +940,7 @@ public java.util.List getEntitiesBu com.google.cloud.language.v1.Entity, com.google.cloud.language.v1.Entity.Builder, com.google.cloud.language.v1.EntityOrBuilder>( - entities_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); + entities_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); entities_ = null; } return entitiesBuilder_; @@ -1061,7 +1057,7 @@ public Builder setLanguageBytes(com.google.protobuf.ByteString value) { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeEntitySentimentRequest.java b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeEntitySentimentRequest.java index 902e5d2b51d2..9dbac87557a5 100644 --- a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeEntitySentimentRequest.java +++ b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeEntitySentimentRequest.java @@ -75,7 +75,7 @@ private AnalyzeEntitySentimentRequest( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -229,14 +229,13 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1.AnalyzeEntitySentimentRequest other = (com.google.cloud.language.v1.AnalyzeEntitySentimentRequest) obj; - boolean result = true; - result = result && (hasDocument() == other.hasDocument()); + if (hasDocument() != other.hasDocument()) return false; if (hasDocument()) { - result = result && getDocument().equals(other.getDocument()); + if (!getDocument().equals(other.getDocument())) return false; } - result = result && encodingType_ == other.encodingType_; - result = result && unknownFields.equals(other.unknownFields); - return result; + if (encodingType_ != other.encodingType_) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -445,35 +444,35 @@ public com.google.cloud.language.v1.AnalyzeEntitySentimentRequest buildPartial() @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -525,7 +524,7 @@ public Builder mergeFrom( return this; } - private com.google.cloud.language.v1.Document document_ = null; + private com.google.cloud.language.v1.Document document_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1.Document, com.google.cloud.language.v1.Document.Builder, @@ -784,7 +783,7 @@ public Builder clearEncodingType() { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeEntitySentimentResponse.java b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeEntitySentimentResponse.java index c700d00782d0..d10ffeb804f3 100644 --- a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeEntitySentimentResponse.java +++ b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeEntitySentimentResponse.java @@ -54,7 +54,7 @@ private AnalyzeEntitySentimentResponse( break; case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { entities_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000001; } @@ -72,7 +72,7 @@ private AnalyzeEntitySentimentResponse( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -84,7 +84,7 @@ private AnalyzeEntitySentimentResponse( } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { - if (((mutable_bitField0_ & 0x00000001) == 0x00000001)) { + if (((mutable_bitField0_ & 0x00000001) != 0)) { entities_ = java.util.Collections.unmodifiableList(entities_); } this.unknownFields = unknownFields.build(); @@ -272,11 +272,10 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1.AnalyzeEntitySentimentResponse other = (com.google.cloud.language.v1.AnalyzeEntitySentimentResponse) obj; - boolean result = true; - result = result && getEntitiesList().equals(other.getEntitiesList()); - result = result && getLanguage().equals(other.getLanguage()); - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!getEntitiesList().equals(other.getEntitiesList())) return false; + if (!getLanguage().equals(other.getLanguage())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -478,7 +477,7 @@ public com.google.cloud.language.v1.AnalyzeEntitySentimentResponse buildPartial( int from_bitField0_ = bitField0_; int to_bitField0_ = 0; if (entitiesBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { + if (((bitField0_ & 0x00000001) != 0)) { entities_ = java.util.Collections.unmodifiableList(entities_); bitField0_ = (bitField0_ & ~0x00000001); } @@ -494,35 +493,35 @@ public com.google.cloud.language.v1.AnalyzeEntitySentimentResponse buildPartial( @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -605,7 +604,7 @@ public Builder mergeFrom( java.util.Collections.emptyList(); private void ensureEntitiesIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { + if (!((bitField0_ & 0x00000001) != 0)) { entities_ = new java.util.ArrayList(entities_); bitField0_ |= 0x00000001; } @@ -943,10 +942,7 @@ public java.util.List getEntitiesBu com.google.cloud.language.v1.Entity, com.google.cloud.language.v1.Entity.Builder, com.google.cloud.language.v1.EntityOrBuilder>( - entities_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); + entities_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); entities_ = null; } return entitiesBuilder_; @@ -1063,7 +1059,7 @@ public Builder setLanguageBytes(com.google.protobuf.ByteString value) { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeSentimentRequest.java b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeSentimentRequest.java index 2299df646979..2b145555c10a 100644 --- a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeSentimentRequest.java +++ b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeSentimentRequest.java @@ -75,7 +75,7 @@ private AnalyzeSentimentRequest( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -229,14 +229,13 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1.AnalyzeSentimentRequest other = (com.google.cloud.language.v1.AnalyzeSentimentRequest) obj; - boolean result = true; - result = result && (hasDocument() == other.hasDocument()); + if (hasDocument() != other.hasDocument()) return false; if (hasDocument()) { - result = result && getDocument().equals(other.getDocument()); + if (!getDocument().equals(other.getDocument())) return false; } - result = result && encodingType_ == other.encodingType_; - result = result && unknownFields.equals(other.unknownFields); - return result; + if (encodingType_ != other.encodingType_) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -444,35 +443,35 @@ public com.google.cloud.language.v1.AnalyzeSentimentRequest buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -524,7 +523,7 @@ public Builder mergeFrom( return this; } - private com.google.cloud.language.v1.Document document_ = null; + private com.google.cloud.language.v1.Document document_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1.Document, com.google.cloud.language.v1.Document.Builder, @@ -783,7 +782,7 @@ public Builder clearEncodingType() { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeSentimentResponse.java b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeSentimentResponse.java index 55ebd12da0df..ab7bdf41f103 100644 --- a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeSentimentResponse.java +++ b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeSentimentResponse.java @@ -76,7 +76,7 @@ private AnalyzeSentimentResponse( } case 26: { - if (!((mutable_bitField0_ & 0x00000004) == 0x00000004)) { + if (!((mutable_bitField0_ & 0x00000004) != 0)) { sentences_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000004; } @@ -87,7 +87,7 @@ private AnalyzeSentimentResponse( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -99,7 +99,7 @@ private AnalyzeSentimentResponse( } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { - if (((mutable_bitField0_ & 0x00000004) == 0x00000004)) { + if (((mutable_bitField0_ & 0x00000004) != 0)) { sentences_ = java.util.Collections.unmodifiableList(sentences_); } this.unknownFields = unknownFields.build(); @@ -334,15 +334,14 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1.AnalyzeSentimentResponse other = (com.google.cloud.language.v1.AnalyzeSentimentResponse) obj; - boolean result = true; - result = result && (hasDocumentSentiment() == other.hasDocumentSentiment()); + if (hasDocumentSentiment() != other.hasDocumentSentiment()) return false; if (hasDocumentSentiment()) { - result = result && getDocumentSentiment().equals(other.getDocumentSentiment()); + if (!getDocumentSentiment().equals(other.getDocumentSentiment())) return false; } - result = result && getLanguage().equals(other.getLanguage()); - result = result && getSentencesList().equals(other.getSentencesList()); - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!getLanguage().equals(other.getLanguage())) return false; + if (!getSentencesList().equals(other.getSentencesList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -560,7 +559,7 @@ public com.google.cloud.language.v1.AnalyzeSentimentResponse buildPartial() { } result.language_ = language_; if (sentencesBuilder_ == null) { - if (((bitField0_ & 0x00000004) == 0x00000004)) { + if (((bitField0_ & 0x00000004) != 0)) { sentences_ = java.util.Collections.unmodifiableList(sentences_); bitField0_ = (bitField0_ & ~0x00000004); } @@ -575,35 +574,35 @@ public com.google.cloud.language.v1.AnalyzeSentimentResponse buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -685,7 +684,7 @@ public Builder mergeFrom( private int bitField0_; - private com.google.cloud.language.v1.Sentiment documentSentiment_ = null; + private com.google.cloud.language.v1.Sentiment documentSentiment_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1.Sentiment, com.google.cloud.language.v1.Sentiment.Builder, @@ -980,7 +979,7 @@ public Builder setLanguageBytes(com.google.protobuf.ByteString value) { java.util.Collections.emptyList(); private void ensureSentencesIsMutable() { - if (!((bitField0_ & 0x00000004) == 0x00000004)) { + if (!((bitField0_ & 0x00000004) != 0)) { sentences_ = new java.util.ArrayList(sentences_); bitField0_ |= 0x00000004; } @@ -1318,10 +1317,7 @@ public java.util.List getSentence com.google.cloud.language.v1.Sentence, com.google.cloud.language.v1.Sentence.Builder, com.google.cloud.language.v1.SentenceOrBuilder>( - sentences_, - ((bitField0_ & 0x00000004) == 0x00000004), - getParentForChildren(), - isClean()); + sentences_, ((bitField0_ & 0x00000004) != 0), getParentForChildren(), isClean()); sentences_ = null; } return sentencesBuilder_; @@ -1329,7 +1325,7 @@ public java.util.List getSentence @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeSyntaxRequest.java b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeSyntaxRequest.java index 059143033ae4..1de0af1bcdda 100644 --- a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeSyntaxRequest.java +++ b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeSyntaxRequest.java @@ -75,7 +75,7 @@ private AnalyzeSyntaxRequest( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -229,14 +229,13 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1.AnalyzeSyntaxRequest other = (com.google.cloud.language.v1.AnalyzeSyntaxRequest) obj; - boolean result = true; - result = result && (hasDocument() == other.hasDocument()); + if (hasDocument() != other.hasDocument()) return false; if (hasDocument()) { - result = result && getDocument().equals(other.getDocument()); + if (!getDocument().equals(other.getDocument())) return false; } - result = result && encodingType_ == other.encodingType_; - result = result && unknownFields.equals(other.unknownFields); - return result; + if (encodingType_ != other.encodingType_) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -444,35 +443,35 @@ public com.google.cloud.language.v1.AnalyzeSyntaxRequest buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -524,7 +523,7 @@ public Builder mergeFrom( return this; } - private com.google.cloud.language.v1.Document document_ = null; + private com.google.cloud.language.v1.Document document_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1.Document, com.google.cloud.language.v1.Document.Builder, @@ -783,7 +782,7 @@ public Builder clearEncodingType() { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeSyntaxResponse.java b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeSyntaxResponse.java index e77f0cbd7e37..9b047ee9a067 100644 --- a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeSyntaxResponse.java +++ b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnalyzeSyntaxResponse.java @@ -54,7 +54,7 @@ private AnalyzeSyntaxResponse( break; case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { sentences_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000001; } @@ -65,7 +65,7 @@ private AnalyzeSyntaxResponse( } case 18: { - if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) { + if (!((mutable_bitField0_ & 0x00000002) != 0)) { tokens_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000002; } @@ -83,7 +83,7 @@ private AnalyzeSyntaxResponse( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -95,10 +95,10 @@ private AnalyzeSyntaxResponse( } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { - if (((mutable_bitField0_ & 0x00000001) == 0x00000001)) { + if (((mutable_bitField0_ & 0x00000001) != 0)) { sentences_ = java.util.Collections.unmodifiableList(sentences_); } - if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) { + if (((mutable_bitField0_ & 0x00000002) != 0)) { tokens_ = java.util.Collections.unmodifiableList(tokens_); } this.unknownFields = unknownFields.build(); @@ -356,12 +356,11 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1.AnalyzeSyntaxResponse other = (com.google.cloud.language.v1.AnalyzeSyntaxResponse) obj; - boolean result = true; - result = result && getSentencesList().equals(other.getSentencesList()); - result = result && getTokensList().equals(other.getTokensList()); - result = result && getLanguage().equals(other.getLanguage()); - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!getSentencesList().equals(other.getSentencesList())) return false; + if (!getTokensList().equals(other.getTokensList())) return false; + if (!getLanguage().equals(other.getLanguage())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -573,7 +572,7 @@ public com.google.cloud.language.v1.AnalyzeSyntaxResponse buildPartial() { int from_bitField0_ = bitField0_; int to_bitField0_ = 0; if (sentencesBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { + if (((bitField0_ & 0x00000001) != 0)) { sentences_ = java.util.Collections.unmodifiableList(sentences_); bitField0_ = (bitField0_ & ~0x00000001); } @@ -582,7 +581,7 @@ public com.google.cloud.language.v1.AnalyzeSyntaxResponse buildPartial() { result.sentences_ = sentencesBuilder_.build(); } if (tokensBuilder_ == null) { - if (((bitField0_ & 0x00000002) == 0x00000002)) { + if (((bitField0_ & 0x00000002) != 0)) { tokens_ = java.util.Collections.unmodifiableList(tokens_); bitField0_ = (bitField0_ & ~0x00000002); } @@ -598,35 +597,35 @@ public com.google.cloud.language.v1.AnalyzeSyntaxResponse buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -736,7 +735,7 @@ public Builder mergeFrom( java.util.Collections.emptyList(); private void ensureSentencesIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { + if (!((bitField0_ & 0x00000001) != 0)) { sentences_ = new java.util.ArrayList(sentences_); bitField0_ |= 0x00000001; } @@ -1074,10 +1073,7 @@ public java.util.List getSentence com.google.cloud.language.v1.Sentence, com.google.cloud.language.v1.Sentence.Builder, com.google.cloud.language.v1.SentenceOrBuilder>( - sentences_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); + sentences_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); sentences_ = null; } return sentencesBuilder_; @@ -1087,7 +1083,7 @@ public java.util.List getSentence java.util.Collections.emptyList(); private void ensureTokensIsMutable() { - if (!((bitField0_ & 0x00000002) == 0x00000002)) { + if (!((bitField0_ & 0x00000002) != 0)) { tokens_ = new java.util.ArrayList(tokens_); bitField0_ |= 0x00000002; } @@ -1425,10 +1421,7 @@ public java.util.List getTokensBuild com.google.cloud.language.v1.Token, com.google.cloud.language.v1.Token.Builder, com.google.cloud.language.v1.TokenOrBuilder>( - tokens_, - ((bitField0_ & 0x00000002) == 0x00000002), - getParentForChildren(), - isClean()); + tokens_, ((bitField0_ & 0x00000002) != 0), getParentForChildren(), isClean()); tokens_ = null; } return tokensBuilder_; @@ -1545,7 +1538,7 @@ public Builder setLanguageBytes(com.google.protobuf.ByteString value) { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnnotateTextRequest.java b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnnotateTextRequest.java index 723debc1cad2..910e1d68a1a6 100644 --- a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnnotateTextRequest.java +++ b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnnotateTextRequest.java @@ -93,7 +93,7 @@ private AnnotateTextRequest( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -205,13 +205,7 @@ private Features(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } - private Features() { - extractSyntax_ = false; - extractEntities_ = false; - extractDocumentSentiment_ = false; - extractEntitySentiment_ = false; - classifyText_ = false; - } + private Features() {} @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { @@ -264,7 +258,7 @@ private Features( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -440,14 +434,13 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1.AnnotateTextRequest.Features other = (com.google.cloud.language.v1.AnnotateTextRequest.Features) obj; - boolean result = true; - result = result && (getExtractSyntax() == other.getExtractSyntax()); - result = result && (getExtractEntities() == other.getExtractEntities()); - result = result && (getExtractDocumentSentiment() == other.getExtractDocumentSentiment()); - result = result && (getExtractEntitySentiment() == other.getExtractEntitySentiment()); - result = result && (getClassifyText() == other.getClassifyText()); - result = result && unknownFields.equals(other.unknownFields); - return result; + if (getExtractSyntax() != other.getExtractSyntax()) return false; + if (getExtractEntities() != other.getExtractEntities()) return false; + if (getExtractDocumentSentiment() != other.getExtractDocumentSentiment()) return false; + if (getExtractEntitySentiment() != other.getExtractEntitySentiment()) return false; + if (getClassifyText() != other.getClassifyText()) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -664,23 +657,23 @@ public com.google.cloud.language.v1.AnnotateTextRequest.Features buildPartial() @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override @@ -688,13 +681,13 @@ public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -978,7 +971,7 @@ public Builder clearClassifyText() { @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override @@ -1196,18 +1189,17 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1.AnnotateTextRequest other = (com.google.cloud.language.v1.AnnotateTextRequest) obj; - boolean result = true; - result = result && (hasDocument() == other.hasDocument()); + if (hasDocument() != other.hasDocument()) return false; if (hasDocument()) { - result = result && getDocument().equals(other.getDocument()); + if (!getDocument().equals(other.getDocument())) return false; } - result = result && (hasFeatures() == other.hasFeatures()); + if (hasFeatures() != other.hasFeatures()) return false; if (hasFeatures()) { - result = result && getFeatures().equals(other.getFeatures()); + if (!getFeatures().equals(other.getFeatures())) return false; } - result = result && encodingType_ == other.encodingType_; - result = result && unknownFields.equals(other.unknownFields); - return result; + if (encodingType_ != other.encodingType_) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -1431,35 +1423,35 @@ public com.google.cloud.language.v1.AnnotateTextRequest buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -1513,7 +1505,7 @@ public Builder mergeFrom( return this; } - private com.google.cloud.language.v1.Document document_ = null; + private com.google.cloud.language.v1.Document document_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1.Document, com.google.cloud.language.v1.Document.Builder, @@ -1694,7 +1686,7 @@ public com.google.cloud.language.v1.DocumentOrBuilder getDocumentOrBuilder() { return documentBuilder_; } - private com.google.cloud.language.v1.AnnotateTextRequest.Features features_ = null; + private com.google.cloud.language.v1.AnnotateTextRequest.Features features_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1.AnnotateTextRequest.Features, com.google.cloud.language.v1.AnnotateTextRequest.Features.Builder, @@ -1955,7 +1947,7 @@ public Builder clearEncodingType() { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnnotateTextResponse.java b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnnotateTextResponse.java index 7040ca98f744..26f4eff5b45c 100644 --- a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnnotateTextResponse.java +++ b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/AnnotateTextResponse.java @@ -56,7 +56,7 @@ private AnnotateTextResponse( break; case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { sentences_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000001; } @@ -67,7 +67,7 @@ private AnnotateTextResponse( } case 18: { - if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) { + if (!((mutable_bitField0_ & 0x00000002) != 0)) { tokens_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000002; } @@ -78,7 +78,7 @@ private AnnotateTextResponse( } case 26: { - if (!((mutable_bitField0_ & 0x00000004) == 0x00000004)) { + if (!((mutable_bitField0_ & 0x00000004) != 0)) { entities_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000004; } @@ -112,7 +112,7 @@ private AnnotateTextResponse( } case 50: { - if (!((mutable_bitField0_ & 0x00000020) == 0x00000020)) { + if (!((mutable_bitField0_ & 0x00000020) != 0)) { categories_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000020; @@ -125,7 +125,7 @@ private AnnotateTextResponse( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -137,16 +137,16 @@ private AnnotateTextResponse( } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { - if (((mutable_bitField0_ & 0x00000001) == 0x00000001)) { + if (((mutable_bitField0_ & 0x00000001) != 0)) { sentences_ = java.util.Collections.unmodifiableList(sentences_); } - if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) { + if (((mutable_bitField0_ & 0x00000002) != 0)) { tokens_ = java.util.Collections.unmodifiableList(tokens_); } - if (((mutable_bitField0_ & 0x00000004) == 0x00000004)) { + if (((mutable_bitField0_ & 0x00000004) != 0)) { entities_ = java.util.Collections.unmodifiableList(entities_); } - if (((mutable_bitField0_ & 0x00000020) == 0x00000020)) { + if (((mutable_bitField0_ & 0x00000020) != 0)) { categories_ = java.util.Collections.unmodifiableList(categories_); } this.unknownFields = unknownFields.build(); @@ -620,18 +620,17 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1.AnnotateTextResponse other = (com.google.cloud.language.v1.AnnotateTextResponse) obj; - boolean result = true; - result = result && getSentencesList().equals(other.getSentencesList()); - result = result && getTokensList().equals(other.getTokensList()); - result = result && getEntitiesList().equals(other.getEntitiesList()); - result = result && (hasDocumentSentiment() == other.hasDocumentSentiment()); + if (!getSentencesList().equals(other.getSentencesList())) return false; + if (!getTokensList().equals(other.getTokensList())) return false; + if (!getEntitiesList().equals(other.getEntitiesList())) return false; + if (hasDocumentSentiment() != other.hasDocumentSentiment()) return false; if (hasDocumentSentiment()) { - result = result && getDocumentSentiment().equals(other.getDocumentSentiment()); + if (!getDocumentSentiment().equals(other.getDocumentSentiment())) return false; } - result = result && getLanguage().equals(other.getLanguage()); - result = result && getCategoriesList().equals(other.getCategoriesList()); - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!getLanguage().equals(other.getLanguage())) return false; + if (!getCategoriesList().equals(other.getCategoriesList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -875,7 +874,7 @@ public com.google.cloud.language.v1.AnnotateTextResponse buildPartial() { int from_bitField0_ = bitField0_; int to_bitField0_ = 0; if (sentencesBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { + if (((bitField0_ & 0x00000001) != 0)) { sentences_ = java.util.Collections.unmodifiableList(sentences_); bitField0_ = (bitField0_ & ~0x00000001); } @@ -884,7 +883,7 @@ public com.google.cloud.language.v1.AnnotateTextResponse buildPartial() { result.sentences_ = sentencesBuilder_.build(); } if (tokensBuilder_ == null) { - if (((bitField0_ & 0x00000002) == 0x00000002)) { + if (((bitField0_ & 0x00000002) != 0)) { tokens_ = java.util.Collections.unmodifiableList(tokens_); bitField0_ = (bitField0_ & ~0x00000002); } @@ -893,7 +892,7 @@ public com.google.cloud.language.v1.AnnotateTextResponse buildPartial() { result.tokens_ = tokensBuilder_.build(); } if (entitiesBuilder_ == null) { - if (((bitField0_ & 0x00000004) == 0x00000004)) { + if (((bitField0_ & 0x00000004) != 0)) { entities_ = java.util.Collections.unmodifiableList(entities_); bitField0_ = (bitField0_ & ~0x00000004); } @@ -908,7 +907,7 @@ public com.google.cloud.language.v1.AnnotateTextResponse buildPartial() { } result.language_ = language_; if (categoriesBuilder_ == null) { - if (((bitField0_ & 0x00000020) == 0x00000020)) { + if (((bitField0_ & 0x00000020) != 0)) { categories_ = java.util.Collections.unmodifiableList(categories_); bitField0_ = (bitField0_ & ~0x00000020); } @@ -923,35 +922,35 @@ public com.google.cloud.language.v1.AnnotateTextResponse buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -1118,7 +1117,7 @@ public Builder mergeFrom( java.util.Collections.emptyList(); private void ensureSentencesIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { + if (!((bitField0_ & 0x00000001) != 0)) { sentences_ = new java.util.ArrayList(sentences_); bitField0_ |= 0x00000001; } @@ -1474,10 +1473,7 @@ public java.util.List getSentence com.google.cloud.language.v1.Sentence, com.google.cloud.language.v1.Sentence.Builder, com.google.cloud.language.v1.SentenceOrBuilder>( - sentences_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); + sentences_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); sentences_ = null; } return sentencesBuilder_; @@ -1487,7 +1483,7 @@ public java.util.List getSentence java.util.Collections.emptyList(); private void ensureTokensIsMutable() { - if (!((bitField0_ & 0x00000002) == 0x00000002)) { + if (!((bitField0_ & 0x00000002) != 0)) { tokens_ = new java.util.ArrayList(tokens_); bitField0_ |= 0x00000002; } @@ -1861,10 +1857,7 @@ public java.util.List getTokensBuild com.google.cloud.language.v1.Token, com.google.cloud.language.v1.Token.Builder, com.google.cloud.language.v1.TokenOrBuilder>( - tokens_, - ((bitField0_ & 0x00000002) == 0x00000002), - getParentForChildren(), - isClean()); + tokens_, ((bitField0_ & 0x00000002) != 0), getParentForChildren(), isClean()); tokens_ = null; } return tokensBuilder_; @@ -1874,7 +1867,7 @@ public java.util.List getTokensBuild java.util.Collections.emptyList(); private void ensureEntitiesIsMutable() { - if (!((bitField0_ & 0x00000004) == 0x00000004)) { + if (!((bitField0_ & 0x00000004) != 0)) { entities_ = new java.util.ArrayList(entities_); bitField0_ |= 0x00000004; } @@ -2248,16 +2241,13 @@ public java.util.List getEntitiesBu com.google.cloud.language.v1.Entity, com.google.cloud.language.v1.Entity.Builder, com.google.cloud.language.v1.EntityOrBuilder>( - entities_, - ((bitField0_ & 0x00000004) == 0x00000004), - getParentForChildren(), - isClean()); + entities_, ((bitField0_ & 0x00000004) != 0), getParentForChildren(), isClean()); entities_ = null; } return entitiesBuilder_; } - private com.google.cloud.language.v1.Sentiment documentSentiment_ = null; + private com.google.cloud.language.v1.Sentiment documentSentiment_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1.Sentiment, com.google.cloud.language.v1.Sentiment.Builder, @@ -2561,7 +2551,7 @@ public Builder setLanguageBytes(com.google.protobuf.ByteString value) { java.util.Collections.emptyList(); private void ensureCategoriesIsMutable() { - if (!((bitField0_ & 0x00000020) == 0x00000020)) { + if (!((bitField0_ & 0x00000020) != 0)) { categories_ = new java.util.ArrayList( categories_); @@ -2909,10 +2899,7 @@ public com.google.cloud.language.v1.ClassificationCategory.Builder addCategories com.google.cloud.language.v1.ClassificationCategory, com.google.cloud.language.v1.ClassificationCategory.Builder, com.google.cloud.language.v1.ClassificationCategoryOrBuilder>( - categories_, - ((bitField0_ & 0x00000020) == 0x00000020), - getParentForChildren(), - isClean()); + categories_, ((bitField0_ & 0x00000020) != 0), getParentForChildren(), isClean()); categories_ = null; } return categoriesBuilder_; @@ -2920,7 +2907,7 @@ public com.google.cloud.language.v1.ClassificationCategory.Builder addCategories @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/ClassificationCategory.java b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/ClassificationCategory.java index ab38b272191c..ca0d2c4bca0d 100644 --- a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/ClassificationCategory.java +++ b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/ClassificationCategory.java @@ -24,7 +24,6 @@ private ClassificationCategory(com.google.protobuf.GeneratedMessageV3.Builder private ClassificationCategory() { name_ = ""; - confidence_ = 0F; } @java.lang.Override @@ -65,7 +64,7 @@ private ClassificationCategory( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -209,14 +208,11 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1.ClassificationCategory other = (com.google.cloud.language.v1.ClassificationCategory) obj; - boolean result = true; - result = result && getName().equals(other.getName()); - result = - result - && (java.lang.Float.floatToIntBits(getConfidence()) - == java.lang.Float.floatToIntBits(other.getConfidence())); - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!getName().equals(other.getName())) return false; + if (java.lang.Float.floatToIntBits(getConfidence()) + != java.lang.Float.floatToIntBits(other.getConfidence())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -414,35 +410,35 @@ public com.google.cloud.language.v1.ClassificationCategory buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -643,7 +639,7 @@ public Builder clearConfidence() { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/ClassifyTextRequest.java b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/ClassifyTextRequest.java index a8e8b31273b2..6d91a05a9bfb 100644 --- a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/ClassifyTextRequest.java +++ b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/ClassifyTextRequest.java @@ -66,7 +66,7 @@ private ClassifyTextRequest( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -184,13 +184,12 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1.ClassifyTextRequest other = (com.google.cloud.language.v1.ClassifyTextRequest) obj; - boolean result = true; - result = result && (hasDocument() == other.hasDocument()); + if (hasDocument() != other.hasDocument()) return false; if (hasDocument()) { - result = result && getDocument().equals(other.getDocument()); + if (!getDocument().equals(other.getDocument())) return false; } - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -393,35 +392,35 @@ public com.google.cloud.language.v1.ClassifyTextRequest buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -469,7 +468,7 @@ public Builder mergeFrom( return this; } - private com.google.cloud.language.v1.Document document_ = null; + private com.google.cloud.language.v1.Document document_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1.Document, com.google.cloud.language.v1.Document.Builder, @@ -652,7 +651,7 @@ public com.google.cloud.language.v1.DocumentOrBuilder getDocumentOrBuilder() { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/ClassifyTextResponse.java b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/ClassifyTextResponse.java index ff17eab96f31..9b504cf998da 100644 --- a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/ClassifyTextResponse.java +++ b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/ClassifyTextResponse.java @@ -52,7 +52,7 @@ private ClassifyTextResponse( break; case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { categories_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000001; @@ -65,7 +65,7 @@ private ClassifyTextResponse( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -77,7 +77,7 @@ private ClassifyTextResponse( } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { - if (((mutable_bitField0_ & 0x00000001) == 0x00000001)) { + if (((mutable_bitField0_ & 0x00000001) != 0)) { categories_ = java.util.Collections.unmodifiableList(categories_); } this.unknownFields = unknownFields.build(); @@ -210,10 +210,9 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1.ClassifyTextResponse other = (com.google.cloud.language.v1.ClassifyTextResponse) obj; - boolean result = true; - result = result && getCategoriesList().equals(other.getCategoriesList()); - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!getCategoriesList().equals(other.getCategoriesList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -409,7 +408,7 @@ public com.google.cloud.language.v1.ClassifyTextResponse buildPartial() { new com.google.cloud.language.v1.ClassifyTextResponse(this); int from_bitField0_ = bitField0_; if (categoriesBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { + if (((bitField0_ & 0x00000001) != 0)) { categories_ = java.util.Collections.unmodifiableList(categories_); bitField0_ = (bitField0_ & ~0x00000001); } @@ -423,35 +422,35 @@ public com.google.cloud.language.v1.ClassifyTextResponse buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -530,7 +529,7 @@ public Builder mergeFrom( java.util.Collections.emptyList(); private void ensureCategoriesIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { + if (!((bitField0_ & 0x00000001) != 0)) { categories_ = new java.util.ArrayList( categories_); @@ -878,10 +877,7 @@ public com.google.cloud.language.v1.ClassificationCategory.Builder addCategories com.google.cloud.language.v1.ClassificationCategory, com.google.cloud.language.v1.ClassificationCategory.Builder, com.google.cloud.language.v1.ClassificationCategoryOrBuilder>( - categories_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); + categories_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); categories_ = null; } return categoriesBuilder_; @@ -889,7 +885,7 @@ public com.google.cloud.language.v1.ClassificationCategory.Builder addCategories @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/DependencyEdge.java b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/DependencyEdge.java index 08cb5a88dd82..0f0822f12b40 100644 --- a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/DependencyEdge.java +++ b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/DependencyEdge.java @@ -25,7 +25,6 @@ private DependencyEdge(com.google.protobuf.GeneratedMessageV3.Builder builder } private DependencyEdge() { - headTokenIndex_ = 0; label_ = 0; } @@ -67,7 +66,7 @@ private DependencyEdge( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -2104,11 +2103,10 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1.DependencyEdge other = (com.google.cloud.language.v1.DependencyEdge) obj; - boolean result = true; - result = result && (getHeadTokenIndex() == other.getHeadTokenIndex()); - result = result && label_ == other.label_; - result = result && unknownFields.equals(other.unknownFields); - return result; + if (getHeadTokenIndex() != other.getHeadTokenIndex()) return false; + if (label_ != other.label_) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -2308,35 +2306,35 @@ public com.google.cloud.language.v1.DependencyEdge buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -2522,7 +2520,7 @@ public Builder clearLabel() { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/Document.java b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/Document.java index ac8be6f7e77b..dbeb0e2da91c 100644 --- a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/Document.java +++ b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/Document.java @@ -82,7 +82,7 @@ private Document( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -560,23 +560,21 @@ public boolean equals(final java.lang.Object obj) { } com.google.cloud.language.v1.Document other = (com.google.cloud.language.v1.Document) obj; - boolean result = true; - result = result && type_ == other.type_; - result = result && getLanguage().equals(other.getLanguage()); - result = result && getSourceCase().equals(other.getSourceCase()); - if (!result) return false; + if (type_ != other.type_) return false; + if (!getLanguage().equals(other.getLanguage())) return false; + if (!getSourceCase().equals(other.getSourceCase())) return false; switch (sourceCase_) { case 2: - result = result && getContent().equals(other.getContent()); + if (!getContent().equals(other.getContent())) return false; break; case 3: - result = result && getGcsContentUri().equals(other.getGcsContentUri()); + if (!getGcsContentUri().equals(other.getGcsContentUri())) return false; break; case 0: default: } - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -795,35 +793,35 @@ public com.google.cloud.language.v1.Document buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -1345,7 +1343,7 @@ public Builder setLanguageBytes(com.google.protobuf.ByteString value) { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/Entity.java b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/Entity.java index 426957652208..20a3050d3c22 100644 --- a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/Entity.java +++ b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/Entity.java @@ -27,7 +27,6 @@ private Entity(com.google.protobuf.GeneratedMessageV3.Builder builder) { private Entity() { name_ = ""; type_ = 0; - salience_ = 0F; mentions_ = java.util.Collections.emptyList(); } @@ -71,7 +70,7 @@ private Entity( } case 26: { - if (!((mutable_bitField0_ & 0x00000004) == 0x00000004)) { + if (!((mutable_bitField0_ & 0x00000004) != 0)) { metadata_ = com.google.protobuf.MapField.newMapField( MetadataDefaultEntryHolder.defaultEntry); @@ -91,7 +90,7 @@ private Entity( } case 42: { - if (!((mutable_bitField0_ & 0x00000010) == 0x00000010)) { + if (!((mutable_bitField0_ & 0x00000010) != 0)) { mentions_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000010; } @@ -118,7 +117,7 @@ private Entity( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -130,7 +129,7 @@ private Entity( } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { - if (((mutable_bitField0_ & 0x00000010) == 0x00000010)) { + if (((mutable_bitField0_ & 0x00000010) != 0)) { mentions_ = java.util.Collections.unmodifiableList(mentions_); } this.unknownFields = unknownFields.build(); @@ -923,21 +922,18 @@ public boolean equals(final java.lang.Object obj) { } com.google.cloud.language.v1.Entity other = (com.google.cloud.language.v1.Entity) obj; - boolean result = true; - result = result && getName().equals(other.getName()); - result = result && type_ == other.type_; - result = result && internalGetMetadata().equals(other.internalGetMetadata()); - result = - result - && (java.lang.Float.floatToIntBits(getSalience()) - == java.lang.Float.floatToIntBits(other.getSalience())); - result = result && getMentionsList().equals(other.getMentionsList()); - result = result && (hasSentiment() == other.hasSentiment()); + if (!getName().equals(other.getName())) return false; + if (type_ != other.type_) return false; + if (!internalGetMetadata().equals(other.internalGetMetadata())) return false; + if (java.lang.Float.floatToIntBits(getSalience()) + != java.lang.Float.floatToIntBits(other.getSalience())) return false; + if (!getMentionsList().equals(other.getMentionsList())) return false; + if (hasSentiment() != other.hasSentiment()) return false; if (hasSentiment()) { - result = result && getSentiment().equals(other.getSentiment()); + if (!getSentiment().equals(other.getSentiment())) return false; } - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -1186,7 +1182,7 @@ public com.google.cloud.language.v1.Entity buildPartial() { result.metadata_.makeImmutable(); result.salience_ = salience_; if (mentionsBuilder_ == null) { - if (((bitField0_ & 0x00000010) == 0x00000010)) { + if (((bitField0_ & 0x00000010) != 0)) { mentions_ = java.util.Collections.unmodifiableList(mentions_); bitField0_ = (bitField0_ & ~0x00000010); } @@ -1206,35 +1202,35 @@ public com.google.cloud.language.v1.Entity buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -1718,7 +1714,7 @@ public Builder clearSalience() { java.util.Collections.emptyList(); private void ensureMentionsIsMutable() { - if (!((bitField0_ & 0x00000010) == 0x00000010)) { + if (!((bitField0_ & 0x00000010) != 0)) { mentions_ = new java.util.ArrayList(mentions_); bitField0_ |= 0x00000010; } @@ -2075,16 +2071,13 @@ public com.google.cloud.language.v1.EntityMention.Builder addMentionsBuilder(int com.google.cloud.language.v1.EntityMention, com.google.cloud.language.v1.EntityMention.Builder, com.google.cloud.language.v1.EntityMentionOrBuilder>( - mentions_, - ((bitField0_ & 0x00000010) == 0x00000010), - getParentForChildren(), - isClean()); + mentions_, ((bitField0_ & 0x00000010) != 0), getParentForChildren(), isClean()); mentions_ = null; } return mentionsBuilder_; } - private com.google.cloud.language.v1.Sentiment sentiment_ = null; + private com.google.cloud.language.v1.Sentiment sentiment_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1.Sentiment, com.google.cloud.language.v1.Sentiment.Builder, @@ -2294,7 +2287,7 @@ public com.google.cloud.language.v1.SentimentOrBuilder getSentimentOrBuilder() { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/EntityMention.java b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/EntityMention.java index d6c0855af3c0..1e4cadd37962 100644 --- a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/EntityMention.java +++ b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/EntityMention.java @@ -92,7 +92,7 @@ private EntityMention( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -445,18 +445,17 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1.EntityMention other = (com.google.cloud.language.v1.EntityMention) obj; - boolean result = true; - result = result && (hasText() == other.hasText()); + if (hasText() != other.hasText()) return false; if (hasText()) { - result = result && getText().equals(other.getText()); + if (!getText().equals(other.getText())) return false; } - result = result && type_ == other.type_; - result = result && (hasSentiment() == other.hasSentiment()); + if (type_ != other.type_) return false; + if (hasSentiment() != other.hasSentiment()) return false; if (hasSentiment()) { - result = result && getSentiment().equals(other.getSentiment()); + if (!getSentiment().equals(other.getSentiment())) return false; } - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -680,35 +679,35 @@ public com.google.cloud.language.v1.EntityMention buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -761,7 +760,7 @@ public Builder mergeFrom( return this; } - private com.google.cloud.language.v1.TextSpan text_ = null; + private com.google.cloud.language.v1.TextSpan text_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1.TextSpan, com.google.cloud.language.v1.TextSpan.Builder, @@ -1014,7 +1013,7 @@ public Builder clearType() { return this; } - private com.google.cloud.language.v1.Sentiment sentiment_ = null; + private com.google.cloud.language.v1.Sentiment sentiment_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1.Sentiment, com.google.cloud.language.v1.Sentiment.Builder, @@ -1224,7 +1223,7 @@ public com.google.cloud.language.v1.SentimentOrBuilder getSentimentOrBuilder() { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/PartOfSpeech.java b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/PartOfSpeech.java index 6a4650c0dea9..4adf9c14b04b 100644 --- a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/PartOfSpeech.java +++ b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/PartOfSpeech.java @@ -149,7 +149,7 @@ private PartOfSpeech( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -3416,21 +3416,20 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1.PartOfSpeech other = (com.google.cloud.language.v1.PartOfSpeech) obj; - boolean result = true; - result = result && tag_ == other.tag_; - result = result && aspect_ == other.aspect_; - result = result && case_ == other.case_; - result = result && form_ == other.form_; - result = result && gender_ == other.gender_; - result = result && mood_ == other.mood_; - result = result && number_ == other.number_; - result = result && person_ == other.person_; - result = result && proper_ == other.proper_; - result = result && reciprocity_ == other.reciprocity_; - result = result && tense_ == other.tense_; - result = result && voice_ == other.voice_; - result = result && unknownFields.equals(other.unknownFields); - return result; + if (tag_ != other.tag_) return false; + if (aspect_ != other.aspect_) return false; + if (case_ != other.case_) return false; + if (form_ != other.form_) return false; + if (gender_ != other.gender_) return false; + if (mood_ != other.mood_) return false; + if (number_ != other.number_) return false; + if (person_ != other.person_) return false; + if (proper_ != other.proper_) return false; + if (reciprocity_ != other.reciprocity_) return false; + if (tense_ != other.tense_) return false; + if (voice_ != other.voice_) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -3680,35 +3679,35 @@ public com.google.cloud.language.v1.PartOfSpeech buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -4714,7 +4713,7 @@ public Builder clearVoice() { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/Sentence.java b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/Sentence.java index 9a25388be955..a1beec6db01b 100644 --- a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/Sentence.java +++ b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/Sentence.java @@ -82,7 +82,7 @@ private Sentence( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -250,17 +250,16 @@ public boolean equals(final java.lang.Object obj) { } com.google.cloud.language.v1.Sentence other = (com.google.cloud.language.v1.Sentence) obj; - boolean result = true; - result = result && (hasText() == other.hasText()); + if (hasText() != other.hasText()) return false; if (hasText()) { - result = result && getText().equals(other.getText()); + if (!getText().equals(other.getText())) return false; } - result = result && (hasSentiment() == other.hasSentiment()); + if (hasSentiment() != other.hasSentiment()) return false; if (hasSentiment()) { - result = result && getSentiment().equals(other.getSentiment()); + if (!getSentiment().equals(other.getSentiment())) return false; } - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -477,35 +476,35 @@ public com.google.cloud.language.v1.Sentence buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -555,7 +554,7 @@ public Builder mergeFrom( return this; } - private com.google.cloud.language.v1.TextSpan text_ = null; + private com.google.cloud.language.v1.TextSpan text_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1.TextSpan, com.google.cloud.language.v1.TextSpan.Builder, @@ -732,7 +731,7 @@ public com.google.cloud.language.v1.TextSpanOrBuilder getTextOrBuilder() { return textBuilder_; } - private com.google.cloud.language.v1.Sentiment sentiment_ = null; + private com.google.cloud.language.v1.Sentiment sentiment_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1.Sentiment, com.google.cloud.language.v1.Sentiment.Builder, @@ -933,7 +932,7 @@ public com.google.cloud.language.v1.SentimentOrBuilder getSentimentOrBuilder() { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/Sentiment.java b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/Sentiment.java index c38ec4a1328a..b58665c7fd6f 100644 --- a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/Sentiment.java +++ b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/Sentiment.java @@ -23,10 +23,7 @@ private Sentiment(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } - private Sentiment() { - magnitude_ = 0F; - score_ = 0F; - } + private Sentiment() {} @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { @@ -64,7 +61,7 @@ private Sentiment( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -179,17 +176,12 @@ public boolean equals(final java.lang.Object obj) { } com.google.cloud.language.v1.Sentiment other = (com.google.cloud.language.v1.Sentiment) obj; - boolean result = true; - result = - result - && (java.lang.Float.floatToIntBits(getMagnitude()) - == java.lang.Float.floatToIntBits(other.getMagnitude())); - result = - result - && (java.lang.Float.floatToIntBits(getScore()) - == java.lang.Float.floatToIntBits(other.getScore())); - result = result && unknownFields.equals(other.unknownFields); - return result; + if (java.lang.Float.floatToIntBits(getMagnitude()) + != java.lang.Float.floatToIntBits(other.getMagnitude())) return false; + if (java.lang.Float.floatToIntBits(getScore()) + != java.lang.Float.floatToIntBits(other.getScore())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -388,35 +380,35 @@ public com.google.cloud.language.v1.Sentiment buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -565,7 +557,7 @@ public Builder clearScore() { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/TextSpan.java b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/TextSpan.java index f6772431f7be..50d6a309f091 100644 --- a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/TextSpan.java +++ b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/TextSpan.java @@ -24,7 +24,6 @@ private TextSpan(com.google.protobuf.GeneratedMessageV3.Builder builder) { private TextSpan() { content_ = ""; - beginOffset_ = 0; } @java.lang.Override @@ -65,7 +64,7 @@ private TextSpan( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -208,11 +207,10 @@ public boolean equals(final java.lang.Object obj) { } com.google.cloud.language.v1.TextSpan other = (com.google.cloud.language.v1.TextSpan) obj; - boolean result = true; - result = result && getContent().equals(other.getContent()); - result = result && (getBeginOffset() == other.getBeginOffset()); - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!getContent().equals(other.getContent())) return false; + if (getBeginOffset() != other.getBeginOffset()) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -409,35 +407,35 @@ public com.google.cloud.language.v1.TextSpan buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -637,7 +635,7 @@ public Builder clearBeginOffset() { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/Token.java b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/Token.java index 6a8c6d8ca2d8..b72b1d6bed0d 100644 --- a/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/Token.java +++ b/google-api-grpc/proto-google-cloud-language-v1/src/main/java/com/google/cloud/language/v1/Token.java @@ -107,7 +107,7 @@ private Token( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -365,22 +365,21 @@ public boolean equals(final java.lang.Object obj) { } com.google.cloud.language.v1.Token other = (com.google.cloud.language.v1.Token) obj; - boolean result = true; - result = result && (hasText() == other.hasText()); + if (hasText() != other.hasText()) return false; if (hasText()) { - result = result && getText().equals(other.getText()); + if (!getText().equals(other.getText())) return false; } - result = result && (hasPartOfSpeech() == other.hasPartOfSpeech()); + if (hasPartOfSpeech() != other.hasPartOfSpeech()) return false; if (hasPartOfSpeech()) { - result = result && getPartOfSpeech().equals(other.getPartOfSpeech()); + if (!getPartOfSpeech().equals(other.getPartOfSpeech())) return false; } - result = result && (hasDependencyEdge() == other.hasDependencyEdge()); + if (hasDependencyEdge() != other.hasDependencyEdge()) return false; if (hasDependencyEdge()) { - result = result && getDependencyEdge().equals(other.getDependencyEdge()); + if (!getDependencyEdge().equals(other.getDependencyEdge())) return false; } - result = result && getLemma().equals(other.getLemma()); - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!getLemma().equals(other.getLemma())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -616,35 +615,35 @@ public com.google.cloud.language.v1.Token buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -701,7 +700,7 @@ public Builder mergeFrom( return this; } - private com.google.cloud.language.v1.TextSpan text_ = null; + private com.google.cloud.language.v1.TextSpan text_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1.TextSpan, com.google.cloud.language.v1.TextSpan.Builder, @@ -878,7 +877,7 @@ public com.google.cloud.language.v1.TextSpanOrBuilder getTextOrBuilder() { return textBuilder_; } - private com.google.cloud.language.v1.PartOfSpeech partOfSpeech_ = null; + private com.google.cloud.language.v1.PartOfSpeech partOfSpeech_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1.PartOfSpeech, com.google.cloud.language.v1.PartOfSpeech.Builder, @@ -1060,7 +1059,7 @@ public com.google.cloud.language.v1.PartOfSpeechOrBuilder getPartOfSpeechOrBuild return partOfSpeechBuilder_; } - private com.google.cloud.language.v1.DependencyEdge dependencyEdge_ = null; + private com.google.cloud.language.v1.DependencyEdge dependencyEdge_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1.DependencyEdge, com.google.cloud.language.v1.DependencyEdge.Builder, @@ -1338,7 +1337,7 @@ public Builder setLemmaBytes(com.google.protobuf.ByteString value) { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeEntitiesRequest.java b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeEntitiesRequest.java index a19bfb458f8d..8ca8e460fda9 100644 --- a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeEntitiesRequest.java +++ b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeEntitiesRequest.java @@ -75,7 +75,7 @@ private AnalyzeEntitiesRequest( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -229,14 +229,13 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1beta2.AnalyzeEntitiesRequest other = (com.google.cloud.language.v1beta2.AnalyzeEntitiesRequest) obj; - boolean result = true; - result = result && (hasDocument() == other.hasDocument()); + if (hasDocument() != other.hasDocument()) return false; if (hasDocument()) { - result = result && getDocument().equals(other.getDocument()); + if (!getDocument().equals(other.getDocument())) return false; } - result = result && encodingType_ == other.encodingType_; - result = result && unknownFields.equals(other.unknownFields); - return result; + if (encodingType_ != other.encodingType_) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -445,35 +444,35 @@ public com.google.cloud.language.v1beta2.AnalyzeEntitiesRequest buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -525,7 +524,7 @@ public Builder mergeFrom( return this; } - private com.google.cloud.language.v1beta2.Document document_ = null; + private com.google.cloud.language.v1beta2.Document document_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1beta2.Document, com.google.cloud.language.v1beta2.Document.Builder, @@ -784,7 +783,7 @@ public Builder clearEncodingType() { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeEntitiesResponse.java b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeEntitiesResponse.java index f891fa2acdbc..abff8dbe655d 100644 --- a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeEntitiesResponse.java +++ b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeEntitiesResponse.java @@ -53,7 +53,7 @@ private AnalyzeEntitiesResponse( break; case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { entities_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000001; } @@ -71,7 +71,7 @@ private AnalyzeEntitiesResponse( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -83,7 +83,7 @@ private AnalyzeEntitiesResponse( } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { - if (((mutable_bitField0_ & 0x00000001) == 0x00000001)) { + if (((mutable_bitField0_ & 0x00000001) != 0)) { entities_ = java.util.Collections.unmodifiableList(entities_); } this.unknownFields = unknownFields.build(); @@ -271,11 +271,10 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1beta2.AnalyzeEntitiesResponse other = (com.google.cloud.language.v1beta2.AnalyzeEntitiesResponse) obj; - boolean result = true; - result = result && getEntitiesList().equals(other.getEntitiesList()); - result = result && getLanguage().equals(other.getLanguage()); - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!getEntitiesList().equals(other.getEntitiesList())) return false; + if (!getLanguage().equals(other.getLanguage())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -477,7 +476,7 @@ public com.google.cloud.language.v1beta2.AnalyzeEntitiesResponse buildPartial() int from_bitField0_ = bitField0_; int to_bitField0_ = 0; if (entitiesBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { + if (((bitField0_ & 0x00000001) != 0)) { entities_ = java.util.Collections.unmodifiableList(entities_); bitField0_ = (bitField0_ & ~0x00000001); } @@ -493,35 +492,35 @@ public com.google.cloud.language.v1beta2.AnalyzeEntitiesResponse buildPartial() @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -604,7 +603,7 @@ public Builder mergeFrom( java.util.Collections.emptyList(); private void ensureEntitiesIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { + if (!((bitField0_ & 0x00000001) != 0)) { entities_ = new java.util.ArrayList(entities_); bitField0_ |= 0x00000001; } @@ -943,10 +942,7 @@ public com.google.cloud.language.v1beta2.Entity.Builder addEntitiesBuilder(int i com.google.cloud.language.v1beta2.Entity, com.google.cloud.language.v1beta2.Entity.Builder, com.google.cloud.language.v1beta2.EntityOrBuilder>( - entities_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); + entities_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); entities_ = null; } return entitiesBuilder_; @@ -1063,7 +1059,7 @@ public Builder setLanguageBytes(com.google.protobuf.ByteString value) { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeEntitySentimentRequest.java b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeEntitySentimentRequest.java index a8314dbaf222..ba758789d681 100644 --- a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeEntitySentimentRequest.java +++ b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeEntitySentimentRequest.java @@ -75,7 +75,7 @@ private AnalyzeEntitySentimentRequest( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -229,14 +229,13 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1beta2.AnalyzeEntitySentimentRequest other = (com.google.cloud.language.v1beta2.AnalyzeEntitySentimentRequest) obj; - boolean result = true; - result = result && (hasDocument() == other.hasDocument()); + if (hasDocument() != other.hasDocument()) return false; if (hasDocument()) { - result = result && getDocument().equals(other.getDocument()); + if (!getDocument().equals(other.getDocument())) return false; } - result = result && encodingType_ == other.encodingType_; - result = result && unknownFields.equals(other.unknownFields); - return result; + if (encodingType_ != other.encodingType_) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -446,35 +445,35 @@ public com.google.cloud.language.v1beta2.AnalyzeEntitySentimentRequest buildPart @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -529,7 +528,7 @@ public Builder mergeFrom( return this; } - private com.google.cloud.language.v1beta2.Document document_ = null; + private com.google.cloud.language.v1beta2.Document document_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1beta2.Document, com.google.cloud.language.v1beta2.Document.Builder, @@ -788,7 +787,7 @@ public Builder clearEncodingType() { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeEntitySentimentResponse.java b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeEntitySentimentResponse.java index ec823f1d86e0..edf539a560cf 100644 --- a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeEntitySentimentResponse.java +++ b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeEntitySentimentResponse.java @@ -54,7 +54,7 @@ private AnalyzeEntitySentimentResponse( break; case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { entities_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000001; } @@ -72,7 +72,7 @@ private AnalyzeEntitySentimentResponse( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -84,7 +84,7 @@ private AnalyzeEntitySentimentResponse( } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { - if (((mutable_bitField0_ & 0x00000001) == 0x00000001)) { + if (((mutable_bitField0_ & 0x00000001) != 0)) { entities_ = java.util.Collections.unmodifiableList(entities_); } this.unknownFields = unknownFields.build(); @@ -272,11 +272,10 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1beta2.AnalyzeEntitySentimentResponse other = (com.google.cloud.language.v1beta2.AnalyzeEntitySentimentResponse) obj; - boolean result = true; - result = result && getEntitiesList().equals(other.getEntitiesList()); - result = result && getLanguage().equals(other.getLanguage()); - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!getEntitiesList().equals(other.getEntitiesList())) return false; + if (!getLanguage().equals(other.getLanguage())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -479,7 +478,7 @@ public com.google.cloud.language.v1beta2.AnalyzeEntitySentimentResponse buildPar int from_bitField0_ = bitField0_; int to_bitField0_ = 0; if (entitiesBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { + if (((bitField0_ & 0x00000001) != 0)) { entities_ = java.util.Collections.unmodifiableList(entities_); bitField0_ = (bitField0_ & ~0x00000001); } @@ -495,35 +494,35 @@ public com.google.cloud.language.v1beta2.AnalyzeEntitySentimentResponse buildPar @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -609,7 +608,7 @@ public Builder mergeFrom( java.util.Collections.emptyList(); private void ensureEntitiesIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { + if (!((bitField0_ & 0x00000001) != 0)) { entities_ = new java.util.ArrayList(entities_); bitField0_ |= 0x00000001; } @@ -948,10 +947,7 @@ public com.google.cloud.language.v1beta2.Entity.Builder addEntitiesBuilder(int i com.google.cloud.language.v1beta2.Entity, com.google.cloud.language.v1beta2.Entity.Builder, com.google.cloud.language.v1beta2.EntityOrBuilder>( - entities_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); + entities_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); entities_ = null; } return entitiesBuilder_; @@ -1068,7 +1064,7 @@ public Builder setLanguageBytes(com.google.protobuf.ByteString value) { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeSentimentRequest.java b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeSentimentRequest.java index b763122e1754..600e7ed7bac6 100644 --- a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeSentimentRequest.java +++ b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeSentimentRequest.java @@ -75,7 +75,7 @@ private AnalyzeSentimentRequest( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -231,14 +231,13 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1beta2.AnalyzeSentimentRequest other = (com.google.cloud.language.v1beta2.AnalyzeSentimentRequest) obj; - boolean result = true; - result = result && (hasDocument() == other.hasDocument()); + if (hasDocument() != other.hasDocument()) return false; if (hasDocument()) { - result = result && getDocument().equals(other.getDocument()); + if (!getDocument().equals(other.getDocument())) return false; } - result = result && encodingType_ == other.encodingType_; - result = result && unknownFields.equals(other.unknownFields); - return result; + if (encodingType_ != other.encodingType_) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -447,35 +446,35 @@ public com.google.cloud.language.v1beta2.AnalyzeSentimentRequest buildPartial() @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -527,7 +526,7 @@ public Builder mergeFrom( return this; } - private com.google.cloud.language.v1beta2.Document document_ = null; + private com.google.cloud.language.v1beta2.Document document_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1beta2.Document, com.google.cloud.language.v1beta2.Document.Builder, @@ -791,7 +790,7 @@ public Builder clearEncodingType() { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeSentimentResponse.java b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeSentimentResponse.java index 4cd36e4bcfce..526d05499b03 100644 --- a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeSentimentResponse.java +++ b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeSentimentResponse.java @@ -76,7 +76,7 @@ private AnalyzeSentimentResponse( } case 26: { - if (!((mutable_bitField0_ & 0x00000004) == 0x00000004)) { + if (!((mutable_bitField0_ & 0x00000004) != 0)) { sentences_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000004; } @@ -87,7 +87,7 @@ private AnalyzeSentimentResponse( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -99,7 +99,7 @@ private AnalyzeSentimentResponse( } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { - if (((mutable_bitField0_ & 0x00000004) == 0x00000004)) { + if (((mutable_bitField0_ & 0x00000004) != 0)) { sentences_ = java.util.Collections.unmodifiableList(sentences_); } this.unknownFields = unknownFields.build(); @@ -334,15 +334,14 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1beta2.AnalyzeSentimentResponse other = (com.google.cloud.language.v1beta2.AnalyzeSentimentResponse) obj; - boolean result = true; - result = result && (hasDocumentSentiment() == other.hasDocumentSentiment()); + if (hasDocumentSentiment() != other.hasDocumentSentiment()) return false; if (hasDocumentSentiment()) { - result = result && getDocumentSentiment().equals(other.getDocumentSentiment()); + if (!getDocumentSentiment().equals(other.getDocumentSentiment())) return false; } - result = result && getLanguage().equals(other.getLanguage()); - result = result && getSentencesList().equals(other.getSentencesList()); - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!getLanguage().equals(other.getLanguage())) return false; + if (!getSentencesList().equals(other.getSentencesList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -560,7 +559,7 @@ public com.google.cloud.language.v1beta2.AnalyzeSentimentResponse buildPartial() } result.language_ = language_; if (sentencesBuilder_ == null) { - if (((bitField0_ & 0x00000004) == 0x00000004)) { + if (((bitField0_ & 0x00000004) != 0)) { sentences_ = java.util.Collections.unmodifiableList(sentences_); bitField0_ = (bitField0_ & ~0x00000004); } @@ -575,35 +574,35 @@ public com.google.cloud.language.v1beta2.AnalyzeSentimentResponse buildPartial() @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -685,7 +684,7 @@ public Builder mergeFrom( private int bitField0_; - private com.google.cloud.language.v1beta2.Sentiment documentSentiment_ = null; + private com.google.cloud.language.v1beta2.Sentiment documentSentiment_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1beta2.Sentiment, com.google.cloud.language.v1beta2.Sentiment.Builder, @@ -980,7 +979,7 @@ public Builder setLanguageBytes(com.google.protobuf.ByteString value) { java.util.Collections.emptyList(); private void ensureSentencesIsMutable() { - if (!((bitField0_ & 0x00000004) == 0x00000004)) { + if (!((bitField0_ & 0x00000004) != 0)) { sentences_ = new java.util.ArrayList(sentences_); bitField0_ |= 0x00000004; @@ -1321,10 +1320,7 @@ public com.google.cloud.language.v1beta2.Sentence.Builder addSentencesBuilder(in com.google.cloud.language.v1beta2.Sentence, com.google.cloud.language.v1beta2.Sentence.Builder, com.google.cloud.language.v1beta2.SentenceOrBuilder>( - sentences_, - ((bitField0_ & 0x00000004) == 0x00000004), - getParentForChildren(), - isClean()); + sentences_, ((bitField0_ & 0x00000004) != 0), getParentForChildren(), isClean()); sentences_ = null; } return sentencesBuilder_; @@ -1332,7 +1328,7 @@ public com.google.cloud.language.v1beta2.Sentence.Builder addSentencesBuilder(in @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeSyntaxRequest.java b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeSyntaxRequest.java index ab60a8f37fcf..27a220e00b5d 100644 --- a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeSyntaxRequest.java +++ b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeSyntaxRequest.java @@ -75,7 +75,7 @@ private AnalyzeSyntaxRequest( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -229,14 +229,13 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1beta2.AnalyzeSyntaxRequest other = (com.google.cloud.language.v1beta2.AnalyzeSyntaxRequest) obj; - boolean result = true; - result = result && (hasDocument() == other.hasDocument()); + if (hasDocument() != other.hasDocument()) return false; if (hasDocument()) { - result = result && getDocument().equals(other.getDocument()); + if (!getDocument().equals(other.getDocument())) return false; } - result = result && encodingType_ == other.encodingType_; - result = result && unknownFields.equals(other.unknownFields); - return result; + if (encodingType_ != other.encodingType_) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -445,35 +444,35 @@ public com.google.cloud.language.v1beta2.AnalyzeSyntaxRequest buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -525,7 +524,7 @@ public Builder mergeFrom( return this; } - private com.google.cloud.language.v1beta2.Document document_ = null; + private com.google.cloud.language.v1beta2.Document document_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1beta2.Document, com.google.cloud.language.v1beta2.Document.Builder, @@ -784,7 +783,7 @@ public Builder clearEncodingType() { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeSyntaxResponse.java b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeSyntaxResponse.java index 978d611e63fc..f1d1c899c6d6 100644 --- a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeSyntaxResponse.java +++ b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnalyzeSyntaxResponse.java @@ -54,7 +54,7 @@ private AnalyzeSyntaxResponse( break; case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { sentences_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000001; } @@ -65,7 +65,7 @@ private AnalyzeSyntaxResponse( } case 18: { - if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) { + if (!((mutable_bitField0_ & 0x00000002) != 0)) { tokens_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000002; } @@ -83,7 +83,7 @@ private AnalyzeSyntaxResponse( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -95,10 +95,10 @@ private AnalyzeSyntaxResponse( } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { - if (((mutable_bitField0_ & 0x00000001) == 0x00000001)) { + if (((mutable_bitField0_ & 0x00000001) != 0)) { sentences_ = java.util.Collections.unmodifiableList(sentences_); } - if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) { + if (((mutable_bitField0_ & 0x00000002) != 0)) { tokens_ = java.util.Collections.unmodifiableList(tokens_); } this.unknownFields = unknownFields.build(); @@ -356,12 +356,11 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1beta2.AnalyzeSyntaxResponse other = (com.google.cloud.language.v1beta2.AnalyzeSyntaxResponse) obj; - boolean result = true; - result = result && getSentencesList().equals(other.getSentencesList()); - result = result && getTokensList().equals(other.getTokensList()); - result = result && getLanguage().equals(other.getLanguage()); - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!getSentencesList().equals(other.getSentencesList())) return false; + if (!getTokensList().equals(other.getTokensList())) return false; + if (!getLanguage().equals(other.getLanguage())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -574,7 +573,7 @@ public com.google.cloud.language.v1beta2.AnalyzeSyntaxResponse buildPartial() { int from_bitField0_ = bitField0_; int to_bitField0_ = 0; if (sentencesBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { + if (((bitField0_ & 0x00000001) != 0)) { sentences_ = java.util.Collections.unmodifiableList(sentences_); bitField0_ = (bitField0_ & ~0x00000001); } @@ -583,7 +582,7 @@ public com.google.cloud.language.v1beta2.AnalyzeSyntaxResponse buildPartial() { result.sentences_ = sentencesBuilder_.build(); } if (tokensBuilder_ == null) { - if (((bitField0_ & 0x00000002) == 0x00000002)) { + if (((bitField0_ & 0x00000002) != 0)) { tokens_ = java.util.Collections.unmodifiableList(tokens_); bitField0_ = (bitField0_ & ~0x00000002); } @@ -599,35 +598,35 @@ public com.google.cloud.language.v1beta2.AnalyzeSyntaxResponse buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -737,7 +736,7 @@ public Builder mergeFrom( java.util.Collections.emptyList(); private void ensureSentencesIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { + if (!((bitField0_ & 0x00000001) != 0)) { sentences_ = new java.util.ArrayList(sentences_); bitField0_ |= 0x00000001; @@ -1078,10 +1077,7 @@ public com.google.cloud.language.v1beta2.Sentence.Builder addSentencesBuilder(in com.google.cloud.language.v1beta2.Sentence, com.google.cloud.language.v1beta2.Sentence.Builder, com.google.cloud.language.v1beta2.SentenceOrBuilder>( - sentences_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); + sentences_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); sentences_ = null; } return sentencesBuilder_; @@ -1091,7 +1087,7 @@ public com.google.cloud.language.v1beta2.Sentence.Builder addSentencesBuilder(in java.util.Collections.emptyList(); private void ensureTokensIsMutable() { - if (!((bitField0_ & 0x00000002) == 0x00000002)) { + if (!((bitField0_ & 0x00000002) != 0)) { tokens_ = new java.util.ArrayList(tokens_); bitField0_ |= 0x00000002; } @@ -1429,10 +1425,7 @@ public java.util.List getTokens com.google.cloud.language.v1beta2.Token, com.google.cloud.language.v1beta2.Token.Builder, com.google.cloud.language.v1beta2.TokenOrBuilder>( - tokens_, - ((bitField0_ & 0x00000002) == 0x00000002), - getParentForChildren(), - isClean()); + tokens_, ((bitField0_ & 0x00000002) != 0), getParentForChildren(), isClean()); tokens_ = null; } return tokensBuilder_; @@ -1549,7 +1542,7 @@ public Builder setLanguageBytes(com.google.protobuf.ByteString value) { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnnotateTextRequest.java b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnnotateTextRequest.java index 0b8bad91f640..b21d0c44b38b 100644 --- a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnnotateTextRequest.java +++ b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnnotateTextRequest.java @@ -94,7 +94,7 @@ private AnnotateTextRequest( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -206,13 +206,7 @@ private Features(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } - private Features() { - extractSyntax_ = false; - extractEntities_ = false; - extractDocumentSentiment_ = false; - extractEntitySentiment_ = false; - classifyText_ = false; - } + private Features() {} @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { @@ -265,7 +259,7 @@ private Features( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -441,14 +435,13 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1beta2.AnnotateTextRequest.Features other = (com.google.cloud.language.v1beta2.AnnotateTextRequest.Features) obj; - boolean result = true; - result = result && (getExtractSyntax() == other.getExtractSyntax()); - result = result && (getExtractEntities() == other.getExtractEntities()); - result = result && (getExtractDocumentSentiment() == other.getExtractDocumentSentiment()); - result = result && (getExtractEntitySentiment() == other.getExtractEntitySentiment()); - result = result && (getClassifyText() == other.getClassifyText()); - result = result && unknownFields.equals(other.unknownFields); - return result; + if (getExtractSyntax() != other.getExtractSyntax()) return false; + if (getExtractEntities() != other.getExtractEntities()) return false; + if (getExtractDocumentSentiment() != other.getExtractDocumentSentiment()) return false; + if (getExtractEntitySentiment() != other.getExtractEntitySentiment()) return false; + if (getClassifyText() != other.getClassifyText()) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -666,23 +659,23 @@ public com.google.cloud.language.v1beta2.AnnotateTextRequest.Features buildParti @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override @@ -690,13 +683,13 @@ public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -983,7 +976,7 @@ public Builder clearClassifyText() { @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override @@ -1205,18 +1198,17 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1beta2.AnnotateTextRequest other = (com.google.cloud.language.v1beta2.AnnotateTextRequest) obj; - boolean result = true; - result = result && (hasDocument() == other.hasDocument()); + if (hasDocument() != other.hasDocument()) return false; if (hasDocument()) { - result = result && getDocument().equals(other.getDocument()); + if (!getDocument().equals(other.getDocument())) return false; } - result = result && (hasFeatures() == other.hasFeatures()); + if (hasFeatures() != other.hasFeatures()) return false; if (hasFeatures()) { - result = result && getFeatures().equals(other.getFeatures()); + if (!getFeatures().equals(other.getFeatures())) return false; } - result = result && encodingType_ == other.encodingType_; - result = result && unknownFields.equals(other.unknownFields); - return result; + if (encodingType_ != other.encodingType_) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -1441,35 +1433,35 @@ public com.google.cloud.language.v1beta2.AnnotateTextRequest buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -1524,7 +1516,7 @@ public Builder mergeFrom( return this; } - private com.google.cloud.language.v1beta2.Document document_ = null; + private com.google.cloud.language.v1beta2.Document document_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1beta2.Document, com.google.cloud.language.v1beta2.Document.Builder, @@ -1705,7 +1697,7 @@ public com.google.cloud.language.v1beta2.DocumentOrBuilder getDocumentOrBuilder( return documentBuilder_; } - private com.google.cloud.language.v1beta2.AnnotateTextRequest.Features features_ = null; + private com.google.cloud.language.v1beta2.AnnotateTextRequest.Features features_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1beta2.AnnotateTextRequest.Features, com.google.cloud.language.v1beta2.AnnotateTextRequest.Features.Builder, @@ -1969,7 +1961,7 @@ public Builder clearEncodingType() { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnnotateTextResponse.java b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnnotateTextResponse.java index 9a6e0b6e5b13..c59ef6b6d3f5 100644 --- a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnnotateTextResponse.java +++ b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/AnnotateTextResponse.java @@ -56,7 +56,7 @@ private AnnotateTextResponse( break; case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { sentences_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000001; } @@ -67,7 +67,7 @@ private AnnotateTextResponse( } case 18: { - if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) { + if (!((mutable_bitField0_ & 0x00000002) != 0)) { tokens_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000002; } @@ -78,7 +78,7 @@ private AnnotateTextResponse( } case 26: { - if (!((mutable_bitField0_ & 0x00000004) == 0x00000004)) { + if (!((mutable_bitField0_ & 0x00000004) != 0)) { entities_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000004; } @@ -112,7 +112,7 @@ private AnnotateTextResponse( } case 50: { - if (!((mutable_bitField0_ & 0x00000020) == 0x00000020)) { + if (!((mutable_bitField0_ & 0x00000020) != 0)) { categories_ = new java.util.ArrayList< com.google.cloud.language.v1beta2.ClassificationCategory>(); @@ -126,7 +126,7 @@ private AnnotateTextResponse( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -138,16 +138,16 @@ private AnnotateTextResponse( } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { - if (((mutable_bitField0_ & 0x00000001) == 0x00000001)) { + if (((mutable_bitField0_ & 0x00000001) != 0)) { sentences_ = java.util.Collections.unmodifiableList(sentences_); } - if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) { + if (((mutable_bitField0_ & 0x00000002) != 0)) { tokens_ = java.util.Collections.unmodifiableList(tokens_); } - if (((mutable_bitField0_ & 0x00000004) == 0x00000004)) { + if (((mutable_bitField0_ & 0x00000004) != 0)) { entities_ = java.util.Collections.unmodifiableList(entities_); } - if (((mutable_bitField0_ & 0x00000020) == 0x00000020)) { + if (((mutable_bitField0_ & 0x00000020) != 0)) { categories_ = java.util.Collections.unmodifiableList(categories_); } this.unknownFields = unknownFields.build(); @@ -622,18 +622,17 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1beta2.AnnotateTextResponse other = (com.google.cloud.language.v1beta2.AnnotateTextResponse) obj; - boolean result = true; - result = result && getSentencesList().equals(other.getSentencesList()); - result = result && getTokensList().equals(other.getTokensList()); - result = result && getEntitiesList().equals(other.getEntitiesList()); - result = result && (hasDocumentSentiment() == other.hasDocumentSentiment()); + if (!getSentencesList().equals(other.getSentencesList())) return false; + if (!getTokensList().equals(other.getTokensList())) return false; + if (!getEntitiesList().equals(other.getEntitiesList())) return false; + if (hasDocumentSentiment() != other.hasDocumentSentiment()) return false; if (hasDocumentSentiment()) { - result = result && getDocumentSentiment().equals(other.getDocumentSentiment()); + if (!getDocumentSentiment().equals(other.getDocumentSentiment())) return false; } - result = result && getLanguage().equals(other.getLanguage()); - result = result && getCategoriesList().equals(other.getCategoriesList()); - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!getLanguage().equals(other.getLanguage())) return false; + if (!getCategoriesList().equals(other.getCategoriesList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -878,7 +877,7 @@ public com.google.cloud.language.v1beta2.AnnotateTextResponse buildPartial() { int from_bitField0_ = bitField0_; int to_bitField0_ = 0; if (sentencesBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { + if (((bitField0_ & 0x00000001) != 0)) { sentences_ = java.util.Collections.unmodifiableList(sentences_); bitField0_ = (bitField0_ & ~0x00000001); } @@ -887,7 +886,7 @@ public com.google.cloud.language.v1beta2.AnnotateTextResponse buildPartial() { result.sentences_ = sentencesBuilder_.build(); } if (tokensBuilder_ == null) { - if (((bitField0_ & 0x00000002) == 0x00000002)) { + if (((bitField0_ & 0x00000002) != 0)) { tokens_ = java.util.Collections.unmodifiableList(tokens_); bitField0_ = (bitField0_ & ~0x00000002); } @@ -896,7 +895,7 @@ public com.google.cloud.language.v1beta2.AnnotateTextResponse buildPartial() { result.tokens_ = tokensBuilder_.build(); } if (entitiesBuilder_ == null) { - if (((bitField0_ & 0x00000004) == 0x00000004)) { + if (((bitField0_ & 0x00000004) != 0)) { entities_ = java.util.Collections.unmodifiableList(entities_); bitField0_ = (bitField0_ & ~0x00000004); } @@ -911,7 +910,7 @@ public com.google.cloud.language.v1beta2.AnnotateTextResponse buildPartial() { } result.language_ = language_; if (categoriesBuilder_ == null) { - if (((bitField0_ & 0x00000020) == 0x00000020)) { + if (((bitField0_ & 0x00000020) != 0)) { categories_ = java.util.Collections.unmodifiableList(categories_); bitField0_ = (bitField0_ & ~0x00000020); } @@ -926,35 +925,35 @@ public com.google.cloud.language.v1beta2.AnnotateTextResponse buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -1121,7 +1120,7 @@ public Builder mergeFrom( java.util.Collections.emptyList(); private void ensureSentencesIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { + if (!((bitField0_ & 0x00000001) != 0)) { sentences_ = new java.util.ArrayList(sentences_); bitField0_ |= 0x00000001; @@ -1480,10 +1479,7 @@ public com.google.cloud.language.v1beta2.Sentence.Builder addSentencesBuilder(in com.google.cloud.language.v1beta2.Sentence, com.google.cloud.language.v1beta2.Sentence.Builder, com.google.cloud.language.v1beta2.SentenceOrBuilder>( - sentences_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); + sentences_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); sentences_ = null; } return sentencesBuilder_; @@ -1493,7 +1489,7 @@ public com.google.cloud.language.v1beta2.Sentence.Builder addSentencesBuilder(in java.util.Collections.emptyList(); private void ensureTokensIsMutable() { - if (!((bitField0_ & 0x00000002) == 0x00000002)) { + if (!((bitField0_ & 0x00000002) != 0)) { tokens_ = new java.util.ArrayList(tokens_); bitField0_ |= 0x00000002; } @@ -1867,10 +1863,7 @@ public java.util.List getTokens com.google.cloud.language.v1beta2.Token, com.google.cloud.language.v1beta2.Token.Builder, com.google.cloud.language.v1beta2.TokenOrBuilder>( - tokens_, - ((bitField0_ & 0x00000002) == 0x00000002), - getParentForChildren(), - isClean()); + tokens_, ((bitField0_ & 0x00000002) != 0), getParentForChildren(), isClean()); tokens_ = null; } return tokensBuilder_; @@ -1880,7 +1873,7 @@ public java.util.List getTokens java.util.Collections.emptyList(); private void ensureEntitiesIsMutable() { - if (!((bitField0_ & 0x00000004) == 0x00000004)) { + if (!((bitField0_ & 0x00000004) != 0)) { entities_ = new java.util.ArrayList(entities_); bitField0_ |= 0x00000004; } @@ -2255,16 +2248,13 @@ public com.google.cloud.language.v1beta2.Entity.Builder addEntitiesBuilder(int i com.google.cloud.language.v1beta2.Entity, com.google.cloud.language.v1beta2.Entity.Builder, com.google.cloud.language.v1beta2.EntityOrBuilder>( - entities_, - ((bitField0_ & 0x00000004) == 0x00000004), - getParentForChildren(), - isClean()); + entities_, ((bitField0_ & 0x00000004) != 0), getParentForChildren(), isClean()); entities_ = null; } return entitiesBuilder_; } - private com.google.cloud.language.v1beta2.Sentiment documentSentiment_ = null; + private com.google.cloud.language.v1beta2.Sentiment documentSentiment_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1beta2.Sentiment, com.google.cloud.language.v1beta2.Sentiment.Builder, @@ -2568,7 +2558,7 @@ public Builder setLanguageBytes(com.google.protobuf.ByteString value) { java.util.Collections.emptyList(); private void ensureCategoriesIsMutable() { - if (!((bitField0_ & 0x00000020) == 0x00000020)) { + if (!((bitField0_ & 0x00000020) != 0)) { categories_ = new java.util.ArrayList( categories_); @@ -2922,10 +2912,7 @@ public com.google.cloud.language.v1beta2.ClassificationCategory.Builder addCateg com.google.cloud.language.v1beta2.ClassificationCategory, com.google.cloud.language.v1beta2.ClassificationCategory.Builder, com.google.cloud.language.v1beta2.ClassificationCategoryOrBuilder>( - categories_, - ((bitField0_ & 0x00000020) == 0x00000020), - getParentForChildren(), - isClean()); + categories_, ((bitField0_ & 0x00000020) != 0), getParentForChildren(), isClean()); categories_ = null; } return categoriesBuilder_; @@ -2933,7 +2920,7 @@ public com.google.cloud.language.v1beta2.ClassificationCategory.Builder addCateg @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/ClassificationCategory.java b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/ClassificationCategory.java index 8800b3632180..eba3d68ab037 100644 --- a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/ClassificationCategory.java +++ b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/ClassificationCategory.java @@ -24,7 +24,6 @@ private ClassificationCategory(com.google.protobuf.GeneratedMessageV3.Builder private ClassificationCategory() { name_ = ""; - confidence_ = 0F; } @java.lang.Override @@ -65,7 +64,7 @@ private ClassificationCategory( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -207,14 +206,11 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1beta2.ClassificationCategory other = (com.google.cloud.language.v1beta2.ClassificationCategory) obj; - boolean result = true; - result = result && getName().equals(other.getName()); - result = - result - && (java.lang.Float.floatToIntBits(getConfidence()) - == java.lang.Float.floatToIntBits(other.getConfidence())); - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!getName().equals(other.getName())) return false; + if (java.lang.Float.floatToIntBits(getConfidence()) + != java.lang.Float.floatToIntBits(other.getConfidence())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -413,35 +409,35 @@ public com.google.cloud.language.v1beta2.ClassificationCategory buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -637,7 +633,7 @@ public Builder clearConfidence() { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/ClassifyTextRequest.java b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/ClassifyTextRequest.java index 91fe88c54d36..d901d7855f7f 100644 --- a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/ClassifyTextRequest.java +++ b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/ClassifyTextRequest.java @@ -66,7 +66,7 @@ private ClassifyTextRequest( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -184,13 +184,12 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1beta2.ClassifyTextRequest other = (com.google.cloud.language.v1beta2.ClassifyTextRequest) obj; - boolean result = true; - result = result && (hasDocument() == other.hasDocument()); + if (hasDocument() != other.hasDocument()) return false; if (hasDocument()) { - result = result && getDocument().equals(other.getDocument()); + if (!getDocument().equals(other.getDocument())) return false; } - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -394,35 +393,35 @@ public com.google.cloud.language.v1beta2.ClassifyTextRequest buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -471,7 +470,7 @@ public Builder mergeFrom( return this; } - private com.google.cloud.language.v1beta2.Document document_ = null; + private com.google.cloud.language.v1beta2.Document document_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1beta2.Document, com.google.cloud.language.v1beta2.Document.Builder, @@ -654,7 +653,7 @@ public com.google.cloud.language.v1beta2.DocumentOrBuilder getDocumentOrBuilder( @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/ClassifyTextResponse.java b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/ClassifyTextResponse.java index c1bc8b8384f2..cf25d0ab8e3a 100644 --- a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/ClassifyTextResponse.java +++ b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/ClassifyTextResponse.java @@ -52,7 +52,7 @@ private ClassifyTextResponse( break; case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { categories_ = new java.util.ArrayList< com.google.cloud.language.v1beta2.ClassificationCategory>(); @@ -66,7 +66,7 @@ private ClassifyTextResponse( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -78,7 +78,7 @@ private ClassifyTextResponse( } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { - if (((mutable_bitField0_ & 0x00000001) == 0x00000001)) { + if (((mutable_bitField0_ & 0x00000001) != 0)) { categories_ = java.util.Collections.unmodifiableList(categories_); } this.unknownFields = unknownFields.build(); @@ -212,10 +212,9 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1beta2.ClassifyTextResponse other = (com.google.cloud.language.v1beta2.ClassifyTextResponse) obj; - boolean result = true; - result = result && getCategoriesList().equals(other.getCategoriesList()); - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!getCategoriesList().equals(other.getCategoriesList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -412,7 +411,7 @@ public com.google.cloud.language.v1beta2.ClassifyTextResponse buildPartial() { new com.google.cloud.language.v1beta2.ClassifyTextResponse(this); int from_bitField0_ = bitField0_; if (categoriesBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { + if (((bitField0_ & 0x00000001) != 0)) { categories_ = java.util.Collections.unmodifiableList(categories_); bitField0_ = (bitField0_ & ~0x00000001); } @@ -426,35 +425,35 @@ public com.google.cloud.language.v1beta2.ClassifyTextResponse buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -533,7 +532,7 @@ public Builder mergeFrom( java.util.Collections.emptyList(); private void ensureCategoriesIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { + if (!((bitField0_ & 0x00000001) != 0)) { categories_ = new java.util.ArrayList( categories_); @@ -887,10 +886,7 @@ public com.google.cloud.language.v1beta2.ClassificationCategory.Builder addCateg com.google.cloud.language.v1beta2.ClassificationCategory, com.google.cloud.language.v1beta2.ClassificationCategory.Builder, com.google.cloud.language.v1beta2.ClassificationCategoryOrBuilder>( - categories_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); + categories_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); categories_ = null; } return categoriesBuilder_; @@ -898,7 +894,7 @@ public com.google.cloud.language.v1beta2.ClassificationCategory.Builder addCateg @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/DependencyEdge.java b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/DependencyEdge.java index 572191d1c350..1b17e9efb3aa 100644 --- a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/DependencyEdge.java +++ b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/DependencyEdge.java @@ -23,7 +23,6 @@ private DependencyEdge(com.google.protobuf.GeneratedMessageV3.Builder builder } private DependencyEdge() { - headTokenIndex_ = 0; label_ = 0; } @@ -65,7 +64,7 @@ private DependencyEdge( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -2104,11 +2103,10 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1beta2.DependencyEdge other = (com.google.cloud.language.v1beta2.DependencyEdge) obj; - boolean result = true; - result = result && (getHeadTokenIndex() == other.getHeadTokenIndex()); - result = result && label_ == other.label_; - result = result && unknownFields.equals(other.unknownFields); - return result; + if (getHeadTokenIndex() != other.getHeadTokenIndex()) return false; + if (label_ != other.label_) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -2306,35 +2304,35 @@ public com.google.cloud.language.v1beta2.DependencyEdge buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -2521,7 +2519,7 @@ public Builder clearLabel() { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/Document.java b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/Document.java index 9a7603862750..6aee03b88487 100644 --- a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/Document.java +++ b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/Document.java @@ -82,7 +82,7 @@ private Document( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -561,23 +561,21 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1beta2.Document other = (com.google.cloud.language.v1beta2.Document) obj; - boolean result = true; - result = result && type_ == other.type_; - result = result && getLanguage().equals(other.getLanguage()); - result = result && getSourceCase().equals(other.getSourceCase()); - if (!result) return false; + if (type_ != other.type_) return false; + if (!getLanguage().equals(other.getLanguage())) return false; + if (!getSourceCase().equals(other.getSourceCase())) return false; switch (sourceCase_) { case 2: - result = result && getContent().equals(other.getContent()); + if (!getContent().equals(other.getContent())) return false; break; case 3: - result = result && getGcsContentUri().equals(other.getGcsContentUri()); + if (!getGcsContentUri().equals(other.getGcsContentUri())) return false; break; case 0: default: } - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -797,35 +795,35 @@ public com.google.cloud.language.v1beta2.Document buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -1347,7 +1345,7 @@ public Builder setLanguageBytes(com.google.protobuf.ByteString value) { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/Entity.java b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/Entity.java index d29a5e695a43..7869b787e2c7 100644 --- a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/Entity.java +++ b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/Entity.java @@ -27,7 +27,6 @@ private Entity(com.google.protobuf.GeneratedMessageV3.Builder builder) { private Entity() { name_ = ""; type_ = 0; - salience_ = 0F; mentions_ = java.util.Collections.emptyList(); } @@ -71,7 +70,7 @@ private Entity( } case 26: { - if (!((mutable_bitField0_ & 0x00000004) == 0x00000004)) { + if (!((mutable_bitField0_ & 0x00000004) != 0)) { metadata_ = com.google.protobuf.MapField.newMapField( MetadataDefaultEntryHolder.defaultEntry); @@ -91,7 +90,7 @@ private Entity( } case 42: { - if (!((mutable_bitField0_ & 0x00000010) == 0x00000010)) { + if (!((mutable_bitField0_ & 0x00000010) != 0)) { mentions_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000010; @@ -119,7 +118,7 @@ private Entity( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -131,7 +130,7 @@ private Entity( } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { - if (((mutable_bitField0_ & 0x00000010) == 0x00000010)) { + if (((mutable_bitField0_ & 0x00000010) != 0)) { mentions_ = java.util.Collections.unmodifiableList(mentions_); } this.unknownFields = unknownFields.build(); @@ -814,21 +813,18 @@ public boolean equals(final java.lang.Object obj) { } com.google.cloud.language.v1beta2.Entity other = (com.google.cloud.language.v1beta2.Entity) obj; - boolean result = true; - result = result && getName().equals(other.getName()); - result = result && type_ == other.type_; - result = result && internalGetMetadata().equals(other.internalGetMetadata()); - result = - result - && (java.lang.Float.floatToIntBits(getSalience()) - == java.lang.Float.floatToIntBits(other.getSalience())); - result = result && getMentionsList().equals(other.getMentionsList()); - result = result && (hasSentiment() == other.hasSentiment()); + if (!getName().equals(other.getName())) return false; + if (type_ != other.type_) return false; + if (!internalGetMetadata().equals(other.internalGetMetadata())) return false; + if (java.lang.Float.floatToIntBits(getSalience()) + != java.lang.Float.floatToIntBits(other.getSalience())) return false; + if (!getMentionsList().equals(other.getMentionsList())) return false; + if (hasSentiment() != other.hasSentiment()) return false; if (hasSentiment()) { - result = result && getSentiment().equals(other.getSentiment()); + if (!getSentiment().equals(other.getSentiment())) return false; } - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -1079,7 +1075,7 @@ public com.google.cloud.language.v1beta2.Entity buildPartial() { result.metadata_.makeImmutable(); result.salience_ = salience_; if (mentionsBuilder_ == null) { - if (((bitField0_ & 0x00000010) == 0x00000010)) { + if (((bitField0_ & 0x00000010) != 0)) { mentions_ = java.util.Collections.unmodifiableList(mentions_); bitField0_ = (bitField0_ & ~0x00000010); } @@ -1099,35 +1095,35 @@ public com.google.cloud.language.v1beta2.Entity buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -1611,7 +1607,7 @@ public Builder clearSalience() { java.util.Collections.emptyList(); private void ensureMentionsIsMutable() { - if (!((bitField0_ & 0x00000010) == 0x00000010)) { + if (!((bitField0_ & 0x00000010) != 0)) { mentions_ = new java.util.ArrayList(mentions_); bitField0_ |= 0x00000010; @@ -1971,16 +1967,13 @@ public com.google.cloud.language.v1beta2.EntityMention.Builder addMentionsBuilde com.google.cloud.language.v1beta2.EntityMention, com.google.cloud.language.v1beta2.EntityMention.Builder, com.google.cloud.language.v1beta2.EntityMentionOrBuilder>( - mentions_, - ((bitField0_ & 0x00000010) == 0x00000010), - getParentForChildren(), - isClean()); + mentions_, ((bitField0_ & 0x00000010) != 0), getParentForChildren(), isClean()); mentions_ = null; } return mentionsBuilder_; } - private com.google.cloud.language.v1beta2.Sentiment sentiment_ = null; + private com.google.cloud.language.v1beta2.Sentiment sentiment_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1beta2.Sentiment, com.google.cloud.language.v1beta2.Sentiment.Builder, @@ -2191,7 +2184,7 @@ public com.google.cloud.language.v1beta2.SentimentOrBuilder getSentimentOrBuilde @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/EntityMention.java b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/EntityMention.java index 7c9d2dabf322..41e3bdf41e5f 100644 --- a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/EntityMention.java +++ b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/EntityMention.java @@ -92,7 +92,7 @@ private EntityMention( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -447,18 +447,17 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1beta2.EntityMention other = (com.google.cloud.language.v1beta2.EntityMention) obj; - boolean result = true; - result = result && (hasText() == other.hasText()); + if (hasText() != other.hasText()) return false; if (hasText()) { - result = result && getText().equals(other.getText()); + if (!getText().equals(other.getText())) return false; } - result = result && type_ == other.type_; - result = result && (hasSentiment() == other.hasSentiment()); + if (type_ != other.type_) return false; + if (hasSentiment() != other.hasSentiment()) return false; if (hasSentiment()) { - result = result && getSentiment().equals(other.getSentiment()); + if (!getSentiment().equals(other.getSentiment())) return false; } - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -682,35 +681,35 @@ public com.google.cloud.language.v1beta2.EntityMention buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -764,7 +763,7 @@ public Builder mergeFrom( return this; } - private com.google.cloud.language.v1beta2.TextSpan text_ = null; + private com.google.cloud.language.v1beta2.TextSpan text_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1beta2.TextSpan, com.google.cloud.language.v1beta2.TextSpan.Builder, @@ -1023,7 +1022,7 @@ public Builder clearType() { return this; } - private com.google.cloud.language.v1beta2.Sentiment sentiment_ = null; + private com.google.cloud.language.v1beta2.Sentiment sentiment_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1beta2.Sentiment, com.google.cloud.language.v1beta2.Sentiment.Builder, @@ -1234,7 +1233,7 @@ public com.google.cloud.language.v1beta2.SentimentOrBuilder getSentimentOrBuilde @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/PartOfSpeech.java b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/PartOfSpeech.java index 0a2b3475ccf0..b702f3bd2257 100644 --- a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/PartOfSpeech.java +++ b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/PartOfSpeech.java @@ -147,7 +147,7 @@ private PartOfSpeech( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -3448,21 +3448,20 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1beta2.PartOfSpeech other = (com.google.cloud.language.v1beta2.PartOfSpeech) obj; - boolean result = true; - result = result && tag_ == other.tag_; - result = result && aspect_ == other.aspect_; - result = result && case_ == other.case_; - result = result && form_ == other.form_; - result = result && gender_ == other.gender_; - result = result && mood_ == other.mood_; - result = result && number_ == other.number_; - result = result && person_ == other.person_; - result = result && proper_ == other.proper_; - result = result && reciprocity_ == other.reciprocity_; - result = result && tense_ == other.tense_; - result = result && voice_ == other.voice_; - result = result && unknownFields.equals(other.unknownFields); - return result; + if (tag_ != other.tag_) return false; + if (aspect_ != other.aspect_) return false; + if (case_ != other.case_) return false; + if (form_ != other.form_) return false; + if (gender_ != other.gender_) return false; + if (mood_ != other.mood_) return false; + if (number_ != other.number_) return false; + if (person_ != other.person_) return false; + if (proper_ != other.proper_) return false; + if (reciprocity_ != other.reciprocity_) return false; + if (tense_ != other.tense_) return false; + if (voice_ != other.voice_) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -3710,35 +3709,35 @@ public com.google.cloud.language.v1beta2.PartOfSpeech buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -4757,7 +4756,7 @@ public Builder clearVoice() { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/Sentence.java b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/Sentence.java index cf287f4a783e..bd67ce27462e 100644 --- a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/Sentence.java +++ b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/Sentence.java @@ -82,7 +82,7 @@ private Sentence( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -251,17 +251,16 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1beta2.Sentence other = (com.google.cloud.language.v1beta2.Sentence) obj; - boolean result = true; - result = result && (hasText() == other.hasText()); + if (hasText() != other.hasText()) return false; if (hasText()) { - result = result && getText().equals(other.getText()); + if (!getText().equals(other.getText())) return false; } - result = result && (hasSentiment() == other.hasSentiment()); + if (hasSentiment() != other.hasSentiment()) return false; if (hasSentiment()) { - result = result && getSentiment().equals(other.getSentiment()); + if (!getSentiment().equals(other.getSentiment())) return false; } - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -479,35 +478,35 @@ public com.google.cloud.language.v1beta2.Sentence buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -557,7 +556,7 @@ public Builder mergeFrom( return this; } - private com.google.cloud.language.v1beta2.TextSpan text_ = null; + private com.google.cloud.language.v1beta2.TextSpan text_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1beta2.TextSpan, com.google.cloud.language.v1beta2.TextSpan.Builder, @@ -738,7 +737,7 @@ public com.google.cloud.language.v1beta2.TextSpanOrBuilder getTextOrBuilder() { return textBuilder_; } - private com.google.cloud.language.v1beta2.Sentiment sentiment_ = null; + private com.google.cloud.language.v1beta2.Sentiment sentiment_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1beta2.Sentiment, com.google.cloud.language.v1beta2.Sentiment.Builder, @@ -940,7 +939,7 @@ public com.google.cloud.language.v1beta2.SentimentOrBuilder getSentimentOrBuilde @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/Sentiment.java b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/Sentiment.java index ad5ed7996a6d..b40d06bf8ee0 100644 --- a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/Sentiment.java +++ b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/Sentiment.java @@ -23,10 +23,7 @@ private Sentiment(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } - private Sentiment() { - magnitude_ = 0F; - score_ = 0F; - } + private Sentiment() {} @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { @@ -64,7 +61,7 @@ private Sentiment( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -180,17 +177,12 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1beta2.Sentiment other = (com.google.cloud.language.v1beta2.Sentiment) obj; - boolean result = true; - result = - result - && (java.lang.Float.floatToIntBits(getMagnitude()) - == java.lang.Float.floatToIntBits(other.getMagnitude())); - result = - result - && (java.lang.Float.floatToIntBits(getScore()) - == java.lang.Float.floatToIntBits(other.getScore())); - result = result && unknownFields.equals(other.unknownFields); - return result; + if (java.lang.Float.floatToIntBits(getMagnitude()) + != java.lang.Float.floatToIntBits(other.getMagnitude())) return false; + if (java.lang.Float.floatToIntBits(getScore()) + != java.lang.Float.floatToIntBits(other.getScore())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -389,35 +381,35 @@ public com.google.cloud.language.v1beta2.Sentiment buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -566,7 +558,7 @@ public Builder clearScore() { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/TextSpan.java b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/TextSpan.java index ddb1c7710c2a..7f82a2ec253b 100644 --- a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/TextSpan.java +++ b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/TextSpan.java @@ -24,7 +24,6 @@ private TextSpan(com.google.protobuf.GeneratedMessageV3.Builder builder) { private TextSpan() { content_ = ""; - beginOffset_ = 0; } @java.lang.Override @@ -65,7 +64,7 @@ private TextSpan( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -209,11 +208,10 @@ public boolean equals(final java.lang.Object obj) { com.google.cloud.language.v1beta2.TextSpan other = (com.google.cloud.language.v1beta2.TextSpan) obj; - boolean result = true; - result = result && getContent().equals(other.getContent()); - result = result && (getBeginOffset() == other.getBeginOffset()); - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!getContent().equals(other.getContent())) return false; + if (getBeginOffset() != other.getBeginOffset()) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -411,35 +409,35 @@ public com.google.cloud.language.v1beta2.TextSpan buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -639,7 +637,7 @@ public Builder clearBeginOffset() { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/Token.java b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/Token.java index 8cbfef147d9c..99e8e26df116 100644 --- a/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/Token.java +++ b/google-api-grpc/proto-google-cloud-language-v1beta2/src/main/java/com/google/cloud/language/v1beta2/Token.java @@ -107,7 +107,7 @@ private Token( } default: { - if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; @@ -365,22 +365,21 @@ public boolean equals(final java.lang.Object obj) { } com.google.cloud.language.v1beta2.Token other = (com.google.cloud.language.v1beta2.Token) obj; - boolean result = true; - result = result && (hasText() == other.hasText()); + if (hasText() != other.hasText()) return false; if (hasText()) { - result = result && getText().equals(other.getText()); + if (!getText().equals(other.getText())) return false; } - result = result && (hasPartOfSpeech() == other.hasPartOfSpeech()); + if (hasPartOfSpeech() != other.hasPartOfSpeech()) return false; if (hasPartOfSpeech()) { - result = result && getPartOfSpeech().equals(other.getPartOfSpeech()); + if (!getPartOfSpeech().equals(other.getPartOfSpeech())) return false; } - result = result && (hasDependencyEdge() == other.hasDependencyEdge()); + if (hasDependencyEdge() != other.hasDependencyEdge()) return false; if (hasDependencyEdge()) { - result = result && getDependencyEdge().equals(other.getDependencyEdge()); + if (!getDependencyEdge().equals(other.getDependencyEdge())) return false; } - result = result && getLemma().equals(other.getLemma()); - result = result && unknownFields.equals(other.unknownFields); - return result; + if (!getLemma().equals(other.getLemma())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override @@ -618,35 +617,35 @@ public com.google.cloud.language.v1beta2.Token buildPartial() { @java.lang.Override public Builder clone() { - return (Builder) super.clone(); + return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.setField(field, value); + return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); + return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); + return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); + return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); + return super.addRepeatedField(field, value); } @java.lang.Override @@ -703,7 +702,7 @@ public Builder mergeFrom( return this; } - private com.google.cloud.language.v1beta2.TextSpan text_ = null; + private com.google.cloud.language.v1beta2.TextSpan text_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1beta2.TextSpan, com.google.cloud.language.v1beta2.TextSpan.Builder, @@ -884,7 +883,7 @@ public com.google.cloud.language.v1beta2.TextSpanOrBuilder getTextOrBuilder() { return textBuilder_; } - private com.google.cloud.language.v1beta2.PartOfSpeech partOfSpeech_ = null; + private com.google.cloud.language.v1beta2.PartOfSpeech partOfSpeech_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1beta2.PartOfSpeech, com.google.cloud.language.v1beta2.PartOfSpeech.Builder, @@ -1066,7 +1065,7 @@ public com.google.cloud.language.v1beta2.PartOfSpeechOrBuilder getPartOfSpeechOr return partOfSpeechBuilder_; } - private com.google.cloud.language.v1beta2.DependencyEdge dependencyEdge_ = null; + private com.google.cloud.language.v1beta2.DependencyEdge dependencyEdge_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.language.v1beta2.DependencyEdge, com.google.cloud.language.v1beta2.DependencyEdge.Builder, @@ -1344,7 +1343,7 @@ public Builder setLemmaBytes(com.google.protobuf.ByteString value) { @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); + return super.setUnknownFields(unknownFields); } @java.lang.Override diff --git a/google-cloud-clients/google-cloud-language/synth.metadata b/google-cloud-clients/google-cloud-language/synth.metadata index 0711f7f4fb8b..66374dc865d1 100644 --- a/google-cloud-clients/google-cloud-language/synth.metadata +++ b/google-cloud-clients/google-cloud-language/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-03-14T07:46:10.361867Z", + "updateTime": "2019-03-29T07:49:02.070836Z", "sources": [ { "generator": { "name": "artman", - "version": "0.16.17", - "dockerImage": "googleapis/artman@sha256:7231f27272231a884e09edb5953148c85ecd8467780d33c4a35c3e507885715b" + "version": "0.16.21", + "dockerImage": "googleapis/artman@sha256:854131ec1af7b3a313253474c24748dc0acd217a58a0b74dbfb559f340a15d78" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "d05a746ba27b89374c7407c88c0d5dabfb0afc7c", - "internalRef": "238372434" + "sha": "37386f1ebcaed51bcb7d15d00124d22c38606e45", + "internalRef": "240841842" } } ],