WIP: upgrade deps

This commit is contained in:
Nex Zhu 2025-03-21 19:34:08 +08:00
parent 65e70efbb9
commit e6c1ca0e06
49 changed files with 5523 additions and 5450 deletions

View File

@ -1,3 +1,7 @@
{ {
"java.configuration.updateBuildConfiguration": "interactive" "java.configuration.updateBuildConfiguration": "interactive",
"java.project.sourcePaths": [
"src"
],
"java.compile.nullAnalysis.mode": "automatic"
} }

View File

@ -1,92 +1,94 @@
buildscript { buildscript {
repositories { repositories {
mavenCentral() mavenCentral()
} }
dependencies { dependencies {
classpath 'com.google.protobuf:protobuf-gradle-plugin:0.8.13' classpath 'com.google.protobuf:protobuf-gradle-plugin:0.9.4'
} }
} }
plugins { plugins {
id 'java' id 'java'
id 'com.google.protobuf' version '0.9.1' id 'com.google.protobuf' version '0.9.4'
id 'com.github.johnrengelman.shadow' version '6.0.0' id 'com.github.johnrengelman.shadow' version '7.1.2'
} }
group 'org.bdware' group = 'org.bdware'
version 'dev-221113' version = 'dev-221113'
compileJava { java {
sourceCompatibility = JavaVersion.VERSION_1_8 sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8 targetCompatibility = JavaVersion.VERSION_1_8
} }
def grpc_java_version = '1.41.0' def protobuf_version = '3.25.6'
def junit_version = '5.7.0' def grpc_java_version = '1.71.0'
def junit_version = '5.12.1'
tasks.withType(JavaCompile) {
options.encoding = "UTF-8" tasks.withType(JavaCompile) {
} options.encoding = "UTF-8"
}
sourceSets {
main { sourceSets {
proto { main {
// In addition to the default 'src/main/proto' proto {
srcDir 'api/grpc/pb' // In addition to the default 'src/main/proto'
} srcDir 'api/grpc/pb'
} }
} }
}
test {
useJUnitPlatform() test {
// testLogging { useJUnitPlatform()
// events "passed", "skipped", "failed" // testLogging {
// } // events "passed", "skipped", "failed"
} // }
}
javadoc {
source = sourceSets.main.allJava javadoc {
classpath = configurations.runtimeClasspath source = sourceSets.main.allJava
options { classpath = configurations.compileClasspath
encoding 'UTF-8' options {
charSet 'UTF-8' encoding = 'UTF-8'
title "BDLedger Java SDK API" charSet = 'UTF-8'
} title = "BDLedger Java SDK API"
} }
}
protobuf {
protoc { protobuf {
artifact = "com.google.protobuf:protoc:3.13.0" protoc {
} artifact = "com.google.protobuf:protoc:" + protobuf_version
plugins { }
grpc { plugins {
artifact = 'io.grpc:protoc-gen-grpc-java:' + grpc_java_version grpc {
} artifact = 'io.grpc:protoc-gen-grpc-java:' + grpc_java_version
} }
generatedFilesBaseDir = "$projectDir/src" }
generateProtoTasks { generatedFilesBaseDir = "$projectDir/src"
all()*.plugins { generateProtoTasks {
grpc { all().each { task ->
outputSubDir = 'java' task.plugins {
} grpc {
} outputSubDir = 'java'
} }
} }
}
repositories { }
mavenCentral() }
}
repositories {
dependencies { mavenCentral()
implementation 'io.grpc:grpc-netty-shaded:' + grpc_java_version }
implementation 'io.grpc:grpc-protobuf:' + grpc_java_version
implementation 'io.grpc:grpc-stub:' + grpc_java_version dependencies {
if (JavaVersion.current().isJava9Compatible()) { implementation 'com.google.protobuf:protobuf-java:' + protobuf_version
// Workaround for @javax.annotation.Generated runtimeOnly 'io.grpc:grpc-netty-shaded:' + grpc_java_version
// see: https://github.com/grpc/grpc-java/issues/3633 implementation 'io.grpc:grpc-protobuf:' + grpc_java_version
implementation 'javax.annotation:javax.annotation-api:1.3.2' implementation 'io.grpc:grpc-stub:' + grpc_java_version
} if (JavaVersion.current().isJava9Compatible()) {
testImplementation 'org.junit.jupiter:junit-jupiter-api:' + junit_version compileOnly 'org.apache.tomcat:annotations-api:6.0.53'
testImplementation 'org.junit.jupiter:junit-jupiter-params:' + junit_version }
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:' + junit_version testImplementation 'org.junit.jupiter:junit-jupiter-api:' + junit_version
} testImplementation 'org.junit.jupiter:junit-jupiter-params:' + junit_version
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:' + junit_version
}

View File

@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-7.5.1-bin.zip distributionUrl=https\://services.gradle.org/distributions/gradle-8.13-bin.zip
zipStoreBase=GRADLE_USER_HOME zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists zipStorePath=wrapper/dists

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/api/annotations.proto // source: google/api/annotations.proto
// Protobuf Java Version: 3.25.6
package com.google.api; package com.google.api;
public final class AnnotationsProto { public final class AnnotationsProto {

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/api/http.proto // source: google/api/http.proto
// Protobuf Java Version: 3.25.6
package com.google.api; package com.google.api;
/** /**
@ -31,60 +32,6 @@ private static final long serialVersionUID = 0L;
return new CustomHttpPattern(); return new CustomHttpPattern();
} }
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private CustomHttpPattern(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
java.lang.String s = input.readStringRequireUtf8();
kind_ = s;
break;
}
case 18: {
java.lang.String s = input.readStringRequireUtf8();
path_ = s;
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() { getDescriptor() {
return com.google.api.HttpProto.internal_static_google_api_CustomHttpPattern_descriptor; return com.google.api.HttpProto.internal_static_google_api_CustomHttpPattern_descriptor;
@ -99,7 +46,8 @@ private static final long serialVersionUID = 0L;
} }
public static final int KIND_FIELD_NUMBER = 1; public static final int KIND_FIELD_NUMBER = 1;
private volatile java.lang.Object kind_; @SuppressWarnings("serial")
private volatile java.lang.Object kind_ = "";
/** /**
* <pre> * <pre>
* The name of this custom HTTP verb. * The name of this custom HTTP verb.
@ -145,7 +93,8 @@ private static final long serialVersionUID = 0L;
} }
public static final int PATH_FIELD_NUMBER = 2; public static final int PATH_FIELD_NUMBER = 2;
private volatile java.lang.Object path_; @SuppressWarnings("serial")
private volatile java.lang.Object path_ = "";
/** /**
* <pre> * <pre>
* The path matched by this custom verb. * The path matched by this custom verb.
@ -204,13 +153,13 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output) public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException { throws java.io.IOException {
if (!getKindBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(kind_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, kind_); com.google.protobuf.GeneratedMessageV3.writeString(output, 1, kind_);
} }
if (!getPathBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(path_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, path_); com.google.protobuf.GeneratedMessageV3.writeString(output, 2, path_);
} }
unknownFields.writeTo(output); getUnknownFields().writeTo(output);
} }
@java.lang.Override @java.lang.Override
@ -219,13 +168,13 @@ private static final long serialVersionUID = 0L;
if (size != -1) return size; if (size != -1) return size;
size = 0; size = 0;
if (!getKindBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(kind_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, kind_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, kind_);
} }
if (!getPathBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(path_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, path_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, path_);
} }
size += unknownFields.getSerializedSize(); size += getUnknownFields().getSerializedSize();
memoizedSize = size; memoizedSize = size;
return size; return size;
} }
@ -244,7 +193,7 @@ private static final long serialVersionUID = 0L;
.equals(other.getKind())) return false; .equals(other.getKind())) return false;
if (!getPath() if (!getPath()
.equals(other.getPath())) return false; .equals(other.getPath())) return false;
if (!unknownFields.equals(other.unknownFields)) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true; return true;
} }
@ -259,7 +208,7 @@ private static final long serialVersionUID = 0L;
hash = (53 * hash) + getKind().hashCode(); hash = (53 * hash) + getKind().hashCode();
hash = (37 * hash) + PATH_FIELD_NUMBER; hash = (37 * hash) + PATH_FIELD_NUMBER;
hash = (53 * hash) + getPath().hashCode(); hash = (53 * hash) + getPath().hashCode();
hash = (29 * hash) + unknownFields.hashCode(); hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash; memoizedHashCode = hash;
return hash; return hash;
} }
@ -308,11 +257,13 @@ private static final long serialVersionUID = 0L;
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry); .parseWithIOException(PARSER, input, extensionRegistry);
} }
public static com.google.api.CustomHttpPattern parseDelimitedFrom(java.io.InputStream input) public static com.google.api.CustomHttpPattern parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException { throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input); .parseDelimitedWithIOException(PARSER, input);
} }
public static com.google.api.CustomHttpPattern parseDelimitedFrom( public static com.google.api.CustomHttpPattern parseDelimitedFrom(
java.io.InputStream input, java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
@ -380,26 +331,20 @@ private static final long serialVersionUID = 0L;
// Construct using com.google.api.CustomHttpPattern.newBuilder() // Construct using com.google.api.CustomHttpPattern.newBuilder()
private Builder() { private Builder() {
maybeForceBuilderInitialization();
} }
private Builder( private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent); super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
} }
@java.lang.Override @java.lang.Override
public Builder clear() { public Builder clear() {
super.clear(); super.clear();
bitField0_ = 0;
kind_ = ""; kind_ = "";
path_ = ""; path_ = "";
return this; return this;
} }
@ -426,12 +371,21 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public com.google.api.CustomHttpPattern buildPartial() { public com.google.api.CustomHttpPattern buildPartial() {
com.google.api.CustomHttpPattern result = new com.google.api.CustomHttpPattern(this); com.google.api.CustomHttpPattern result = new com.google.api.CustomHttpPattern(this);
result.kind_ = kind_; if (bitField0_ != 0) { buildPartial0(result); }
result.path_ = path_;
onBuilt(); onBuilt();
return result; return result;
} }
private void buildPartial0(com.google.api.CustomHttpPattern result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.kind_ = kind_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.path_ = path_;
}
}
@java.lang.Override @java.lang.Override
public Builder clone() { public Builder clone() {
return super.clone(); return super.clone();
@ -478,13 +432,15 @@ private static final long serialVersionUID = 0L;
if (other == com.google.api.CustomHttpPattern.getDefaultInstance()) return this; if (other == com.google.api.CustomHttpPattern.getDefaultInstance()) return this;
if (!other.getKind().isEmpty()) { if (!other.getKind().isEmpty()) {
kind_ = other.kind_; kind_ = other.kind_;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
} }
if (!other.getPath().isEmpty()) { if (!other.getPath().isEmpty()) {
path_ = other.path_; path_ = other.path_;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
} }
this.mergeUnknownFields(other.unknownFields); this.mergeUnknownFields(other.getUnknownFields());
onChanged(); onChanged();
return this; return this;
} }
@ -499,19 +455,43 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException { throws java.io.IOException {
com.google.api.CustomHttpPattern parsedMessage = null; if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try { try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
kind_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 18: {
path_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000002;
break;
} // case 18
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) { } catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.google.api.CustomHttpPattern) e.getUnfinishedMessage();
throw e.unwrapIOException(); throw e.unwrapIOException();
} finally { } finally {
if (parsedMessage != null) { onChanged();
mergeFrom(parsedMessage); } // finally
}
}
return this; return this;
} }
private int bitField0_;
private java.lang.Object kind_ = ""; private java.lang.Object kind_ = "";
/** /**
@ -566,11 +546,9 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setKind( public Builder setKind(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
kind_ = value; kind_ = value;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -583,8 +561,8 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearKind() { public Builder clearKind() {
kind_ = getDefaultInstance().getKind(); kind_ = getDefaultInstance().getKind();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged(); onChanged();
return this; return this;
} }
@ -599,12 +577,10 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setKindBytes( public Builder setKindBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
kind_ = value; kind_ = value;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -662,11 +638,9 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setPath( public Builder setPath(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
path_ = value; path_ = value;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
return this; return this;
} }
@ -679,8 +653,8 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearPath() { public Builder clearPath() {
path_ = getDefaultInstance().getPath(); path_ = getDefaultInstance().getPath();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged(); onChanged();
return this; return this;
} }
@ -695,12 +669,10 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setPathBytes( public Builder setPathBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
path_ = value; path_ = value;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
return this; return this;
} }
@ -737,7 +709,18 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException { throws com.google.protobuf.InvalidProtocolBufferException {
return new CustomHttpPattern(input, extensionRegistry); Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
} }
}; };

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/api/http.proto // source: google/api/http.proto
// Protobuf Java Version: 3.25.6
package com.google.api; package com.google.api;
public interface CustomHttpPatternOrBuilder extends public interface CustomHttpPatternOrBuilder extends

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/api/http.proto // source: google/api/http.proto
// Protobuf Java Version: 3.25.6
package com.google.api; package com.google.api;
/** /**
@ -32,66 +33,6 @@ private static final long serialVersionUID = 0L;
return new Http(); return new Http();
} }
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private Http(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
int mutable_bitField0_ = 0;
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
if (!((mutable_bitField0_ & 0x00000001) != 0)) {
rules_ = new java.util.ArrayList<com.google.api.HttpRule>();
mutable_bitField0_ |= 0x00000001;
}
rules_.add(
input.readMessage(com.google.api.HttpRule.parser(), extensionRegistry));
break;
}
case 16: {
fullyDecodeReservedExpansion_ = input.readBool();
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
if (((mutable_bitField0_ & 0x00000001) != 0)) {
rules_ = java.util.Collections.unmodifiableList(rules_);
}
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() { getDescriptor() {
return com.google.api.HttpProto.internal_static_google_api_Http_descriptor; return com.google.api.HttpProto.internal_static_google_api_Http_descriptor;
@ -106,10 +47,12 @@ private static final long serialVersionUID = 0L;
} }
public static final int RULES_FIELD_NUMBER = 1; public static final int RULES_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private java.util.List<com.google.api.HttpRule> rules_; private java.util.List<com.google.api.HttpRule> rules_;
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -122,6 +65,7 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -135,6 +79,7 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -147,6 +92,7 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -159,6 +105,7 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -171,12 +118,13 @@ private static final long serialVersionUID = 0L;
} }
public static final int FULLY_DECODE_RESERVED_EXPANSION_FIELD_NUMBER = 2; public static final int FULLY_DECODE_RESERVED_EXPANSION_FIELD_NUMBER = 2;
private boolean fullyDecodeReservedExpansion_; private boolean fullyDecodeReservedExpansion_ = false;
/** /**
* <pre> * <pre>
* When set to true, URL path parmeters will be fully URI-decoded except in * When set to true, URL path parmeters will be fully URI-decoded except in
* cases of single segment matches in reserved expansion, where "%2F" will be * cases of single segment matches in reserved expansion, where "%2F" will be
* left encoded. * left encoded.
*
* The default behavior is to not decode RFC 6570 reserved characters in multi * The default behavior is to not decode RFC 6570 reserved characters in multi
* segment matches. * segment matches.
* </pre> * </pre>
@ -209,7 +157,7 @@ private static final long serialVersionUID = 0L;
if (fullyDecodeReservedExpansion_ != false) { if (fullyDecodeReservedExpansion_ != false) {
output.writeBool(2, fullyDecodeReservedExpansion_); output.writeBool(2, fullyDecodeReservedExpansion_);
} }
unknownFields.writeTo(output); getUnknownFields().writeTo(output);
} }
@java.lang.Override @java.lang.Override
@ -226,7 +174,7 @@ private static final long serialVersionUID = 0L;
size += com.google.protobuf.CodedOutputStream size += com.google.protobuf.CodedOutputStream
.computeBoolSize(2, fullyDecodeReservedExpansion_); .computeBoolSize(2, fullyDecodeReservedExpansion_);
} }
size += unknownFields.getSerializedSize(); size += getUnknownFields().getSerializedSize();
memoizedSize = size; memoizedSize = size;
return size; return size;
} }
@ -245,7 +193,7 @@ private static final long serialVersionUID = 0L;
.equals(other.getRulesList())) return false; .equals(other.getRulesList())) return false;
if (getFullyDecodeReservedExpansion() if (getFullyDecodeReservedExpansion()
!= other.getFullyDecodeReservedExpansion()) return false; != other.getFullyDecodeReservedExpansion()) return false;
if (!unknownFields.equals(other.unknownFields)) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true; return true;
} }
@ -263,7 +211,7 @@ private static final long serialVersionUID = 0L;
hash = (37 * hash) + FULLY_DECODE_RESERVED_EXPANSION_FIELD_NUMBER; hash = (37 * hash) + FULLY_DECODE_RESERVED_EXPANSION_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean( hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
getFullyDecodeReservedExpansion()); getFullyDecodeReservedExpansion());
hash = (29 * hash) + unknownFields.hashCode(); hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash; memoizedHashCode = hash;
return hash; return hash;
} }
@ -312,11 +260,13 @@ private static final long serialVersionUID = 0L;
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry); .parseWithIOException(PARSER, input, extensionRegistry);
} }
public static com.google.api.Http parseDelimitedFrom(java.io.InputStream input) public static com.google.api.Http parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException { throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input); .parseDelimitedWithIOException(PARSER, input);
} }
public static com.google.api.Http parseDelimitedFrom( public static com.google.api.Http parseDelimitedFrom(
java.io.InputStream input, java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
@ -386,31 +336,26 @@ private static final long serialVersionUID = 0L;
// Construct using com.google.api.Http.newBuilder() // Construct using com.google.api.Http.newBuilder()
private Builder() { private Builder() {
maybeForceBuilderInitialization();
} }
private Builder( private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent); super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getRulesFieldBuilder();
}
} }
@java.lang.Override @java.lang.Override
public Builder clear() { public Builder clear() {
super.clear(); super.clear();
bitField0_ = 0;
if (rulesBuilder_ == null) { if (rulesBuilder_ == null) {
rules_ = java.util.Collections.emptyList(); rules_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001);
} else { } else {
rules_ = null;
rulesBuilder_.clear(); rulesBuilder_.clear();
} }
bitField0_ = (bitField0_ & ~0x00000001);
fullyDecodeReservedExpansion_ = false; fullyDecodeReservedExpansion_ = false;
return this; return this;
} }
@ -437,7 +382,13 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public com.google.api.Http buildPartial() { public com.google.api.Http buildPartial() {
com.google.api.Http result = new com.google.api.Http(this); com.google.api.Http result = new com.google.api.Http(this);
int from_bitField0_ = bitField0_; buildPartialRepeatedFields(result);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartialRepeatedFields(com.google.api.Http result) {
if (rulesBuilder_ == null) { if (rulesBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0)) { if (((bitField0_ & 0x00000001) != 0)) {
rules_ = java.util.Collections.unmodifiableList(rules_); rules_ = java.util.Collections.unmodifiableList(rules_);
@ -447,9 +398,13 @@ private static final long serialVersionUID = 0L;
} else { } else {
result.rules_ = rulesBuilder_.build(); result.rules_ = rulesBuilder_.build();
} }
result.fullyDecodeReservedExpansion_ = fullyDecodeReservedExpansion_; }
onBuilt();
return result; private void buildPartial0(com.google.api.Http result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000002) != 0)) {
result.fullyDecodeReservedExpansion_ = fullyDecodeReservedExpansion_;
}
} }
@java.lang.Override @java.lang.Override
@ -525,7 +480,7 @@ private static final long serialVersionUID = 0L;
if (other.getFullyDecodeReservedExpansion() != false) { if (other.getFullyDecodeReservedExpansion() != false) {
setFullyDecodeReservedExpansion(other.getFullyDecodeReservedExpansion()); setFullyDecodeReservedExpansion(other.getFullyDecodeReservedExpansion());
} }
this.mergeUnknownFields(other.unknownFields); this.mergeUnknownFields(other.getUnknownFields());
onChanged(); onChanged();
return this; return this;
} }
@ -540,17 +495,48 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException { throws java.io.IOException {
com.google.api.Http parsedMessage = null; if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try { try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
com.google.api.HttpRule m =
input.readMessage(
com.google.api.HttpRule.parser(),
extensionRegistry);
if (rulesBuilder_ == null) {
ensureRulesIsMutable();
rules_.add(m);
} else {
rulesBuilder_.addMessage(m);
}
break;
} // case 10
case 16: {
fullyDecodeReservedExpansion_ = input.readBool();
bitField0_ |= 0x00000002;
break;
} // case 16
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) { } catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.google.api.Http) e.getUnfinishedMessage();
throw e.unwrapIOException(); throw e.unwrapIOException();
} finally { } finally {
if (parsedMessage != null) { onChanged();
mergeFrom(parsedMessage); } // finally
}
}
return this; return this;
} }
private int bitField0_; private int bitField0_;
@ -570,6 +556,7 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -585,6 +572,7 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -600,6 +588,7 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -615,6 +604,7 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -637,6 +627,7 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -656,6 +647,7 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -677,6 +669,7 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -699,6 +692,7 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -718,6 +712,7 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -737,6 +732,7 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -757,6 +753,7 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -775,6 +772,7 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -793,6 +791,7 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -805,6 +804,7 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -820,6 +820,7 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -836,6 +837,7 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -848,6 +850,7 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -861,6 +864,7 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -891,6 +895,7 @@ private static final long serialVersionUID = 0L;
* When set to true, URL path parmeters will be fully URI-decoded except in * When set to true, URL path parmeters will be fully URI-decoded except in
* cases of single segment matches in reserved expansion, where "%2F" will be * cases of single segment matches in reserved expansion, where "%2F" will be
* left encoded. * left encoded.
*
* The default behavior is to not decode RFC 6570 reserved characters in multi * The default behavior is to not decode RFC 6570 reserved characters in multi
* segment matches. * segment matches.
* </pre> * </pre>
@ -907,6 +912,7 @@ private static final long serialVersionUID = 0L;
* When set to true, URL path parmeters will be fully URI-decoded except in * When set to true, URL path parmeters will be fully URI-decoded except in
* cases of single segment matches in reserved expansion, where "%2F" will be * cases of single segment matches in reserved expansion, where "%2F" will be
* left encoded. * left encoded.
*
* The default behavior is to not decode RFC 6570 reserved characters in multi * The default behavior is to not decode RFC 6570 reserved characters in multi
* segment matches. * segment matches.
* </pre> * </pre>
@ -916,8 +922,9 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder setFullyDecodeReservedExpansion(boolean value) { public Builder setFullyDecodeReservedExpansion(boolean value) {
fullyDecodeReservedExpansion_ = value; fullyDecodeReservedExpansion_ = value;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
return this; return this;
} }
@ -926,6 +933,7 @@ private static final long serialVersionUID = 0L;
* When set to true, URL path parmeters will be fully URI-decoded except in * When set to true, URL path parmeters will be fully URI-decoded except in
* cases of single segment matches in reserved expansion, where "%2F" will be * cases of single segment matches in reserved expansion, where "%2F" will be
* left encoded. * left encoded.
*
* The default behavior is to not decode RFC 6570 reserved characters in multi * The default behavior is to not decode RFC 6570 reserved characters in multi
* segment matches. * segment matches.
* </pre> * </pre>
@ -934,7 +942,7 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearFullyDecodeReservedExpansion() { public Builder clearFullyDecodeReservedExpansion() {
bitField0_ = (bitField0_ & ~0x00000002);
fullyDecodeReservedExpansion_ = false; fullyDecodeReservedExpansion_ = false;
onChanged(); onChanged();
return this; return this;
@ -972,7 +980,18 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException { throws com.google.protobuf.InvalidProtocolBufferException {
return new Http(input, extensionRegistry); Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
} }
}; };

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/api/httpbody.proto // source: google/api/httpbody.proto
// Protobuf Java Version: 3.25.6
package com.google.api; package com.google.api;
/** /**
@ -8,30 +9,40 @@ package com.google.api;
* Message that represents an arbitrary HTTP body. It should only be used for * Message that represents an arbitrary HTTP body. It should only be used for
* payload formats that can't be represented as JSON, such as raw binary or * payload formats that can't be represented as JSON, such as raw binary or
* an HTML page. * an HTML page.
*
*
* This message can be used both in streaming and non-streaming API methods in * This message can be used both in streaming and non-streaming API methods in
* the request as well as the response. * the request as well as the response.
*
* It can be used as a top-level request field, which is convenient if one * It can be used as a top-level request field, which is convenient if one
* wants to extract parameters from either the URL or HTTP template into the * wants to extract parameters from either the URL or HTTP template into the
* request fields and also want access to the raw HTTP body. * request fields and also want access to the raw HTTP body.
*
* Example: * Example:
*
* message GetResourceRequest { * message GetResourceRequest {
* // A unique request id. * // A unique request id.
* string request_id = 1; * string request_id = 1;
*
* // The raw HTTP body is bound to this field. * // The raw HTTP body is bound to this field.
* google.api.HttpBody http_body = 2; * google.api.HttpBody http_body = 2;
* } * }
*
* service ResourceService { * service ResourceService {
* rpc GetResource(GetResourceRequest) returns (google.api.HttpBody); * rpc GetResource(GetResourceRequest) returns (google.api.HttpBody);
* rpc UpdateResource(google.api.HttpBody) returns * rpc UpdateResource(google.api.HttpBody) returns
* (google.protobuf.Empty); * (google.protobuf.Empty);
* } * }
*
* Example with streaming methods: * Example with streaming methods:
*
* service CaldavService { * service CaldavService {
* rpc GetCalendar(stream google.api.HttpBody) * rpc GetCalendar(stream google.api.HttpBody)
* returns (stream google.api.HttpBody); * returns (stream google.api.HttpBody);
* rpc UpdateCalendar(stream google.api.HttpBody) * rpc UpdateCalendar(stream google.api.HttpBody)
* returns (stream google.api.HttpBody); * returns (stream google.api.HttpBody);
* } * }
*
* Use of this type only changes how the request and response bodies are * Use of this type only changes how the request and response bodies are
* handled, all other features will continue to work unchanged. * handled, all other features will continue to work unchanged.
* </pre> * </pre>
@ -60,72 +71,6 @@ private static final long serialVersionUID = 0L;
return new HttpBody(); return new HttpBody();
} }
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private HttpBody(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
int mutable_bitField0_ = 0;
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
java.lang.String s = input.readStringRequireUtf8();
contentType_ = s;
break;
}
case 18: {
data_ = input.readBytes();
break;
}
case 26: {
if (!((mutable_bitField0_ & 0x00000001) != 0)) {
extensions_ = new java.util.ArrayList<com.google.protobuf.Any>();
mutable_bitField0_ |= 0x00000001;
}
extensions_.add(
input.readMessage(com.google.protobuf.Any.parser(), extensionRegistry));
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
if (((mutable_bitField0_ & 0x00000001) != 0)) {
extensions_ = java.util.Collections.unmodifiableList(extensions_);
}
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() { getDescriptor() {
return com.google.api.HttpBodyProto.internal_static_google_api_HttpBody_descriptor; return com.google.api.HttpBodyProto.internal_static_google_api_HttpBody_descriptor;
@ -140,7 +85,8 @@ private static final long serialVersionUID = 0L;
} }
public static final int CONTENT_TYPE_FIELD_NUMBER = 1; public static final int CONTENT_TYPE_FIELD_NUMBER = 1;
private volatile java.lang.Object contentType_; @SuppressWarnings("serial")
private volatile java.lang.Object contentType_ = "";
/** /**
* <pre> * <pre>
* The HTTP Content-Type header value specifying the content type of the body. * The HTTP Content-Type header value specifying the content type of the body.
@ -186,7 +132,7 @@ private static final long serialVersionUID = 0L;
} }
public static final int DATA_FIELD_NUMBER = 2; public static final int DATA_FIELD_NUMBER = 2;
private com.google.protobuf.ByteString data_; private com.google.protobuf.ByteString data_ = com.google.protobuf.ByteString.EMPTY;
/** /**
* <pre> * <pre>
* The HTTP request/response body as raw binary. * The HTTP request/response body as raw binary.
@ -201,6 +147,7 @@ private static final long serialVersionUID = 0L;
} }
public static final int EXTENSIONS_FIELD_NUMBER = 3; public static final int EXTENSIONS_FIELD_NUMBER = 3;
@SuppressWarnings("serial")
private java.util.List<com.google.protobuf.Any> extensions_; private java.util.List<com.google.protobuf.Any> extensions_;
/** /**
* <pre> * <pre>
@ -279,7 +226,7 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output) public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException { throws java.io.IOException {
if (!getContentTypeBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(contentType_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, contentType_); com.google.protobuf.GeneratedMessageV3.writeString(output, 1, contentType_);
} }
if (!data_.isEmpty()) { if (!data_.isEmpty()) {
@ -288,7 +235,7 @@ private static final long serialVersionUID = 0L;
for (int i = 0; i < extensions_.size(); i++) { for (int i = 0; i < extensions_.size(); i++) {
output.writeMessage(3, extensions_.get(i)); output.writeMessage(3, extensions_.get(i));
} }
unknownFields.writeTo(output); getUnknownFields().writeTo(output);
} }
@java.lang.Override @java.lang.Override
@ -297,7 +244,7 @@ private static final long serialVersionUID = 0L;
if (size != -1) return size; if (size != -1) return size;
size = 0; size = 0;
if (!getContentTypeBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(contentType_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, contentType_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, contentType_);
} }
if (!data_.isEmpty()) { if (!data_.isEmpty()) {
@ -308,7 +255,7 @@ private static final long serialVersionUID = 0L;
size += com.google.protobuf.CodedOutputStream size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, extensions_.get(i)); .computeMessageSize(3, extensions_.get(i));
} }
size += unknownFields.getSerializedSize(); size += getUnknownFields().getSerializedSize();
memoizedSize = size; memoizedSize = size;
return size; return size;
} }
@ -329,7 +276,7 @@ private static final long serialVersionUID = 0L;
.equals(other.getData())) return false; .equals(other.getData())) return false;
if (!getExtensionsList() if (!getExtensionsList()
.equals(other.getExtensionsList())) return false; .equals(other.getExtensionsList())) return false;
if (!unknownFields.equals(other.unknownFields)) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true; return true;
} }
@ -348,7 +295,7 @@ private static final long serialVersionUID = 0L;
hash = (37 * hash) + EXTENSIONS_FIELD_NUMBER; hash = (37 * hash) + EXTENSIONS_FIELD_NUMBER;
hash = (53 * hash) + getExtensionsList().hashCode(); hash = (53 * hash) + getExtensionsList().hashCode();
} }
hash = (29 * hash) + unknownFields.hashCode(); hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash; memoizedHashCode = hash;
return hash; return hash;
} }
@ -397,11 +344,13 @@ private static final long serialVersionUID = 0L;
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry); .parseWithIOException(PARSER, input, extensionRegistry);
} }
public static com.google.api.HttpBody parseDelimitedFrom(java.io.InputStream input) public static com.google.api.HttpBody parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException { throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input); .parseDelimitedWithIOException(PARSER, input);
} }
public static com.google.api.HttpBody parseDelimitedFrom( public static com.google.api.HttpBody parseDelimitedFrom(
java.io.InputStream input, java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
@ -448,30 +397,40 @@ private static final long serialVersionUID = 0L;
* Message that represents an arbitrary HTTP body. It should only be used for * Message that represents an arbitrary HTTP body. It should only be used for
* payload formats that can't be represented as JSON, such as raw binary or * payload formats that can't be represented as JSON, such as raw binary or
* an HTML page. * an HTML page.
*
*
* This message can be used both in streaming and non-streaming API methods in * This message can be used both in streaming and non-streaming API methods in
* the request as well as the response. * the request as well as the response.
*
* It can be used as a top-level request field, which is convenient if one * It can be used as a top-level request field, which is convenient if one
* wants to extract parameters from either the URL or HTTP template into the * wants to extract parameters from either the URL or HTTP template into the
* request fields and also want access to the raw HTTP body. * request fields and also want access to the raw HTTP body.
*
* Example: * Example:
*
* message GetResourceRequest { * message GetResourceRequest {
* // A unique request id. * // A unique request id.
* string request_id = 1; * string request_id = 1;
*
* // The raw HTTP body is bound to this field. * // The raw HTTP body is bound to this field.
* google.api.HttpBody http_body = 2; * google.api.HttpBody http_body = 2;
* } * }
*
* service ResourceService { * service ResourceService {
* rpc GetResource(GetResourceRequest) returns (google.api.HttpBody); * rpc GetResource(GetResourceRequest) returns (google.api.HttpBody);
* rpc UpdateResource(google.api.HttpBody) returns * rpc UpdateResource(google.api.HttpBody) returns
* (google.protobuf.Empty); * (google.protobuf.Empty);
* } * }
*
* Example with streaming methods: * Example with streaming methods:
*
* service CaldavService { * service CaldavService {
* rpc GetCalendar(stream google.api.HttpBody) * rpc GetCalendar(stream google.api.HttpBody)
* returns (stream google.api.HttpBody); * returns (stream google.api.HttpBody);
* rpc UpdateCalendar(stream google.api.HttpBody) * rpc UpdateCalendar(stream google.api.HttpBody)
* returns (stream google.api.HttpBody); * returns (stream google.api.HttpBody);
* } * }
*
* Use of this type only changes how the request and response bodies are * Use of this type only changes how the request and response bodies are
* handled, all other features will continue to work unchanged. * handled, all other features will continue to work unchanged.
* </pre> * </pre>
@ -497,33 +456,27 @@ private static final long serialVersionUID = 0L;
// Construct using com.google.api.HttpBody.newBuilder() // Construct using com.google.api.HttpBody.newBuilder()
private Builder() { private Builder() {
maybeForceBuilderInitialization();
} }
private Builder( private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent); super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getExtensionsFieldBuilder();
}
} }
@java.lang.Override @java.lang.Override
public Builder clear() { public Builder clear() {
super.clear(); super.clear();
bitField0_ = 0;
contentType_ = ""; contentType_ = "";
data_ = com.google.protobuf.ByteString.EMPTY; data_ = com.google.protobuf.ByteString.EMPTY;
if (extensionsBuilder_ == null) { if (extensionsBuilder_ == null) {
extensions_ = java.util.Collections.emptyList(); extensions_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001);
} else { } else {
extensions_ = null;
extensionsBuilder_.clear(); extensionsBuilder_.clear();
} }
bitField0_ = (bitField0_ & ~0x00000004);
return this; return this;
} }
@ -550,20 +503,32 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public com.google.api.HttpBody buildPartial() { public com.google.api.HttpBody buildPartial() {
com.google.api.HttpBody result = new com.google.api.HttpBody(this); com.google.api.HttpBody result = new com.google.api.HttpBody(this);
int from_bitField0_ = bitField0_; buildPartialRepeatedFields(result);
result.contentType_ = contentType_; if (bitField0_ != 0) { buildPartial0(result); }
result.data_ = data_; onBuilt();
return result;
}
private void buildPartialRepeatedFields(com.google.api.HttpBody result) {
if (extensionsBuilder_ == null) { if (extensionsBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0)) { if (((bitField0_ & 0x00000004) != 0)) {
extensions_ = java.util.Collections.unmodifiableList(extensions_); extensions_ = java.util.Collections.unmodifiableList(extensions_);
bitField0_ = (bitField0_ & ~0x00000001); bitField0_ = (bitField0_ & ~0x00000004);
} }
result.extensions_ = extensions_; result.extensions_ = extensions_;
} else { } else {
result.extensions_ = extensionsBuilder_.build(); result.extensions_ = extensionsBuilder_.build();
} }
onBuilt(); }
return result;
private void buildPartial0(com.google.api.HttpBody result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.contentType_ = contentType_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.data_ = data_;
}
} }
@java.lang.Override @java.lang.Override
@ -612,6 +577,7 @@ private static final long serialVersionUID = 0L;
if (other == com.google.api.HttpBody.getDefaultInstance()) return this; if (other == com.google.api.HttpBody.getDefaultInstance()) return this;
if (!other.getContentType().isEmpty()) { if (!other.getContentType().isEmpty()) {
contentType_ = other.contentType_; contentType_ = other.contentType_;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
} }
if (other.getData() != com.google.protobuf.ByteString.EMPTY) { if (other.getData() != com.google.protobuf.ByteString.EMPTY) {
@ -621,7 +587,7 @@ private static final long serialVersionUID = 0L;
if (!other.extensions_.isEmpty()) { if (!other.extensions_.isEmpty()) {
if (extensions_.isEmpty()) { if (extensions_.isEmpty()) {
extensions_ = other.extensions_; extensions_ = other.extensions_;
bitField0_ = (bitField0_ & ~0x00000001); bitField0_ = (bitField0_ & ~0x00000004);
} else { } else {
ensureExtensionsIsMutable(); ensureExtensionsIsMutable();
extensions_.addAll(other.extensions_); extensions_.addAll(other.extensions_);
@ -634,7 +600,7 @@ private static final long serialVersionUID = 0L;
extensionsBuilder_.dispose(); extensionsBuilder_.dispose();
extensionsBuilder_ = null; extensionsBuilder_ = null;
extensions_ = other.extensions_; extensions_ = other.extensions_;
bitField0_ = (bitField0_ & ~0x00000001); bitField0_ = (bitField0_ & ~0x00000004);
extensionsBuilder_ = extensionsBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getExtensionsFieldBuilder() : null; getExtensionsFieldBuilder() : null;
@ -643,7 +609,7 @@ private static final long serialVersionUID = 0L;
} }
} }
} }
this.mergeUnknownFields(other.unknownFields); this.mergeUnknownFields(other.getUnknownFields());
onChanged(); onChanged();
return this; return this;
} }
@ -658,17 +624,53 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException { throws java.io.IOException {
com.google.api.HttpBody parsedMessage = null; if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try { try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
contentType_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 18: {
data_ = input.readBytes();
bitField0_ |= 0x00000002;
break;
} // case 18
case 26: {
com.google.protobuf.Any m =
input.readMessage(
com.google.protobuf.Any.parser(),
extensionRegistry);
if (extensionsBuilder_ == null) {
ensureExtensionsIsMutable();
extensions_.add(m);
} else {
extensionsBuilder_.addMessage(m);
}
break;
} // case 26
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) { } catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.google.api.HttpBody) e.getUnfinishedMessage();
throw e.unwrapIOException(); throw e.unwrapIOException();
} finally { } finally {
if (parsedMessage != null) { onChanged();
mergeFrom(parsedMessage); } // finally
}
}
return this; return this;
} }
private int bitField0_; private int bitField0_;
@ -726,11 +728,9 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setContentType( public Builder setContentType(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
contentType_ = value; contentType_ = value;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -743,8 +743,8 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearContentType() { public Builder clearContentType() {
contentType_ = getDefaultInstance().getContentType(); contentType_ = getDefaultInstance().getContentType();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged(); onChanged();
return this; return this;
} }
@ -759,12 +759,10 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setContentTypeBytes( public Builder setContentTypeBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
contentType_ = value; contentType_ = value;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -792,11 +790,9 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder setData(com.google.protobuf.ByteString value) { public Builder setData(com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
data_ = value; data_ = value;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
return this; return this;
} }
@ -809,7 +805,7 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearData() { public Builder clearData() {
bitField0_ = (bitField0_ & ~0x00000002);
data_ = getDefaultInstance().getData(); data_ = getDefaultInstance().getData();
onChanged(); onChanged();
return this; return this;
@ -818,9 +814,9 @@ private static final long serialVersionUID = 0L;
private java.util.List<com.google.protobuf.Any> extensions_ = private java.util.List<com.google.protobuf.Any> extensions_ =
java.util.Collections.emptyList(); java.util.Collections.emptyList();
private void ensureExtensionsIsMutable() { private void ensureExtensionsIsMutable() {
if (!((bitField0_ & 0x00000001) != 0)) { if (!((bitField0_ & 0x00000004) != 0)) {
extensions_ = new java.util.ArrayList<com.google.protobuf.Any>(extensions_); extensions_ = new java.util.ArrayList<com.google.protobuf.Any>(extensions_);
bitField0_ |= 0x00000001; bitField0_ |= 0x00000004;
} }
} }
@ -1025,7 +1021,7 @@ private static final long serialVersionUID = 0L;
public Builder clearExtensions() { public Builder clearExtensions() {
if (extensionsBuilder_ == null) { if (extensionsBuilder_ == null) {
extensions_ = java.util.Collections.emptyList(); extensions_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001); bitField0_ = (bitField0_ & ~0x00000004);
onChanged(); onChanged();
} else { } else {
extensionsBuilder_.clear(); extensionsBuilder_.clear();
@ -1137,7 +1133,7 @@ private static final long serialVersionUID = 0L;
extensionsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< extensionsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
com.google.protobuf.Any, com.google.protobuf.Any.Builder, com.google.protobuf.AnyOrBuilder>( com.google.protobuf.Any, com.google.protobuf.Any.Builder, com.google.protobuf.AnyOrBuilder>(
extensions_, extensions_,
((bitField0_ & 0x00000001) != 0), ((bitField0_ & 0x00000004) != 0),
getParentForChildren(), getParentForChildren(),
isClean()); isClean());
extensions_ = null; extensions_ = null;
@ -1177,7 +1173,18 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException { throws com.google.protobuf.InvalidProtocolBufferException {
return new HttpBody(input, extensionRegistry); Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
} }
}; };

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/api/httpbody.proto // source: google/api/httpbody.proto
// Protobuf Java Version: 3.25.6
package com.google.api; package com.google.api;
public interface HttpBodyOrBuilder extends public interface HttpBodyOrBuilder extends

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/api/httpbody.proto // source: google/api/httpbody.proto
// Protobuf Java Version: 3.25.6
package com.google.api; package com.google.api;
public final class HttpBodyProto { public final class HttpBodyProto {

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/api/http.proto // source: google/api/http.proto
// Protobuf Java Version: 3.25.6
package com.google.api; package com.google.api;
public interface HttpOrBuilder extends public interface HttpOrBuilder extends
@ -10,6 +11,7 @@ public interface HttpOrBuilder extends
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -20,6 +22,7 @@ public interface HttpOrBuilder extends
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -29,6 +32,7 @@ public interface HttpOrBuilder extends
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -38,6 +42,7 @@ public interface HttpOrBuilder extends
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -48,6 +53,7 @@ public interface HttpOrBuilder extends
/** /**
* <pre> * <pre>
* A list of HTTP configuration rules that apply to individual API methods. * A list of HTTP configuration rules that apply to individual API methods.
*
* **NOTE:** All service configuration rules follow "last one wins" order. * **NOTE:** All service configuration rules follow "last one wins" order.
* </pre> * </pre>
* *
@ -61,6 +67,7 @@ public interface HttpOrBuilder extends
* When set to true, URL path parmeters will be fully URI-decoded except in * When set to true, URL path parmeters will be fully URI-decoded except in
* cases of single segment matches in reserved expansion, where "%2F" will be * cases of single segment matches in reserved expansion, where "%2F" will be
* left encoded. * left encoded.
*
* The default behavior is to not decode RFC 6570 reserved characters in multi * The default behavior is to not decode RFC 6570 reserved characters in multi
* segment matches. * segment matches.
* </pre> * </pre>

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/api/http.proto // source: google/api/http.proto
// Protobuf Java Version: 3.25.6
package com.google.api; package com.google.api;
public final class HttpProto { public final class HttpProto {

File diff suppressed because it is too large Load Diff

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/api/http.proto // source: google/api/http.proto
// Protobuf Java Version: 3.25.6
package com.google.api; package com.google.api;
public interface HttpRuleOrBuilder extends public interface HttpRuleOrBuilder extends
@ -10,6 +11,7 @@ public interface HttpRuleOrBuilder extends
/** /**
* <pre> * <pre>
* Selects methods to which this rule applies. * Selects methods to which this rule applies.
*
* Refer to [selector][google.api.DocumentationRule.selector] for syntax details. * Refer to [selector][google.api.DocumentationRule.selector] for syntax details.
* </pre> * </pre>
* *
@ -20,6 +22,7 @@ public interface HttpRuleOrBuilder extends
/** /**
* <pre> * <pre>
* Selects methods to which this rule applies. * Selects methods to which this rule applies.
*
* Refer to [selector][google.api.DocumentationRule.selector] for syntax details. * Refer to [selector][google.api.DocumentationRule.selector] for syntax details.
* </pre> * </pre>
* *
@ -29,6 +32,15 @@ public interface HttpRuleOrBuilder extends
com.google.protobuf.ByteString com.google.protobuf.ByteString
getSelectorBytes(); getSelectorBytes();
/**
* <pre>
* Used for listing and getting information about resources.
* </pre>
*
* <code>string get = 2;</code>
* @return Whether the get field is set.
*/
boolean hasGet();
/** /**
* <pre> * <pre>
* Used for listing and getting information about resources. * Used for listing and getting information about resources.
@ -49,6 +61,15 @@ public interface HttpRuleOrBuilder extends
com.google.protobuf.ByteString com.google.protobuf.ByteString
getGetBytes(); getGetBytes();
/**
* <pre>
* Used for updating a resource.
* </pre>
*
* <code>string put = 3;</code>
* @return Whether the put field is set.
*/
boolean hasPut();
/** /**
* <pre> * <pre>
* Used for updating a resource. * Used for updating a resource.
@ -69,6 +90,15 @@ public interface HttpRuleOrBuilder extends
com.google.protobuf.ByteString com.google.protobuf.ByteString
getPutBytes(); getPutBytes();
/**
* <pre>
* Used for creating a resource.
* </pre>
*
* <code>string post = 4;</code>
* @return Whether the post field is set.
*/
boolean hasPost();
/** /**
* <pre> * <pre>
* Used for creating a resource. * Used for creating a resource.
@ -89,6 +119,15 @@ public interface HttpRuleOrBuilder extends
com.google.protobuf.ByteString com.google.protobuf.ByteString
getPostBytes(); getPostBytes();
/**
* <pre>
* Used for deleting a resource.
* </pre>
*
* <code>string delete = 5;</code>
* @return Whether the delete field is set.
*/
boolean hasDelete();
/** /**
* <pre> * <pre>
* Used for deleting a resource. * Used for deleting a resource.
@ -109,6 +148,15 @@ public interface HttpRuleOrBuilder extends
com.google.protobuf.ByteString com.google.protobuf.ByteString
getDeleteBytes(); getDeleteBytes();
/**
* <pre>
* Used for updating a resource.
* </pre>
*
* <code>string patch = 6;</code>
* @return Whether the patch field is set.
*/
boolean hasPatch();
/** /**
* <pre> * <pre>
* Used for updating a resource. * Used for updating a resource.
@ -269,5 +317,5 @@ public interface HttpRuleOrBuilder extends
com.google.api.HttpRuleOrBuilder getAdditionalBindingsOrBuilder( com.google.api.HttpRuleOrBuilder getAdditionalBindingsOrBuilder(
int index); int index);
public com.google.api.HttpRule.PatternCase getPatternCase(); com.google.api.HttpRule.PatternCase getPatternCase();
} }

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/protobuf/empty.proto // source: google/protobuf/empty.proto
// Protobuf Java Version: 3.25.6
package com.google.protobuf; package com.google.protobuf;
/** /**
@ -8,9 +9,11 @@ package com.google.protobuf;
* A generic empty message that you can re-use to avoid defining duplicated * A generic empty message that you can re-use to avoid defining duplicated
* empty messages in your APIs. A typical example is to use it as the request * empty messages in your APIs. A typical example is to use it as the request
* or the response type of an API method. For instance: * or the response type of an API method. For instance:
*
* service Foo { * service Foo {
* rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); * rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
* } * }
*
* The JSON representation for `Empty` is empty JSON object `{}`. * The JSON representation for `Empty` is empty JSON object `{}`.
* </pre> * </pre>
* *
@ -35,48 +38,6 @@ private static final long serialVersionUID = 0L;
return new Empty(); return new Empty();
} }
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private Empty(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() { getDescriptor() {
return com.google.protobuf.EmptyProto.internal_static_google_protobuf_Empty_descriptor; return com.google.protobuf.EmptyProto.internal_static_google_protobuf_Empty_descriptor;
@ -104,7 +65,7 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output) public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException { throws java.io.IOException {
unknownFields.writeTo(output); getUnknownFields().writeTo(output);
} }
@java.lang.Override @java.lang.Override
@ -113,7 +74,7 @@ private static final long serialVersionUID = 0L;
if (size != -1) return size; if (size != -1) return size;
size = 0; size = 0;
size += unknownFields.getSerializedSize(); size += getUnknownFields().getSerializedSize();
memoizedSize = size; memoizedSize = size;
return size; return size;
} }
@ -128,7 +89,7 @@ private static final long serialVersionUID = 0L;
} }
com.google.protobuf.Empty other = (com.google.protobuf.Empty) obj; com.google.protobuf.Empty other = (com.google.protobuf.Empty) obj;
if (!unknownFields.equals(other.unknownFields)) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true; return true;
} }
@ -139,7 +100,7 @@ private static final long serialVersionUID = 0L;
} }
int hash = 41; int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode(); hash = (19 * hash) + getDescriptor().hashCode();
hash = (29 * hash) + unknownFields.hashCode(); hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash; memoizedHashCode = hash;
return hash; return hash;
} }
@ -188,11 +149,13 @@ private static final long serialVersionUID = 0L;
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry); .parseWithIOException(PARSER, input, extensionRegistry);
} }
public static com.google.protobuf.Empty parseDelimitedFrom(java.io.InputStream input) public static com.google.protobuf.Empty parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException { throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input); .parseDelimitedWithIOException(PARSER, input);
} }
public static com.google.protobuf.Empty parseDelimitedFrom( public static com.google.protobuf.Empty parseDelimitedFrom(
java.io.InputStream input, java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
@ -239,9 +202,11 @@ private static final long serialVersionUID = 0L;
* A generic empty message that you can re-use to avoid defining duplicated * A generic empty message that you can re-use to avoid defining duplicated
* empty messages in your APIs. A typical example is to use it as the request * empty messages in your APIs. A typical example is to use it as the request
* or the response type of an API method. For instance: * or the response type of an API method. For instance:
*
* service Foo { * service Foo {
* rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); * rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
* } * }
*
* The JSON representation for `Empty` is empty JSON object `{}`. * The JSON representation for `Empty` is empty JSON object `{}`.
* </pre> * </pre>
* *
@ -266,18 +231,13 @@ private static final long serialVersionUID = 0L;
// Construct using com.google.protobuf.Empty.newBuilder() // Construct using com.google.protobuf.Empty.newBuilder()
private Builder() { private Builder() {
maybeForceBuilderInitialization();
} }
private Builder( private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent); super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
} }
@java.lang.Override @java.lang.Override
public Builder clear() { public Builder clear() {
@ -356,7 +316,7 @@ private static final long serialVersionUID = 0L;
public Builder mergeFrom(com.google.protobuf.Empty other) { public Builder mergeFrom(com.google.protobuf.Empty other) {
if (other == com.google.protobuf.Empty.getDefaultInstance()) return this; if (other == com.google.protobuf.Empty.getDefaultInstance()) return this;
this.mergeUnknownFields(other.unknownFields); this.mergeUnknownFields(other.getUnknownFields());
onChanged(); onChanged();
return this; return this;
} }
@ -371,17 +331,30 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException { throws java.io.IOException {
com.google.protobuf.Empty parsedMessage = null; if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try { try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) { } catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.google.protobuf.Empty) e.getUnfinishedMessage();
throw e.unwrapIOException(); throw e.unwrapIOException();
} finally { } finally {
if (parsedMessage != null) { onChanged();
mergeFrom(parsedMessage); } // finally
}
}
return this; return this;
} }
@java.lang.Override @java.lang.Override
@ -417,7 +390,18 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException { throws com.google.protobuf.InvalidProtocolBufferException {
return new Empty(input, extensionRegistry); Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
} }
}; };

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/protobuf/empty.proto // source: google/protobuf/empty.proto
// Protobuf Java Version: 3.25.6
package com.google.protobuf; package com.google.protobuf;
public interface EmptyOrBuilder extends public interface EmptyOrBuilder extends

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/protobuf/empty.proto // source: google/protobuf/empty.proto
// Protobuf Java Version: 3.25.6
package com.google.protobuf; package com.google.protobuf;
public final class EmptyProto { public final class EmptyProto {

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/rpc/error_details.proto // source: google/rpc/error_details.proto
// Protobuf Java Version: 3.25.6
package com.google.rpc; package com.google.rpc;
/** /**
@ -31,61 +32,6 @@ private static final long serialVersionUID = 0L;
return new BadRequest(); return new BadRequest();
} }
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private BadRequest(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
int mutable_bitField0_ = 0;
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
if (!((mutable_bitField0_ & 0x00000001) != 0)) {
fieldViolations_ = new java.util.ArrayList<com.google.rpc.BadRequest.FieldViolation>();
mutable_bitField0_ |= 0x00000001;
}
fieldViolations_.add(
input.readMessage(com.google.rpc.BadRequest.FieldViolation.parser(), extensionRegistry));
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
if (((mutable_bitField0_ & 0x00000001) != 0)) {
fieldViolations_ = java.util.Collections.unmodifiableList(fieldViolations_);
}
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() { getDescriptor() {
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_BadRequest_descriptor; return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_BadRequest_descriptor;
@ -175,60 +121,6 @@ private static final long serialVersionUID = 0L;
return new FieldViolation(); return new FieldViolation();
} }
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private FieldViolation(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
java.lang.String s = input.readStringRequireUtf8();
field_ = s;
break;
}
case 18: {
java.lang.String s = input.readStringRequireUtf8();
description_ = s;
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() { getDescriptor() {
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_BadRequest_FieldViolation_descriptor; return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_BadRequest_FieldViolation_descriptor;
@ -243,7 +135,8 @@ private static final long serialVersionUID = 0L;
} }
public static final int FIELD_FIELD_NUMBER = 1; public static final int FIELD_FIELD_NUMBER = 1;
private volatile java.lang.Object field_; @SuppressWarnings("serial")
private volatile java.lang.Object field_ = "";
/** /**
* <pre> * <pre>
* A path leading to a field in the request body. The value will be a * A path leading to a field in the request body. The value will be a
@ -293,7 +186,8 @@ private static final long serialVersionUID = 0L;
} }
public static final int DESCRIPTION_FIELD_NUMBER = 2; public static final int DESCRIPTION_FIELD_NUMBER = 2;
private volatile java.lang.Object description_; @SuppressWarnings("serial")
private volatile java.lang.Object description_ = "";
/** /**
* <pre> * <pre>
* A description of why the request element is bad. * A description of why the request element is bad.
@ -352,13 +246,13 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output) public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException { throws java.io.IOException {
if (!getFieldBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(field_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, field_); com.google.protobuf.GeneratedMessageV3.writeString(output, 1, field_);
} }
if (!getDescriptionBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, description_); com.google.protobuf.GeneratedMessageV3.writeString(output, 2, description_);
} }
unknownFields.writeTo(output); getUnknownFields().writeTo(output);
} }
@java.lang.Override @java.lang.Override
@ -367,13 +261,13 @@ private static final long serialVersionUID = 0L;
if (size != -1) return size; if (size != -1) return size;
size = 0; size = 0;
if (!getFieldBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(field_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, field_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, field_);
} }
if (!getDescriptionBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, description_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, description_);
} }
size += unknownFields.getSerializedSize(); size += getUnknownFields().getSerializedSize();
memoizedSize = size; memoizedSize = size;
return size; return size;
} }
@ -392,7 +286,7 @@ private static final long serialVersionUID = 0L;
.equals(other.getField())) return false; .equals(other.getField())) return false;
if (!getDescription() if (!getDescription()
.equals(other.getDescription())) return false; .equals(other.getDescription())) return false;
if (!unknownFields.equals(other.unknownFields)) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true; return true;
} }
@ -407,7 +301,7 @@ private static final long serialVersionUID = 0L;
hash = (53 * hash) + getField().hashCode(); hash = (53 * hash) + getField().hashCode();
hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER;
hash = (53 * hash) + getDescription().hashCode(); hash = (53 * hash) + getDescription().hashCode();
hash = (29 * hash) + unknownFields.hashCode(); hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash; memoizedHashCode = hash;
return hash; return hash;
} }
@ -456,11 +350,13 @@ private static final long serialVersionUID = 0L;
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry); .parseWithIOException(PARSER, input, extensionRegistry);
} }
public static com.google.rpc.BadRequest.FieldViolation parseDelimitedFrom(java.io.InputStream input) public static com.google.rpc.BadRequest.FieldViolation parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException { throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input); .parseDelimitedWithIOException(PARSER, input);
} }
public static com.google.rpc.BadRequest.FieldViolation parseDelimitedFrom( public static com.google.rpc.BadRequest.FieldViolation parseDelimitedFrom(
java.io.InputStream input, java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
@ -528,26 +424,20 @@ private static final long serialVersionUID = 0L;
// Construct using com.google.rpc.BadRequest.FieldViolation.newBuilder() // Construct using com.google.rpc.BadRequest.FieldViolation.newBuilder()
private Builder() { private Builder() {
maybeForceBuilderInitialization();
} }
private Builder( private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent); super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
} }
@java.lang.Override @java.lang.Override
public Builder clear() { public Builder clear() {
super.clear(); super.clear();
bitField0_ = 0;
field_ = ""; field_ = "";
description_ = ""; description_ = "";
return this; return this;
} }
@ -574,12 +464,21 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public com.google.rpc.BadRequest.FieldViolation buildPartial() { public com.google.rpc.BadRequest.FieldViolation buildPartial() {
com.google.rpc.BadRequest.FieldViolation result = new com.google.rpc.BadRequest.FieldViolation(this); com.google.rpc.BadRequest.FieldViolation result = new com.google.rpc.BadRequest.FieldViolation(this);
result.field_ = field_; if (bitField0_ != 0) { buildPartial0(result); }
result.description_ = description_;
onBuilt(); onBuilt();
return result; return result;
} }
private void buildPartial0(com.google.rpc.BadRequest.FieldViolation result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.field_ = field_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.description_ = description_;
}
}
@java.lang.Override @java.lang.Override
public Builder clone() { public Builder clone() {
return super.clone(); return super.clone();
@ -626,13 +525,15 @@ private static final long serialVersionUID = 0L;
if (other == com.google.rpc.BadRequest.FieldViolation.getDefaultInstance()) return this; if (other == com.google.rpc.BadRequest.FieldViolation.getDefaultInstance()) return this;
if (!other.getField().isEmpty()) { if (!other.getField().isEmpty()) {
field_ = other.field_; field_ = other.field_;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
} }
if (!other.getDescription().isEmpty()) { if (!other.getDescription().isEmpty()) {
description_ = other.description_; description_ = other.description_;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
} }
this.mergeUnknownFields(other.unknownFields); this.mergeUnknownFields(other.getUnknownFields());
onChanged(); onChanged();
return this; return this;
} }
@ -647,19 +548,43 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException { throws java.io.IOException {
com.google.rpc.BadRequest.FieldViolation parsedMessage = null; if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try { try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
field_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 18: {
description_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000002;
break;
} // case 18
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) { } catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.google.rpc.BadRequest.FieldViolation) e.getUnfinishedMessage();
throw e.unwrapIOException(); throw e.unwrapIOException();
} finally { } finally {
if (parsedMessage != null) { onChanged();
mergeFrom(parsedMessage); } // finally
}
}
return this; return this;
} }
private int bitField0_;
private java.lang.Object field_ = ""; private java.lang.Object field_ = "";
/** /**
@ -720,11 +645,9 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setField( public Builder setField(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
field_ = value; field_ = value;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -739,8 +662,8 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearField() { public Builder clearField() {
field_ = getDefaultInstance().getField(); field_ = getDefaultInstance().getField();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged(); onChanged();
return this; return this;
} }
@ -757,12 +680,10 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setFieldBytes( public Builder setFieldBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
field_ = value; field_ = value;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -820,11 +741,9 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setDescription( public Builder setDescription(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
description_ = value; description_ = value;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
return this; return this;
} }
@ -837,8 +756,8 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearDescription() { public Builder clearDescription() {
description_ = getDefaultInstance().getDescription(); description_ = getDefaultInstance().getDescription();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged(); onChanged();
return this; return this;
} }
@ -853,12 +772,10 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setDescriptionBytes( public Builder setDescriptionBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
description_ = value; description_ = value;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
return this; return this;
} }
@ -895,7 +812,18 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException { throws com.google.protobuf.InvalidProtocolBufferException {
return new FieldViolation(input, extensionRegistry); Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
} }
}; };
@ -916,6 +844,7 @@ private static final long serialVersionUID = 0L;
} }
public static final int FIELD_VIOLATIONS_FIELD_NUMBER = 1; public static final int FIELD_VIOLATIONS_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private java.util.List<com.google.rpc.BadRequest.FieldViolation> fieldViolations_; private java.util.List<com.google.rpc.BadRequest.FieldViolation> fieldViolations_;
/** /**
* <pre> * <pre>
@ -992,7 +921,7 @@ private static final long serialVersionUID = 0L;
for (int i = 0; i < fieldViolations_.size(); i++) { for (int i = 0; i < fieldViolations_.size(); i++) {
output.writeMessage(1, fieldViolations_.get(i)); output.writeMessage(1, fieldViolations_.get(i));
} }
unknownFields.writeTo(output); getUnknownFields().writeTo(output);
} }
@java.lang.Override @java.lang.Override
@ -1005,7 +934,7 @@ private static final long serialVersionUID = 0L;
size += com.google.protobuf.CodedOutputStream size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, fieldViolations_.get(i)); .computeMessageSize(1, fieldViolations_.get(i));
} }
size += unknownFields.getSerializedSize(); size += getUnknownFields().getSerializedSize();
memoizedSize = size; memoizedSize = size;
return size; return size;
} }
@ -1022,7 +951,7 @@ private static final long serialVersionUID = 0L;
if (!getFieldViolationsList() if (!getFieldViolationsList()
.equals(other.getFieldViolationsList())) return false; .equals(other.getFieldViolationsList())) return false;
if (!unknownFields.equals(other.unknownFields)) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true; return true;
} }
@ -1037,7 +966,7 @@ private static final long serialVersionUID = 0L;
hash = (37 * hash) + FIELD_VIOLATIONS_FIELD_NUMBER; hash = (37 * hash) + FIELD_VIOLATIONS_FIELD_NUMBER;
hash = (53 * hash) + getFieldViolationsList().hashCode(); hash = (53 * hash) + getFieldViolationsList().hashCode();
} }
hash = (29 * hash) + unknownFields.hashCode(); hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash; memoizedHashCode = hash;
return hash; return hash;
} }
@ -1086,11 +1015,13 @@ private static final long serialVersionUID = 0L;
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry); .parseWithIOException(PARSER, input, extensionRegistry);
} }
public static com.google.rpc.BadRequest parseDelimitedFrom(java.io.InputStream input) public static com.google.rpc.BadRequest parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException { throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input); .parseDelimitedWithIOException(PARSER, input);
} }
public static com.google.rpc.BadRequest parseDelimitedFrom( public static com.google.rpc.BadRequest parseDelimitedFrom(
java.io.InputStream input, java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
@ -1159,29 +1090,25 @@ private static final long serialVersionUID = 0L;
// Construct using com.google.rpc.BadRequest.newBuilder() // Construct using com.google.rpc.BadRequest.newBuilder()
private Builder() { private Builder() {
maybeForceBuilderInitialization();
} }
private Builder( private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent); super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getFieldViolationsFieldBuilder();
}
} }
@java.lang.Override @java.lang.Override
public Builder clear() { public Builder clear() {
super.clear(); super.clear();
bitField0_ = 0;
if (fieldViolationsBuilder_ == null) { if (fieldViolationsBuilder_ == null) {
fieldViolations_ = java.util.Collections.emptyList(); fieldViolations_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001);
} else { } else {
fieldViolations_ = null;
fieldViolationsBuilder_.clear(); fieldViolationsBuilder_.clear();
} }
bitField0_ = (bitField0_ & ~0x00000001);
return this; return this;
} }
@ -1208,7 +1135,13 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public com.google.rpc.BadRequest buildPartial() { public com.google.rpc.BadRequest buildPartial() {
com.google.rpc.BadRequest result = new com.google.rpc.BadRequest(this); com.google.rpc.BadRequest result = new com.google.rpc.BadRequest(this);
int from_bitField0_ = bitField0_; buildPartialRepeatedFields(result);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartialRepeatedFields(com.google.rpc.BadRequest result) {
if (fieldViolationsBuilder_ == null) { if (fieldViolationsBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0)) { if (((bitField0_ & 0x00000001) != 0)) {
fieldViolations_ = java.util.Collections.unmodifiableList(fieldViolations_); fieldViolations_ = java.util.Collections.unmodifiableList(fieldViolations_);
@ -1218,8 +1151,10 @@ private static final long serialVersionUID = 0L;
} else { } else {
result.fieldViolations_ = fieldViolationsBuilder_.build(); result.fieldViolations_ = fieldViolationsBuilder_.build();
} }
onBuilt(); }
return result;
private void buildPartial0(com.google.rpc.BadRequest result) {
int from_bitField0_ = bitField0_;
} }
@java.lang.Override @java.lang.Override
@ -1292,7 +1227,7 @@ private static final long serialVersionUID = 0L;
} }
} }
} }
this.mergeUnknownFields(other.unknownFields); this.mergeUnknownFields(other.getUnknownFields());
onChanged(); onChanged();
return this; return this;
} }
@ -1307,17 +1242,43 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException { throws java.io.IOException {
com.google.rpc.BadRequest parsedMessage = null; if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try { try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
com.google.rpc.BadRequest.FieldViolation m =
input.readMessage(
com.google.rpc.BadRequest.FieldViolation.parser(),
extensionRegistry);
if (fieldViolationsBuilder_ == null) {
ensureFieldViolationsIsMutable();
fieldViolations_.add(m);
} else {
fieldViolationsBuilder_.addMessage(m);
}
break;
} // case 10
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) { } catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.google.rpc.BadRequest) e.getUnfinishedMessage();
throw e.unwrapIOException(); throw e.unwrapIOException();
} finally { } finally {
if (parsedMessage != null) { onChanged();
mergeFrom(parsedMessage); } // finally
}
}
return this; return this;
} }
private int bitField0_; private int bitField0_;
@ -1666,7 +1627,18 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException { throws com.google.protobuf.InvalidProtocolBufferException {
return new BadRequest(input, extensionRegistry); Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
} }
}; };

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/rpc/error_details.proto // source: google/rpc/error_details.proto
// Protobuf Java Version: 3.25.6
package com.google.rpc; package com.google.rpc;
public interface BadRequestOrBuilder extends public interface BadRequestOrBuilder extends

View File

@ -1,11 +1,14 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/rpc/code.proto // source: google/rpc/code.proto
// Protobuf Java Version: 3.25.6
package com.google.rpc; package com.google.rpc;
/** /**
* <pre> * <pre>
* The canonical error codes for Google APIs. * The canonical error codes for Google APIs.
*
*
* Sometimes multiple error codes may apply. Services should return * Sometimes multiple error codes may apply. Services should return
* the most specific error code that applies. For example, prefer * the most specific error code that applies. For example, prefer
* `OUT_OF_RANGE` over `FAILED_PRECONDITION` if both codes apply. * `OUT_OF_RANGE` over `FAILED_PRECONDITION` if both codes apply.
@ -19,6 +22,7 @@ public enum Code
/** /**
* <pre> * <pre>
* Not an error; returned on success * Not an error; returned on success
*
* HTTP Mapping: 200 OK * HTTP Mapping: 200 OK
* </pre> * </pre>
* *
@ -28,6 +32,7 @@ public enum Code
/** /**
* <pre> * <pre>
* The operation was cancelled, typically by the caller. * The operation was cancelled, typically by the caller.
*
* HTTP Mapping: 499 Client Closed Request * HTTP Mapping: 499 Client Closed Request
* </pre> * </pre>
* *
@ -41,6 +46,7 @@ public enum Code
* an error space that is not known in this address space. Also * an error space that is not known in this address space. Also
* errors raised by APIs that do not return enough error information * errors raised by APIs that do not return enough error information
* may be converted to this error. * may be converted to this error.
*
* HTTP Mapping: 500 Internal Server Error * HTTP Mapping: 500 Internal Server Error
* </pre> * </pre>
* *
@ -53,6 +59,7 @@ public enum Code
* from `FAILED_PRECONDITION`. `INVALID_ARGUMENT` indicates arguments * from `FAILED_PRECONDITION`. `INVALID_ARGUMENT` indicates arguments
* that are problematic regardless of the state of the system * that are problematic regardless of the state of the system
* (e.g., a malformed file name). * (e.g., a malformed file name).
*
* HTTP Mapping: 400 Bad Request * HTTP Mapping: 400 Bad Request
* </pre> * </pre>
* *
@ -66,6 +73,7 @@ public enum Code
* even if the operation has completed successfully. For example, a * even if the operation has completed successfully. For example, a
* successful response from a server could have been delayed long * successful response from a server could have been delayed long
* enough for the deadline to expire. * enough for the deadline to expire.
*
* HTTP Mapping: 504 Gateway Timeout * HTTP Mapping: 504 Gateway Timeout
* </pre> * </pre>
* *
@ -75,11 +83,13 @@ public enum Code
/** /**
* <pre> * <pre>
* Some requested entity (e.g., file or directory) was not found. * Some requested entity (e.g., file or directory) was not found.
*
* Note to server developers: if a request is denied for an entire class * Note to server developers: if a request is denied for an entire class
* of users, such as gradual feature rollout or undocumented whitelist, * of users, such as gradual feature rollout or undocumented whitelist,
* `NOT_FOUND` may be used. If a request is denied for some users within * `NOT_FOUND` may be used. If a request is denied for some users within
* a class of users, such as user-based access control, `PERMISSION_DENIED` * a class of users, such as user-based access control, `PERMISSION_DENIED`
* must be used. * must be used.
*
* HTTP Mapping: 404 Not Found * HTTP Mapping: 404 Not Found
* </pre> * </pre>
* *
@ -90,6 +100,7 @@ public enum Code
* <pre> * <pre>
* The entity that a client attempted to create (e.g., file or directory) * The entity that a client attempted to create (e.g., file or directory)
* already exists. * already exists.
*
* HTTP Mapping: 409 Conflict * HTTP Mapping: 409 Conflict
* </pre> * </pre>
* *
@ -106,6 +117,7 @@ public enum Code
* instead for those errors). This error code does not imply the * instead for those errors). This error code does not imply the
* request is valid or the requested entity exists or satisfies * request is valid or the requested entity exists or satisfies
* other pre-conditions. * other pre-conditions.
*
* HTTP Mapping: 403 Forbidden * HTTP Mapping: 403 Forbidden
* </pre> * </pre>
* *
@ -116,6 +128,7 @@ public enum Code
* <pre> * <pre>
* The request does not have valid authentication credentials for the * The request does not have valid authentication credentials for the
* operation. * operation.
*
* HTTP Mapping: 401 Unauthorized * HTTP Mapping: 401 Unauthorized
* </pre> * </pre>
* *
@ -126,6 +139,7 @@ public enum Code
* <pre> * <pre>
* Some resource has been exhausted, perhaps a per-user quota, or * Some resource has been exhausted, perhaps a per-user quota, or
* perhaps the entire file system is out of space. * perhaps the entire file system is out of space.
*
* HTTP Mapping: 429 Too Many Requests * HTTP Mapping: 429 Too Many Requests
* </pre> * </pre>
* *
@ -138,6 +152,7 @@ public enum Code
* required for the operation's execution. For example, the directory * required for the operation's execution. For example, the directory
* to be deleted is non-empty, an rmdir operation is applied to * to be deleted is non-empty, an rmdir operation is applied to
* a non-directory, etc. * a non-directory, etc.
*
* Service implementors can use the following guidelines to decide * Service implementors can use the following guidelines to decide
* between `FAILED_PRECONDITION`, `ABORTED`, and `UNAVAILABLE`: * between `FAILED_PRECONDITION`, `ABORTED`, and `UNAVAILABLE`:
* (a) Use `UNAVAILABLE` if the client can retry just the failing call. * (a) Use `UNAVAILABLE` if the client can retry just the failing call.
@ -149,6 +164,7 @@ public enum Code
* fails because the directory is non-empty, `FAILED_PRECONDITION` * fails because the directory is non-empty, `FAILED_PRECONDITION`
* should be returned since the client should not retry unless * should be returned since the client should not retry unless
* the files are deleted from the directory. * the files are deleted from the directory.
*
* HTTP Mapping: 400 Bad Request * HTTP Mapping: 400 Bad Request
* </pre> * </pre>
* *
@ -159,8 +175,10 @@ public enum Code
* <pre> * <pre>
* The operation was aborted, typically due to a concurrency issue such as * The operation was aborted, typically due to a concurrency issue such as
* a sequencer check failure or transaction abort. * a sequencer check failure or transaction abort.
*
* See the guidelines above for deciding between `FAILED_PRECONDITION`, * See the guidelines above for deciding between `FAILED_PRECONDITION`,
* `ABORTED`, and `UNAVAILABLE`. * `ABORTED`, and `UNAVAILABLE`.
*
* HTTP Mapping: 409 Conflict * HTTP Mapping: 409 Conflict
* </pre> * </pre>
* *
@ -171,17 +189,20 @@ public enum Code
* <pre> * <pre>
* The operation was attempted past the valid range. E.g., seeking or * The operation was attempted past the valid range. E.g., seeking or
* reading past end-of-file. * reading past end-of-file.
*
* Unlike `INVALID_ARGUMENT`, this error indicates a problem that may * Unlike `INVALID_ARGUMENT`, this error indicates a problem that may
* be fixed if the system state changes. For example, a 32-bit file * be fixed if the system state changes. For example, a 32-bit file
* system will generate `INVALID_ARGUMENT` if asked to read at an * system will generate `INVALID_ARGUMENT` if asked to read at an
* offset that is not in the range [0,2^32-1], but it will generate * offset that is not in the range [0,2^32-1], but it will generate
* `OUT_OF_RANGE` if asked to read from an offset past the current * `OUT_OF_RANGE` if asked to read from an offset past the current
* file size. * file size.
*
* There is a fair bit of overlap between `FAILED_PRECONDITION` and * There is a fair bit of overlap between `FAILED_PRECONDITION` and
* `OUT_OF_RANGE`. We recommend using `OUT_OF_RANGE` (the more specific * `OUT_OF_RANGE`. We recommend using `OUT_OF_RANGE` (the more specific
* error) when it applies so that callers who are iterating through * error) when it applies so that callers who are iterating through
* a space can easily look for an `OUT_OF_RANGE` error to detect when * a space can easily look for an `OUT_OF_RANGE` error to detect when
* they are done. * they are done.
*
* HTTP Mapping: 400 Bad Request * HTTP Mapping: 400 Bad Request
* </pre> * </pre>
* *
@ -192,6 +213,7 @@ public enum Code
* <pre> * <pre>
* The operation is not implemented or is not supported/enabled in this * The operation is not implemented or is not supported/enabled in this
* service. * service.
*
* HTTP Mapping: 501 Not Implemented * HTTP Mapping: 501 Not Implemented
* </pre> * </pre>
* *
@ -203,6 +225,7 @@ public enum Code
* Internal errors. This means that some invariants expected by the * Internal errors. This means that some invariants expected by the
* underlying system have been broken. This error code is reserved * underlying system have been broken. This error code is reserved
* for serious errors. * for serious errors.
*
* HTTP Mapping: 500 Internal Server Error * HTTP Mapping: 500 Internal Server Error
* </pre> * </pre>
* *
@ -214,8 +237,10 @@ public enum Code
* The service is currently unavailable. This is most likely a * The service is currently unavailable. This is most likely a
* transient condition, which can be corrected by retrying with * transient condition, which can be corrected by retrying with
* a backoff. * a backoff.
*
* See the guidelines above for deciding between `FAILED_PRECONDITION`, * See the guidelines above for deciding between `FAILED_PRECONDITION`,
* `ABORTED`, and `UNAVAILABLE`. * `ABORTED`, and `UNAVAILABLE`.
*
* HTTP Mapping: 503 Service Unavailable * HTTP Mapping: 503 Service Unavailable
* </pre> * </pre>
* *
@ -225,6 +250,7 @@ public enum Code
/** /**
* <pre> * <pre>
* Unrecoverable data loss or corruption. * Unrecoverable data loss or corruption.
*
* HTTP Mapping: 500 Internal Server Error * HTTP Mapping: 500 Internal Server Error
* </pre> * </pre>
* *
@ -237,6 +263,7 @@ public enum Code
/** /**
* <pre> * <pre>
* Not an error; returned on success * Not an error; returned on success
*
* HTTP Mapping: 200 OK * HTTP Mapping: 200 OK
* </pre> * </pre>
* *
@ -246,6 +273,7 @@ public enum Code
/** /**
* <pre> * <pre>
* The operation was cancelled, typically by the caller. * The operation was cancelled, typically by the caller.
*
* HTTP Mapping: 499 Client Closed Request * HTTP Mapping: 499 Client Closed Request
* </pre> * </pre>
* *
@ -259,6 +287,7 @@ public enum Code
* an error space that is not known in this address space. Also * an error space that is not known in this address space. Also
* errors raised by APIs that do not return enough error information * errors raised by APIs that do not return enough error information
* may be converted to this error. * may be converted to this error.
*
* HTTP Mapping: 500 Internal Server Error * HTTP Mapping: 500 Internal Server Error
* </pre> * </pre>
* *
@ -271,6 +300,7 @@ public enum Code
* from `FAILED_PRECONDITION`. `INVALID_ARGUMENT` indicates arguments * from `FAILED_PRECONDITION`. `INVALID_ARGUMENT` indicates arguments
* that are problematic regardless of the state of the system * that are problematic regardless of the state of the system
* (e.g., a malformed file name). * (e.g., a malformed file name).
*
* HTTP Mapping: 400 Bad Request * HTTP Mapping: 400 Bad Request
* </pre> * </pre>
* *
@ -284,6 +314,7 @@ public enum Code
* even if the operation has completed successfully. For example, a * even if the operation has completed successfully. For example, a
* successful response from a server could have been delayed long * successful response from a server could have been delayed long
* enough for the deadline to expire. * enough for the deadline to expire.
*
* HTTP Mapping: 504 Gateway Timeout * HTTP Mapping: 504 Gateway Timeout
* </pre> * </pre>
* *
@ -293,11 +324,13 @@ public enum Code
/** /**
* <pre> * <pre>
* Some requested entity (e.g., file or directory) was not found. * Some requested entity (e.g., file or directory) was not found.
*
* Note to server developers: if a request is denied for an entire class * Note to server developers: if a request is denied for an entire class
* of users, such as gradual feature rollout or undocumented whitelist, * of users, such as gradual feature rollout or undocumented whitelist,
* `NOT_FOUND` may be used. If a request is denied for some users within * `NOT_FOUND` may be used. If a request is denied for some users within
* a class of users, such as user-based access control, `PERMISSION_DENIED` * a class of users, such as user-based access control, `PERMISSION_DENIED`
* must be used. * must be used.
*
* HTTP Mapping: 404 Not Found * HTTP Mapping: 404 Not Found
* </pre> * </pre>
* *
@ -308,6 +341,7 @@ public enum Code
* <pre> * <pre>
* The entity that a client attempted to create (e.g., file or directory) * The entity that a client attempted to create (e.g., file or directory)
* already exists. * already exists.
*
* HTTP Mapping: 409 Conflict * HTTP Mapping: 409 Conflict
* </pre> * </pre>
* *
@ -324,6 +358,7 @@ public enum Code
* instead for those errors). This error code does not imply the * instead for those errors). This error code does not imply the
* request is valid or the requested entity exists or satisfies * request is valid or the requested entity exists or satisfies
* other pre-conditions. * other pre-conditions.
*
* HTTP Mapping: 403 Forbidden * HTTP Mapping: 403 Forbidden
* </pre> * </pre>
* *
@ -334,6 +369,7 @@ public enum Code
* <pre> * <pre>
* The request does not have valid authentication credentials for the * The request does not have valid authentication credentials for the
* operation. * operation.
*
* HTTP Mapping: 401 Unauthorized * HTTP Mapping: 401 Unauthorized
* </pre> * </pre>
* *
@ -344,6 +380,7 @@ public enum Code
* <pre> * <pre>
* Some resource has been exhausted, perhaps a per-user quota, or * Some resource has been exhausted, perhaps a per-user quota, or
* perhaps the entire file system is out of space. * perhaps the entire file system is out of space.
*
* HTTP Mapping: 429 Too Many Requests * HTTP Mapping: 429 Too Many Requests
* </pre> * </pre>
* *
@ -356,6 +393,7 @@ public enum Code
* required for the operation's execution. For example, the directory * required for the operation's execution. For example, the directory
* to be deleted is non-empty, an rmdir operation is applied to * to be deleted is non-empty, an rmdir operation is applied to
* a non-directory, etc. * a non-directory, etc.
*
* Service implementors can use the following guidelines to decide * Service implementors can use the following guidelines to decide
* between `FAILED_PRECONDITION`, `ABORTED`, and `UNAVAILABLE`: * between `FAILED_PRECONDITION`, `ABORTED`, and `UNAVAILABLE`:
* (a) Use `UNAVAILABLE` if the client can retry just the failing call. * (a) Use `UNAVAILABLE` if the client can retry just the failing call.
@ -367,6 +405,7 @@ public enum Code
* fails because the directory is non-empty, `FAILED_PRECONDITION` * fails because the directory is non-empty, `FAILED_PRECONDITION`
* should be returned since the client should not retry unless * should be returned since the client should not retry unless
* the files are deleted from the directory. * the files are deleted from the directory.
*
* HTTP Mapping: 400 Bad Request * HTTP Mapping: 400 Bad Request
* </pre> * </pre>
* *
@ -377,8 +416,10 @@ public enum Code
* <pre> * <pre>
* The operation was aborted, typically due to a concurrency issue such as * The operation was aborted, typically due to a concurrency issue such as
* a sequencer check failure or transaction abort. * a sequencer check failure or transaction abort.
*
* See the guidelines above for deciding between `FAILED_PRECONDITION`, * See the guidelines above for deciding between `FAILED_PRECONDITION`,
* `ABORTED`, and `UNAVAILABLE`. * `ABORTED`, and `UNAVAILABLE`.
*
* HTTP Mapping: 409 Conflict * HTTP Mapping: 409 Conflict
* </pre> * </pre>
* *
@ -389,17 +430,20 @@ public enum Code
* <pre> * <pre>
* The operation was attempted past the valid range. E.g., seeking or * The operation was attempted past the valid range. E.g., seeking or
* reading past end-of-file. * reading past end-of-file.
*
* Unlike `INVALID_ARGUMENT`, this error indicates a problem that may * Unlike `INVALID_ARGUMENT`, this error indicates a problem that may
* be fixed if the system state changes. For example, a 32-bit file * be fixed if the system state changes. For example, a 32-bit file
* system will generate `INVALID_ARGUMENT` if asked to read at an * system will generate `INVALID_ARGUMENT` if asked to read at an
* offset that is not in the range [0,2^32-1], but it will generate * offset that is not in the range [0,2^32-1], but it will generate
* `OUT_OF_RANGE` if asked to read from an offset past the current * `OUT_OF_RANGE` if asked to read from an offset past the current
* file size. * file size.
*
* There is a fair bit of overlap between `FAILED_PRECONDITION` and * There is a fair bit of overlap between `FAILED_PRECONDITION` and
* `OUT_OF_RANGE`. We recommend using `OUT_OF_RANGE` (the more specific * `OUT_OF_RANGE`. We recommend using `OUT_OF_RANGE` (the more specific
* error) when it applies so that callers who are iterating through * error) when it applies so that callers who are iterating through
* a space can easily look for an `OUT_OF_RANGE` error to detect when * a space can easily look for an `OUT_OF_RANGE` error to detect when
* they are done. * they are done.
*
* HTTP Mapping: 400 Bad Request * HTTP Mapping: 400 Bad Request
* </pre> * </pre>
* *
@ -410,6 +454,7 @@ public enum Code
* <pre> * <pre>
* The operation is not implemented or is not supported/enabled in this * The operation is not implemented or is not supported/enabled in this
* service. * service.
*
* HTTP Mapping: 501 Not Implemented * HTTP Mapping: 501 Not Implemented
* </pre> * </pre>
* *
@ -421,6 +466,7 @@ public enum Code
* Internal errors. This means that some invariants expected by the * Internal errors. This means that some invariants expected by the
* underlying system have been broken. This error code is reserved * underlying system have been broken. This error code is reserved
* for serious errors. * for serious errors.
*
* HTTP Mapping: 500 Internal Server Error * HTTP Mapping: 500 Internal Server Error
* </pre> * </pre>
* *
@ -432,8 +478,10 @@ public enum Code
* The service is currently unavailable. This is most likely a * The service is currently unavailable. This is most likely a
* transient condition, which can be corrected by retrying with * transient condition, which can be corrected by retrying with
* a backoff. * a backoff.
*
* See the guidelines above for deciding between `FAILED_PRECONDITION`, * See the guidelines above for deciding between `FAILED_PRECONDITION`,
* `ABORTED`, and `UNAVAILABLE`. * `ABORTED`, and `UNAVAILABLE`.
*
* HTTP Mapping: 503 Service Unavailable * HTTP Mapping: 503 Service Unavailable
* </pre> * </pre>
* *
@ -443,6 +491,7 @@ public enum Code
/** /**
* <pre> * <pre>
* Unrecoverable data loss or corruption. * Unrecoverable data loss or corruption.
*
* HTTP Mapping: 500 Internal Server Error * HTTP Mapping: 500 Internal Server Error
* </pre> * </pre>
* *

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/rpc/code.proto // source: google/rpc/code.proto
// Protobuf Java Version: 3.25.6
package com.google.rpc; package com.google.rpc;
public final class CodeProto { public final class CodeProto {

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/rpc/error_details.proto // source: google/rpc/error_details.proto
// Protobuf Java Version: 3.25.6
package com.google.rpc; package com.google.rpc;
/** /**
@ -20,7 +21,8 @@ private static final long serialVersionUID = 0L;
super(builder); super(builder);
} }
private DebugInfo() { private DebugInfo() {
stackEntries_ = com.google.protobuf.LazyStringArrayList.EMPTY; stackEntries_ =
com.google.protobuf.LazyStringArrayList.emptyList();
detail_ = ""; detail_ = "";
} }
@ -31,67 +33,6 @@ private static final long serialVersionUID = 0L;
return new DebugInfo(); return new DebugInfo();
} }
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private DebugInfo(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
int mutable_bitField0_ = 0;
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
java.lang.String s = input.readStringRequireUtf8();
if (!((mutable_bitField0_ & 0x00000001) != 0)) {
stackEntries_ = new com.google.protobuf.LazyStringArrayList();
mutable_bitField0_ |= 0x00000001;
}
stackEntries_.add(s);
break;
}
case 18: {
java.lang.String s = input.readStringRequireUtf8();
detail_ = s;
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
if (((mutable_bitField0_ & 0x00000001) != 0)) {
stackEntries_ = stackEntries_.getUnmodifiableView();
}
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() { getDescriptor() {
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_DebugInfo_descriptor; return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_DebugInfo_descriptor;
@ -106,7 +47,9 @@ private static final long serialVersionUID = 0L;
} }
public static final int STACK_ENTRIES_FIELD_NUMBER = 1; public static final int STACK_ENTRIES_FIELD_NUMBER = 1;
private com.google.protobuf.LazyStringList stackEntries_; @SuppressWarnings("serial")
private com.google.protobuf.LazyStringArrayList stackEntries_ =
com.google.protobuf.LazyStringArrayList.emptyList();
/** /**
* <pre> * <pre>
* The stack trace entries indicating where the error occurred. * The stack trace entries indicating where the error occurred.
@ -157,7 +100,8 @@ private static final long serialVersionUID = 0L;
} }
public static final int DETAIL_FIELD_NUMBER = 2; public static final int DETAIL_FIELD_NUMBER = 2;
private volatile java.lang.Object detail_; @SuppressWarnings("serial")
private volatile java.lang.Object detail_ = "";
/** /**
* <pre> * <pre>
* Additional debugging information provided by the server. * Additional debugging information provided by the server.
@ -219,10 +163,10 @@ private static final long serialVersionUID = 0L;
for (int i = 0; i < stackEntries_.size(); i++) { for (int i = 0; i < stackEntries_.size(); i++) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, stackEntries_.getRaw(i)); com.google.protobuf.GeneratedMessageV3.writeString(output, 1, stackEntries_.getRaw(i));
} }
if (!getDetailBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(detail_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, detail_); com.google.protobuf.GeneratedMessageV3.writeString(output, 2, detail_);
} }
unknownFields.writeTo(output); getUnknownFields().writeTo(output);
} }
@java.lang.Override @java.lang.Override
@ -239,10 +183,10 @@ private static final long serialVersionUID = 0L;
size += dataSize; size += dataSize;
size += 1 * getStackEntriesList().size(); size += 1 * getStackEntriesList().size();
} }
if (!getDetailBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(detail_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, detail_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, detail_);
} }
size += unknownFields.getSerializedSize(); size += getUnknownFields().getSerializedSize();
memoizedSize = size; memoizedSize = size;
return size; return size;
} }
@ -261,7 +205,7 @@ private static final long serialVersionUID = 0L;
.equals(other.getStackEntriesList())) return false; .equals(other.getStackEntriesList())) return false;
if (!getDetail() if (!getDetail()
.equals(other.getDetail())) return false; .equals(other.getDetail())) return false;
if (!unknownFields.equals(other.unknownFields)) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true; return true;
} }
@ -278,7 +222,7 @@ private static final long serialVersionUID = 0L;
} }
hash = (37 * hash) + DETAIL_FIELD_NUMBER; hash = (37 * hash) + DETAIL_FIELD_NUMBER;
hash = (53 * hash) + getDetail().hashCode(); hash = (53 * hash) + getDetail().hashCode();
hash = (29 * hash) + unknownFields.hashCode(); hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash; memoizedHashCode = hash;
return hash; return hash;
} }
@ -327,11 +271,13 @@ private static final long serialVersionUID = 0L;
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry); .parseWithIOException(PARSER, input, extensionRegistry);
} }
public static com.google.rpc.DebugInfo parseDelimitedFrom(java.io.InputStream input) public static com.google.rpc.DebugInfo parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException { throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input); .parseDelimitedWithIOException(PARSER, input);
} }
public static com.google.rpc.DebugInfo parseDelimitedFrom( public static com.google.rpc.DebugInfo parseDelimitedFrom(
java.io.InputStream input, java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
@ -399,26 +345,21 @@ private static final long serialVersionUID = 0L;
// Construct using com.google.rpc.DebugInfo.newBuilder() // Construct using com.google.rpc.DebugInfo.newBuilder()
private Builder() { private Builder() {
maybeForceBuilderInitialization();
} }
private Builder( private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent); super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
} }
@java.lang.Override @java.lang.Override
public Builder clear() { public Builder clear() {
super.clear(); super.clear();
stackEntries_ = com.google.protobuf.LazyStringArrayList.EMPTY; bitField0_ = 0;
bitField0_ = (bitField0_ & ~0x00000001); stackEntries_ =
com.google.protobuf.LazyStringArrayList.emptyList();
detail_ = ""; detail_ = "";
return this; return this;
} }
@ -445,17 +386,22 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public com.google.rpc.DebugInfo buildPartial() { public com.google.rpc.DebugInfo buildPartial() {
com.google.rpc.DebugInfo result = new com.google.rpc.DebugInfo(this); com.google.rpc.DebugInfo result = new com.google.rpc.DebugInfo(this);
int from_bitField0_ = bitField0_; if (bitField0_ != 0) { buildPartial0(result); }
if (((bitField0_ & 0x00000001) != 0)) {
stackEntries_ = stackEntries_.getUnmodifiableView();
bitField0_ = (bitField0_ & ~0x00000001);
}
result.stackEntries_ = stackEntries_;
result.detail_ = detail_;
onBuilt(); onBuilt();
return result; return result;
} }
private void buildPartial0(com.google.rpc.DebugInfo result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
stackEntries_.makeImmutable();
result.stackEntries_ = stackEntries_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.detail_ = detail_;
}
}
@java.lang.Override @java.lang.Override
public Builder clone() { public Builder clone() {
return super.clone(); return super.clone();
@ -503,7 +449,7 @@ private static final long serialVersionUID = 0L;
if (!other.stackEntries_.isEmpty()) { if (!other.stackEntries_.isEmpty()) {
if (stackEntries_.isEmpty()) { if (stackEntries_.isEmpty()) {
stackEntries_ = other.stackEntries_; stackEntries_ = other.stackEntries_;
bitField0_ = (bitField0_ & ~0x00000001); bitField0_ |= 0x00000001;
} else { } else {
ensureStackEntriesIsMutable(); ensureStackEntriesIsMutable();
stackEntries_.addAll(other.stackEntries_); stackEntries_.addAll(other.stackEntries_);
@ -512,9 +458,10 @@ private static final long serialVersionUID = 0L;
} }
if (!other.getDetail().isEmpty()) { if (!other.getDetail().isEmpty()) {
detail_ = other.detail_; detail_ = other.detail_;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
} }
this.mergeUnknownFields(other.unknownFields); this.mergeUnknownFields(other.getUnknownFields());
onChanged(); onChanged();
return this; return this;
} }
@ -529,27 +476,52 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException { throws java.io.IOException {
com.google.rpc.DebugInfo parsedMessage = null; if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try { try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
java.lang.String s = input.readStringRequireUtf8();
ensureStackEntriesIsMutable();
stackEntries_.add(s);
break;
} // case 10
case 18: {
detail_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000002;
break;
} // case 18
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) { } catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.google.rpc.DebugInfo) e.getUnfinishedMessage();
throw e.unwrapIOException(); throw e.unwrapIOException();
} finally { } finally {
if (parsedMessage != null) { onChanged();
mergeFrom(parsedMessage); } // finally
}
}
return this; return this;
} }
private int bitField0_; private int bitField0_;
private com.google.protobuf.LazyStringList stackEntries_ = com.google.protobuf.LazyStringArrayList.EMPTY; private com.google.protobuf.LazyStringArrayList stackEntries_ =
com.google.protobuf.LazyStringArrayList.emptyList();
private void ensureStackEntriesIsMutable() { private void ensureStackEntriesIsMutable() {
if (!((bitField0_ & 0x00000001) != 0)) { if (!stackEntries_.isModifiable()) {
stackEntries_ = new com.google.protobuf.LazyStringArrayList(stackEntries_); stackEntries_ = new com.google.protobuf.LazyStringArrayList(stackEntries_);
bitField0_ |= 0x00000001; }
} bitField0_ |= 0x00000001;
} }
/** /**
* <pre> * <pre>
@ -561,7 +533,8 @@ private static final long serialVersionUID = 0L;
*/ */
public com.google.protobuf.ProtocolStringList public com.google.protobuf.ProtocolStringList
getStackEntriesList() { getStackEntriesList() {
return stackEntries_.getUnmodifiableView(); stackEntries_.makeImmutable();
return stackEntries_;
} }
/** /**
* <pre> * <pre>
@ -611,11 +584,10 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setStackEntries( public Builder setStackEntries(
int index, java.lang.String value) { int index, java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); ensureStackEntriesIsMutable();
}
ensureStackEntriesIsMutable();
stackEntries_.set(index, value); stackEntries_.set(index, value);
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -630,11 +602,10 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder addStackEntries( public Builder addStackEntries(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); ensureStackEntriesIsMutable();
}
ensureStackEntriesIsMutable();
stackEntries_.add(value); stackEntries_.add(value);
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -652,6 +623,7 @@ private static final long serialVersionUID = 0L;
ensureStackEntriesIsMutable(); ensureStackEntriesIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll( com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, stackEntries_); values, stackEntries_);
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -664,8 +636,9 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearStackEntries() { public Builder clearStackEntries() {
stackEntries_ = com.google.protobuf.LazyStringArrayList.EMPTY; stackEntries_ =
bitField0_ = (bitField0_ & ~0x00000001); com.google.protobuf.LazyStringArrayList.emptyList();
bitField0_ = (bitField0_ & ~0x00000001);;
onChanged(); onChanged();
return this; return this;
} }
@ -680,12 +653,11 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder addStackEntriesBytes( public Builder addStackEntriesBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
ensureStackEntriesIsMutable(); ensureStackEntriesIsMutable();
stackEntries_.add(value); stackEntries_.add(value);
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -743,11 +715,9 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setDetail( public Builder setDetail(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
detail_ = value; detail_ = value;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
return this; return this;
} }
@ -760,8 +730,8 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearDetail() { public Builder clearDetail() {
detail_ = getDefaultInstance().getDetail(); detail_ = getDefaultInstance().getDetail();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged(); onChanged();
return this; return this;
} }
@ -776,12 +746,10 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setDetailBytes( public Builder setDetailBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
detail_ = value; detail_ = value;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
return this; return this;
} }
@ -818,7 +786,18 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException { throws com.google.protobuf.InvalidProtocolBufferException {
return new DebugInfo(input, extensionRegistry); Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
} }
}; };

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/rpc/error_details.proto // source: google/rpc/error_details.proto
// Protobuf Java Version: 3.25.6
package com.google.rpc; package com.google.rpc;
public interface DebugInfoOrBuilder extends public interface DebugInfoOrBuilder extends

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/rpc/error_details.proto // source: google/rpc/error_details.proto
// Protobuf Java Version: 3.25.6
package com.google.rpc; package com.google.rpc;
public final class ErrorDetailsProto { public final class ErrorDetailsProto {

View File

@ -1,11 +1,13 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/rpc/error_details.proto // source: google/rpc/error_details.proto
// Protobuf Java Version: 3.25.6
package com.google.rpc; package com.google.rpc;
/** /**
* <pre> * <pre>
* Provides links to documentation or for performing an out of band action. * Provides links to documentation or for performing an out of band action.
*
* For example, if a quota check failed with an error indicating the calling * For example, if a quota check failed with an error indicating the calling
* project hasn't enabled the accessed service, this can contain a URL pointing * project hasn't enabled the accessed service, this can contain a URL pointing
* directly to the right place in the developer console to flip the bit. * directly to the right place in the developer console to flip the bit.
@ -33,61 +35,6 @@ private static final long serialVersionUID = 0L;
return new Help(); return new Help();
} }
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private Help(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
int mutable_bitField0_ = 0;
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
if (!((mutable_bitField0_ & 0x00000001) != 0)) {
links_ = new java.util.ArrayList<com.google.rpc.Help.Link>();
mutable_bitField0_ |= 0x00000001;
}
links_.add(
input.readMessage(com.google.rpc.Help.Link.parser(), extensionRegistry));
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
if (((mutable_bitField0_ & 0x00000001) != 0)) {
links_ = java.util.Collections.unmodifiableList(links_);
}
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() { getDescriptor() {
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_Help_descriptor; return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_Help_descriptor;
@ -173,60 +120,6 @@ private static final long serialVersionUID = 0L;
return new Link(); return new Link();
} }
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private Link(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
java.lang.String s = input.readStringRequireUtf8();
description_ = s;
break;
}
case 18: {
java.lang.String s = input.readStringRequireUtf8();
url_ = s;
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() { getDescriptor() {
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_Help_Link_descriptor; return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_Help_Link_descriptor;
@ -241,7 +134,8 @@ private static final long serialVersionUID = 0L;
} }
public static final int DESCRIPTION_FIELD_NUMBER = 1; public static final int DESCRIPTION_FIELD_NUMBER = 1;
private volatile java.lang.Object description_; @SuppressWarnings("serial")
private volatile java.lang.Object description_ = "";
/** /**
* <pre> * <pre>
* Describes what the link offers. * Describes what the link offers.
@ -287,7 +181,8 @@ private static final long serialVersionUID = 0L;
} }
public static final int URL_FIELD_NUMBER = 2; public static final int URL_FIELD_NUMBER = 2;
private volatile java.lang.Object url_; @SuppressWarnings("serial")
private volatile java.lang.Object url_ = "";
/** /**
* <pre> * <pre>
* The URL of the link. * The URL of the link.
@ -346,13 +241,13 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output) public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException { throws java.io.IOException {
if (!getDescriptionBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, description_); com.google.protobuf.GeneratedMessageV3.writeString(output, 1, description_);
} }
if (!getUrlBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(url_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, url_); com.google.protobuf.GeneratedMessageV3.writeString(output, 2, url_);
} }
unknownFields.writeTo(output); getUnknownFields().writeTo(output);
} }
@java.lang.Override @java.lang.Override
@ -361,13 +256,13 @@ private static final long serialVersionUID = 0L;
if (size != -1) return size; if (size != -1) return size;
size = 0; size = 0;
if (!getDescriptionBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, description_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, description_);
} }
if (!getUrlBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(url_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, url_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, url_);
} }
size += unknownFields.getSerializedSize(); size += getUnknownFields().getSerializedSize();
memoizedSize = size; memoizedSize = size;
return size; return size;
} }
@ -386,7 +281,7 @@ private static final long serialVersionUID = 0L;
.equals(other.getDescription())) return false; .equals(other.getDescription())) return false;
if (!getUrl() if (!getUrl()
.equals(other.getUrl())) return false; .equals(other.getUrl())) return false;
if (!unknownFields.equals(other.unknownFields)) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true; return true;
} }
@ -401,7 +296,7 @@ private static final long serialVersionUID = 0L;
hash = (53 * hash) + getDescription().hashCode(); hash = (53 * hash) + getDescription().hashCode();
hash = (37 * hash) + URL_FIELD_NUMBER; hash = (37 * hash) + URL_FIELD_NUMBER;
hash = (53 * hash) + getUrl().hashCode(); hash = (53 * hash) + getUrl().hashCode();
hash = (29 * hash) + unknownFields.hashCode(); hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash; memoizedHashCode = hash;
return hash; return hash;
} }
@ -450,11 +345,13 @@ private static final long serialVersionUID = 0L;
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry); .parseWithIOException(PARSER, input, extensionRegistry);
} }
public static com.google.rpc.Help.Link parseDelimitedFrom(java.io.InputStream input) public static com.google.rpc.Help.Link parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException { throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input); .parseDelimitedWithIOException(PARSER, input);
} }
public static com.google.rpc.Help.Link parseDelimitedFrom( public static com.google.rpc.Help.Link parseDelimitedFrom(
java.io.InputStream input, java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
@ -522,26 +419,20 @@ private static final long serialVersionUID = 0L;
// Construct using com.google.rpc.Help.Link.newBuilder() // Construct using com.google.rpc.Help.Link.newBuilder()
private Builder() { private Builder() {
maybeForceBuilderInitialization();
} }
private Builder( private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent); super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
} }
@java.lang.Override @java.lang.Override
public Builder clear() { public Builder clear() {
super.clear(); super.clear();
bitField0_ = 0;
description_ = ""; description_ = "";
url_ = ""; url_ = "";
return this; return this;
} }
@ -568,12 +459,21 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public com.google.rpc.Help.Link buildPartial() { public com.google.rpc.Help.Link buildPartial() {
com.google.rpc.Help.Link result = new com.google.rpc.Help.Link(this); com.google.rpc.Help.Link result = new com.google.rpc.Help.Link(this);
result.description_ = description_; if (bitField0_ != 0) { buildPartial0(result); }
result.url_ = url_;
onBuilt(); onBuilt();
return result; return result;
} }
private void buildPartial0(com.google.rpc.Help.Link result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.description_ = description_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.url_ = url_;
}
}
@java.lang.Override @java.lang.Override
public Builder clone() { public Builder clone() {
return super.clone(); return super.clone();
@ -620,13 +520,15 @@ private static final long serialVersionUID = 0L;
if (other == com.google.rpc.Help.Link.getDefaultInstance()) return this; if (other == com.google.rpc.Help.Link.getDefaultInstance()) return this;
if (!other.getDescription().isEmpty()) { if (!other.getDescription().isEmpty()) {
description_ = other.description_; description_ = other.description_;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
} }
if (!other.getUrl().isEmpty()) { if (!other.getUrl().isEmpty()) {
url_ = other.url_; url_ = other.url_;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
} }
this.mergeUnknownFields(other.unknownFields); this.mergeUnknownFields(other.getUnknownFields());
onChanged(); onChanged();
return this; return this;
} }
@ -641,19 +543,43 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException { throws java.io.IOException {
com.google.rpc.Help.Link parsedMessage = null; if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try { try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
description_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 18: {
url_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000002;
break;
} // case 18
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) { } catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.google.rpc.Help.Link) e.getUnfinishedMessage();
throw e.unwrapIOException(); throw e.unwrapIOException();
} finally { } finally {
if (parsedMessage != null) { onChanged();
mergeFrom(parsedMessage); } // finally
}
}
return this; return this;
} }
private int bitField0_;
private java.lang.Object description_ = ""; private java.lang.Object description_ = "";
/** /**
@ -708,11 +634,9 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setDescription( public Builder setDescription(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
description_ = value; description_ = value;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -725,8 +649,8 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearDescription() { public Builder clearDescription() {
description_ = getDefaultInstance().getDescription(); description_ = getDefaultInstance().getDescription();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged(); onChanged();
return this; return this;
} }
@ -741,12 +665,10 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setDescriptionBytes( public Builder setDescriptionBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
description_ = value; description_ = value;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -804,11 +726,9 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setUrl( public Builder setUrl(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
url_ = value; url_ = value;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
return this; return this;
} }
@ -821,8 +741,8 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearUrl() { public Builder clearUrl() {
url_ = getDefaultInstance().getUrl(); url_ = getDefaultInstance().getUrl();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged(); onChanged();
return this; return this;
} }
@ -837,12 +757,10 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setUrlBytes( public Builder setUrlBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
url_ = value; url_ = value;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
return this; return this;
} }
@ -879,7 +797,18 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException { throws com.google.protobuf.InvalidProtocolBufferException {
return new Link(input, extensionRegistry); Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
} }
}; };
@ -900,6 +829,7 @@ private static final long serialVersionUID = 0L;
} }
public static final int LINKS_FIELD_NUMBER = 1; public static final int LINKS_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private java.util.List<com.google.rpc.Help.Link> links_; private java.util.List<com.google.rpc.Help.Link> links_;
/** /**
* <pre> * <pre>
@ -976,7 +906,7 @@ private static final long serialVersionUID = 0L;
for (int i = 0; i < links_.size(); i++) { for (int i = 0; i < links_.size(); i++) {
output.writeMessage(1, links_.get(i)); output.writeMessage(1, links_.get(i));
} }
unknownFields.writeTo(output); getUnknownFields().writeTo(output);
} }
@java.lang.Override @java.lang.Override
@ -989,7 +919,7 @@ private static final long serialVersionUID = 0L;
size += com.google.protobuf.CodedOutputStream size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, links_.get(i)); .computeMessageSize(1, links_.get(i));
} }
size += unknownFields.getSerializedSize(); size += getUnknownFields().getSerializedSize();
memoizedSize = size; memoizedSize = size;
return size; return size;
} }
@ -1006,7 +936,7 @@ private static final long serialVersionUID = 0L;
if (!getLinksList() if (!getLinksList()
.equals(other.getLinksList())) return false; .equals(other.getLinksList())) return false;
if (!unknownFields.equals(other.unknownFields)) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true; return true;
} }
@ -1021,7 +951,7 @@ private static final long serialVersionUID = 0L;
hash = (37 * hash) + LINKS_FIELD_NUMBER; hash = (37 * hash) + LINKS_FIELD_NUMBER;
hash = (53 * hash) + getLinksList().hashCode(); hash = (53 * hash) + getLinksList().hashCode();
} }
hash = (29 * hash) + unknownFields.hashCode(); hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash; memoizedHashCode = hash;
return hash; return hash;
} }
@ -1070,11 +1000,13 @@ private static final long serialVersionUID = 0L;
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry); .parseWithIOException(PARSER, input, extensionRegistry);
} }
public static com.google.rpc.Help parseDelimitedFrom(java.io.InputStream input) public static com.google.rpc.Help parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException { throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input); .parseDelimitedWithIOException(PARSER, input);
} }
public static com.google.rpc.Help parseDelimitedFrom( public static com.google.rpc.Help parseDelimitedFrom(
java.io.InputStream input, java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
@ -1119,6 +1051,7 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* Provides links to documentation or for performing an out of band action. * Provides links to documentation or for performing an out of band action.
*
* For example, if a quota check failed with an error indicating the calling * For example, if a quota check failed with an error indicating the calling
* project hasn't enabled the accessed service, this can contain a URL pointing * project hasn't enabled the accessed service, this can contain a URL pointing
* directly to the right place in the developer console to flip the bit. * directly to the right place in the developer console to flip the bit.
@ -1145,29 +1078,25 @@ private static final long serialVersionUID = 0L;
// Construct using com.google.rpc.Help.newBuilder() // Construct using com.google.rpc.Help.newBuilder()
private Builder() { private Builder() {
maybeForceBuilderInitialization();
} }
private Builder( private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent); super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getLinksFieldBuilder();
}
} }
@java.lang.Override @java.lang.Override
public Builder clear() { public Builder clear() {
super.clear(); super.clear();
bitField0_ = 0;
if (linksBuilder_ == null) { if (linksBuilder_ == null) {
links_ = java.util.Collections.emptyList(); links_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001);
} else { } else {
links_ = null;
linksBuilder_.clear(); linksBuilder_.clear();
} }
bitField0_ = (bitField0_ & ~0x00000001);
return this; return this;
} }
@ -1194,7 +1123,13 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public com.google.rpc.Help buildPartial() { public com.google.rpc.Help buildPartial() {
com.google.rpc.Help result = new com.google.rpc.Help(this); com.google.rpc.Help result = new com.google.rpc.Help(this);
int from_bitField0_ = bitField0_; buildPartialRepeatedFields(result);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartialRepeatedFields(com.google.rpc.Help result) {
if (linksBuilder_ == null) { if (linksBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0)) { if (((bitField0_ & 0x00000001) != 0)) {
links_ = java.util.Collections.unmodifiableList(links_); links_ = java.util.Collections.unmodifiableList(links_);
@ -1204,8 +1139,10 @@ private static final long serialVersionUID = 0L;
} else { } else {
result.links_ = linksBuilder_.build(); result.links_ = linksBuilder_.build();
} }
onBuilt(); }
return result;
private void buildPartial0(com.google.rpc.Help result) {
int from_bitField0_ = bitField0_;
} }
@java.lang.Override @java.lang.Override
@ -1278,7 +1215,7 @@ private static final long serialVersionUID = 0L;
} }
} }
} }
this.mergeUnknownFields(other.unknownFields); this.mergeUnknownFields(other.getUnknownFields());
onChanged(); onChanged();
return this; return this;
} }
@ -1293,17 +1230,43 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException { throws java.io.IOException {
com.google.rpc.Help parsedMessage = null; if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try { try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
com.google.rpc.Help.Link m =
input.readMessage(
com.google.rpc.Help.Link.parser(),
extensionRegistry);
if (linksBuilder_ == null) {
ensureLinksIsMutable();
links_.add(m);
} else {
linksBuilder_.addMessage(m);
}
break;
} // case 10
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) { } catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.google.rpc.Help) e.getUnfinishedMessage();
throw e.unwrapIOException(); throw e.unwrapIOException();
} finally { } finally {
if (parsedMessage != null) { onChanged();
mergeFrom(parsedMessage); } // finally
}
}
return this; return this;
} }
private int bitField0_; private int bitField0_;
@ -1652,7 +1615,18 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException { throws com.google.protobuf.InvalidProtocolBufferException {
return new Help(input, extensionRegistry); Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
} }
}; };

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/rpc/error_details.proto // source: google/rpc/error_details.proto
// Protobuf Java Version: 3.25.6
package com.google.rpc; package com.google.rpc;
public interface HelpOrBuilder extends public interface HelpOrBuilder extends

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/rpc/error_details.proto // source: google/rpc/error_details.proto
// Protobuf Java Version: 3.25.6
package com.google.rpc; package com.google.rpc;
/** /**
@ -32,60 +33,6 @@ private static final long serialVersionUID = 0L;
return new LocalizedMessage(); return new LocalizedMessage();
} }
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private LocalizedMessage(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
java.lang.String s = input.readStringRequireUtf8();
locale_ = s;
break;
}
case 18: {
java.lang.String s = input.readStringRequireUtf8();
message_ = s;
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() { getDescriptor() {
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_LocalizedMessage_descriptor; return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_LocalizedMessage_descriptor;
@ -100,7 +47,8 @@ private static final long serialVersionUID = 0L;
} }
public static final int LOCALE_FIELD_NUMBER = 1; public static final int LOCALE_FIELD_NUMBER = 1;
private volatile java.lang.Object locale_; @SuppressWarnings("serial")
private volatile java.lang.Object locale_ = "";
/** /**
* <pre> * <pre>
* The locale used following the specification defined at * The locale used following the specification defined at
@ -150,7 +98,8 @@ private static final long serialVersionUID = 0L;
} }
public static final int MESSAGE_FIELD_NUMBER = 2; public static final int MESSAGE_FIELD_NUMBER = 2;
private volatile java.lang.Object message_; @SuppressWarnings("serial")
private volatile java.lang.Object message_ = "";
/** /**
* <pre> * <pre>
* The localized error message in the above locale. * The localized error message in the above locale.
@ -209,13 +158,13 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output) public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException { throws java.io.IOException {
if (!getLocaleBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(locale_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, locale_); com.google.protobuf.GeneratedMessageV3.writeString(output, 1, locale_);
} }
if (!getMessageBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(message_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, message_); com.google.protobuf.GeneratedMessageV3.writeString(output, 2, message_);
} }
unknownFields.writeTo(output); getUnknownFields().writeTo(output);
} }
@java.lang.Override @java.lang.Override
@ -224,13 +173,13 @@ private static final long serialVersionUID = 0L;
if (size != -1) return size; if (size != -1) return size;
size = 0; size = 0;
if (!getLocaleBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(locale_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, locale_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, locale_);
} }
if (!getMessageBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(message_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, message_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, message_);
} }
size += unknownFields.getSerializedSize(); size += getUnknownFields().getSerializedSize();
memoizedSize = size; memoizedSize = size;
return size; return size;
} }
@ -249,7 +198,7 @@ private static final long serialVersionUID = 0L;
.equals(other.getLocale())) return false; .equals(other.getLocale())) return false;
if (!getMessage() if (!getMessage()
.equals(other.getMessage())) return false; .equals(other.getMessage())) return false;
if (!unknownFields.equals(other.unknownFields)) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true; return true;
} }
@ -264,7 +213,7 @@ private static final long serialVersionUID = 0L;
hash = (53 * hash) + getLocale().hashCode(); hash = (53 * hash) + getLocale().hashCode();
hash = (37 * hash) + MESSAGE_FIELD_NUMBER; hash = (37 * hash) + MESSAGE_FIELD_NUMBER;
hash = (53 * hash) + getMessage().hashCode(); hash = (53 * hash) + getMessage().hashCode();
hash = (29 * hash) + unknownFields.hashCode(); hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash; memoizedHashCode = hash;
return hash; return hash;
} }
@ -313,11 +262,13 @@ private static final long serialVersionUID = 0L;
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry); .parseWithIOException(PARSER, input, extensionRegistry);
} }
public static com.google.rpc.LocalizedMessage parseDelimitedFrom(java.io.InputStream input) public static com.google.rpc.LocalizedMessage parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException { throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input); .parseDelimitedWithIOException(PARSER, input);
} }
public static com.google.rpc.LocalizedMessage parseDelimitedFrom( public static com.google.rpc.LocalizedMessage parseDelimitedFrom(
java.io.InputStream input, java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
@ -386,26 +337,20 @@ private static final long serialVersionUID = 0L;
// Construct using com.google.rpc.LocalizedMessage.newBuilder() // Construct using com.google.rpc.LocalizedMessage.newBuilder()
private Builder() { private Builder() {
maybeForceBuilderInitialization();
} }
private Builder( private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent); super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
} }
@java.lang.Override @java.lang.Override
public Builder clear() { public Builder clear() {
super.clear(); super.clear();
bitField0_ = 0;
locale_ = ""; locale_ = "";
message_ = ""; message_ = "";
return this; return this;
} }
@ -432,12 +377,21 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public com.google.rpc.LocalizedMessage buildPartial() { public com.google.rpc.LocalizedMessage buildPartial() {
com.google.rpc.LocalizedMessage result = new com.google.rpc.LocalizedMessage(this); com.google.rpc.LocalizedMessage result = new com.google.rpc.LocalizedMessage(this);
result.locale_ = locale_; if (bitField0_ != 0) { buildPartial0(result); }
result.message_ = message_;
onBuilt(); onBuilt();
return result; return result;
} }
private void buildPartial0(com.google.rpc.LocalizedMessage result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.locale_ = locale_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.message_ = message_;
}
}
@java.lang.Override @java.lang.Override
public Builder clone() { public Builder clone() {
return super.clone(); return super.clone();
@ -484,13 +438,15 @@ private static final long serialVersionUID = 0L;
if (other == com.google.rpc.LocalizedMessage.getDefaultInstance()) return this; if (other == com.google.rpc.LocalizedMessage.getDefaultInstance()) return this;
if (!other.getLocale().isEmpty()) { if (!other.getLocale().isEmpty()) {
locale_ = other.locale_; locale_ = other.locale_;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
} }
if (!other.getMessage().isEmpty()) { if (!other.getMessage().isEmpty()) {
message_ = other.message_; message_ = other.message_;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
} }
this.mergeUnknownFields(other.unknownFields); this.mergeUnknownFields(other.getUnknownFields());
onChanged(); onChanged();
return this; return this;
} }
@ -505,19 +461,43 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException { throws java.io.IOException {
com.google.rpc.LocalizedMessage parsedMessage = null; if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try { try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
locale_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 18: {
message_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000002;
break;
} // case 18
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) { } catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.google.rpc.LocalizedMessage) e.getUnfinishedMessage();
throw e.unwrapIOException(); throw e.unwrapIOException();
} finally { } finally {
if (parsedMessage != null) { onChanged();
mergeFrom(parsedMessage); } // finally
}
}
return this; return this;
} }
private int bitField0_;
private java.lang.Object locale_ = ""; private java.lang.Object locale_ = "";
/** /**
@ -578,11 +558,9 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setLocale( public Builder setLocale(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
locale_ = value; locale_ = value;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -597,8 +575,8 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearLocale() { public Builder clearLocale() {
locale_ = getDefaultInstance().getLocale(); locale_ = getDefaultInstance().getLocale();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged(); onChanged();
return this; return this;
} }
@ -615,12 +593,10 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setLocaleBytes( public Builder setLocaleBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
locale_ = value; locale_ = value;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -678,11 +654,9 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setMessage( public Builder setMessage(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
message_ = value; message_ = value;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
return this; return this;
} }
@ -695,8 +669,8 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearMessage() { public Builder clearMessage() {
message_ = getDefaultInstance().getMessage(); message_ = getDefaultInstance().getMessage();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged(); onChanged();
return this; return this;
} }
@ -711,12 +685,10 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setMessageBytes( public Builder setMessageBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
message_ = value; message_ = value;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
return this; return this;
} }
@ -753,7 +725,18 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException { throws com.google.protobuf.InvalidProtocolBufferException {
return new LocalizedMessage(input, extensionRegistry); Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
} }
}; };

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/rpc/error_details.proto // source: google/rpc/error_details.proto
// Protobuf Java Version: 3.25.6
package com.google.rpc; package com.google.rpc;
public interface LocalizedMessageOrBuilder extends public interface LocalizedMessageOrBuilder extends

View File

@ -1,11 +1,13 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/rpc/error_details.proto // source: google/rpc/error_details.proto
// Protobuf Java Version: 3.25.6
package com.google.rpc; package com.google.rpc;
/** /**
* <pre> * <pre>
* Describes what preconditions have failed. * Describes what preconditions have failed.
*
* For example, if an RPC failed because it required the Terms of Service to be * For example, if an RPC failed because it required the Terms of Service to be
* acknowledged, it could list the terms of service violation in the * acknowledged, it could list the terms of service violation in the
* PreconditionFailure message. * PreconditionFailure message.
@ -33,61 +35,6 @@ private static final long serialVersionUID = 0L;
return new PreconditionFailure(); return new PreconditionFailure();
} }
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private PreconditionFailure(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
int mutable_bitField0_ = 0;
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
if (!((mutable_bitField0_ & 0x00000001) != 0)) {
violations_ = new java.util.ArrayList<com.google.rpc.PreconditionFailure.Violation>();
mutable_bitField0_ |= 0x00000001;
}
violations_.add(
input.readMessage(com.google.rpc.PreconditionFailure.Violation.parser(), extensionRegistry));
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
if (((mutable_bitField0_ & 0x00000001) != 0)) {
violations_ = java.util.Collections.unmodifiableList(violations_);
}
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() { getDescriptor() {
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_PreconditionFailure_descriptor; return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_PreconditionFailure_descriptor;
@ -157,6 +104,7 @@ private static final long serialVersionUID = 0L;
* <pre> * <pre>
* A description of how the precondition failed. Developers can use this * A description of how the precondition failed. Developers can use this
* description to understand how to fix the failure. * description to understand how to fix the failure.
*
* For example: "Terms of service not accepted". * For example: "Terms of service not accepted".
* </pre> * </pre>
* *
@ -168,6 +116,7 @@ private static final long serialVersionUID = 0L;
* <pre> * <pre>
* A description of how the precondition failed. Developers can use this * A description of how the precondition failed. Developers can use this
* description to understand how to fix the failure. * description to understand how to fix the failure.
*
* For example: "Terms of service not accepted". * For example: "Terms of service not accepted".
* </pre> * </pre>
* *
@ -206,66 +155,6 @@ private static final long serialVersionUID = 0L;
return new Violation(); return new Violation();
} }
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private Violation(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
java.lang.String s = input.readStringRequireUtf8();
type_ = s;
break;
}
case 18: {
java.lang.String s = input.readStringRequireUtf8();
subject_ = s;
break;
}
case 26: {
java.lang.String s = input.readStringRequireUtf8();
description_ = s;
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() { getDescriptor() {
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_PreconditionFailure_Violation_descriptor; return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_PreconditionFailure_Violation_descriptor;
@ -280,7 +169,8 @@ private static final long serialVersionUID = 0L;
} }
public static final int TYPE_FIELD_NUMBER = 1; public static final int TYPE_FIELD_NUMBER = 1;
private volatile java.lang.Object type_; @SuppressWarnings("serial")
private volatile java.lang.Object type_ = "";
/** /**
* <pre> * <pre>
* The type of PreconditionFailure. We recommend using a service-specific * The type of PreconditionFailure. We recommend using a service-specific
@ -330,7 +220,8 @@ private static final long serialVersionUID = 0L;
} }
public static final int SUBJECT_FIELD_NUMBER = 2; public static final int SUBJECT_FIELD_NUMBER = 2;
private volatile java.lang.Object subject_; @SuppressWarnings("serial")
private volatile java.lang.Object subject_ = "";
/** /**
* <pre> * <pre>
* The subject, relative to the type, that failed. * The subject, relative to the type, that failed.
@ -380,11 +271,13 @@ private static final long serialVersionUID = 0L;
} }
public static final int DESCRIPTION_FIELD_NUMBER = 3; public static final int DESCRIPTION_FIELD_NUMBER = 3;
private volatile java.lang.Object description_; @SuppressWarnings("serial")
private volatile java.lang.Object description_ = "";
/** /**
* <pre> * <pre>
* A description of how the precondition failed. Developers can use this * A description of how the precondition failed. Developers can use this
* description to understand how to fix the failure. * description to understand how to fix the failure.
*
* For example: "Terms of service not accepted". * For example: "Terms of service not accepted".
* </pre> * </pre>
* *
@ -408,6 +301,7 @@ private static final long serialVersionUID = 0L;
* <pre> * <pre>
* A description of how the precondition failed. Developers can use this * A description of how the precondition failed. Developers can use this
* description to understand how to fix the failure. * description to understand how to fix the failure.
*
* For example: "Terms of service not accepted". * For example: "Terms of service not accepted".
* </pre> * </pre>
* *
@ -443,16 +337,16 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output) public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException { throws java.io.IOException {
if (!getTypeBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(type_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, type_); com.google.protobuf.GeneratedMessageV3.writeString(output, 1, type_);
} }
if (!getSubjectBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(subject_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, subject_); com.google.protobuf.GeneratedMessageV3.writeString(output, 2, subject_);
} }
if (!getDescriptionBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 3, description_); com.google.protobuf.GeneratedMessageV3.writeString(output, 3, description_);
} }
unknownFields.writeTo(output); getUnknownFields().writeTo(output);
} }
@java.lang.Override @java.lang.Override
@ -461,16 +355,16 @@ private static final long serialVersionUID = 0L;
if (size != -1) return size; if (size != -1) return size;
size = 0; size = 0;
if (!getTypeBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(type_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, type_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, type_);
} }
if (!getSubjectBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(subject_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, subject_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, subject_);
} }
if (!getDescriptionBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, description_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, description_);
} }
size += unknownFields.getSerializedSize(); size += getUnknownFields().getSerializedSize();
memoizedSize = size; memoizedSize = size;
return size; return size;
} }
@ -491,7 +385,7 @@ private static final long serialVersionUID = 0L;
.equals(other.getSubject())) return false; .equals(other.getSubject())) return false;
if (!getDescription() if (!getDescription()
.equals(other.getDescription())) return false; .equals(other.getDescription())) return false;
if (!unknownFields.equals(other.unknownFields)) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true; return true;
} }
@ -508,7 +402,7 @@ private static final long serialVersionUID = 0L;
hash = (53 * hash) + getSubject().hashCode(); hash = (53 * hash) + getSubject().hashCode();
hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER;
hash = (53 * hash) + getDescription().hashCode(); hash = (53 * hash) + getDescription().hashCode();
hash = (29 * hash) + unknownFields.hashCode(); hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash; memoizedHashCode = hash;
return hash; return hash;
} }
@ -557,11 +451,13 @@ private static final long serialVersionUID = 0L;
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry); .parseWithIOException(PARSER, input, extensionRegistry);
} }
public static com.google.rpc.PreconditionFailure.Violation parseDelimitedFrom(java.io.InputStream input) public static com.google.rpc.PreconditionFailure.Violation parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException { throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input); .parseDelimitedWithIOException(PARSER, input);
} }
public static com.google.rpc.PreconditionFailure.Violation parseDelimitedFrom( public static com.google.rpc.PreconditionFailure.Violation parseDelimitedFrom(
java.io.InputStream input, java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
@ -629,28 +525,21 @@ private static final long serialVersionUID = 0L;
// Construct using com.google.rpc.PreconditionFailure.Violation.newBuilder() // Construct using com.google.rpc.PreconditionFailure.Violation.newBuilder()
private Builder() { private Builder() {
maybeForceBuilderInitialization();
} }
private Builder( private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent); super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
} }
@java.lang.Override @java.lang.Override
public Builder clear() { public Builder clear() {
super.clear(); super.clear();
bitField0_ = 0;
type_ = ""; type_ = "";
subject_ = ""; subject_ = "";
description_ = ""; description_ = "";
return this; return this;
} }
@ -677,13 +566,24 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public com.google.rpc.PreconditionFailure.Violation buildPartial() { public com.google.rpc.PreconditionFailure.Violation buildPartial() {
com.google.rpc.PreconditionFailure.Violation result = new com.google.rpc.PreconditionFailure.Violation(this); com.google.rpc.PreconditionFailure.Violation result = new com.google.rpc.PreconditionFailure.Violation(this);
result.type_ = type_; if (bitField0_ != 0) { buildPartial0(result); }
result.subject_ = subject_;
result.description_ = description_;
onBuilt(); onBuilt();
return result; return result;
} }
private void buildPartial0(com.google.rpc.PreconditionFailure.Violation result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.type_ = type_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.subject_ = subject_;
}
if (((from_bitField0_ & 0x00000004) != 0)) {
result.description_ = description_;
}
}
@java.lang.Override @java.lang.Override
public Builder clone() { public Builder clone() {
return super.clone(); return super.clone();
@ -730,17 +630,20 @@ private static final long serialVersionUID = 0L;
if (other == com.google.rpc.PreconditionFailure.Violation.getDefaultInstance()) return this; if (other == com.google.rpc.PreconditionFailure.Violation.getDefaultInstance()) return this;
if (!other.getType().isEmpty()) { if (!other.getType().isEmpty()) {
type_ = other.type_; type_ = other.type_;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
} }
if (!other.getSubject().isEmpty()) { if (!other.getSubject().isEmpty()) {
subject_ = other.subject_; subject_ = other.subject_;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
} }
if (!other.getDescription().isEmpty()) { if (!other.getDescription().isEmpty()) {
description_ = other.description_; description_ = other.description_;
bitField0_ |= 0x00000004;
onChanged(); onChanged();
} }
this.mergeUnknownFields(other.unknownFields); this.mergeUnknownFields(other.getUnknownFields());
onChanged(); onChanged();
return this; return this;
} }
@ -755,19 +658,48 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException { throws java.io.IOException {
com.google.rpc.PreconditionFailure.Violation parsedMessage = null; if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try { try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
type_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 18: {
subject_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000002;
break;
} // case 18
case 26: {
description_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000004;
break;
} // case 26
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) { } catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.google.rpc.PreconditionFailure.Violation) e.getUnfinishedMessage();
throw e.unwrapIOException(); throw e.unwrapIOException();
} finally { } finally {
if (parsedMessage != null) { onChanged();
mergeFrom(parsedMessage); } // finally
}
}
return this; return this;
} }
private int bitField0_;
private java.lang.Object type_ = ""; private java.lang.Object type_ = "";
/** /**
@ -828,11 +760,9 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setType( public Builder setType(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
type_ = value; type_ = value;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -847,8 +777,8 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearType() { public Builder clearType() {
type_ = getDefaultInstance().getType(); type_ = getDefaultInstance().getType();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged(); onChanged();
return this; return this;
} }
@ -865,12 +795,10 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setTypeBytes( public Builder setTypeBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
type_ = value; type_ = value;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -934,11 +862,9 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setSubject( public Builder setSubject(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
subject_ = value; subject_ = value;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
return this; return this;
} }
@ -953,8 +879,8 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearSubject() { public Builder clearSubject() {
subject_ = getDefaultInstance().getSubject(); subject_ = getDefaultInstance().getSubject();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged(); onChanged();
return this; return this;
} }
@ -971,12 +897,10 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setSubjectBytes( public Builder setSubjectBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
subject_ = value; subject_ = value;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
return this; return this;
} }
@ -986,6 +910,7 @@ private static final long serialVersionUID = 0L;
* <pre> * <pre>
* A description of how the precondition failed. Developers can use this * A description of how the precondition failed. Developers can use this
* description to understand how to fix the failure. * description to understand how to fix the failure.
*
* For example: "Terms of service not accepted". * For example: "Terms of service not accepted".
* </pre> * </pre>
* *
@ -1008,6 +933,7 @@ private static final long serialVersionUID = 0L;
* <pre> * <pre>
* A description of how the precondition failed. Developers can use this * A description of how the precondition failed. Developers can use this
* description to understand how to fix the failure. * description to understand how to fix the failure.
*
* For example: "Terms of service not accepted". * For example: "Terms of service not accepted".
* </pre> * </pre>
* *
@ -1031,6 +957,7 @@ private static final long serialVersionUID = 0L;
* <pre> * <pre>
* A description of how the precondition failed. Developers can use this * A description of how the precondition failed. Developers can use this
* description to understand how to fix the failure. * description to understand how to fix the failure.
*
* For example: "Terms of service not accepted". * For example: "Terms of service not accepted".
* </pre> * </pre>
* *
@ -1040,11 +967,9 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setDescription( public Builder setDescription(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
description_ = value; description_ = value;
bitField0_ |= 0x00000004;
onChanged(); onChanged();
return this; return this;
} }
@ -1052,6 +977,7 @@ private static final long serialVersionUID = 0L;
* <pre> * <pre>
* A description of how the precondition failed. Developers can use this * A description of how the precondition failed. Developers can use this
* description to understand how to fix the failure. * description to understand how to fix the failure.
*
* For example: "Terms of service not accepted". * For example: "Terms of service not accepted".
* </pre> * </pre>
* *
@ -1059,8 +985,8 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearDescription() { public Builder clearDescription() {
description_ = getDefaultInstance().getDescription(); description_ = getDefaultInstance().getDescription();
bitField0_ = (bitField0_ & ~0x00000004);
onChanged(); onChanged();
return this; return this;
} }
@ -1068,6 +994,7 @@ private static final long serialVersionUID = 0L;
* <pre> * <pre>
* A description of how the precondition failed. Developers can use this * A description of how the precondition failed. Developers can use this
* description to understand how to fix the failure. * description to understand how to fix the failure.
*
* For example: "Terms of service not accepted". * For example: "Terms of service not accepted".
* </pre> * </pre>
* *
@ -1077,12 +1004,10 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setDescriptionBytes( public Builder setDescriptionBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
description_ = value; description_ = value;
bitField0_ |= 0x00000004;
onChanged(); onChanged();
return this; return this;
} }
@ -1119,7 +1044,18 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException { throws com.google.protobuf.InvalidProtocolBufferException {
return new Violation(input, extensionRegistry); Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
} }
}; };
@ -1140,6 +1076,7 @@ private static final long serialVersionUID = 0L;
} }
public static final int VIOLATIONS_FIELD_NUMBER = 1; public static final int VIOLATIONS_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private java.util.List<com.google.rpc.PreconditionFailure.Violation> violations_; private java.util.List<com.google.rpc.PreconditionFailure.Violation> violations_;
/** /**
* <pre> * <pre>
@ -1216,7 +1153,7 @@ private static final long serialVersionUID = 0L;
for (int i = 0; i < violations_.size(); i++) { for (int i = 0; i < violations_.size(); i++) {
output.writeMessage(1, violations_.get(i)); output.writeMessage(1, violations_.get(i));
} }
unknownFields.writeTo(output); getUnknownFields().writeTo(output);
} }
@java.lang.Override @java.lang.Override
@ -1229,7 +1166,7 @@ private static final long serialVersionUID = 0L;
size += com.google.protobuf.CodedOutputStream size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, violations_.get(i)); .computeMessageSize(1, violations_.get(i));
} }
size += unknownFields.getSerializedSize(); size += getUnknownFields().getSerializedSize();
memoizedSize = size; memoizedSize = size;
return size; return size;
} }
@ -1246,7 +1183,7 @@ private static final long serialVersionUID = 0L;
if (!getViolationsList() if (!getViolationsList()
.equals(other.getViolationsList())) return false; .equals(other.getViolationsList())) return false;
if (!unknownFields.equals(other.unknownFields)) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true; return true;
} }
@ -1261,7 +1198,7 @@ private static final long serialVersionUID = 0L;
hash = (37 * hash) + VIOLATIONS_FIELD_NUMBER; hash = (37 * hash) + VIOLATIONS_FIELD_NUMBER;
hash = (53 * hash) + getViolationsList().hashCode(); hash = (53 * hash) + getViolationsList().hashCode();
} }
hash = (29 * hash) + unknownFields.hashCode(); hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash; memoizedHashCode = hash;
return hash; return hash;
} }
@ -1310,11 +1247,13 @@ private static final long serialVersionUID = 0L;
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry); .parseWithIOException(PARSER, input, extensionRegistry);
} }
public static com.google.rpc.PreconditionFailure parseDelimitedFrom(java.io.InputStream input) public static com.google.rpc.PreconditionFailure parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException { throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input); .parseDelimitedWithIOException(PARSER, input);
} }
public static com.google.rpc.PreconditionFailure parseDelimitedFrom( public static com.google.rpc.PreconditionFailure parseDelimitedFrom(
java.io.InputStream input, java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
@ -1359,6 +1298,7 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* Describes what preconditions have failed. * Describes what preconditions have failed.
*
* For example, if an RPC failed because it required the Terms of Service to be * For example, if an RPC failed because it required the Terms of Service to be
* acknowledged, it could list the terms of service violation in the * acknowledged, it could list the terms of service violation in the
* PreconditionFailure message. * PreconditionFailure message.
@ -1385,29 +1325,25 @@ private static final long serialVersionUID = 0L;
// Construct using com.google.rpc.PreconditionFailure.newBuilder() // Construct using com.google.rpc.PreconditionFailure.newBuilder()
private Builder() { private Builder() {
maybeForceBuilderInitialization();
} }
private Builder( private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent); super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getViolationsFieldBuilder();
}
} }
@java.lang.Override @java.lang.Override
public Builder clear() { public Builder clear() {
super.clear(); super.clear();
bitField0_ = 0;
if (violationsBuilder_ == null) { if (violationsBuilder_ == null) {
violations_ = java.util.Collections.emptyList(); violations_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001);
} else { } else {
violations_ = null;
violationsBuilder_.clear(); violationsBuilder_.clear();
} }
bitField0_ = (bitField0_ & ~0x00000001);
return this; return this;
} }
@ -1434,7 +1370,13 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public com.google.rpc.PreconditionFailure buildPartial() { public com.google.rpc.PreconditionFailure buildPartial() {
com.google.rpc.PreconditionFailure result = new com.google.rpc.PreconditionFailure(this); com.google.rpc.PreconditionFailure result = new com.google.rpc.PreconditionFailure(this);
int from_bitField0_ = bitField0_; buildPartialRepeatedFields(result);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartialRepeatedFields(com.google.rpc.PreconditionFailure result) {
if (violationsBuilder_ == null) { if (violationsBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0)) { if (((bitField0_ & 0x00000001) != 0)) {
violations_ = java.util.Collections.unmodifiableList(violations_); violations_ = java.util.Collections.unmodifiableList(violations_);
@ -1444,8 +1386,10 @@ private static final long serialVersionUID = 0L;
} else { } else {
result.violations_ = violationsBuilder_.build(); result.violations_ = violationsBuilder_.build();
} }
onBuilt(); }
return result;
private void buildPartial0(com.google.rpc.PreconditionFailure result) {
int from_bitField0_ = bitField0_;
} }
@java.lang.Override @java.lang.Override
@ -1518,7 +1462,7 @@ private static final long serialVersionUID = 0L;
} }
} }
} }
this.mergeUnknownFields(other.unknownFields); this.mergeUnknownFields(other.getUnknownFields());
onChanged(); onChanged();
return this; return this;
} }
@ -1533,17 +1477,43 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException { throws java.io.IOException {
com.google.rpc.PreconditionFailure parsedMessage = null; if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try { try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
com.google.rpc.PreconditionFailure.Violation m =
input.readMessage(
com.google.rpc.PreconditionFailure.Violation.parser(),
extensionRegistry);
if (violationsBuilder_ == null) {
ensureViolationsIsMutable();
violations_.add(m);
} else {
violationsBuilder_.addMessage(m);
}
break;
} // case 10
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) { } catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.google.rpc.PreconditionFailure) e.getUnfinishedMessage();
throw e.unwrapIOException(); throw e.unwrapIOException();
} finally { } finally {
if (parsedMessage != null) { onChanged();
mergeFrom(parsedMessage); } // finally
}
}
return this; return this;
} }
private int bitField0_; private int bitField0_;
@ -1892,7 +1862,18 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException { throws com.google.protobuf.InvalidProtocolBufferException {
return new PreconditionFailure(input, extensionRegistry); Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
} }
}; };

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/rpc/error_details.proto // source: google/rpc/error_details.proto
// Protobuf Java Version: 3.25.6
package com.google.rpc; package com.google.rpc;
public interface PreconditionFailureOrBuilder extends public interface PreconditionFailureOrBuilder extends

View File

@ -1,17 +1,20 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/rpc/error_details.proto // source: google/rpc/error_details.proto
// Protobuf Java Version: 3.25.6
package com.google.rpc; package com.google.rpc;
/** /**
* <pre> * <pre>
* Describes how a quota check failed. * Describes how a quota check failed.
*
* For example if a daily limit was exceeded for the calling project, * For example if a daily limit was exceeded for the calling project,
* a service could respond with a QuotaFailure detail containing the project * a service could respond with a QuotaFailure detail containing the project
* id and the description of the quota limit that was exceeded. If the * id and the description of the quota limit that was exceeded. If the
* calling project hasn't enabled the service in the developer console, then * calling project hasn't enabled the service in the developer console, then
* a service could respond with the project id and set `service_disabled` * a service could respond with the project id and set `service_disabled`
* to true. * to true.
*
* Also see RetryDetail and Help types for other details about handling a * Also see RetryDetail and Help types for other details about handling a
* quota failure. * quota failure.
* </pre> * </pre>
@ -38,61 +41,6 @@ private static final long serialVersionUID = 0L;
return new QuotaFailure(); return new QuotaFailure();
} }
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private QuotaFailure(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
int mutable_bitField0_ = 0;
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
if (!((mutable_bitField0_ & 0x00000001) != 0)) {
violations_ = new java.util.ArrayList<com.google.rpc.QuotaFailure.Violation>();
mutable_bitField0_ |= 0x00000001;
}
violations_.add(
input.readMessage(com.google.rpc.QuotaFailure.Violation.parser(), extensionRegistry));
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
if (((mutable_bitField0_ & 0x00000001) != 0)) {
violations_ = java.util.Collections.unmodifiableList(violations_);
}
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() { getDescriptor() {
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_QuotaFailure_descriptor; return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_QuotaFailure_descriptor;
@ -140,6 +88,7 @@ private static final long serialVersionUID = 0L;
* description to find more about the quota configuration in the service's * description to find more about the quota configuration in the service's
* public documentation, or find the relevant quota limit to adjust through * public documentation, or find the relevant quota limit to adjust through
* developer console. * developer console.
*
* For example: "Service disabled" or "Daily Limit for read operations * For example: "Service disabled" or "Daily Limit for read operations
* exceeded". * exceeded".
* </pre> * </pre>
@ -154,6 +103,7 @@ private static final long serialVersionUID = 0L;
* description to find more about the quota configuration in the service's * description to find more about the quota configuration in the service's
* public documentation, or find the relevant quota limit to adjust through * public documentation, or find the relevant quota limit to adjust through
* developer console. * developer console.
*
* For example: "Service disabled" or "Daily Limit for read operations * For example: "Service disabled" or "Daily Limit for read operations
* exceeded". * exceeded".
* </pre> * </pre>
@ -193,60 +143,6 @@ private static final long serialVersionUID = 0L;
return new Violation(); return new Violation();
} }
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private Violation(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
java.lang.String s = input.readStringRequireUtf8();
subject_ = s;
break;
}
case 18: {
java.lang.String s = input.readStringRequireUtf8();
description_ = s;
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() { getDescriptor() {
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_QuotaFailure_Violation_descriptor; return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_QuotaFailure_Violation_descriptor;
@ -261,7 +157,8 @@ private static final long serialVersionUID = 0L;
} }
public static final int SUBJECT_FIELD_NUMBER = 1; public static final int SUBJECT_FIELD_NUMBER = 1;
private volatile java.lang.Object subject_; @SuppressWarnings("serial")
private volatile java.lang.Object subject_ = "";
/** /**
* <pre> * <pre>
* The subject on which the quota check failed. * The subject on which the quota check failed.
@ -311,13 +208,15 @@ private static final long serialVersionUID = 0L;
} }
public static final int DESCRIPTION_FIELD_NUMBER = 2; public static final int DESCRIPTION_FIELD_NUMBER = 2;
private volatile java.lang.Object description_; @SuppressWarnings("serial")
private volatile java.lang.Object description_ = "";
/** /**
* <pre> * <pre>
* A description of how the quota check failed. Clients can use this * A description of how the quota check failed. Clients can use this
* description to find more about the quota configuration in the service's * description to find more about the quota configuration in the service's
* public documentation, or find the relevant quota limit to adjust through * public documentation, or find the relevant quota limit to adjust through
* developer console. * developer console.
*
* For example: "Service disabled" or "Daily Limit for read operations * For example: "Service disabled" or "Daily Limit for read operations
* exceeded". * exceeded".
* </pre> * </pre>
@ -344,6 +243,7 @@ private static final long serialVersionUID = 0L;
* description to find more about the quota configuration in the service's * description to find more about the quota configuration in the service's
* public documentation, or find the relevant quota limit to adjust through * public documentation, or find the relevant quota limit to adjust through
* developer console. * developer console.
*
* For example: "Service disabled" or "Daily Limit for read operations * For example: "Service disabled" or "Daily Limit for read operations
* exceeded". * exceeded".
* </pre> * </pre>
@ -380,13 +280,13 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output) public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException { throws java.io.IOException {
if (!getSubjectBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(subject_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, subject_); com.google.protobuf.GeneratedMessageV3.writeString(output, 1, subject_);
} }
if (!getDescriptionBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, description_); com.google.protobuf.GeneratedMessageV3.writeString(output, 2, description_);
} }
unknownFields.writeTo(output); getUnknownFields().writeTo(output);
} }
@java.lang.Override @java.lang.Override
@ -395,13 +295,13 @@ private static final long serialVersionUID = 0L;
if (size != -1) return size; if (size != -1) return size;
size = 0; size = 0;
if (!getSubjectBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(subject_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, subject_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, subject_);
} }
if (!getDescriptionBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, description_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, description_);
} }
size += unknownFields.getSerializedSize(); size += getUnknownFields().getSerializedSize();
memoizedSize = size; memoizedSize = size;
return size; return size;
} }
@ -420,7 +320,7 @@ private static final long serialVersionUID = 0L;
.equals(other.getSubject())) return false; .equals(other.getSubject())) return false;
if (!getDescription() if (!getDescription()
.equals(other.getDescription())) return false; .equals(other.getDescription())) return false;
if (!unknownFields.equals(other.unknownFields)) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true; return true;
} }
@ -435,7 +335,7 @@ private static final long serialVersionUID = 0L;
hash = (53 * hash) + getSubject().hashCode(); hash = (53 * hash) + getSubject().hashCode();
hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER;
hash = (53 * hash) + getDescription().hashCode(); hash = (53 * hash) + getDescription().hashCode();
hash = (29 * hash) + unknownFields.hashCode(); hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash; memoizedHashCode = hash;
return hash; return hash;
} }
@ -484,11 +384,13 @@ private static final long serialVersionUID = 0L;
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry); .parseWithIOException(PARSER, input, extensionRegistry);
} }
public static com.google.rpc.QuotaFailure.Violation parseDelimitedFrom(java.io.InputStream input) public static com.google.rpc.QuotaFailure.Violation parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException { throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input); .parseDelimitedWithIOException(PARSER, input);
} }
public static com.google.rpc.QuotaFailure.Violation parseDelimitedFrom( public static com.google.rpc.QuotaFailure.Violation parseDelimitedFrom(
java.io.InputStream input, java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
@ -557,26 +459,20 @@ private static final long serialVersionUID = 0L;
// Construct using com.google.rpc.QuotaFailure.Violation.newBuilder() // Construct using com.google.rpc.QuotaFailure.Violation.newBuilder()
private Builder() { private Builder() {
maybeForceBuilderInitialization();
} }
private Builder( private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent); super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
} }
@java.lang.Override @java.lang.Override
public Builder clear() { public Builder clear() {
super.clear(); super.clear();
bitField0_ = 0;
subject_ = ""; subject_ = "";
description_ = ""; description_ = "";
return this; return this;
} }
@ -603,12 +499,21 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public com.google.rpc.QuotaFailure.Violation buildPartial() { public com.google.rpc.QuotaFailure.Violation buildPartial() {
com.google.rpc.QuotaFailure.Violation result = new com.google.rpc.QuotaFailure.Violation(this); com.google.rpc.QuotaFailure.Violation result = new com.google.rpc.QuotaFailure.Violation(this);
result.subject_ = subject_; if (bitField0_ != 0) { buildPartial0(result); }
result.description_ = description_;
onBuilt(); onBuilt();
return result; return result;
} }
private void buildPartial0(com.google.rpc.QuotaFailure.Violation result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.subject_ = subject_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.description_ = description_;
}
}
@java.lang.Override @java.lang.Override
public Builder clone() { public Builder clone() {
return super.clone(); return super.clone();
@ -655,13 +560,15 @@ private static final long serialVersionUID = 0L;
if (other == com.google.rpc.QuotaFailure.Violation.getDefaultInstance()) return this; if (other == com.google.rpc.QuotaFailure.Violation.getDefaultInstance()) return this;
if (!other.getSubject().isEmpty()) { if (!other.getSubject().isEmpty()) {
subject_ = other.subject_; subject_ = other.subject_;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
} }
if (!other.getDescription().isEmpty()) { if (!other.getDescription().isEmpty()) {
description_ = other.description_; description_ = other.description_;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
} }
this.mergeUnknownFields(other.unknownFields); this.mergeUnknownFields(other.getUnknownFields());
onChanged(); onChanged();
return this; return this;
} }
@ -676,19 +583,43 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException { throws java.io.IOException {
com.google.rpc.QuotaFailure.Violation parsedMessage = null; if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try { try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
subject_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 18: {
description_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000002;
break;
} // case 18
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) { } catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.google.rpc.QuotaFailure.Violation) e.getUnfinishedMessage();
throw e.unwrapIOException(); throw e.unwrapIOException();
} finally { } finally {
if (parsedMessage != null) { onChanged();
mergeFrom(parsedMessage); } // finally
}
}
return this; return this;
} }
private int bitField0_;
private java.lang.Object subject_ = ""; private java.lang.Object subject_ = "";
/** /**
@ -749,11 +680,9 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setSubject( public Builder setSubject(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
subject_ = value; subject_ = value;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -768,8 +697,8 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearSubject() { public Builder clearSubject() {
subject_ = getDefaultInstance().getSubject(); subject_ = getDefaultInstance().getSubject();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged(); onChanged();
return this; return this;
} }
@ -786,12 +715,10 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setSubjectBytes( public Builder setSubjectBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
subject_ = value; subject_ = value;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -803,6 +730,7 @@ private static final long serialVersionUID = 0L;
* description to find more about the quota configuration in the service's * description to find more about the quota configuration in the service's
* public documentation, or find the relevant quota limit to adjust through * public documentation, or find the relevant quota limit to adjust through
* developer console. * developer console.
*
* For example: "Service disabled" or "Daily Limit for read operations * For example: "Service disabled" or "Daily Limit for read operations
* exceeded". * exceeded".
* </pre> * </pre>
@ -828,6 +756,7 @@ private static final long serialVersionUID = 0L;
* description to find more about the quota configuration in the service's * description to find more about the quota configuration in the service's
* public documentation, or find the relevant quota limit to adjust through * public documentation, or find the relevant quota limit to adjust through
* developer console. * developer console.
*
* For example: "Service disabled" or "Daily Limit for read operations * For example: "Service disabled" or "Daily Limit for read operations
* exceeded". * exceeded".
* </pre> * </pre>
@ -854,6 +783,7 @@ private static final long serialVersionUID = 0L;
* description to find more about the quota configuration in the service's * description to find more about the quota configuration in the service's
* public documentation, or find the relevant quota limit to adjust through * public documentation, or find the relevant quota limit to adjust through
* developer console. * developer console.
*
* For example: "Service disabled" or "Daily Limit for read operations * For example: "Service disabled" or "Daily Limit for read operations
* exceeded". * exceeded".
* </pre> * </pre>
@ -864,11 +794,9 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setDescription( public Builder setDescription(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
description_ = value; description_ = value;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
return this; return this;
} }
@ -878,6 +806,7 @@ private static final long serialVersionUID = 0L;
* description to find more about the quota configuration in the service's * description to find more about the quota configuration in the service's
* public documentation, or find the relevant quota limit to adjust through * public documentation, or find the relevant quota limit to adjust through
* developer console. * developer console.
*
* For example: "Service disabled" or "Daily Limit for read operations * For example: "Service disabled" or "Daily Limit for read operations
* exceeded". * exceeded".
* </pre> * </pre>
@ -886,8 +815,8 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearDescription() { public Builder clearDescription() {
description_ = getDefaultInstance().getDescription(); description_ = getDefaultInstance().getDescription();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged(); onChanged();
return this; return this;
} }
@ -897,6 +826,7 @@ private static final long serialVersionUID = 0L;
* description to find more about the quota configuration in the service's * description to find more about the quota configuration in the service's
* public documentation, or find the relevant quota limit to adjust through * public documentation, or find the relevant quota limit to adjust through
* developer console. * developer console.
*
* For example: "Service disabled" or "Daily Limit for read operations * For example: "Service disabled" or "Daily Limit for read operations
* exceeded". * exceeded".
* </pre> * </pre>
@ -907,12 +837,10 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setDescriptionBytes( public Builder setDescriptionBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
description_ = value; description_ = value;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
return this; return this;
} }
@ -949,7 +877,18 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException { throws com.google.protobuf.InvalidProtocolBufferException {
return new Violation(input, extensionRegistry); Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
} }
}; };
@ -970,6 +909,7 @@ private static final long serialVersionUID = 0L;
} }
public static final int VIOLATIONS_FIELD_NUMBER = 1; public static final int VIOLATIONS_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private java.util.List<com.google.rpc.QuotaFailure.Violation> violations_; private java.util.List<com.google.rpc.QuotaFailure.Violation> violations_;
/** /**
* <pre> * <pre>
@ -1046,7 +986,7 @@ private static final long serialVersionUID = 0L;
for (int i = 0; i < violations_.size(); i++) { for (int i = 0; i < violations_.size(); i++) {
output.writeMessage(1, violations_.get(i)); output.writeMessage(1, violations_.get(i));
} }
unknownFields.writeTo(output); getUnknownFields().writeTo(output);
} }
@java.lang.Override @java.lang.Override
@ -1059,7 +999,7 @@ private static final long serialVersionUID = 0L;
size += com.google.protobuf.CodedOutputStream size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, violations_.get(i)); .computeMessageSize(1, violations_.get(i));
} }
size += unknownFields.getSerializedSize(); size += getUnknownFields().getSerializedSize();
memoizedSize = size; memoizedSize = size;
return size; return size;
} }
@ -1076,7 +1016,7 @@ private static final long serialVersionUID = 0L;
if (!getViolationsList() if (!getViolationsList()
.equals(other.getViolationsList())) return false; .equals(other.getViolationsList())) return false;
if (!unknownFields.equals(other.unknownFields)) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true; return true;
} }
@ -1091,7 +1031,7 @@ private static final long serialVersionUID = 0L;
hash = (37 * hash) + VIOLATIONS_FIELD_NUMBER; hash = (37 * hash) + VIOLATIONS_FIELD_NUMBER;
hash = (53 * hash) + getViolationsList().hashCode(); hash = (53 * hash) + getViolationsList().hashCode();
} }
hash = (29 * hash) + unknownFields.hashCode(); hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash; memoizedHashCode = hash;
return hash; return hash;
} }
@ -1140,11 +1080,13 @@ private static final long serialVersionUID = 0L;
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry); .parseWithIOException(PARSER, input, extensionRegistry);
} }
public static com.google.rpc.QuotaFailure parseDelimitedFrom(java.io.InputStream input) public static com.google.rpc.QuotaFailure parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException { throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input); .parseDelimitedWithIOException(PARSER, input);
} }
public static com.google.rpc.QuotaFailure parseDelimitedFrom( public static com.google.rpc.QuotaFailure parseDelimitedFrom(
java.io.InputStream input, java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
@ -1189,12 +1131,14 @@ private static final long serialVersionUID = 0L;
/** /**
* <pre> * <pre>
* Describes how a quota check failed. * Describes how a quota check failed.
*
* For example if a daily limit was exceeded for the calling project, * For example if a daily limit was exceeded for the calling project,
* a service could respond with a QuotaFailure detail containing the project * a service could respond with a QuotaFailure detail containing the project
* id and the description of the quota limit that was exceeded. If the * id and the description of the quota limit that was exceeded. If the
* calling project hasn't enabled the service in the developer console, then * calling project hasn't enabled the service in the developer console, then
* a service could respond with the project id and set `service_disabled` * a service could respond with the project id and set `service_disabled`
* to true. * to true.
*
* Also see RetryDetail and Help types for other details about handling a * Also see RetryDetail and Help types for other details about handling a
* quota failure. * quota failure.
* </pre> * </pre>
@ -1220,29 +1164,25 @@ private static final long serialVersionUID = 0L;
// Construct using com.google.rpc.QuotaFailure.newBuilder() // Construct using com.google.rpc.QuotaFailure.newBuilder()
private Builder() { private Builder() {
maybeForceBuilderInitialization();
} }
private Builder( private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent); super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getViolationsFieldBuilder();
}
} }
@java.lang.Override @java.lang.Override
public Builder clear() { public Builder clear() {
super.clear(); super.clear();
bitField0_ = 0;
if (violationsBuilder_ == null) { if (violationsBuilder_ == null) {
violations_ = java.util.Collections.emptyList(); violations_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001);
} else { } else {
violations_ = null;
violationsBuilder_.clear(); violationsBuilder_.clear();
} }
bitField0_ = (bitField0_ & ~0x00000001);
return this; return this;
} }
@ -1269,7 +1209,13 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public com.google.rpc.QuotaFailure buildPartial() { public com.google.rpc.QuotaFailure buildPartial() {
com.google.rpc.QuotaFailure result = new com.google.rpc.QuotaFailure(this); com.google.rpc.QuotaFailure result = new com.google.rpc.QuotaFailure(this);
int from_bitField0_ = bitField0_; buildPartialRepeatedFields(result);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartialRepeatedFields(com.google.rpc.QuotaFailure result) {
if (violationsBuilder_ == null) { if (violationsBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0)) { if (((bitField0_ & 0x00000001) != 0)) {
violations_ = java.util.Collections.unmodifiableList(violations_); violations_ = java.util.Collections.unmodifiableList(violations_);
@ -1279,8 +1225,10 @@ private static final long serialVersionUID = 0L;
} else { } else {
result.violations_ = violationsBuilder_.build(); result.violations_ = violationsBuilder_.build();
} }
onBuilt(); }
return result;
private void buildPartial0(com.google.rpc.QuotaFailure result) {
int from_bitField0_ = bitField0_;
} }
@java.lang.Override @java.lang.Override
@ -1353,7 +1301,7 @@ private static final long serialVersionUID = 0L;
} }
} }
} }
this.mergeUnknownFields(other.unknownFields); this.mergeUnknownFields(other.getUnknownFields());
onChanged(); onChanged();
return this; return this;
} }
@ -1368,17 +1316,43 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException { throws java.io.IOException {
com.google.rpc.QuotaFailure parsedMessage = null; if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try { try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
com.google.rpc.QuotaFailure.Violation m =
input.readMessage(
com.google.rpc.QuotaFailure.Violation.parser(),
extensionRegistry);
if (violationsBuilder_ == null) {
ensureViolationsIsMutable();
violations_.add(m);
} else {
violationsBuilder_.addMessage(m);
}
break;
} // case 10
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) { } catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.google.rpc.QuotaFailure) e.getUnfinishedMessage();
throw e.unwrapIOException(); throw e.unwrapIOException();
} finally { } finally {
if (parsedMessage != null) { onChanged();
mergeFrom(parsedMessage); } // finally
}
}
return this; return this;
} }
private int bitField0_; private int bitField0_;
@ -1727,7 +1701,18 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException { throws com.google.protobuf.InvalidProtocolBufferException {
return new QuotaFailure(input, extensionRegistry); Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
} }
}; };

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/rpc/error_details.proto // source: google/rpc/error_details.proto
// Protobuf Java Version: 3.25.6
package com.google.rpc; package com.google.rpc;
public interface QuotaFailureOrBuilder extends public interface QuotaFailureOrBuilder extends

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/rpc/error_details.proto // source: google/rpc/error_details.proto
// Protobuf Java Version: 3.25.6
package com.google.rpc; package com.google.rpc;
/** /**
@ -32,60 +33,6 @@ private static final long serialVersionUID = 0L;
return new RequestInfo(); return new RequestInfo();
} }
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private RequestInfo(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
java.lang.String s = input.readStringRequireUtf8();
requestId_ = s;
break;
}
case 18: {
java.lang.String s = input.readStringRequireUtf8();
servingData_ = s;
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() { getDescriptor() {
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_RequestInfo_descriptor; return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_RequestInfo_descriptor;
@ -100,7 +47,8 @@ private static final long serialVersionUID = 0L;
} }
public static final int REQUEST_ID_FIELD_NUMBER = 1; public static final int REQUEST_ID_FIELD_NUMBER = 1;
private volatile java.lang.Object requestId_; @SuppressWarnings("serial")
private volatile java.lang.Object requestId_ = "";
/** /**
* <pre> * <pre>
* An opaque string that should only be interpreted by the service generating * An opaque string that should only be interpreted by the service generating
@ -148,7 +96,8 @@ private static final long serialVersionUID = 0L;
} }
public static final int SERVING_DATA_FIELD_NUMBER = 2; public static final int SERVING_DATA_FIELD_NUMBER = 2;
private volatile java.lang.Object servingData_; @SuppressWarnings("serial")
private volatile java.lang.Object servingData_ = "";
/** /**
* <pre> * <pre>
* Any data that was used to serve this request. For example, an encrypted * Any data that was used to serve this request. For example, an encrypted
@ -209,13 +158,13 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output) public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException { throws java.io.IOException {
if (!getRequestIdBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(requestId_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, requestId_); com.google.protobuf.GeneratedMessageV3.writeString(output, 1, requestId_);
} }
if (!getServingDataBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(servingData_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, servingData_); com.google.protobuf.GeneratedMessageV3.writeString(output, 2, servingData_);
} }
unknownFields.writeTo(output); getUnknownFields().writeTo(output);
} }
@java.lang.Override @java.lang.Override
@ -224,13 +173,13 @@ private static final long serialVersionUID = 0L;
if (size != -1) return size; if (size != -1) return size;
size = 0; size = 0;
if (!getRequestIdBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(requestId_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, requestId_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, requestId_);
} }
if (!getServingDataBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(servingData_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, servingData_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, servingData_);
} }
size += unknownFields.getSerializedSize(); size += getUnknownFields().getSerializedSize();
memoizedSize = size; memoizedSize = size;
return size; return size;
} }
@ -249,7 +198,7 @@ private static final long serialVersionUID = 0L;
.equals(other.getRequestId())) return false; .equals(other.getRequestId())) return false;
if (!getServingData() if (!getServingData()
.equals(other.getServingData())) return false; .equals(other.getServingData())) return false;
if (!unknownFields.equals(other.unknownFields)) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true; return true;
} }
@ -264,7 +213,7 @@ private static final long serialVersionUID = 0L;
hash = (53 * hash) + getRequestId().hashCode(); hash = (53 * hash) + getRequestId().hashCode();
hash = (37 * hash) + SERVING_DATA_FIELD_NUMBER; hash = (37 * hash) + SERVING_DATA_FIELD_NUMBER;
hash = (53 * hash) + getServingData().hashCode(); hash = (53 * hash) + getServingData().hashCode();
hash = (29 * hash) + unknownFields.hashCode(); hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash; memoizedHashCode = hash;
return hash; return hash;
} }
@ -313,11 +262,13 @@ private static final long serialVersionUID = 0L;
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry); .parseWithIOException(PARSER, input, extensionRegistry);
} }
public static com.google.rpc.RequestInfo parseDelimitedFrom(java.io.InputStream input) public static com.google.rpc.RequestInfo parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException { throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input); .parseDelimitedWithIOException(PARSER, input);
} }
public static com.google.rpc.RequestInfo parseDelimitedFrom( public static com.google.rpc.RequestInfo parseDelimitedFrom(
java.io.InputStream input, java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
@ -386,26 +337,20 @@ private static final long serialVersionUID = 0L;
// Construct using com.google.rpc.RequestInfo.newBuilder() // Construct using com.google.rpc.RequestInfo.newBuilder()
private Builder() { private Builder() {
maybeForceBuilderInitialization();
} }
private Builder( private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent); super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
} }
@java.lang.Override @java.lang.Override
public Builder clear() { public Builder clear() {
super.clear(); super.clear();
bitField0_ = 0;
requestId_ = ""; requestId_ = "";
servingData_ = ""; servingData_ = "";
return this; return this;
} }
@ -432,12 +377,21 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public com.google.rpc.RequestInfo buildPartial() { public com.google.rpc.RequestInfo buildPartial() {
com.google.rpc.RequestInfo result = new com.google.rpc.RequestInfo(this); com.google.rpc.RequestInfo result = new com.google.rpc.RequestInfo(this);
result.requestId_ = requestId_; if (bitField0_ != 0) { buildPartial0(result); }
result.servingData_ = servingData_;
onBuilt(); onBuilt();
return result; return result;
} }
private void buildPartial0(com.google.rpc.RequestInfo result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.requestId_ = requestId_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.servingData_ = servingData_;
}
}
@java.lang.Override @java.lang.Override
public Builder clone() { public Builder clone() {
return super.clone(); return super.clone();
@ -484,13 +438,15 @@ private static final long serialVersionUID = 0L;
if (other == com.google.rpc.RequestInfo.getDefaultInstance()) return this; if (other == com.google.rpc.RequestInfo.getDefaultInstance()) return this;
if (!other.getRequestId().isEmpty()) { if (!other.getRequestId().isEmpty()) {
requestId_ = other.requestId_; requestId_ = other.requestId_;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
} }
if (!other.getServingData().isEmpty()) { if (!other.getServingData().isEmpty()) {
servingData_ = other.servingData_; servingData_ = other.servingData_;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
} }
this.mergeUnknownFields(other.unknownFields); this.mergeUnknownFields(other.getUnknownFields());
onChanged(); onChanged();
return this; return this;
} }
@ -505,19 +461,43 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException { throws java.io.IOException {
com.google.rpc.RequestInfo parsedMessage = null; if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try { try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
requestId_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 18: {
servingData_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000002;
break;
} // case 18
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) { } catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.google.rpc.RequestInfo) e.getUnfinishedMessage();
throw e.unwrapIOException(); throw e.unwrapIOException();
} finally { } finally {
if (parsedMessage != null) { onChanged();
mergeFrom(parsedMessage); } // finally
}
}
return this; return this;
} }
private int bitField0_;
private java.lang.Object requestId_ = ""; private java.lang.Object requestId_ = "";
/** /**
@ -575,11 +555,9 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setRequestId( public Builder setRequestId(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
requestId_ = value; requestId_ = value;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -593,8 +571,8 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearRequestId() { public Builder clearRequestId() {
requestId_ = getDefaultInstance().getRequestId(); requestId_ = getDefaultInstance().getRequestId();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged(); onChanged();
return this; return this;
} }
@ -610,12 +588,10 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setRequestIdBytes( public Builder setRequestIdBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
requestId_ = value; requestId_ = value;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -676,11 +652,9 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setServingData( public Builder setServingData(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
servingData_ = value; servingData_ = value;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
return this; return this;
} }
@ -694,8 +668,8 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearServingData() { public Builder clearServingData() {
servingData_ = getDefaultInstance().getServingData(); servingData_ = getDefaultInstance().getServingData();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged(); onChanged();
return this; return this;
} }
@ -711,12 +685,10 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setServingDataBytes( public Builder setServingDataBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
servingData_ = value; servingData_ = value;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
return this; return this;
} }
@ -753,7 +725,18 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException { throws com.google.protobuf.InvalidProtocolBufferException {
return new RequestInfo(input, extensionRegistry); Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
} }
}; };

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/rpc/error_details.proto // source: google/rpc/error_details.proto
// Protobuf Java Version: 3.25.6
package com.google.rpc; package com.google.rpc;
public interface RequestInfoOrBuilder extends public interface RequestInfoOrBuilder extends

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/rpc/error_details.proto // source: google/rpc/error_details.proto
// Protobuf Java Version: 3.25.6
package com.google.rpc; package com.google.rpc;
/** /**
@ -33,72 +34,6 @@ private static final long serialVersionUID = 0L;
return new ResourceInfo(); return new ResourceInfo();
} }
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private ResourceInfo(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
java.lang.String s = input.readStringRequireUtf8();
resourceType_ = s;
break;
}
case 18: {
java.lang.String s = input.readStringRequireUtf8();
resourceName_ = s;
break;
}
case 26: {
java.lang.String s = input.readStringRequireUtf8();
owner_ = s;
break;
}
case 34: {
java.lang.String s = input.readStringRequireUtf8();
description_ = s;
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() { getDescriptor() {
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_ResourceInfo_descriptor; return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_ResourceInfo_descriptor;
@ -113,7 +48,8 @@ private static final long serialVersionUID = 0L;
} }
public static final int RESOURCE_TYPE_FIELD_NUMBER = 1; public static final int RESOURCE_TYPE_FIELD_NUMBER = 1;
private volatile java.lang.Object resourceType_; @SuppressWarnings("serial")
private volatile java.lang.Object resourceType_ = "";
/** /**
* <pre> * <pre>
* A name for the type of resource being accessed, e.g. "sql table", * A name for the type of resource being accessed, e.g. "sql table",
@ -163,7 +99,8 @@ private static final long serialVersionUID = 0L;
} }
public static final int RESOURCE_NAME_FIELD_NUMBER = 2; public static final int RESOURCE_NAME_FIELD_NUMBER = 2;
private volatile java.lang.Object resourceName_; @SuppressWarnings("serial")
private volatile java.lang.Object resourceName_ = "";
/** /**
* <pre> * <pre>
* The name of the resource being accessed. For example, a shared calendar * The name of the resource being accessed. For example, a shared calendar
@ -213,7 +150,8 @@ private static final long serialVersionUID = 0L;
} }
public static final int OWNER_FIELD_NUMBER = 3; public static final int OWNER_FIELD_NUMBER = 3;
private volatile java.lang.Object owner_; @SuppressWarnings("serial")
private volatile java.lang.Object owner_ = "";
/** /**
* <pre> * <pre>
* The owner of the resource (optional). * The owner of the resource (optional).
@ -263,7 +201,8 @@ private static final long serialVersionUID = 0L;
} }
public static final int DESCRIPTION_FIELD_NUMBER = 4; public static final int DESCRIPTION_FIELD_NUMBER = 4;
private volatile java.lang.Object description_; @SuppressWarnings("serial")
private volatile java.lang.Object description_ = "";
/** /**
* <pre> * <pre>
* Describes what error is encountered when accessing this resource. * Describes what error is encountered when accessing this resource.
@ -326,19 +265,19 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output) public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException { throws java.io.IOException {
if (!getResourceTypeBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(resourceType_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, resourceType_); com.google.protobuf.GeneratedMessageV3.writeString(output, 1, resourceType_);
} }
if (!getResourceNameBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(resourceName_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, resourceName_); com.google.protobuf.GeneratedMessageV3.writeString(output, 2, resourceName_);
} }
if (!getOwnerBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(owner_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 3, owner_); com.google.protobuf.GeneratedMessageV3.writeString(output, 3, owner_);
} }
if (!getDescriptionBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 4, description_); com.google.protobuf.GeneratedMessageV3.writeString(output, 4, description_);
} }
unknownFields.writeTo(output); getUnknownFields().writeTo(output);
} }
@java.lang.Override @java.lang.Override
@ -347,19 +286,19 @@ private static final long serialVersionUID = 0L;
if (size != -1) return size; if (size != -1) return size;
size = 0; size = 0;
if (!getResourceTypeBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(resourceType_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, resourceType_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, resourceType_);
} }
if (!getResourceNameBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(resourceName_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, resourceName_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, resourceName_);
} }
if (!getOwnerBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(owner_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, owner_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, owner_);
} }
if (!getDescriptionBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, description_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, description_);
} }
size += unknownFields.getSerializedSize(); size += getUnknownFields().getSerializedSize();
memoizedSize = size; memoizedSize = size;
return size; return size;
} }
@ -382,7 +321,7 @@ private static final long serialVersionUID = 0L;
.equals(other.getOwner())) return false; .equals(other.getOwner())) return false;
if (!getDescription() if (!getDescription()
.equals(other.getDescription())) return false; .equals(other.getDescription())) return false;
if (!unknownFields.equals(other.unknownFields)) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true; return true;
} }
@ -401,7 +340,7 @@ private static final long serialVersionUID = 0L;
hash = (53 * hash) + getOwner().hashCode(); hash = (53 * hash) + getOwner().hashCode();
hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER;
hash = (53 * hash) + getDescription().hashCode(); hash = (53 * hash) + getDescription().hashCode();
hash = (29 * hash) + unknownFields.hashCode(); hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash; memoizedHashCode = hash;
return hash; return hash;
} }
@ -450,11 +389,13 @@ private static final long serialVersionUID = 0L;
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry); .parseWithIOException(PARSER, input, extensionRegistry);
} }
public static com.google.rpc.ResourceInfo parseDelimitedFrom(java.io.InputStream input) public static com.google.rpc.ResourceInfo parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException { throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input); .parseDelimitedWithIOException(PARSER, input);
} }
public static com.google.rpc.ResourceInfo parseDelimitedFrom( public static com.google.rpc.ResourceInfo parseDelimitedFrom(
java.io.InputStream input, java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
@ -522,30 +463,22 @@ private static final long serialVersionUID = 0L;
// Construct using com.google.rpc.ResourceInfo.newBuilder() // Construct using com.google.rpc.ResourceInfo.newBuilder()
private Builder() { private Builder() {
maybeForceBuilderInitialization();
} }
private Builder( private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent); super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
} }
@java.lang.Override @java.lang.Override
public Builder clear() { public Builder clear() {
super.clear(); super.clear();
bitField0_ = 0;
resourceType_ = ""; resourceType_ = "";
resourceName_ = ""; resourceName_ = "";
owner_ = ""; owner_ = "";
description_ = ""; description_ = "";
return this; return this;
} }
@ -572,14 +505,27 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public com.google.rpc.ResourceInfo buildPartial() { public com.google.rpc.ResourceInfo buildPartial() {
com.google.rpc.ResourceInfo result = new com.google.rpc.ResourceInfo(this); com.google.rpc.ResourceInfo result = new com.google.rpc.ResourceInfo(this);
result.resourceType_ = resourceType_; if (bitField0_ != 0) { buildPartial0(result); }
result.resourceName_ = resourceName_;
result.owner_ = owner_;
result.description_ = description_;
onBuilt(); onBuilt();
return result; return result;
} }
private void buildPartial0(com.google.rpc.ResourceInfo result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.resourceType_ = resourceType_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.resourceName_ = resourceName_;
}
if (((from_bitField0_ & 0x00000004) != 0)) {
result.owner_ = owner_;
}
if (((from_bitField0_ & 0x00000008) != 0)) {
result.description_ = description_;
}
}
@java.lang.Override @java.lang.Override
public Builder clone() { public Builder clone() {
return super.clone(); return super.clone();
@ -626,21 +572,25 @@ private static final long serialVersionUID = 0L;
if (other == com.google.rpc.ResourceInfo.getDefaultInstance()) return this; if (other == com.google.rpc.ResourceInfo.getDefaultInstance()) return this;
if (!other.getResourceType().isEmpty()) { if (!other.getResourceType().isEmpty()) {
resourceType_ = other.resourceType_; resourceType_ = other.resourceType_;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
} }
if (!other.getResourceName().isEmpty()) { if (!other.getResourceName().isEmpty()) {
resourceName_ = other.resourceName_; resourceName_ = other.resourceName_;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
} }
if (!other.getOwner().isEmpty()) { if (!other.getOwner().isEmpty()) {
owner_ = other.owner_; owner_ = other.owner_;
bitField0_ |= 0x00000004;
onChanged(); onChanged();
} }
if (!other.getDescription().isEmpty()) { if (!other.getDescription().isEmpty()) {
description_ = other.description_; description_ = other.description_;
bitField0_ |= 0x00000008;
onChanged(); onChanged();
} }
this.mergeUnknownFields(other.unknownFields); this.mergeUnknownFields(other.getUnknownFields());
onChanged(); onChanged();
return this; return this;
} }
@ -655,19 +605,53 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException { throws java.io.IOException {
com.google.rpc.ResourceInfo parsedMessage = null; if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try { try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
resourceType_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 18: {
resourceName_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000002;
break;
} // case 18
case 26: {
owner_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000004;
break;
} // case 26
case 34: {
description_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000008;
break;
} // case 34
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) { } catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.google.rpc.ResourceInfo) e.getUnfinishedMessage();
throw e.unwrapIOException(); throw e.unwrapIOException();
} finally { } finally {
if (parsedMessage != null) { onChanged();
mergeFrom(parsedMessage); } // finally
}
}
return this; return this;
} }
private int bitField0_;
private java.lang.Object resourceType_ = ""; private java.lang.Object resourceType_ = "";
/** /**
@ -728,11 +712,9 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setResourceType( public Builder setResourceType(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
resourceType_ = value; resourceType_ = value;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -747,8 +729,8 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearResourceType() { public Builder clearResourceType() {
resourceType_ = getDefaultInstance().getResourceType(); resourceType_ = getDefaultInstance().getResourceType();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged(); onChanged();
return this; return this;
} }
@ -765,12 +747,10 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setResourceTypeBytes( public Builder setResourceTypeBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
resourceType_ = value; resourceType_ = value;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -834,11 +814,9 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setResourceName( public Builder setResourceName(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
resourceName_ = value; resourceName_ = value;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
return this; return this;
} }
@ -853,8 +831,8 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearResourceName() { public Builder clearResourceName() {
resourceName_ = getDefaultInstance().getResourceName(); resourceName_ = getDefaultInstance().getResourceName();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged(); onChanged();
return this; return this;
} }
@ -871,12 +849,10 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setResourceNameBytes( public Builder setResourceNameBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
resourceName_ = value; resourceName_ = value;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
return this; return this;
} }
@ -940,11 +916,9 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setOwner( public Builder setOwner(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
owner_ = value; owner_ = value;
bitField0_ |= 0x00000004;
onChanged(); onChanged();
return this; return this;
} }
@ -959,8 +933,8 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearOwner() { public Builder clearOwner() {
owner_ = getDefaultInstance().getOwner(); owner_ = getDefaultInstance().getOwner();
bitField0_ = (bitField0_ & ~0x00000004);
onChanged(); onChanged();
return this; return this;
} }
@ -977,12 +951,10 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setOwnerBytes( public Builder setOwnerBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
owner_ = value; owner_ = value;
bitField0_ |= 0x00000004;
onChanged(); onChanged();
return this; return this;
} }
@ -1046,11 +1018,9 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setDescription( public Builder setDescription(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
description_ = value; description_ = value;
bitField0_ |= 0x00000008;
onChanged(); onChanged();
return this; return this;
} }
@ -1065,8 +1035,8 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearDescription() { public Builder clearDescription() {
description_ = getDefaultInstance().getDescription(); description_ = getDefaultInstance().getDescription();
bitField0_ = (bitField0_ & ~0x00000008);
onChanged(); onChanged();
return this; return this;
} }
@ -1083,12 +1053,10 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setDescriptionBytes( public Builder setDescriptionBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
description_ = value; description_ = value;
bitField0_ |= 0x00000008;
onChanged(); onChanged();
return this; return this;
} }
@ -1125,7 +1093,18 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException { throws com.google.protobuf.InvalidProtocolBufferException {
return new ResourceInfo(input, extensionRegistry); Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
} }
}; };

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/rpc/error_details.proto // source: google/rpc/error_details.proto
// Protobuf Java Version: 3.25.6
package com.google.rpc; package com.google.rpc;
public interface ResourceInfoOrBuilder extends public interface ResourceInfoOrBuilder extends

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/rpc/error_details.proto // source: google/rpc/error_details.proto
// Protobuf Java Version: 3.25.6
package com.google.rpc; package com.google.rpc;
/** /**
@ -8,8 +9,10 @@ package com.google.rpc;
* Describes when the clients can retry a failed request. Clients could ignore * Describes when the clients can retry a failed request. Clients could ignore
* the recommendation here or retry when this information is missing from error * the recommendation here or retry when this information is missing from error
* responses. * responses.
*
* It's always recommended that clients should use exponential backoff when * It's always recommended that clients should use exponential backoff when
* retrying. * retrying.
*
* Clients should wait until `retry_delay` amount of time has passed since * Clients should wait until `retry_delay` amount of time has passed since
* receiving the error response before retrying. If retrying requests also * receiving the error response before retrying. If retrying requests also
* fail, clients should use an exponential backoff scheme to gradually increase * fail, clients should use an exponential backoff scheme to gradually increase
@ -39,61 +42,6 @@ private static final long serialVersionUID = 0L;
return new RetryInfo(); return new RetryInfo();
} }
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private RetryInfo(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
com.google.protobuf.Duration.Builder subBuilder = null;
if (retryDelay_ != null) {
subBuilder = retryDelay_.toBuilder();
}
retryDelay_ = input.readMessage(com.google.protobuf.Duration.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom(retryDelay_);
retryDelay_ = subBuilder.buildPartial();
}
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() { getDescriptor() {
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_RetryInfo_descriptor; return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_RetryInfo_descriptor;
@ -107,6 +55,7 @@ private static final long serialVersionUID = 0L;
com.google.rpc.RetryInfo.class, com.google.rpc.RetryInfo.Builder.class); com.google.rpc.RetryInfo.class, com.google.rpc.RetryInfo.Builder.class);
} }
private int bitField0_;
public static final int RETRY_DELAY_FIELD_NUMBER = 1; public static final int RETRY_DELAY_FIELD_NUMBER = 1;
private com.google.protobuf.Duration retryDelay_; private com.google.protobuf.Duration retryDelay_;
/** /**
@ -119,7 +68,7 @@ private static final long serialVersionUID = 0L;
*/ */
@java.lang.Override @java.lang.Override
public boolean hasRetryDelay() { public boolean hasRetryDelay() {
return retryDelay_ != null; return ((bitField0_ & 0x00000001) != 0);
} }
/** /**
* <pre> * <pre>
@ -142,7 +91,7 @@ private static final long serialVersionUID = 0L;
*/ */
@java.lang.Override @java.lang.Override
public com.google.protobuf.DurationOrBuilder getRetryDelayOrBuilder() { public com.google.protobuf.DurationOrBuilder getRetryDelayOrBuilder() {
return getRetryDelay(); return retryDelay_ == null ? com.google.protobuf.Duration.getDefaultInstance() : retryDelay_;
} }
private byte memoizedIsInitialized = -1; private byte memoizedIsInitialized = -1;
@ -159,10 +108,10 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output) public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException { throws java.io.IOException {
if (retryDelay_ != null) { if (((bitField0_ & 0x00000001) != 0)) {
output.writeMessage(1, getRetryDelay()); output.writeMessage(1, getRetryDelay());
} }
unknownFields.writeTo(output); getUnknownFields().writeTo(output);
} }
@java.lang.Override @java.lang.Override
@ -171,11 +120,11 @@ private static final long serialVersionUID = 0L;
if (size != -1) return size; if (size != -1) return size;
size = 0; size = 0;
if (retryDelay_ != null) { if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.CodedOutputStream size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, getRetryDelay()); .computeMessageSize(1, getRetryDelay());
} }
size += unknownFields.getSerializedSize(); size += getUnknownFields().getSerializedSize();
memoizedSize = size; memoizedSize = size;
return size; return size;
} }
@ -195,7 +144,7 @@ private static final long serialVersionUID = 0L;
if (!getRetryDelay() if (!getRetryDelay()
.equals(other.getRetryDelay())) return false; .equals(other.getRetryDelay())) return false;
} }
if (!unknownFields.equals(other.unknownFields)) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true; return true;
} }
@ -210,7 +159,7 @@ private static final long serialVersionUID = 0L;
hash = (37 * hash) + RETRY_DELAY_FIELD_NUMBER; hash = (37 * hash) + RETRY_DELAY_FIELD_NUMBER;
hash = (53 * hash) + getRetryDelay().hashCode(); hash = (53 * hash) + getRetryDelay().hashCode();
} }
hash = (29 * hash) + unknownFields.hashCode(); hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash; memoizedHashCode = hash;
return hash; return hash;
} }
@ -259,11 +208,13 @@ private static final long serialVersionUID = 0L;
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry); .parseWithIOException(PARSER, input, extensionRegistry);
} }
public static com.google.rpc.RetryInfo parseDelimitedFrom(java.io.InputStream input) public static com.google.rpc.RetryInfo parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException { throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input); .parseDelimitedWithIOException(PARSER, input);
} }
public static com.google.rpc.RetryInfo parseDelimitedFrom( public static com.google.rpc.RetryInfo parseDelimitedFrom(
java.io.InputStream input, java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
@ -310,8 +261,10 @@ private static final long serialVersionUID = 0L;
* Describes when the clients can retry a failed request. Clients could ignore * Describes when the clients can retry a failed request. Clients could ignore
* the recommendation here or retry when this information is missing from error * the recommendation here or retry when this information is missing from error
* responses. * responses.
*
* It's always recommended that clients should use exponential backoff when * It's always recommended that clients should use exponential backoff when
* retrying. * retrying.
*
* Clients should wait until `retry_delay` amount of time has passed since * Clients should wait until `retry_delay` amount of time has passed since
* receiving the error response before retrying. If retrying requests also * receiving the error response before retrying. If retrying requests also
* fail, clients should use an exponential backoff scheme to gradually increase * fail, clients should use an exponential backoff scheme to gradually increase
@ -352,15 +305,16 @@ private static final long serialVersionUID = 0L;
private void maybeForceBuilderInitialization() { private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3 if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) { .alwaysUseFieldBuilders) {
getRetryDelayFieldBuilder();
} }
} }
@java.lang.Override @java.lang.Override
public Builder clear() { public Builder clear() {
super.clear(); super.clear();
if (retryDelayBuilder_ == null) { bitField0_ = 0;
retryDelay_ = null; retryDelay_ = null;
} else { if (retryDelayBuilder_ != null) {
retryDelay_ = null; retryDelayBuilder_.dispose();
retryDelayBuilder_ = null; retryDelayBuilder_ = null;
} }
return this; return this;
@ -389,15 +343,23 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public com.google.rpc.RetryInfo buildPartial() { public com.google.rpc.RetryInfo buildPartial() {
com.google.rpc.RetryInfo result = new com.google.rpc.RetryInfo(this); com.google.rpc.RetryInfo result = new com.google.rpc.RetryInfo(this);
if (retryDelayBuilder_ == null) { if (bitField0_ != 0) { buildPartial0(result); }
result.retryDelay_ = retryDelay_;
} else {
result.retryDelay_ = retryDelayBuilder_.build();
}
onBuilt(); onBuilt();
return result; return result;
} }
private void buildPartial0(com.google.rpc.RetryInfo result) {
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.retryDelay_ = retryDelayBuilder_ == null
? retryDelay_
: retryDelayBuilder_.build();
to_bitField0_ |= 0x00000001;
}
result.bitField0_ |= to_bitField0_;
}
@java.lang.Override @java.lang.Override
public Builder clone() { public Builder clone() {
return super.clone(); return super.clone();
@ -445,7 +407,7 @@ private static final long serialVersionUID = 0L;
if (other.hasRetryDelay()) { if (other.hasRetryDelay()) {
mergeRetryDelay(other.getRetryDelay()); mergeRetryDelay(other.getRetryDelay());
} }
this.mergeUnknownFields(other.unknownFields); this.mergeUnknownFields(other.getUnknownFields());
onChanged(); onChanged();
return this; return this;
} }
@ -460,19 +422,40 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException { throws java.io.IOException {
com.google.rpc.RetryInfo parsedMessage = null; if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try { try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
input.readMessage(
getRetryDelayFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000001;
break;
} // case 10
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) { } catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.google.rpc.RetryInfo) e.getUnfinishedMessage();
throw e.unwrapIOException(); throw e.unwrapIOException();
} finally { } finally {
if (parsedMessage != null) { onChanged();
mergeFrom(parsedMessage); } // finally
}
}
return this; return this;
} }
private int bitField0_;
private com.google.protobuf.Duration retryDelay_; private com.google.protobuf.Duration retryDelay_;
private com.google.protobuf.SingleFieldBuilderV3< private com.google.protobuf.SingleFieldBuilderV3<
@ -486,7 +469,7 @@ private static final long serialVersionUID = 0L;
* @return Whether the retryDelay field is set. * @return Whether the retryDelay field is set.
*/ */
public boolean hasRetryDelay() { public boolean hasRetryDelay() {
return retryDelayBuilder_ != null || retryDelay_ != null; return ((bitField0_ & 0x00000001) != 0);
} }
/** /**
* <pre> * <pre>
@ -516,11 +499,11 @@ private static final long serialVersionUID = 0L;
throw new NullPointerException(); throw new NullPointerException();
} }
retryDelay_ = value; retryDelay_ = value;
onChanged();
} else { } else {
retryDelayBuilder_.setMessage(value); retryDelayBuilder_.setMessage(value);
} }
bitField0_ |= 0x00000001;
onChanged();
return this; return this;
} }
/** /**
@ -534,11 +517,11 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.Duration.Builder builderForValue) { com.google.protobuf.Duration.Builder builderForValue) {
if (retryDelayBuilder_ == null) { if (retryDelayBuilder_ == null) {
retryDelay_ = builderForValue.build(); retryDelay_ = builderForValue.build();
onChanged();
} else { } else {
retryDelayBuilder_.setMessage(builderForValue.build()); retryDelayBuilder_.setMessage(builderForValue.build());
} }
bitField0_ |= 0x00000001;
onChanged();
return this; return this;
} }
/** /**
@ -550,17 +533,20 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder mergeRetryDelay(com.google.protobuf.Duration value) { public Builder mergeRetryDelay(com.google.protobuf.Duration value) {
if (retryDelayBuilder_ == null) { if (retryDelayBuilder_ == null) {
if (retryDelay_ != null) { if (((bitField0_ & 0x00000001) != 0) &&
retryDelay_ = retryDelay_ != null &&
com.google.protobuf.Duration.newBuilder(retryDelay_).mergeFrom(value).buildPartial(); retryDelay_ != com.google.protobuf.Duration.getDefaultInstance()) {
getRetryDelayBuilder().mergeFrom(value);
} else { } else {
retryDelay_ = value; retryDelay_ = value;
} }
onChanged();
} else { } else {
retryDelayBuilder_.mergeFrom(value); retryDelayBuilder_.mergeFrom(value);
} }
if (retryDelay_ != null) {
bitField0_ |= 0x00000001;
onChanged();
}
return this; return this;
} }
/** /**
@ -571,14 +557,13 @@ private static final long serialVersionUID = 0L;
* <code>.google.protobuf.Duration retry_delay = 1;</code> * <code>.google.protobuf.Duration retry_delay = 1;</code>
*/ */
public Builder clearRetryDelay() { public Builder clearRetryDelay() {
if (retryDelayBuilder_ == null) { bitField0_ = (bitField0_ & ~0x00000001);
retryDelay_ = null; retryDelay_ = null;
onChanged(); if (retryDelayBuilder_ != null) {
} else { retryDelayBuilder_.dispose();
retryDelay_ = null;
retryDelayBuilder_ = null; retryDelayBuilder_ = null;
} }
onChanged();
return this; return this;
} }
/** /**
@ -589,7 +574,7 @@ private static final long serialVersionUID = 0L;
* <code>.google.protobuf.Duration retry_delay = 1;</code> * <code>.google.protobuf.Duration retry_delay = 1;</code>
*/ */
public com.google.protobuf.Duration.Builder getRetryDelayBuilder() { public com.google.protobuf.Duration.Builder getRetryDelayBuilder() {
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return getRetryDelayFieldBuilder().getBuilder(); return getRetryDelayFieldBuilder().getBuilder();
} }
@ -661,7 +646,18 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException { throws com.google.protobuf.InvalidProtocolBufferException {
return new RetryInfo(input, extensionRegistry); Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
} }
}; };

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/rpc/error_details.proto // source: google/rpc/error_details.proto
// Protobuf Java Version: 3.25.6
package com.google.rpc; package com.google.rpc;
public interface RetryInfoOrBuilder extends public interface RetryInfoOrBuilder extends

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/rpc/status.proto // source: google/rpc/status.proto
// Protobuf Java Version: 3.25.6
package com.google.rpc; package com.google.rpc;
/** /**
@ -8,9 +9,12 @@ package com.google.rpc;
* The `Status` type defines a logical error model that is suitable for different * The `Status` type defines a logical error model that is suitable for different
* programming environments, including REST APIs and RPC APIs. It is used by * programming environments, including REST APIs and RPC APIs. It is used by
* [gRPC](https://github.com/grpc). The error model is designed to be: * [gRPC](https://github.com/grpc). The error model is designed to be:
*
* - Simple to use and understand for most users * - Simple to use and understand for most users
* - Flexible enough to meet unexpected needs * - Flexible enough to meet unexpected needs
*
* # Overview * # Overview
*
* The `Status` message contains three pieces of data: error code, error message, * The `Status` message contains three pieces of data: error code, error message,
* and error details. The error code should be an enum value of * and error details. The error code should be an enum value of
* [google.rpc.Code][google.rpc.Code], but it may accept additional error codes if needed. The * [google.rpc.Code][google.rpc.Code], but it may accept additional error codes if needed. The
@ -20,28 +24,38 @@ package com.google.rpc;
* localize it in the client. The optional error details may contain arbitrary * localize it in the client. The optional error details may contain arbitrary
* information about the error. There is a predefined set of error detail types * information about the error. There is a predefined set of error detail types
* in the package `google.rpc` that can be used for common error conditions. * in the package `google.rpc` that can be used for common error conditions.
*
* # Language mapping * # Language mapping
*
* The `Status` message is the logical representation of the error model, but it * The `Status` message is the logical representation of the error model, but it
* is not necessarily the actual wire format. When the `Status` message is * is not necessarily the actual wire format. When the `Status` message is
* exposed in different client libraries and different wire protocols, it can be * exposed in different client libraries and different wire protocols, it can be
* mapped differently. For example, it will likely be mapped to some exceptions * mapped differently. For example, it will likely be mapped to some exceptions
* in Java, but more likely mapped to some error codes in C. * in Java, but more likely mapped to some error codes in C.
*
* # Other uses * # Other uses
*
* The error model and the `Status` message can be used in a variety of * The error model and the `Status` message can be used in a variety of
* environments, either with or without APIs, to provide a * environments, either with or without APIs, to provide a
* consistent developer experience across different environments. * consistent developer experience across different environments.
*
* Example uses of this error model include: * Example uses of this error model include:
*
* - Partial errors. If a service needs to return partial errors to the client, * - Partial errors. If a service needs to return partial errors to the client,
* it may embed the `Status` in the normal response to indicate the partial * it may embed the `Status` in the normal response to indicate the partial
* errors. * errors.
*
* - Workflow errors. A typical workflow has multiple steps. Each step may * - Workflow errors. A typical workflow has multiple steps. Each step may
* have a `Status` message for error reporting. * have a `Status` message for error reporting.
*
* - Batch operations. If a client uses batch request and batch response, the * - Batch operations. If a client uses batch request and batch response, the
* `Status` message should be used directly inside batch response, one for * `Status` message should be used directly inside batch response, one for
* each error sub-response. * each error sub-response.
*
* - Asynchronous operations. If an API call embeds asynchronous operation * - Asynchronous operations. If an API call embeds asynchronous operation
* results in its response, the status of those operations should be * results in its response, the status of those operations should be
* represented directly using the `Status` message. * represented directly using the `Status` message.
*
* - Logging. If some API errors are stored in logs, the message `Status` could * - Logging. If some API errors are stored in logs, the message `Status` could
* be used directly after any stripping needed for security/privacy reasons. * be used directly after any stripping needed for security/privacy reasons.
* </pre> * </pre>
@ -69,72 +83,6 @@ private static final long serialVersionUID = 0L;
return new Status(); return new Status();
} }
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private Status(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
int mutable_bitField0_ = 0;
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
code_ = input.readInt32();
break;
}
case 18: {
java.lang.String s = input.readStringRequireUtf8();
message_ = s;
break;
}
case 26: {
if (!((mutable_bitField0_ & 0x00000001) != 0)) {
details_ = new java.util.ArrayList<com.google.protobuf.Any>();
mutable_bitField0_ |= 0x00000001;
}
details_.add(
input.readMessage(com.google.protobuf.Any.parser(), extensionRegistry));
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
if (((mutable_bitField0_ & 0x00000001) != 0)) {
details_ = java.util.Collections.unmodifiableList(details_);
}
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() { getDescriptor() {
return com.google.rpc.StatusProto.internal_static_google_rpc_Status_descriptor; return com.google.rpc.StatusProto.internal_static_google_rpc_Status_descriptor;
@ -149,7 +97,7 @@ private static final long serialVersionUID = 0L;
} }
public static final int CODE_FIELD_NUMBER = 1; public static final int CODE_FIELD_NUMBER = 1;
private int code_; private int code_ = 0;
/** /**
* <pre> * <pre>
* The status code, which should be an enum value of [google.rpc.Code][google.rpc.Code]. * The status code, which should be an enum value of [google.rpc.Code][google.rpc.Code].
@ -164,7 +112,8 @@ private static final long serialVersionUID = 0L;
} }
public static final int MESSAGE_FIELD_NUMBER = 2; public static final int MESSAGE_FIELD_NUMBER = 2;
private volatile java.lang.Object message_; @SuppressWarnings("serial")
private volatile java.lang.Object message_ = "";
/** /**
* <pre> * <pre>
* A developer-facing error message, which should be in English. Any * A developer-facing error message, which should be in English. Any
@ -214,6 +163,7 @@ private static final long serialVersionUID = 0L;
} }
public static final int DETAILS_FIELD_NUMBER = 3; public static final int DETAILS_FIELD_NUMBER = 3;
@SuppressWarnings("serial")
private java.util.List<com.google.protobuf.Any> details_; private java.util.List<com.google.protobuf.Any> details_;
/** /**
* <pre> * <pre>
@ -295,13 +245,13 @@ private static final long serialVersionUID = 0L;
if (code_ != 0) { if (code_ != 0) {
output.writeInt32(1, code_); output.writeInt32(1, code_);
} }
if (!getMessageBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(message_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, message_); com.google.protobuf.GeneratedMessageV3.writeString(output, 2, message_);
} }
for (int i = 0; i < details_.size(); i++) { for (int i = 0; i < details_.size(); i++) {
output.writeMessage(3, details_.get(i)); output.writeMessage(3, details_.get(i));
} }
unknownFields.writeTo(output); getUnknownFields().writeTo(output);
} }
@java.lang.Override @java.lang.Override
@ -314,14 +264,14 @@ private static final long serialVersionUID = 0L;
size += com.google.protobuf.CodedOutputStream size += com.google.protobuf.CodedOutputStream
.computeInt32Size(1, code_); .computeInt32Size(1, code_);
} }
if (!getMessageBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(message_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, message_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, message_);
} }
for (int i = 0; i < details_.size(); i++) { for (int i = 0; i < details_.size(); i++) {
size += com.google.protobuf.CodedOutputStream size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, details_.get(i)); .computeMessageSize(3, details_.get(i));
} }
size += unknownFields.getSerializedSize(); size += getUnknownFields().getSerializedSize();
memoizedSize = size; memoizedSize = size;
return size; return size;
} }
@ -342,7 +292,7 @@ private static final long serialVersionUID = 0L;
.equals(other.getMessage())) return false; .equals(other.getMessage())) return false;
if (!getDetailsList() if (!getDetailsList()
.equals(other.getDetailsList())) return false; .equals(other.getDetailsList())) return false;
if (!unknownFields.equals(other.unknownFields)) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true; return true;
} }
@ -361,7 +311,7 @@ private static final long serialVersionUID = 0L;
hash = (37 * hash) + DETAILS_FIELD_NUMBER; hash = (37 * hash) + DETAILS_FIELD_NUMBER;
hash = (53 * hash) + getDetailsList().hashCode(); hash = (53 * hash) + getDetailsList().hashCode();
} }
hash = (29 * hash) + unknownFields.hashCode(); hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash; memoizedHashCode = hash;
return hash; return hash;
} }
@ -410,11 +360,13 @@ private static final long serialVersionUID = 0L;
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry); .parseWithIOException(PARSER, input, extensionRegistry);
} }
public static com.google.rpc.Status parseDelimitedFrom(java.io.InputStream input) public static com.google.rpc.Status parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException { throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input); .parseDelimitedWithIOException(PARSER, input);
} }
public static com.google.rpc.Status parseDelimitedFrom( public static com.google.rpc.Status parseDelimitedFrom(
java.io.InputStream input, java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
@ -461,9 +413,12 @@ private static final long serialVersionUID = 0L;
* The `Status` type defines a logical error model that is suitable for different * The `Status` type defines a logical error model that is suitable for different
* programming environments, including REST APIs and RPC APIs. It is used by * programming environments, including REST APIs and RPC APIs. It is used by
* [gRPC](https://github.com/grpc). The error model is designed to be: * [gRPC](https://github.com/grpc). The error model is designed to be:
*
* - Simple to use and understand for most users * - Simple to use and understand for most users
* - Flexible enough to meet unexpected needs * - Flexible enough to meet unexpected needs
*
* # Overview * # Overview
*
* The `Status` message contains three pieces of data: error code, error message, * The `Status` message contains three pieces of data: error code, error message,
* and error details. The error code should be an enum value of * and error details. The error code should be an enum value of
* [google.rpc.Code][google.rpc.Code], but it may accept additional error codes if needed. The * [google.rpc.Code][google.rpc.Code], but it may accept additional error codes if needed. The
@ -473,28 +428,38 @@ private static final long serialVersionUID = 0L;
* localize it in the client. The optional error details may contain arbitrary * localize it in the client. The optional error details may contain arbitrary
* information about the error. There is a predefined set of error detail types * information about the error. There is a predefined set of error detail types
* in the package `google.rpc` that can be used for common error conditions. * in the package `google.rpc` that can be used for common error conditions.
*
* # Language mapping * # Language mapping
*
* The `Status` message is the logical representation of the error model, but it * The `Status` message is the logical representation of the error model, but it
* is not necessarily the actual wire format. When the `Status` message is * is not necessarily the actual wire format. When the `Status` message is
* exposed in different client libraries and different wire protocols, it can be * exposed in different client libraries and different wire protocols, it can be
* mapped differently. For example, it will likely be mapped to some exceptions * mapped differently. For example, it will likely be mapped to some exceptions
* in Java, but more likely mapped to some error codes in C. * in Java, but more likely mapped to some error codes in C.
*
* # Other uses * # Other uses
*
* The error model and the `Status` message can be used in a variety of * The error model and the `Status` message can be used in a variety of
* environments, either with or without APIs, to provide a * environments, either with or without APIs, to provide a
* consistent developer experience across different environments. * consistent developer experience across different environments.
*
* Example uses of this error model include: * Example uses of this error model include:
*
* - Partial errors. If a service needs to return partial errors to the client, * - Partial errors. If a service needs to return partial errors to the client,
* it may embed the `Status` in the normal response to indicate the partial * it may embed the `Status` in the normal response to indicate the partial
* errors. * errors.
*
* - Workflow errors. A typical workflow has multiple steps. Each step may * - Workflow errors. A typical workflow has multiple steps. Each step may
* have a `Status` message for error reporting. * have a `Status` message for error reporting.
*
* - Batch operations. If a client uses batch request and batch response, the * - Batch operations. If a client uses batch request and batch response, the
* `Status` message should be used directly inside batch response, one for * `Status` message should be used directly inside batch response, one for
* each error sub-response. * each error sub-response.
*
* - Asynchronous operations. If an API call embeds asynchronous operation * - Asynchronous operations. If an API call embeds asynchronous operation
* results in its response, the status of those operations should be * results in its response, the status of those operations should be
* represented directly using the `Status` message. * represented directly using the `Status` message.
*
* - Logging. If some API errors are stored in logs, the message `Status` could * - Logging. If some API errors are stored in logs, the message `Status` could
* be used directly after any stripping needed for security/privacy reasons. * be used directly after any stripping needed for security/privacy reasons.
* </pre> * </pre>
@ -520,33 +485,27 @@ private static final long serialVersionUID = 0L;
// Construct using com.google.rpc.Status.newBuilder() // Construct using com.google.rpc.Status.newBuilder()
private Builder() { private Builder() {
maybeForceBuilderInitialization();
} }
private Builder( private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent); super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getDetailsFieldBuilder();
}
} }
@java.lang.Override @java.lang.Override
public Builder clear() { public Builder clear() {
super.clear(); super.clear();
bitField0_ = 0;
code_ = 0; code_ = 0;
message_ = ""; message_ = "";
if (detailsBuilder_ == null) { if (detailsBuilder_ == null) {
details_ = java.util.Collections.emptyList(); details_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001);
} else { } else {
details_ = null;
detailsBuilder_.clear(); detailsBuilder_.clear();
} }
bitField0_ = (bitField0_ & ~0x00000004);
return this; return this;
} }
@ -573,20 +532,32 @@ private static final long serialVersionUID = 0L;
@java.lang.Override @java.lang.Override
public com.google.rpc.Status buildPartial() { public com.google.rpc.Status buildPartial() {
com.google.rpc.Status result = new com.google.rpc.Status(this); com.google.rpc.Status result = new com.google.rpc.Status(this);
int from_bitField0_ = bitField0_; buildPartialRepeatedFields(result);
result.code_ = code_; if (bitField0_ != 0) { buildPartial0(result); }
result.message_ = message_; onBuilt();
return result;
}
private void buildPartialRepeatedFields(com.google.rpc.Status result) {
if (detailsBuilder_ == null) { if (detailsBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0)) { if (((bitField0_ & 0x00000004) != 0)) {
details_ = java.util.Collections.unmodifiableList(details_); details_ = java.util.Collections.unmodifiableList(details_);
bitField0_ = (bitField0_ & ~0x00000001); bitField0_ = (bitField0_ & ~0x00000004);
} }
result.details_ = details_; result.details_ = details_;
} else { } else {
result.details_ = detailsBuilder_.build(); result.details_ = detailsBuilder_.build();
} }
onBuilt(); }
return result;
private void buildPartial0(com.google.rpc.Status result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.code_ = code_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.message_ = message_;
}
} }
@java.lang.Override @java.lang.Override
@ -638,13 +609,14 @@ private static final long serialVersionUID = 0L;
} }
if (!other.getMessage().isEmpty()) { if (!other.getMessage().isEmpty()) {
message_ = other.message_; message_ = other.message_;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
} }
if (detailsBuilder_ == null) { if (detailsBuilder_ == null) {
if (!other.details_.isEmpty()) { if (!other.details_.isEmpty()) {
if (details_.isEmpty()) { if (details_.isEmpty()) {
details_ = other.details_; details_ = other.details_;
bitField0_ = (bitField0_ & ~0x00000001); bitField0_ = (bitField0_ & ~0x00000004);
} else { } else {
ensureDetailsIsMutable(); ensureDetailsIsMutable();
details_.addAll(other.details_); details_.addAll(other.details_);
@ -657,7 +629,7 @@ private static final long serialVersionUID = 0L;
detailsBuilder_.dispose(); detailsBuilder_.dispose();
detailsBuilder_ = null; detailsBuilder_ = null;
details_ = other.details_; details_ = other.details_;
bitField0_ = (bitField0_ & ~0x00000001); bitField0_ = (bitField0_ & ~0x00000004);
detailsBuilder_ = detailsBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getDetailsFieldBuilder() : null; getDetailsFieldBuilder() : null;
@ -666,7 +638,7 @@ private static final long serialVersionUID = 0L;
} }
} }
} }
this.mergeUnknownFields(other.unknownFields); this.mergeUnknownFields(other.getUnknownFields());
onChanged(); onChanged();
return this; return this;
} }
@ -681,17 +653,53 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException { throws java.io.IOException {
com.google.rpc.Status parsedMessage = null; if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try { try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
code_ = input.readInt32();
bitField0_ |= 0x00000001;
break;
} // case 8
case 18: {
message_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000002;
break;
} // case 18
case 26: {
com.google.protobuf.Any m =
input.readMessage(
com.google.protobuf.Any.parser(),
extensionRegistry);
if (detailsBuilder_ == null) {
ensureDetailsIsMutable();
details_.add(m);
} else {
detailsBuilder_.addMessage(m);
}
break;
} // case 26
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) { } catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.google.rpc.Status) e.getUnfinishedMessage();
throw e.unwrapIOException(); throw e.unwrapIOException();
} finally { } finally {
if (parsedMessage != null) { onChanged();
mergeFrom(parsedMessage); } // finally
}
}
return this; return this;
} }
private int bitField0_; private int bitField0_;
@ -719,8 +727,9 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder setCode(int value) { public Builder setCode(int value) {
code_ = value; code_ = value;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -733,7 +742,7 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearCode() { public Builder clearCode() {
bitField0_ = (bitField0_ & ~0x00000001);
code_ = 0; code_ = 0;
onChanged(); onChanged();
return this; return this;
@ -798,11 +807,9 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setMessage( public Builder setMessage(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
message_ = value; message_ = value;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
return this; return this;
} }
@ -817,8 +824,8 @@ private static final long serialVersionUID = 0L;
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearMessage() { public Builder clearMessage() {
message_ = getDefaultInstance().getMessage(); message_ = getDefaultInstance().getMessage();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged(); onChanged();
return this; return this;
} }
@ -835,12 +842,10 @@ private static final long serialVersionUID = 0L;
*/ */
public Builder setMessageBytes( public Builder setMessageBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
message_ = value; message_ = value;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
return this; return this;
} }
@ -848,9 +853,9 @@ private static final long serialVersionUID = 0L;
private java.util.List<com.google.protobuf.Any> details_ = private java.util.List<com.google.protobuf.Any> details_ =
java.util.Collections.emptyList(); java.util.Collections.emptyList();
private void ensureDetailsIsMutable() { private void ensureDetailsIsMutable() {
if (!((bitField0_ & 0x00000001) != 0)) { if (!((bitField0_ & 0x00000004) != 0)) {
details_ = new java.util.ArrayList<com.google.protobuf.Any>(details_); details_ = new java.util.ArrayList<com.google.protobuf.Any>(details_);
bitField0_ |= 0x00000001; bitField0_ |= 0x00000004;
} }
} }
@ -1055,7 +1060,7 @@ private static final long serialVersionUID = 0L;
public Builder clearDetails() { public Builder clearDetails() {
if (detailsBuilder_ == null) { if (detailsBuilder_ == null) {
details_ = java.util.Collections.emptyList(); details_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001); bitField0_ = (bitField0_ & ~0x00000004);
onChanged(); onChanged();
} else { } else {
detailsBuilder_.clear(); detailsBuilder_.clear();
@ -1167,7 +1172,7 @@ private static final long serialVersionUID = 0L;
detailsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< detailsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
com.google.protobuf.Any, com.google.protobuf.Any.Builder, com.google.protobuf.AnyOrBuilder>( com.google.protobuf.Any, com.google.protobuf.Any.Builder, com.google.protobuf.AnyOrBuilder>(
details_, details_,
((bitField0_ & 0x00000001) != 0), ((bitField0_ & 0x00000004) != 0),
getParentForChildren(), getParentForChildren(),
isClean()); isClean());
details_ = null; details_ = null;
@ -1207,7 +1212,18 @@ private static final long serialVersionUID = 0L;
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException { throws com.google.protobuf.InvalidProtocolBufferException {
return new Status(input, extensionRegistry); Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
} }
}; };

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/rpc/status.proto // source: google/rpc/status.proto
// Protobuf Java Version: 3.25.6
package com.google.rpc; package com.google.rpc;
public interface StatusOrBuilder extends public interface StatusOrBuilder extends

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/rpc/status.proto // source: google/rpc/status.proto
// Protobuf Java Version: 3.25.6
package com.google.rpc; package com.google.rpc;
public final class StatusProto { public final class StatusProto {

File diff suppressed because it is too large Load Diff

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: bdware/bdledger/api/error_details.proto // source: bdware/bdledger/api/error_details.proto
// Protobuf Java Version: 3.25.6
package org.bdware.bdledger.api.grpc.pb; package org.bdware.bdledger.api.grpc.pb;
public final class ErrorDetailsProto { public final class ErrorDetailsProto {
@ -92,61 +93,6 @@ public final class ErrorDetailsProto {
return new InvalidArgument(); return new InvalidArgument();
} }
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private InvalidArgument(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
int mutable_bitField0_ = 0;
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
if (!((mutable_bitField0_ & 0x00000001) != 0)) {
fieldViolations_ = new java.util.ArrayList<org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.FieldViolation>();
mutable_bitField0_ |= 0x00000001;
}
fieldViolations_.add(
input.readMessage(org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.FieldViolation.parser(), extensionRegistry));
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
if (((mutable_bitField0_ & 0x00000001) != 0)) {
fieldViolations_ = java.util.Collections.unmodifiableList(fieldViolations_);
}
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() { getDescriptor() {
return org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.internal_static_bdware_bdledger_api_InvalidArgument_descriptor; return org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.internal_static_bdware_bdledger_api_InvalidArgument_descriptor;
@ -236,60 +182,6 @@ public final class ErrorDetailsProto {
return new FieldViolation(); return new FieldViolation();
} }
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private FieldViolation(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
java.lang.String s = input.readStringRequireUtf8();
field_ = s;
break;
}
case 18: {
java.lang.String s = input.readStringRequireUtf8();
description_ = s;
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() { getDescriptor() {
return org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.internal_static_bdware_bdledger_api_InvalidArgument_FieldViolation_descriptor; return org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.internal_static_bdware_bdledger_api_InvalidArgument_FieldViolation_descriptor;
@ -304,7 +196,8 @@ public final class ErrorDetailsProto {
} }
public static final int FIELD_FIELD_NUMBER = 1; public static final int FIELD_FIELD_NUMBER = 1;
private volatile java.lang.Object field_; @SuppressWarnings("serial")
private volatile java.lang.Object field_ = "";
/** /**
* <pre> * <pre>
* A path leading to a field in the request body. The value will be a * A path leading to a field in the request body. The value will be a
@ -354,7 +247,8 @@ public final class ErrorDetailsProto {
} }
public static final int DESCRIPTION_FIELD_NUMBER = 2; public static final int DESCRIPTION_FIELD_NUMBER = 2;
private volatile java.lang.Object description_; @SuppressWarnings("serial")
private volatile java.lang.Object description_ = "";
/** /**
* <pre> * <pre>
* A description of why the request element is bad. * A description of why the request element is bad.
@ -413,13 +307,13 @@ public final class ErrorDetailsProto {
@java.lang.Override @java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output) public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException { throws java.io.IOException {
if (!getFieldBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(field_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, field_); com.google.protobuf.GeneratedMessageV3.writeString(output, 1, field_);
} }
if (!getDescriptionBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, description_); com.google.protobuf.GeneratedMessageV3.writeString(output, 2, description_);
} }
unknownFields.writeTo(output); getUnknownFields().writeTo(output);
} }
@java.lang.Override @java.lang.Override
@ -428,13 +322,13 @@ public final class ErrorDetailsProto {
if (size != -1) return size; if (size != -1) return size;
size = 0; size = 0;
if (!getFieldBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(field_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, field_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, field_);
} }
if (!getDescriptionBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, description_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, description_);
} }
size += unknownFields.getSerializedSize(); size += getUnknownFields().getSerializedSize();
memoizedSize = size; memoizedSize = size;
return size; return size;
} }
@ -453,7 +347,7 @@ public final class ErrorDetailsProto {
.equals(other.getField())) return false; .equals(other.getField())) return false;
if (!getDescription() if (!getDescription()
.equals(other.getDescription())) return false; .equals(other.getDescription())) return false;
if (!unknownFields.equals(other.unknownFields)) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true; return true;
} }
@ -468,7 +362,7 @@ public final class ErrorDetailsProto {
hash = (53 * hash) + getField().hashCode(); hash = (53 * hash) + getField().hashCode();
hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER;
hash = (53 * hash) + getDescription().hashCode(); hash = (53 * hash) + getDescription().hashCode();
hash = (29 * hash) + unknownFields.hashCode(); hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash; memoizedHashCode = hash;
return hash; return hash;
} }
@ -517,11 +411,13 @@ public final class ErrorDetailsProto {
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry); .parseWithIOException(PARSER, input, extensionRegistry);
} }
public static org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.FieldViolation parseDelimitedFrom(java.io.InputStream input) public static org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.FieldViolation parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException { throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input); .parseDelimitedWithIOException(PARSER, input);
} }
public static org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.FieldViolation parseDelimitedFrom( public static org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.FieldViolation parseDelimitedFrom(
java.io.InputStream input, java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
@ -589,26 +485,20 @@ public final class ErrorDetailsProto {
// Construct using org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.FieldViolation.newBuilder() // Construct using org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.FieldViolation.newBuilder()
private Builder() { private Builder() {
maybeForceBuilderInitialization();
} }
private Builder( private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent); super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
} }
@java.lang.Override @java.lang.Override
public Builder clear() { public Builder clear() {
super.clear(); super.clear();
bitField0_ = 0;
field_ = ""; field_ = "";
description_ = ""; description_ = "";
return this; return this;
} }
@ -635,12 +525,21 @@ public final class ErrorDetailsProto {
@java.lang.Override @java.lang.Override
public org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.FieldViolation buildPartial() { public org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.FieldViolation buildPartial() {
org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.FieldViolation result = new org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.FieldViolation(this); org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.FieldViolation result = new org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.FieldViolation(this);
result.field_ = field_; if (bitField0_ != 0) { buildPartial0(result); }
result.description_ = description_;
onBuilt(); onBuilt();
return result; return result;
} }
private void buildPartial0(org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.FieldViolation result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.field_ = field_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.description_ = description_;
}
}
@java.lang.Override @java.lang.Override
public Builder clone() { public Builder clone() {
return super.clone(); return super.clone();
@ -687,13 +586,15 @@ public final class ErrorDetailsProto {
if (other == org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.FieldViolation.getDefaultInstance()) return this; if (other == org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.FieldViolation.getDefaultInstance()) return this;
if (!other.getField().isEmpty()) { if (!other.getField().isEmpty()) {
field_ = other.field_; field_ = other.field_;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
} }
if (!other.getDescription().isEmpty()) { if (!other.getDescription().isEmpty()) {
description_ = other.description_; description_ = other.description_;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
} }
this.mergeUnknownFields(other.unknownFields); this.mergeUnknownFields(other.getUnknownFields());
onChanged(); onChanged();
return this; return this;
} }
@ -708,19 +609,43 @@ public final class ErrorDetailsProto {
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException { throws java.io.IOException {
org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.FieldViolation parsedMessage = null; if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try { try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
field_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 18: {
description_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000002;
break;
} // case 18
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) { } catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.FieldViolation) e.getUnfinishedMessage();
throw e.unwrapIOException(); throw e.unwrapIOException();
} finally { } finally {
if (parsedMessage != null) { onChanged();
mergeFrom(parsedMessage); } // finally
}
}
return this; return this;
} }
private int bitField0_;
private java.lang.Object field_ = ""; private java.lang.Object field_ = "";
/** /**
@ -781,11 +706,9 @@ public final class ErrorDetailsProto {
*/ */
public Builder setField( public Builder setField(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
field_ = value; field_ = value;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -800,8 +723,8 @@ public final class ErrorDetailsProto {
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearField() { public Builder clearField() {
field_ = getDefaultInstance().getField(); field_ = getDefaultInstance().getField();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged(); onChanged();
return this; return this;
} }
@ -818,12 +741,10 @@ public final class ErrorDetailsProto {
*/ */
public Builder setFieldBytes( public Builder setFieldBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
field_ = value; field_ = value;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -881,11 +802,9 @@ public final class ErrorDetailsProto {
*/ */
public Builder setDescription( public Builder setDescription(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
description_ = value; description_ = value;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
return this; return this;
} }
@ -898,8 +817,8 @@ public final class ErrorDetailsProto {
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearDescription() { public Builder clearDescription() {
description_ = getDefaultInstance().getDescription(); description_ = getDefaultInstance().getDescription();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged(); onChanged();
return this; return this;
} }
@ -914,12 +833,10 @@ public final class ErrorDetailsProto {
*/ */
public Builder setDescriptionBytes( public Builder setDescriptionBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
description_ = value; description_ = value;
bitField0_ |= 0x00000002;
onChanged(); onChanged();
return this; return this;
} }
@ -956,7 +873,18 @@ public final class ErrorDetailsProto {
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException { throws com.google.protobuf.InvalidProtocolBufferException {
return new FieldViolation(input, extensionRegistry); Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
} }
}; };
@ -977,6 +905,7 @@ public final class ErrorDetailsProto {
} }
public static final int FIELD_VIOLATIONS_FIELD_NUMBER = 1; public static final int FIELD_VIOLATIONS_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private java.util.List<org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.FieldViolation> fieldViolations_; private java.util.List<org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.FieldViolation> fieldViolations_;
/** /**
* <pre> * <pre>
@ -1053,7 +982,7 @@ public final class ErrorDetailsProto {
for (int i = 0; i < fieldViolations_.size(); i++) { for (int i = 0; i < fieldViolations_.size(); i++) {
output.writeMessage(1, fieldViolations_.get(i)); output.writeMessage(1, fieldViolations_.get(i));
} }
unknownFields.writeTo(output); getUnknownFields().writeTo(output);
} }
@java.lang.Override @java.lang.Override
@ -1066,7 +995,7 @@ public final class ErrorDetailsProto {
size += com.google.protobuf.CodedOutputStream size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, fieldViolations_.get(i)); .computeMessageSize(1, fieldViolations_.get(i));
} }
size += unknownFields.getSerializedSize(); size += getUnknownFields().getSerializedSize();
memoizedSize = size; memoizedSize = size;
return size; return size;
} }
@ -1083,7 +1012,7 @@ public final class ErrorDetailsProto {
if (!getFieldViolationsList() if (!getFieldViolationsList()
.equals(other.getFieldViolationsList())) return false; .equals(other.getFieldViolationsList())) return false;
if (!unknownFields.equals(other.unknownFields)) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true; return true;
} }
@ -1098,7 +1027,7 @@ public final class ErrorDetailsProto {
hash = (37 * hash) + FIELD_VIOLATIONS_FIELD_NUMBER; hash = (37 * hash) + FIELD_VIOLATIONS_FIELD_NUMBER;
hash = (53 * hash) + getFieldViolationsList().hashCode(); hash = (53 * hash) + getFieldViolationsList().hashCode();
} }
hash = (29 * hash) + unknownFields.hashCode(); hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash; memoizedHashCode = hash;
return hash; return hash;
} }
@ -1147,11 +1076,13 @@ public final class ErrorDetailsProto {
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry); .parseWithIOException(PARSER, input, extensionRegistry);
} }
public static org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument parseDelimitedFrom(java.io.InputStream input) public static org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException { throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input); .parseDelimitedWithIOException(PARSER, input);
} }
public static org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument parseDelimitedFrom( public static org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument parseDelimitedFrom(
java.io.InputStream input, java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
@ -1222,29 +1153,25 @@ public final class ErrorDetailsProto {
// Construct using org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.newBuilder() // Construct using org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.newBuilder()
private Builder() { private Builder() {
maybeForceBuilderInitialization();
} }
private Builder( private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent); super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getFieldViolationsFieldBuilder();
}
} }
@java.lang.Override @java.lang.Override
public Builder clear() { public Builder clear() {
super.clear(); super.clear();
bitField0_ = 0;
if (fieldViolationsBuilder_ == null) { if (fieldViolationsBuilder_ == null) {
fieldViolations_ = java.util.Collections.emptyList(); fieldViolations_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001);
} else { } else {
fieldViolations_ = null;
fieldViolationsBuilder_.clear(); fieldViolationsBuilder_.clear();
} }
bitField0_ = (bitField0_ & ~0x00000001);
return this; return this;
} }
@ -1271,7 +1198,13 @@ public final class ErrorDetailsProto {
@java.lang.Override @java.lang.Override
public org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument buildPartial() { public org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument buildPartial() {
org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument result = new org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument(this); org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument result = new org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument(this);
int from_bitField0_ = bitField0_; buildPartialRepeatedFields(result);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartialRepeatedFields(org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument result) {
if (fieldViolationsBuilder_ == null) { if (fieldViolationsBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0)) { if (((bitField0_ & 0x00000001) != 0)) {
fieldViolations_ = java.util.Collections.unmodifiableList(fieldViolations_); fieldViolations_ = java.util.Collections.unmodifiableList(fieldViolations_);
@ -1281,8 +1214,10 @@ public final class ErrorDetailsProto {
} else { } else {
result.fieldViolations_ = fieldViolationsBuilder_.build(); result.fieldViolations_ = fieldViolationsBuilder_.build();
} }
onBuilt(); }
return result;
private void buildPartial0(org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument result) {
int from_bitField0_ = bitField0_;
} }
@java.lang.Override @java.lang.Override
@ -1355,7 +1290,7 @@ public final class ErrorDetailsProto {
} }
} }
} }
this.mergeUnknownFields(other.unknownFields); this.mergeUnknownFields(other.getUnknownFields());
onChanged(); onChanged();
return this; return this;
} }
@ -1370,17 +1305,43 @@ public final class ErrorDetailsProto {
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException { throws java.io.IOException {
org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument parsedMessage = null; if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try { try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.FieldViolation m =
input.readMessage(
org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument.FieldViolation.parser(),
extensionRegistry);
if (fieldViolationsBuilder_ == null) {
ensureFieldViolationsIsMutable();
fieldViolations_.add(m);
} else {
fieldViolationsBuilder_.addMessage(m);
}
break;
} // case 10
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) { } catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (org.bdware.bdledger.api.grpc.pb.ErrorDetailsProto.InvalidArgument) e.getUnfinishedMessage();
throw e.unwrapIOException(); throw e.unwrapIOException();
} finally { } finally {
if (parsedMessage != null) { onChanged();
mergeFrom(parsedMessage); } // finally
}
}
return this; return this;
} }
private int bitField0_; private int bitField0_;
@ -1729,7 +1690,18 @@ public final class ErrorDetailsProto {
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException { throws com.google.protobuf.InvalidProtocolBufferException {
return new InvalidArgument(input, extensionRegistry); Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
} }
}; };

View File

@ -5,14 +5,14 @@ import static io.grpc.MethodDescriptor.generateFullMethodName;
/** /**
*/ */
@javax.annotation.Generated( @javax.annotation.Generated(
value = "by gRPC proto compiler (version 1.41.0)", value = "by gRPC proto compiler (version 1.71.0)",
comments = "Source: bdware/bdledger/api/ledger.proto") comments = "Source: bdware/bdledger/api/ledger.proto")
@io.grpc.stub.annotations.GrpcGenerated @io.grpc.stub.annotations.GrpcGenerated
public final class LedgerGrpc { public final class LedgerGrpc {
private LedgerGrpc() {} private LedgerGrpc() {}
public static final String SERVICE_NAME = "bdware.bdledger.api.Ledger"; public static final java.lang.String SERVICE_NAME = "bdware.bdledger.api.Ledger";
// Static method descriptors that strictly reflect the proto. // Static method descriptors that strictly reflect the proto.
private static volatile io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.LedgerProto.CreateLedgerRequest, private static volatile io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.LedgerProto.CreateLedgerRequest,
@ -122,6 +122,21 @@ public final class LedgerGrpc {
return LedgerStub.newStub(factory, channel); return LedgerStub.newStub(factory, channel);
} }
/**
* Creates a new blocking-style stub that supports all types of calls on the service
*/
public static LedgerBlockingV2Stub newBlockingV2Stub(
io.grpc.Channel channel) {
io.grpc.stub.AbstractStub.StubFactory<LedgerBlockingV2Stub> factory =
new io.grpc.stub.AbstractStub.StubFactory<LedgerBlockingV2Stub>() {
@java.lang.Override
public LedgerBlockingV2Stub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new LedgerBlockingV2Stub(channel, callOptions);
}
};
return LedgerBlockingV2Stub.newStub(factory, channel);
}
/** /**
* Creates a new blocking-style stub that supports unary and streaming output calls on the service * Creates a new blocking-style stub that supports unary and streaming output calls on the service
*/ */
@ -154,7 +169,7 @@ public final class LedgerGrpc {
/** /**
*/ */
public static abstract class LedgerImplBase implements io.grpc.BindableService { public interface AsyncService {
/** /**
* <pre> * <pre>
@ -163,7 +178,7 @@ public final class LedgerGrpc {
* 创建一个新账本 * 创建一个新账本
* </pre> * </pre>
*/ */
public void createLedger(org.bdware.bdledger.api.grpc.pb.LedgerProto.CreateLedgerRequest request, default void createLedger(org.bdware.bdledger.api.grpc.pb.LedgerProto.CreateLedgerRequest request,
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.LedgerProto.CreateLedgerResponse> responseObserver) { io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.LedgerProto.CreateLedgerResponse> responseObserver) {
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getCreateLedgerMethod(), responseObserver); io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getCreateLedgerMethod(), responseObserver);
} }
@ -175,7 +190,7 @@ public final class LedgerGrpc {
* 查询所有帐本列表 * 查询所有帐本列表
* </pre> * </pre>
*/ */
public void getLedgers(com.google.protobuf.Empty request, default void getLedgers(com.google.protobuf.Empty request,
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.LedgerProto.GetLedgersResponse> responseObserver) { io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.LedgerProto.GetLedgersResponse> responseObserver) {
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetLedgersMethod(), responseObserver); io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetLedgersMethod(), responseObserver);
} }
@ -187,41 +202,28 @@ public final class LedgerGrpc {
* 发送一个新事务 * 发送一个新事务
* </pre> * </pre>
*/ */
public void sendTransaction(org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionRequest request, default void sendTransaction(org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionRequest request,
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionResponse> responseObserver) { io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionResponse> responseObserver) {
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getSendTransactionMethod(), responseObserver); io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getSendTransactionMethod(), responseObserver);
} }
@java.lang.Override public final io.grpc.ServerServiceDefinition bindService() {
return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor())
.addMethod(
getCreateLedgerMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
org.bdware.bdledger.api.grpc.pb.LedgerProto.CreateLedgerRequest,
org.bdware.bdledger.api.grpc.pb.LedgerProto.CreateLedgerResponse>(
this, METHODID_CREATE_LEDGER)))
.addMethod(
getGetLedgersMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
com.google.protobuf.Empty,
org.bdware.bdledger.api.grpc.pb.LedgerProto.GetLedgersResponse>(
this, METHODID_GET_LEDGERS)))
.addMethod(
getSendTransactionMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionRequest,
org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionResponse>(
this, METHODID_SEND_TRANSACTION)))
.build();
}
} }
/** /**
* Base class for the server implementation of the service Ledger.
*/ */
public static final class LedgerStub extends io.grpc.stub.AbstractAsyncStub<LedgerStub> { public static abstract class LedgerImplBase
implements io.grpc.BindableService, AsyncService {
@java.lang.Override public final io.grpc.ServerServiceDefinition bindService() {
return LedgerGrpc.bindService(this);
}
}
/**
* A stub to allow clients to do asynchronous rpc calls to service Ledger.
*/
public static final class LedgerStub
extends io.grpc.stub.AbstractAsyncStub<LedgerStub> {
private LedgerStub( private LedgerStub(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) { io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions); super(channel, callOptions);
@ -274,8 +276,63 @@ public final class LedgerGrpc {
} }
/** /**
* A stub to allow clients to do synchronous rpc calls to service Ledger.
*/ */
public static final class LedgerBlockingStub extends io.grpc.stub.AbstractBlockingStub<LedgerBlockingStub> { public static final class LedgerBlockingV2Stub
extends io.grpc.stub.AbstractBlockingStub<LedgerBlockingV2Stub> {
private LedgerBlockingV2Stub(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
protected LedgerBlockingV2Stub build(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new LedgerBlockingV2Stub(channel, callOptions);
}
/**
* <pre>
**
* Create a new ledger
* 创建一个新账本
* </pre>
*/
public org.bdware.bdledger.api.grpc.pb.LedgerProto.CreateLedgerResponse createLedger(org.bdware.bdledger.api.grpc.pb.LedgerProto.CreateLedgerRequest request) {
return io.grpc.stub.ClientCalls.blockingUnaryCall(
getChannel(), getCreateLedgerMethod(), getCallOptions(), request);
}
/**
* <pre>
**
* Get all ledgers
* 查询所有帐本列表
* </pre>
*/
public org.bdware.bdledger.api.grpc.pb.LedgerProto.GetLedgersResponse getLedgers(com.google.protobuf.Empty request) {
return io.grpc.stub.ClientCalls.blockingUnaryCall(
getChannel(), getGetLedgersMethod(), getCallOptions(), request);
}
/**
* <pre>
**
* Send a new transaction
* 发送一个新事务
* </pre>
*/
public org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionResponse sendTransaction(org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionRequest request) {
return io.grpc.stub.ClientCalls.blockingUnaryCall(
getChannel(), getSendTransactionMethod(), getCallOptions(), request);
}
}
/**
* A stub to allow clients to do limited synchronous rpc calls to service Ledger.
*/
public static final class LedgerBlockingStub
extends io.grpc.stub.AbstractBlockingStub<LedgerBlockingStub> {
private LedgerBlockingStub( private LedgerBlockingStub(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) { io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions); super(channel, callOptions);
@ -325,8 +382,10 @@ public final class LedgerGrpc {
} }
/** /**
* A stub to allow clients to do ListenableFuture-style rpc calls to service Ledger.
*/ */
public static final class LedgerFutureStub extends io.grpc.stub.AbstractFutureStub<LedgerFutureStub> { public static final class LedgerFutureStub
extends io.grpc.stub.AbstractFutureStub<LedgerFutureStub> {
private LedgerFutureStub( private LedgerFutureStub(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) { io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions); super(channel, callOptions);
@ -387,10 +446,10 @@ public final class LedgerGrpc {
io.grpc.stub.ServerCalls.ServerStreamingMethod<Req, Resp>, io.grpc.stub.ServerCalls.ServerStreamingMethod<Req, Resp>,
io.grpc.stub.ServerCalls.ClientStreamingMethod<Req, Resp>, io.grpc.stub.ServerCalls.ClientStreamingMethod<Req, Resp>,
io.grpc.stub.ServerCalls.BidiStreamingMethod<Req, Resp> { io.grpc.stub.ServerCalls.BidiStreamingMethod<Req, Resp> {
private final LedgerImplBase serviceImpl; private final AsyncService serviceImpl;
private final int methodId; private final int methodId;
MethodHandlers(LedgerImplBase serviceImpl, int methodId) { MethodHandlers(AsyncService serviceImpl, int methodId) {
this.serviceImpl = serviceImpl; this.serviceImpl = serviceImpl;
this.methodId = methodId; this.methodId = methodId;
} }
@ -427,6 +486,32 @@ public final class LedgerGrpc {
} }
} }
public static final io.grpc.ServerServiceDefinition bindService(AsyncService service) {
return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor())
.addMethod(
getCreateLedgerMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
org.bdware.bdledger.api.grpc.pb.LedgerProto.CreateLedgerRequest,
org.bdware.bdledger.api.grpc.pb.LedgerProto.CreateLedgerResponse>(
service, METHODID_CREATE_LEDGER)))
.addMethod(
getGetLedgersMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
com.google.protobuf.Empty,
org.bdware.bdledger.api.grpc.pb.LedgerProto.GetLedgersResponse>(
service, METHODID_GET_LEDGERS)))
.addMethod(
getSendTransactionMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionRequest,
org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionResponse>(
service, METHODID_SEND_TRANSACTION)))
.build();
}
private static abstract class LedgerBaseDescriptorSupplier private static abstract class LedgerBaseDescriptorSupplier
implements io.grpc.protobuf.ProtoFileDescriptorSupplier, io.grpc.protobuf.ProtoServiceDescriptorSupplier { implements io.grpc.protobuf.ProtoFileDescriptorSupplier, io.grpc.protobuf.ProtoServiceDescriptorSupplier {
LedgerBaseDescriptorSupplier() {} LedgerBaseDescriptorSupplier() {}
@ -450,9 +535,9 @@ public final class LedgerGrpc {
private static final class LedgerMethodDescriptorSupplier private static final class LedgerMethodDescriptorSupplier
extends LedgerBaseDescriptorSupplier extends LedgerBaseDescriptorSupplier
implements io.grpc.protobuf.ProtoMethodDescriptorSupplier { implements io.grpc.protobuf.ProtoMethodDescriptorSupplier {
private final String methodName; private final java.lang.String methodName;
LedgerMethodDescriptorSupplier(String methodName) { LedgerMethodDescriptorSupplier(java.lang.String methodName) {
this.methodName = methodName; this.methodName = methodName;
} }

File diff suppressed because it is too large Load Diff

View File

@ -5,14 +5,14 @@ import static io.grpc.MethodDescriptor.generateFullMethodName;
/** /**
*/ */
@javax.annotation.Generated( @javax.annotation.Generated(
value = "by gRPC proto compiler (version 1.41.0)", value = "by gRPC proto compiler (version 1.71.0)",
comments = "Source: bdware/bdledger/api/node.proto") comments = "Source: bdware/bdledger/api/node.proto")
@io.grpc.stub.annotations.GrpcGenerated @io.grpc.stub.annotations.GrpcGenerated
public final class NodeGrpc { public final class NodeGrpc {
private NodeGrpc() {} private NodeGrpc() {}
public static final String SERVICE_NAME = "bdware.bdledger.api.Node"; public static final java.lang.String SERVICE_NAME = "bdware.bdledger.api.Node";
// Static method descriptors that strictly reflect the proto. // Static method descriptors that strictly reflect the proto.
private static volatile io.grpc.MethodDescriptor<com.google.protobuf.Empty, private static volatile io.grpc.MethodDescriptor<com.google.protobuf.Empty,
@ -60,6 +60,21 @@ public final class NodeGrpc {
return NodeStub.newStub(factory, channel); return NodeStub.newStub(factory, channel);
} }
/**
* Creates a new blocking-style stub that supports all types of calls on the service
*/
public static NodeBlockingV2Stub newBlockingV2Stub(
io.grpc.Channel channel) {
io.grpc.stub.AbstractStub.StubFactory<NodeBlockingV2Stub> factory =
new io.grpc.stub.AbstractStub.StubFactory<NodeBlockingV2Stub>() {
@java.lang.Override
public NodeBlockingV2Stub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new NodeBlockingV2Stub(channel, callOptions);
}
};
return NodeBlockingV2Stub.newStub(factory, channel);
}
/** /**
* Creates a new blocking-style stub that supports unary and streaming output calls on the service * Creates a new blocking-style stub that supports unary and streaming output calls on the service
*/ */
@ -92,7 +107,7 @@ public final class NodeGrpc {
/** /**
*/ */
public static abstract class NodeImplBase implements io.grpc.BindableService { public interface AsyncService {
/** /**
* <pre> * <pre>
@ -101,27 +116,28 @@ public final class NodeGrpc {
* 查询BDLedger节点版本 * 查询BDLedger节点版本
* </pre> * </pre>
*/ */
public void clientVersion(com.google.protobuf.Empty request, default void clientVersion(com.google.protobuf.Empty request,
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse> responseObserver) { io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse> responseObserver) {
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getClientVersionMethod(), responseObserver); io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getClientVersionMethod(), responseObserver);
} }
@java.lang.Override public final io.grpc.ServerServiceDefinition bindService() {
return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor())
.addMethod(
getClientVersionMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
com.google.protobuf.Empty,
org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse>(
this, METHODID_CLIENT_VERSION)))
.build();
}
} }
/** /**
* Base class for the server implementation of the service Node.
*/ */
public static final class NodeStub extends io.grpc.stub.AbstractAsyncStub<NodeStub> { public static abstract class NodeImplBase
implements io.grpc.BindableService, AsyncService {
@java.lang.Override public final io.grpc.ServerServiceDefinition bindService() {
return NodeGrpc.bindService(this);
}
}
/**
* A stub to allow clients to do asynchronous rpc calls to service Node.
*/
public static final class NodeStub
extends io.grpc.stub.AbstractAsyncStub<NodeStub> {
private NodeStub( private NodeStub(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) { io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions); super(channel, callOptions);
@ -148,8 +164,39 @@ public final class NodeGrpc {
} }
/** /**
* A stub to allow clients to do synchronous rpc calls to service Node.
*/ */
public static final class NodeBlockingStub extends io.grpc.stub.AbstractBlockingStub<NodeBlockingStub> { public static final class NodeBlockingV2Stub
extends io.grpc.stub.AbstractBlockingStub<NodeBlockingV2Stub> {
private NodeBlockingV2Stub(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
protected NodeBlockingV2Stub build(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new NodeBlockingV2Stub(channel, callOptions);
}
/**
* <pre>
**
* Get BDLedger node version
* 查询BDLedger节点版本
* </pre>
*/
public org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse clientVersion(com.google.protobuf.Empty request) {
return io.grpc.stub.ClientCalls.blockingUnaryCall(
getChannel(), getClientVersionMethod(), getCallOptions(), request);
}
}
/**
* A stub to allow clients to do limited synchronous rpc calls to service Node.
*/
public static final class NodeBlockingStub
extends io.grpc.stub.AbstractBlockingStub<NodeBlockingStub> {
private NodeBlockingStub( private NodeBlockingStub(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) { io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions); super(channel, callOptions);
@ -175,8 +222,10 @@ public final class NodeGrpc {
} }
/** /**
* A stub to allow clients to do ListenableFuture-style rpc calls to service Node.
*/ */
public static final class NodeFutureStub extends io.grpc.stub.AbstractFutureStub<NodeFutureStub> { public static final class NodeFutureStub
extends io.grpc.stub.AbstractFutureStub<NodeFutureStub> {
private NodeFutureStub( private NodeFutureStub(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) { io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions); super(channel, callOptions);
@ -209,10 +258,10 @@ public final class NodeGrpc {
io.grpc.stub.ServerCalls.ServerStreamingMethod<Req, Resp>, io.grpc.stub.ServerCalls.ServerStreamingMethod<Req, Resp>,
io.grpc.stub.ServerCalls.ClientStreamingMethod<Req, Resp>, io.grpc.stub.ServerCalls.ClientStreamingMethod<Req, Resp>,
io.grpc.stub.ServerCalls.BidiStreamingMethod<Req, Resp> { io.grpc.stub.ServerCalls.BidiStreamingMethod<Req, Resp> {
private final NodeImplBase serviceImpl; private final AsyncService serviceImpl;
private final int methodId; private final int methodId;
MethodHandlers(NodeImplBase serviceImpl, int methodId) { MethodHandlers(AsyncService serviceImpl, int methodId) {
this.serviceImpl = serviceImpl; this.serviceImpl = serviceImpl;
this.methodId = methodId; this.methodId = methodId;
} }
@ -241,6 +290,18 @@ public final class NodeGrpc {
} }
} }
public static final io.grpc.ServerServiceDefinition bindService(AsyncService service) {
return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor())
.addMethod(
getClientVersionMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
com.google.protobuf.Empty,
org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse>(
service, METHODID_CLIENT_VERSION)))
.build();
}
private static abstract class NodeBaseDescriptorSupplier private static abstract class NodeBaseDescriptorSupplier
implements io.grpc.protobuf.ProtoFileDescriptorSupplier, io.grpc.protobuf.ProtoServiceDescriptorSupplier { implements io.grpc.protobuf.ProtoFileDescriptorSupplier, io.grpc.protobuf.ProtoServiceDescriptorSupplier {
NodeBaseDescriptorSupplier() {} NodeBaseDescriptorSupplier() {}
@ -264,9 +325,9 @@ public final class NodeGrpc {
private static final class NodeMethodDescriptorSupplier private static final class NodeMethodDescriptorSupplier
extends NodeBaseDescriptorSupplier extends NodeBaseDescriptorSupplier
implements io.grpc.protobuf.ProtoMethodDescriptorSupplier { implements io.grpc.protobuf.ProtoMethodDescriptorSupplier {
private final String methodName; private final java.lang.String methodName;
NodeMethodDescriptorSupplier(String methodName) { NodeMethodDescriptorSupplier(java.lang.String methodName) {
this.methodName = methodName; this.methodName = methodName;
} }

View File

@ -1,6 +1,7 @@
// Generated by the protocol buffer compiler. DO NOT EDIT! // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: bdware/bdledger/api/node.proto // source: bdware/bdledger/api/node.proto
// Protobuf Java Version: 3.25.6
package org.bdware.bdledger.api.grpc.pb; package org.bdware.bdledger.api.grpc.pb;
public final class NodeProto { public final class NodeProto {
@ -63,54 +64,6 @@ public final class NodeProto {
return new ClientVersionResponse(); return new ClientVersionResponse();
} }
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private ClientVersionResponse(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
java.lang.String s = input.readStringRequireUtf8();
version_ = s;
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() { getDescriptor() {
return org.bdware.bdledger.api.grpc.pb.NodeProto.internal_static_bdware_bdledger_api_ClientVersionResponse_descriptor; return org.bdware.bdledger.api.grpc.pb.NodeProto.internal_static_bdware_bdledger_api_ClientVersionResponse_descriptor;
@ -125,7 +78,8 @@ public final class NodeProto {
} }
public static final int VERSION_FIELD_NUMBER = 1; public static final int VERSION_FIELD_NUMBER = 1;
private volatile java.lang.Object version_; @SuppressWarnings("serial")
private volatile java.lang.Object version_ = "";
/** /**
* <pre> * <pre>
* Client version * Client version
@ -186,10 +140,10 @@ public final class NodeProto {
@java.lang.Override @java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output) public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException { throws java.io.IOException {
if (!getVersionBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(version_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, version_); com.google.protobuf.GeneratedMessageV3.writeString(output, 1, version_);
} }
unknownFields.writeTo(output); getUnknownFields().writeTo(output);
} }
@java.lang.Override @java.lang.Override
@ -198,10 +152,10 @@ public final class NodeProto {
if (size != -1) return size; if (size != -1) return size;
size = 0; size = 0;
if (!getVersionBytes().isEmpty()) { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(version_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, version_); size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, version_);
} }
size += unknownFields.getSerializedSize(); size += getUnknownFields().getSerializedSize();
memoizedSize = size; memoizedSize = size;
return size; return size;
} }
@ -218,7 +172,7 @@ public final class NodeProto {
if (!getVersion() if (!getVersion()
.equals(other.getVersion())) return false; .equals(other.getVersion())) return false;
if (!unknownFields.equals(other.unknownFields)) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true; return true;
} }
@ -231,7 +185,7 @@ public final class NodeProto {
hash = (19 * hash) + getDescriptor().hashCode(); hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + VERSION_FIELD_NUMBER; hash = (37 * hash) + VERSION_FIELD_NUMBER;
hash = (53 * hash) + getVersion().hashCode(); hash = (53 * hash) + getVersion().hashCode();
hash = (29 * hash) + unknownFields.hashCode(); hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash; memoizedHashCode = hash;
return hash; return hash;
} }
@ -280,11 +234,13 @@ public final class NodeProto {
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry); .parseWithIOException(PARSER, input, extensionRegistry);
} }
public static org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse parseDelimitedFrom(java.io.InputStream input) public static org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException { throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3 return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input); .parseDelimitedWithIOException(PARSER, input);
} }
public static org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse parseDelimitedFrom( public static org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse parseDelimitedFrom(
java.io.InputStream input, java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
@ -348,24 +304,19 @@ public final class NodeProto {
// Construct using org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse.newBuilder() // Construct using org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse.newBuilder()
private Builder() { private Builder() {
maybeForceBuilderInitialization();
} }
private Builder( private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent); super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
} }
@java.lang.Override @java.lang.Override
public Builder clear() { public Builder clear() {
super.clear(); super.clear();
bitField0_ = 0;
version_ = ""; version_ = "";
return this; return this;
} }
@ -392,11 +343,18 @@ public final class NodeProto {
@java.lang.Override @java.lang.Override
public org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse buildPartial() { public org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse buildPartial() {
org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse result = new org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse(this); org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse result = new org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse(this);
result.version_ = version_; if (bitField0_ != 0) { buildPartial0(result); }
onBuilt(); onBuilt();
return result; return result;
} }
private void buildPartial0(org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.version_ = version_;
}
}
@java.lang.Override @java.lang.Override
public Builder clone() { public Builder clone() {
return super.clone(); return super.clone();
@ -443,9 +401,10 @@ public final class NodeProto {
if (other == org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse.getDefaultInstance()) return this; if (other == org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse.getDefaultInstance()) return this;
if (!other.getVersion().isEmpty()) { if (!other.getVersion().isEmpty()) {
version_ = other.version_; version_ = other.version_;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
} }
this.mergeUnknownFields(other.unknownFields); this.mergeUnknownFields(other.getUnknownFields());
onChanged(); onChanged();
return this; return this;
} }
@ -460,19 +419,38 @@ public final class NodeProto {
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException { throws java.io.IOException {
org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse parsedMessage = null; if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try { try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
version_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) { } catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse) e.getUnfinishedMessage();
throw e.unwrapIOException(); throw e.unwrapIOException();
} finally { } finally {
if (parsedMessage != null) { onChanged();
mergeFrom(parsedMessage); } // finally
}
}
return this; return this;
} }
private int bitField0_;
private java.lang.Object version_ = ""; private java.lang.Object version_ = "";
/** /**
@ -530,11 +508,9 @@ public final class NodeProto {
*/ */
public Builder setVersion( public Builder setVersion(
java.lang.String value) { java.lang.String value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException();
}
version_ = value; version_ = value;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -548,8 +524,8 @@ public final class NodeProto {
* @return This builder for chaining. * @return This builder for chaining.
*/ */
public Builder clearVersion() { public Builder clearVersion() {
version_ = getDefaultInstance().getVersion(); version_ = getDefaultInstance().getVersion();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged(); onChanged();
return this; return this;
} }
@ -565,12 +541,10 @@ public final class NodeProto {
*/ */
public Builder setVersionBytes( public Builder setVersionBytes(
com.google.protobuf.ByteString value) { com.google.protobuf.ByteString value) {
if (value == null) { if (value == null) { throw new NullPointerException(); }
throw new NullPointerException(); checkByteStringIsUtf8(value);
}
checkByteStringIsUtf8(value);
version_ = value; version_ = value;
bitField0_ |= 0x00000001;
onChanged(); onChanged();
return this; return this;
} }
@ -607,7 +581,18 @@ public final class NodeProto {
com.google.protobuf.CodedInputStream input, com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException { throws com.google.protobuf.InvalidProtocolBufferException {
return new ClientVersionResponse(input, extensionRegistry); Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
} }
}; };

View File

@ -5,14 +5,14 @@ import static io.grpc.MethodDescriptor.generateFullMethodName;
/** /**
*/ */
@javax.annotation.Generated( @javax.annotation.Generated(
value = "by gRPC proto compiler (version 1.41.0)", value = "by gRPC proto compiler (version 1.71.0)",
comments = "Source: bdware/bdledger/api/query.proto") comments = "Source: bdware/bdledger/api/query.proto")
@io.grpc.stub.annotations.GrpcGenerated @io.grpc.stub.annotations.GrpcGenerated
public final class QueryGrpc { public final class QueryGrpc {
private QueryGrpc() {} private QueryGrpc() {}
public static final String SERVICE_NAME = "bdware.bdledger.api.Query"; public static final java.lang.String SERVICE_NAME = "bdware.bdledger.api.Query";
// Static method descriptors that strictly reflect the proto. // Static method descriptors that strictly reflect the proto.
private static volatile io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlockByHashRequest, private static volatile io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlockByHashRequest,
@ -277,6 +277,21 @@ public final class QueryGrpc {
return QueryStub.newStub(factory, channel); return QueryStub.newStub(factory, channel);
} }
/**
* Creates a new blocking-style stub that supports all types of calls on the service
*/
public static QueryBlockingV2Stub newBlockingV2Stub(
io.grpc.Channel channel) {
io.grpc.stub.AbstractStub.StubFactory<QueryBlockingV2Stub> factory =
new io.grpc.stub.AbstractStub.StubFactory<QueryBlockingV2Stub>() {
@java.lang.Override
public QueryBlockingV2Stub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new QueryBlockingV2Stub(channel, callOptions);
}
};
return QueryBlockingV2Stub.newStub(factory, channel);
}
/** /**
* Creates a new blocking-style stub that supports unary and streaming output calls on the service * Creates a new blocking-style stub that supports unary and streaming output calls on the service
*/ */
@ -309,7 +324,7 @@ public final class QueryGrpc {
/** /**
*/ */
public static abstract class QueryImplBase implements io.grpc.BindableService { public interface AsyncService {
/** /**
* <pre> * <pre>
@ -318,7 +333,7 @@ public final class QueryGrpc {
* 查询哈希所指定的区块 * 查询哈希所指定的区块
* </pre> * </pre>
*/ */
public void getBlockByHash(org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlockByHashRequest request, default void getBlockByHash(org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlockByHashRequest request,
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlockByHashResponse> responseObserver) { io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlockByHashResponse> responseObserver) {
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetBlockByHashMethod(), responseObserver); io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetBlockByHashMethod(), responseObserver);
} }
@ -339,7 +354,7 @@ public final class QueryGrpc {
* and 'end_timestamp' will never be later than the current timestamp when the node process the query request. * and 'end_timestamp' will never be later than the current timestamp when the node process the query request.
* </pre> * </pre>
*/ */
public void getBlocks(org.bdware.bdledger.api.grpc.pb.QueryProto.BlocksRequest request, default void getBlocks(org.bdware.bdledger.api.grpc.pb.QueryProto.BlocksRequest request,
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlocksResponse> responseObserver) { io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlocksResponse> responseObserver) {
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetBlocksMethod(), responseObserver); io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetBlocksMethod(), responseObserver);
} }
@ -357,7 +372,7 @@ public final class QueryGrpc {
* and 'end_timestamp' will never be later than the current timestamp when the node process the query request. * and 'end_timestamp' will never be later than the current timestamp when the node process the query request.
* </pre> * </pre>
*/ */
public void countBlocks(org.bdware.bdledger.api.grpc.pb.QueryProto.BlocksRequest request, default void countBlocks(org.bdware.bdledger.api.grpc.pb.QueryProto.BlocksRequest request,
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.CountBlocksResponse> responseObserver) { io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.CountBlocksResponse> responseObserver) {
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getCountBlocksMethod(), responseObserver); io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getCountBlocksMethod(), responseObserver);
} }
@ -369,7 +384,7 @@ public final class QueryGrpc {
* 查询最新的 'count' 个区块 * 查询最新的 'count' 个区块
* </pre> * </pre>
*/ */
public void getRecentBlocks(org.bdware.bdledger.api.grpc.pb.QueryProto.RecentBlocksRequest request, default void getRecentBlocks(org.bdware.bdledger.api.grpc.pb.QueryProto.RecentBlocksRequest request,
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlocksResponse> responseObserver) { io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlocksResponse> responseObserver) {
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetRecentBlocksMethod(), responseObserver); io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetRecentBlocksMethod(), responseObserver);
} }
@ -381,7 +396,7 @@ public final class QueryGrpc {
* 查询哈希所指定的事务 * 查询哈希所指定的事务
* </pre> * </pre>
*/ */
public void getTransactionByHash(org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByHashRequest request, default void getTransactionByHash(org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByHashRequest request,
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByHashResponse> responseObserver) { io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByHashResponse> responseObserver) {
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetTransactionByHashMethod(), responseObserver); io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetTransactionByHashMethod(), responseObserver);
} }
@ -393,7 +408,7 @@ public final class QueryGrpc {
* 查询所在区块的哈希与其在区块中的index所指定的事务 * 查询所在区块的哈希与其在区块中的index所指定的事务
* </pre> * </pre>
*/ */
public void getTransactionByBlockHashAndIndex(org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByBlockHashAndIndexRequest request, default void getTransactionByBlockHashAndIndex(org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByBlockHashAndIndexRequest request,
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByBlockHashAndIndexResponse> responseObserver) { io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByBlockHashAndIndexResponse> responseObserver) {
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetTransactionByBlockHashAndIndexMethod(), responseObserver); io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetTransactionByBlockHashAndIndexMethod(), responseObserver);
} }
@ -406,7 +421,7 @@ public final class QueryGrpc {
* 'start_timestamp' and 'end_timestamp' follow the same requirements and rules as in 'GetBlocks'. * 'start_timestamp' and 'end_timestamp' follow the same requirements and rules as in 'GetBlocks'.
* </pre> * </pre>
*/ */
public void getTransactions(org.bdware.bdledger.api.grpc.pb.QueryProto.TransactionsRequest request, default void getTransactions(org.bdware.bdledger.api.grpc.pb.QueryProto.TransactionsRequest request,
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionsResponse> responseObserver) { io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionsResponse> responseObserver) {
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetTransactionsMethod(), responseObserver); io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetTransactionsMethod(), responseObserver);
} }
@ -419,76 +434,28 @@ public final class QueryGrpc {
* 'start_timestamp' and 'end_timestamp' follow the same requirements and rules as in 'CountBlocks'. * 'start_timestamp' and 'end_timestamp' follow the same requirements and rules as in 'CountBlocks'.
* </pre> * </pre>
*/ */
public void countTransactions(org.bdware.bdledger.api.grpc.pb.QueryProto.TransactionsRequest request, default void countTransactions(org.bdware.bdledger.api.grpc.pb.QueryProto.TransactionsRequest request,
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.CountTransactionsResponse> responseObserver) { io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.CountTransactionsResponse> responseObserver) {
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getCountTransactionsMethod(), responseObserver); io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getCountTransactionsMethod(), responseObserver);
} }
@java.lang.Override public final io.grpc.ServerServiceDefinition bindService() {
return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor())
.addMethod(
getGetBlockByHashMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlockByHashRequest,
org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlockByHashResponse>(
this, METHODID_GET_BLOCK_BY_HASH)))
.addMethod(
getGetBlocksMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
org.bdware.bdledger.api.grpc.pb.QueryProto.BlocksRequest,
org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlocksResponse>(
this, METHODID_GET_BLOCKS)))
.addMethod(
getCountBlocksMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
org.bdware.bdledger.api.grpc.pb.QueryProto.BlocksRequest,
org.bdware.bdledger.api.grpc.pb.QueryProto.CountBlocksResponse>(
this, METHODID_COUNT_BLOCKS)))
.addMethod(
getGetRecentBlocksMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
org.bdware.bdledger.api.grpc.pb.QueryProto.RecentBlocksRequest,
org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlocksResponse>(
this, METHODID_GET_RECENT_BLOCKS)))
.addMethod(
getGetTransactionByHashMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByHashRequest,
org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByHashResponse>(
this, METHODID_GET_TRANSACTION_BY_HASH)))
.addMethod(
getGetTransactionByBlockHashAndIndexMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByBlockHashAndIndexRequest,
org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByBlockHashAndIndexResponse>(
this, METHODID_GET_TRANSACTION_BY_BLOCK_HASH_AND_INDEX)))
.addMethod(
getGetTransactionsMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
org.bdware.bdledger.api.grpc.pb.QueryProto.TransactionsRequest,
org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionsResponse>(
this, METHODID_GET_TRANSACTIONS)))
.addMethod(
getCountTransactionsMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
org.bdware.bdledger.api.grpc.pb.QueryProto.TransactionsRequest,
org.bdware.bdledger.api.grpc.pb.QueryProto.CountTransactionsResponse>(
this, METHODID_COUNT_TRANSACTIONS)))
.build();
}
} }
/** /**
* Base class for the server implementation of the service Query.
*/ */
public static final class QueryStub extends io.grpc.stub.AbstractAsyncStub<QueryStub> { public static abstract class QueryImplBase
implements io.grpc.BindableService, AsyncService {
@java.lang.Override public final io.grpc.ServerServiceDefinition bindService() {
return QueryGrpc.bindService(this);
}
}
/**
* A stub to allow clients to do asynchronous rpc calls to service Query.
*/
public static final class QueryStub
extends io.grpc.stub.AbstractAsyncStub<QueryStub> {
private QueryStub( private QueryStub(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) { io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions); super(channel, callOptions);
@ -623,8 +590,140 @@ public final class QueryGrpc {
} }
/** /**
* A stub to allow clients to do synchronous rpc calls to service Query.
*/ */
public static final class QueryBlockingStub extends io.grpc.stub.AbstractBlockingStub<QueryBlockingStub> { public static final class QueryBlockingV2Stub
extends io.grpc.stub.AbstractBlockingStub<QueryBlockingV2Stub> {
private QueryBlockingV2Stub(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
protected QueryBlockingV2Stub build(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new QueryBlockingV2Stub(channel, callOptions);
}
/**
* <pre>
**
* Get a block identified by its hash
* 查询哈希所指定的区块
* </pre>
*/
public org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlockByHashResponse getBlockByHash(org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlockByHashRequest request) {
return io.grpc.stub.ClientCalls.blockingUnaryCall(
getChannel(), getGetBlockByHashMethod(), getCallOptions(), request);
}
/**
* <pre>
**
* Get blocks in a timestamp range
* 查询时间范围内的区块
* Requirement: start_timestamp &lt;= end_timestamp
* If neither 'start_timestamp' nor 'end_timestamp' is specified, then 'start_timestamp' will be set to
* the genesis block's timestamp, and 'end_timestamp' will be set to (start_timestamp + query.maxDuration)
* (query.maxDuration is specified in go-bdledger's config file).
* If only 'end_timestamp' is not specified, or (end_timestamp - start_timestamp &gt; query.maxDuration),
* then 'end_timestamp' will be set to (start_timestamp + query.maxDuration).
* If only 'start_timestamp' is not specified, then 'start_timestamp' will be set to (end_timestamp - query.maxDuration).
* In all cases, 'start_timestamp' will never be earlier than the genesis block's timestamp,
* and 'end_timestamp' will never be later than the current timestamp when the node process the query request.
* </pre>
*/
public org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlocksResponse getBlocks(org.bdware.bdledger.api.grpc.pb.QueryProto.BlocksRequest request) {
return io.grpc.stub.ClientCalls.blockingUnaryCall(
getChannel(), getGetBlocksMethod(), getCallOptions(), request);
}
/**
* <pre>
**
* Count all blocks in a ledger, or blocks in a timestamp range
* 查询帐本中的所有区块数量或时间范围内的区块数量
* Requirement: start_timestamp &lt;= end_timestamp
* If neither 'start_timestamp' nor 'end_timestamp' is specified, then count all blocks in the specified ledger.
* If only 'end_timestamp' is not specified, then count all blocks with timestamps later than 'start_timestamp'.
* If only 'start_timestamp' is not specified, then count all blocks with timestamps earlier than 'end_timestamp'.
* In all cases, 'start_timestamp' will never be earlier than the genesis block's timestamp,
* and 'end_timestamp' will never be later than the current timestamp when the node process the query request.
* </pre>
*/
public org.bdware.bdledger.api.grpc.pb.QueryProto.CountBlocksResponse countBlocks(org.bdware.bdledger.api.grpc.pb.QueryProto.BlocksRequest request) {
return io.grpc.stub.ClientCalls.blockingUnaryCall(
getChannel(), getCountBlocksMethod(), getCallOptions(), request);
}
/**
* <pre>
**
* Get recent 'count' blocks (Only support IncludeTransactions=NONE for now)
* 查询最新的 'count' 个区块
* </pre>
*/
public org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlocksResponse getRecentBlocks(org.bdware.bdledger.api.grpc.pb.QueryProto.RecentBlocksRequest request) {
return io.grpc.stub.ClientCalls.blockingUnaryCall(
getChannel(), getGetRecentBlocksMethod(), getCallOptions(), request);
}
/**
* <pre>
**
* Get a transaction identified by its hash
* 查询哈希所指定的事务
* </pre>
*/
public org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByHashResponse getTransactionByHash(org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByHashRequest request) {
return io.grpc.stub.ClientCalls.blockingUnaryCall(
getChannel(), getGetTransactionByHashMethod(), getCallOptions(), request);
}
/**
* <pre>
**
* Get a transaction identified by hash of the block it belongs to and its index inside the block
* 查询所在区块的哈希与其在区块中的index所指定的事务
* </pre>
*/
public org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByBlockHashAndIndexResponse getTransactionByBlockHashAndIndex(org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByBlockHashAndIndexRequest request) {
return io.grpc.stub.ClientCalls.blockingUnaryCall(
getChannel(), getGetTransactionByBlockHashAndIndexMethod(), getCallOptions(), request);
}
/**
* <pre>
**
* Get transactions in a timestamp range
* 查询时间范围内的事务
* 'start_timestamp' and 'end_timestamp' follow the same requirements and rules as in 'GetBlocks'.
* </pre>
*/
public org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionsResponse getTransactions(org.bdware.bdledger.api.grpc.pb.QueryProto.TransactionsRequest request) {
return io.grpc.stub.ClientCalls.blockingUnaryCall(
getChannel(), getGetTransactionsMethod(), getCallOptions(), request);
}
/**
* <pre>
**
* Count all transactions in a ledger, or transactions in a timestamp range
* 查询帐本中的所有事务数量或时间范围内的事务数量
* 'start_timestamp' and 'end_timestamp' follow the same requirements and rules as in 'CountBlocks'.
* </pre>
*/
public org.bdware.bdledger.api.grpc.pb.QueryProto.CountTransactionsResponse countTransactions(org.bdware.bdledger.api.grpc.pb.QueryProto.TransactionsRequest request) {
return io.grpc.stub.ClientCalls.blockingUnaryCall(
getChannel(), getCountTransactionsMethod(), getCallOptions(), request);
}
}
/**
* A stub to allow clients to do limited synchronous rpc calls to service Query.
*/
public static final class QueryBlockingStub
extends io.grpc.stub.AbstractBlockingStub<QueryBlockingStub> {
private QueryBlockingStub( private QueryBlockingStub(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) { io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions); super(channel, callOptions);
@ -751,8 +850,10 @@ public final class QueryGrpc {
} }
/** /**
* A stub to allow clients to do ListenableFuture-style rpc calls to service Query.
*/ */
public static final class QueryFutureStub extends io.grpc.stub.AbstractFutureStub<QueryFutureStub> { public static final class QueryFutureStub
extends io.grpc.stub.AbstractFutureStub<QueryFutureStub> {
private QueryFutureStub( private QueryFutureStub(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) { io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions); super(channel, callOptions);
@ -900,10 +1001,10 @@ public final class QueryGrpc {
io.grpc.stub.ServerCalls.ServerStreamingMethod<Req, Resp>, io.grpc.stub.ServerCalls.ServerStreamingMethod<Req, Resp>,
io.grpc.stub.ServerCalls.ClientStreamingMethod<Req, Resp>, io.grpc.stub.ServerCalls.ClientStreamingMethod<Req, Resp>,
io.grpc.stub.ServerCalls.BidiStreamingMethod<Req, Resp> { io.grpc.stub.ServerCalls.BidiStreamingMethod<Req, Resp> {
private final QueryImplBase serviceImpl; private final AsyncService serviceImpl;
private final int methodId; private final int methodId;
MethodHandlers(QueryImplBase serviceImpl, int methodId) { MethodHandlers(AsyncService serviceImpl, int methodId) {
this.serviceImpl = serviceImpl; this.serviceImpl = serviceImpl;
this.methodId = methodId; this.methodId = methodId;
} }
@ -960,6 +1061,67 @@ public final class QueryGrpc {
} }
} }
public static final io.grpc.ServerServiceDefinition bindService(AsyncService service) {
return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor())
.addMethod(
getGetBlockByHashMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlockByHashRequest,
org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlockByHashResponse>(
service, METHODID_GET_BLOCK_BY_HASH)))
.addMethod(
getGetBlocksMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
org.bdware.bdledger.api.grpc.pb.QueryProto.BlocksRequest,
org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlocksResponse>(
service, METHODID_GET_BLOCKS)))
.addMethod(
getCountBlocksMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
org.bdware.bdledger.api.grpc.pb.QueryProto.BlocksRequest,
org.bdware.bdledger.api.grpc.pb.QueryProto.CountBlocksResponse>(
service, METHODID_COUNT_BLOCKS)))
.addMethod(
getGetRecentBlocksMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
org.bdware.bdledger.api.grpc.pb.QueryProto.RecentBlocksRequest,
org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlocksResponse>(
service, METHODID_GET_RECENT_BLOCKS)))
.addMethod(
getGetTransactionByHashMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByHashRequest,
org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByHashResponse>(
service, METHODID_GET_TRANSACTION_BY_HASH)))
.addMethod(
getGetTransactionByBlockHashAndIndexMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByBlockHashAndIndexRequest,
org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByBlockHashAndIndexResponse>(
service, METHODID_GET_TRANSACTION_BY_BLOCK_HASH_AND_INDEX)))
.addMethod(
getGetTransactionsMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
org.bdware.bdledger.api.grpc.pb.QueryProto.TransactionsRequest,
org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionsResponse>(
service, METHODID_GET_TRANSACTIONS)))
.addMethod(
getCountTransactionsMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
org.bdware.bdledger.api.grpc.pb.QueryProto.TransactionsRequest,
org.bdware.bdledger.api.grpc.pb.QueryProto.CountTransactionsResponse>(
service, METHODID_COUNT_TRANSACTIONS)))
.build();
}
private static abstract class QueryBaseDescriptorSupplier private static abstract class QueryBaseDescriptorSupplier
implements io.grpc.protobuf.ProtoFileDescriptorSupplier, io.grpc.protobuf.ProtoServiceDescriptorSupplier { implements io.grpc.protobuf.ProtoFileDescriptorSupplier, io.grpc.protobuf.ProtoServiceDescriptorSupplier {
QueryBaseDescriptorSupplier() {} QueryBaseDescriptorSupplier() {}
@ -983,9 +1145,9 @@ public final class QueryGrpc {
private static final class QueryMethodDescriptorSupplier private static final class QueryMethodDescriptorSupplier
extends QueryBaseDescriptorSupplier extends QueryBaseDescriptorSupplier
implements io.grpc.protobuf.ProtoMethodDescriptorSupplier { implements io.grpc.protobuf.ProtoMethodDescriptorSupplier {
private final String methodName; private final java.lang.String methodName;
QueryMethodDescriptorSupplier(String methodName) { QueryMethodDescriptorSupplier(java.lang.String methodName) {
this.methodName = methodName; this.methodName = methodName;
} }

File diff suppressed because it is too large Load Diff