feat: update to latest API
This commit is contained in:
parent
bf08b23fde
commit
8bfe33e2d2
@ -83,7 +83,7 @@ with **Maven**
|
||||
## Distributing
|
||||
|
||||
```
|
||||
./gradlew jar
|
||||
./gradlew jar
|
||||
./gradlew shadowJar
|
||||
./gradlew javadoc
|
||||
./gradlew installDist
|
||||
|
2
api
2
api
@ -1 +1 @@
|
||||
Subproject commit 0845a71abad8aee67f858f491c715e4a24106865
|
||||
Subproject commit b74f3fe89c63fe5ed75b0111f3fb71ec0cf86a2d
|
@ -14,7 +14,7 @@ plugins {
|
||||
}
|
||||
|
||||
group 'org.bdware'
|
||||
version 'dev-200922.1278255c'
|
||||
version 'dev-221113'
|
||||
|
||||
sourceCompatibility = JavaVersion.VERSION_1_8
|
||||
|
||||
|
63
src/main/java/com/google/api/AnnotationsProto.java
Normal file
63
src/main/java/com/google/api/AnnotationsProto.java
Normal file
@ -0,0 +1,63 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/api/annotations.proto
|
||||
|
||||
package com.google.api;
|
||||
|
||||
public final class AnnotationsProto {
|
||||
private AnnotationsProto() {}
|
||||
public static void registerAllExtensions(
|
||||
com.google.protobuf.ExtensionRegistryLite registry) {
|
||||
registry.add(com.google.api.AnnotationsProto.http);
|
||||
}
|
||||
|
||||
public static void registerAllExtensions(
|
||||
com.google.protobuf.ExtensionRegistry registry) {
|
||||
registerAllExtensions(
|
||||
(com.google.protobuf.ExtensionRegistryLite) registry);
|
||||
}
|
||||
public static final int HTTP_FIELD_NUMBER = 72295728;
|
||||
/**
|
||||
* <pre>
|
||||
* See `HttpRule`.
|
||||
* </pre>
|
||||
*
|
||||
* <code>extend .google.protobuf.MethodOptions { ... }</code>
|
||||
*/
|
||||
public static final
|
||||
com.google.protobuf.GeneratedMessage.GeneratedExtension<
|
||||
com.google.protobuf.DescriptorProtos.MethodOptions,
|
||||
com.google.api.HttpRule> http = com.google.protobuf.GeneratedMessage
|
||||
.newFileScopedGeneratedExtension(
|
||||
com.google.api.HttpRule.class,
|
||||
com.google.api.HttpRule.getDefaultInstance());
|
||||
|
||||
public static com.google.protobuf.Descriptors.FileDescriptor
|
||||
getDescriptor() {
|
||||
return descriptor;
|
||||
}
|
||||
private static com.google.protobuf.Descriptors.FileDescriptor
|
||||
descriptor;
|
||||
static {
|
||||
java.lang.String[] descriptorData = {
|
||||
"\n\034google/api/annotations.proto\022\ngoogle.a" +
|
||||
"pi\032\025google/api/http.proto\032 google/protob" +
|
||||
"uf/descriptor.proto:E\n\004http\022\036.google.pro" +
|
||||
"tobuf.MethodOptions\030\260\312\274\" \001(\0132\024.google.ap" +
|
||||
"i.HttpRuleBn\n\016com.google.apiB\020Annotation" +
|
||||
"sProtoP\001ZAgoogle.golang.org/genproto/goo" +
|
||||
"gleapis/api/annotations;annotations\242\002\004GA" +
|
||||
"PIb\006proto3"
|
||||
};
|
||||
descriptor = com.google.protobuf.Descriptors.FileDescriptor
|
||||
.internalBuildGeneratedFileFrom(descriptorData,
|
||||
new com.google.protobuf.Descriptors.FileDescriptor[] {
|
||||
com.google.api.HttpProto.getDescriptor(),
|
||||
com.google.protobuf.DescriptorProtos.getDescriptor(),
|
||||
});
|
||||
http.internalInit(descriptor.getExtensions().get(0));
|
||||
com.google.api.HttpProto.getDescriptor();
|
||||
com.google.protobuf.DescriptorProtos.getDescriptor();
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(outer_class_scope)
|
||||
}
|
759
src/main/java/com/google/api/CustomHttpPattern.java
Normal file
759
src/main/java/com/google/api/CustomHttpPattern.java
Normal file
@ -0,0 +1,759 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/api/http.proto
|
||||
|
||||
package com.google.api;
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* A custom pattern is used for defining custom HTTP verb.
|
||||
* </pre>
|
||||
*
|
||||
* Protobuf type {@code google.api.CustomHttpPattern}
|
||||
*/
|
||||
public final class CustomHttpPattern extends
|
||||
com.google.protobuf.GeneratedMessageV3 implements
|
||||
// @@protoc_insertion_point(message_implements:google.api.CustomHttpPattern)
|
||||
CustomHttpPatternOrBuilder {
|
||||
private static final long serialVersionUID = 0L;
|
||||
// Use CustomHttpPattern.newBuilder() to construct.
|
||||
private CustomHttpPattern(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
|
||||
super(builder);
|
||||
}
|
||||
private CustomHttpPattern() {
|
||||
kind_ = "";
|
||||
path_ = "";
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
@SuppressWarnings({"unused"})
|
||||
protected java.lang.Object newInstance(
|
||||
UnusedPrivateParameter unused) {
|
||||
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
|
||||
getDescriptor() {
|
||||
return com.google.api.HttpProto.internal_static_google_api_CustomHttpPattern_descriptor;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return com.google.api.HttpProto.internal_static_google_api_CustomHttpPattern_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
com.google.api.CustomHttpPattern.class, com.google.api.CustomHttpPattern.Builder.class);
|
||||
}
|
||||
|
||||
public static final int KIND_FIELD_NUMBER = 1;
|
||||
private volatile java.lang.Object kind_;
|
||||
/**
|
||||
* <pre>
|
||||
* The name of this custom HTTP verb.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string kind = 1;</code>
|
||||
* @return The kind.
|
||||
*/
|
||||
@java.lang.Override
|
||||
public java.lang.String getKind() {
|
||||
java.lang.Object ref = kind_;
|
||||
if (ref instanceof java.lang.String) {
|
||||
return (java.lang.String) ref;
|
||||
} else {
|
||||
com.google.protobuf.ByteString bs =
|
||||
(com.google.protobuf.ByteString) ref;
|
||||
java.lang.String s = bs.toStringUtf8();
|
||||
kind_ = s;
|
||||
return s;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The name of this custom HTTP verb.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string kind = 1;</code>
|
||||
* @return The bytes for kind.
|
||||
*/
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.ByteString
|
||||
getKindBytes() {
|
||||
java.lang.Object ref = kind_;
|
||||
if (ref instanceof java.lang.String) {
|
||||
com.google.protobuf.ByteString b =
|
||||
com.google.protobuf.ByteString.copyFromUtf8(
|
||||
(java.lang.String) ref);
|
||||
kind_ = b;
|
||||
return b;
|
||||
} else {
|
||||
return (com.google.protobuf.ByteString) ref;
|
||||
}
|
||||
}
|
||||
|
||||
public static final int PATH_FIELD_NUMBER = 2;
|
||||
private volatile java.lang.Object path_;
|
||||
/**
|
||||
* <pre>
|
||||
* The path matched by this custom verb.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string path = 2;</code>
|
||||
* @return The path.
|
||||
*/
|
||||
@java.lang.Override
|
||||
public java.lang.String getPath() {
|
||||
java.lang.Object ref = path_;
|
||||
if (ref instanceof java.lang.String) {
|
||||
return (java.lang.String) ref;
|
||||
} else {
|
||||
com.google.protobuf.ByteString bs =
|
||||
(com.google.protobuf.ByteString) ref;
|
||||
java.lang.String s = bs.toStringUtf8();
|
||||
path_ = s;
|
||||
return s;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The path matched by this custom verb.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string path = 2;</code>
|
||||
* @return The bytes for path.
|
||||
*/
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.ByteString
|
||||
getPathBytes() {
|
||||
java.lang.Object ref = path_;
|
||||
if (ref instanceof java.lang.String) {
|
||||
com.google.protobuf.ByteString b =
|
||||
com.google.protobuf.ByteString.copyFromUtf8(
|
||||
(java.lang.String) ref);
|
||||
path_ = b;
|
||||
return b;
|
||||
} else {
|
||||
return (com.google.protobuf.ByteString) ref;
|
||||
}
|
||||
}
|
||||
|
||||
private byte memoizedIsInitialized = -1;
|
||||
@java.lang.Override
|
||||
public final boolean isInitialized() {
|
||||
byte isInitialized = memoizedIsInitialized;
|
||||
if (isInitialized == 1) return true;
|
||||
if (isInitialized == 0) return false;
|
||||
|
||||
memoizedIsInitialized = 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
||||
throws java.io.IOException {
|
||||
if (!getKindBytes().isEmpty()) {
|
||||
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, kind_);
|
||||
}
|
||||
if (!getPathBytes().isEmpty()) {
|
||||
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, path_);
|
||||
}
|
||||
unknownFields.writeTo(output);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public int getSerializedSize() {
|
||||
int size = memoizedSize;
|
||||
if (size != -1) return size;
|
||||
|
||||
size = 0;
|
||||
if (!getKindBytes().isEmpty()) {
|
||||
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, kind_);
|
||||
}
|
||||
if (!getPathBytes().isEmpty()) {
|
||||
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, path_);
|
||||
}
|
||||
size += unknownFields.getSerializedSize();
|
||||
memoizedSize = size;
|
||||
return size;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public boolean equals(final java.lang.Object obj) {
|
||||
if (obj == this) {
|
||||
return true;
|
||||
}
|
||||
if (!(obj instanceof com.google.api.CustomHttpPattern)) {
|
||||
return super.equals(obj);
|
||||
}
|
||||
com.google.api.CustomHttpPattern other = (com.google.api.CustomHttpPattern) obj;
|
||||
|
||||
if (!getKind()
|
||||
.equals(other.getKind())) return false;
|
||||
if (!getPath()
|
||||
.equals(other.getPath())) return false;
|
||||
if (!unknownFields.equals(other.unknownFields)) return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public int hashCode() {
|
||||
if (memoizedHashCode != 0) {
|
||||
return memoizedHashCode;
|
||||
}
|
||||
int hash = 41;
|
||||
hash = (19 * hash) + getDescriptor().hashCode();
|
||||
hash = (37 * hash) + KIND_FIELD_NUMBER;
|
||||
hash = (53 * hash) + getKind().hashCode();
|
||||
hash = (37 * hash) + PATH_FIELD_NUMBER;
|
||||
hash = (53 * hash) + getPath().hashCode();
|
||||
hash = (29 * hash) + unknownFields.hashCode();
|
||||
memoizedHashCode = hash;
|
||||
return hash;
|
||||
}
|
||||
|
||||
public static com.google.api.CustomHttpPattern parseFrom(
|
||||
java.nio.ByteBuffer data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static com.google.api.CustomHttpPattern parseFrom(
|
||||
java.nio.ByteBuffer data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static com.google.api.CustomHttpPattern parseFrom(
|
||||
com.google.protobuf.ByteString data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static com.google.api.CustomHttpPattern parseFrom(
|
||||
com.google.protobuf.ByteString data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static com.google.api.CustomHttpPattern parseFrom(byte[] data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static com.google.api.CustomHttpPattern parseFrom(
|
||||
byte[] data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static com.google.api.CustomHttpPattern parseFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseWithIOException(PARSER, input);
|
||||
}
|
||||
public static com.google.api.CustomHttpPattern parseFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
||||
}
|
||||
public static com.google.api.CustomHttpPattern parseDelimitedFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseDelimitedWithIOException(PARSER, input);
|
||||
}
|
||||
public static com.google.api.CustomHttpPattern parseDelimitedFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
|
||||
}
|
||||
public static com.google.api.CustomHttpPattern parseFrom(
|
||||
com.google.protobuf.CodedInputStream input)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseWithIOException(PARSER, input);
|
||||
}
|
||||
public static com.google.api.CustomHttpPattern parseFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public Builder newBuilderForType() { return newBuilder(); }
|
||||
public static Builder newBuilder() {
|
||||
return DEFAULT_INSTANCE.toBuilder();
|
||||
}
|
||||
public static Builder newBuilder(com.google.api.CustomHttpPattern prototype) {
|
||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder toBuilder() {
|
||||
return this == DEFAULT_INSTANCE
|
||||
? new Builder() : new Builder().mergeFrom(this);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected Builder newBuilderForType(
|
||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
||||
Builder builder = new Builder(parent);
|
||||
return builder;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* A custom pattern is used for defining custom HTTP verb.
|
||||
* </pre>
|
||||
*
|
||||
* Protobuf type {@code google.api.CustomHttpPattern}
|
||||
*/
|
||||
public static final class Builder extends
|
||||
com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
|
||||
// @@protoc_insertion_point(builder_implements:google.api.CustomHttpPattern)
|
||||
com.google.api.CustomHttpPatternOrBuilder {
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return com.google.api.HttpProto.internal_static_google_api_CustomHttpPattern_descriptor;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return com.google.api.HttpProto.internal_static_google_api_CustomHttpPattern_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
com.google.api.CustomHttpPattern.class, com.google.api.CustomHttpPattern.Builder.class);
|
||||
}
|
||||
|
||||
// Construct using com.google.api.CustomHttpPattern.newBuilder()
|
||||
private Builder() {
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
|
||||
private Builder(
|
||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
||||
super(parent);
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
private void maybeForceBuilderInitialization() {
|
||||
if (com.google.protobuf.GeneratedMessageV3
|
||||
.alwaysUseFieldBuilders) {
|
||||
}
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder clear() {
|
||||
super.clear();
|
||||
kind_ = "";
|
||||
|
||||
path_ = "";
|
||||
|
||||
return this;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptorForType() {
|
||||
return com.google.api.HttpProto.internal_static_google_api_CustomHttpPattern_descriptor;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.api.CustomHttpPattern getDefaultInstanceForType() {
|
||||
return com.google.api.CustomHttpPattern.getDefaultInstance();
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.api.CustomHttpPattern build() {
|
||||
com.google.api.CustomHttpPattern result = buildPartial();
|
||||
if (!result.isInitialized()) {
|
||||
throw newUninitializedMessageException(result);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.api.CustomHttpPattern buildPartial() {
|
||||
com.google.api.CustomHttpPattern result = new com.google.api.CustomHttpPattern(this);
|
||||
result.kind_ = kind_;
|
||||
result.path_ = path_;
|
||||
onBuilt();
|
||||
return result;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public Builder clone() {
|
||||
return super.clone();
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder setField(
|
||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
||||
java.lang.Object value) {
|
||||
return super.setField(field, value);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder clearField(
|
||||
com.google.protobuf.Descriptors.FieldDescriptor field) {
|
||||
return super.clearField(field);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder clearOneof(
|
||||
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
|
||||
return super.clearOneof(oneof);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder setRepeatedField(
|
||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
||||
int index, java.lang.Object value) {
|
||||
return super.setRepeatedField(field, index, value);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder addRepeatedField(
|
||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
||||
java.lang.Object value) {
|
||||
return super.addRepeatedField(field, value);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
||||
if (other instanceof com.google.api.CustomHttpPattern) {
|
||||
return mergeFrom((com.google.api.CustomHttpPattern)other);
|
||||
} else {
|
||||
super.mergeFrom(other);
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
public Builder mergeFrom(com.google.api.CustomHttpPattern other) {
|
||||
if (other == com.google.api.CustomHttpPattern.getDefaultInstance()) return this;
|
||||
if (!other.getKind().isEmpty()) {
|
||||
kind_ = other.kind_;
|
||||
onChanged();
|
||||
}
|
||||
if (!other.getPath().isEmpty()) {
|
||||
path_ = other.path_;
|
||||
onChanged();
|
||||
}
|
||||
this.mergeUnknownFields(other.unknownFields);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final boolean isInitialized() {
|
||||
return true;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public Builder mergeFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
com.google.api.CustomHttpPattern parsedMessage = null;
|
||||
try {
|
||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
parsedMessage = (com.google.api.CustomHttpPattern) e.getUnfinishedMessage();
|
||||
throw e.unwrapIOException();
|
||||
} finally {
|
||||
if (parsedMessage != null) {
|
||||
mergeFrom(parsedMessage);
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
private java.lang.Object kind_ = "";
|
||||
/**
|
||||
* <pre>
|
||||
* The name of this custom HTTP verb.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string kind = 1;</code>
|
||||
* @return The kind.
|
||||
*/
|
||||
public java.lang.String getKind() {
|
||||
java.lang.Object ref = kind_;
|
||||
if (!(ref instanceof java.lang.String)) {
|
||||
com.google.protobuf.ByteString bs =
|
||||
(com.google.protobuf.ByteString) ref;
|
||||
java.lang.String s = bs.toStringUtf8();
|
||||
kind_ = s;
|
||||
return s;
|
||||
} else {
|
||||
return (java.lang.String) ref;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The name of this custom HTTP verb.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string kind = 1;</code>
|
||||
* @return The bytes for kind.
|
||||
*/
|
||||
public com.google.protobuf.ByteString
|
||||
getKindBytes() {
|
||||
java.lang.Object ref = kind_;
|
||||
if (ref instanceof String) {
|
||||
com.google.protobuf.ByteString b =
|
||||
com.google.protobuf.ByteString.copyFromUtf8(
|
||||
(java.lang.String) ref);
|
||||
kind_ = b;
|
||||
return b;
|
||||
} else {
|
||||
return (com.google.protobuf.ByteString) ref;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The name of this custom HTTP verb.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string kind = 1;</code>
|
||||
* @param value The kind to set.
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder setKind(
|
||||
java.lang.String value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
|
||||
kind_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The name of this custom HTTP verb.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string kind = 1;</code>
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder clearKind() {
|
||||
|
||||
kind_ = getDefaultInstance().getKind();
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The name of this custom HTTP verb.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string kind = 1;</code>
|
||||
* @param value The bytes for kind to set.
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder setKindBytes(
|
||||
com.google.protobuf.ByteString value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
checkByteStringIsUtf8(value);
|
||||
|
||||
kind_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private java.lang.Object path_ = "";
|
||||
/**
|
||||
* <pre>
|
||||
* The path matched by this custom verb.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string path = 2;</code>
|
||||
* @return The path.
|
||||
*/
|
||||
public java.lang.String getPath() {
|
||||
java.lang.Object ref = path_;
|
||||
if (!(ref instanceof java.lang.String)) {
|
||||
com.google.protobuf.ByteString bs =
|
||||
(com.google.protobuf.ByteString) ref;
|
||||
java.lang.String s = bs.toStringUtf8();
|
||||
path_ = s;
|
||||
return s;
|
||||
} else {
|
||||
return (java.lang.String) ref;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The path matched by this custom verb.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string path = 2;</code>
|
||||
* @return The bytes for path.
|
||||
*/
|
||||
public com.google.protobuf.ByteString
|
||||
getPathBytes() {
|
||||
java.lang.Object ref = path_;
|
||||
if (ref instanceof String) {
|
||||
com.google.protobuf.ByteString b =
|
||||
com.google.protobuf.ByteString.copyFromUtf8(
|
||||
(java.lang.String) ref);
|
||||
path_ = b;
|
||||
return b;
|
||||
} else {
|
||||
return (com.google.protobuf.ByteString) ref;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The path matched by this custom verb.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string path = 2;</code>
|
||||
* @param value The path to set.
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder setPath(
|
||||
java.lang.String value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
|
||||
path_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The path matched by this custom verb.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string path = 2;</code>
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder clearPath() {
|
||||
|
||||
path_ = getDefaultInstance().getPath();
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The path matched by this custom verb.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string path = 2;</code>
|
||||
* @param value The bytes for path to set.
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder setPathBytes(
|
||||
com.google.protobuf.ByteString value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
checkByteStringIsUtf8(value);
|
||||
|
||||
path_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
@java.lang.Override
|
||||
public final Builder setUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return super.setUnknownFields(unknownFields);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final Builder mergeUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return super.mergeUnknownFields(unknownFields);
|
||||
}
|
||||
|
||||
|
||||
// @@protoc_insertion_point(builder_scope:google.api.CustomHttpPattern)
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(class_scope:google.api.CustomHttpPattern)
|
||||
private static final com.google.api.CustomHttpPattern DEFAULT_INSTANCE;
|
||||
static {
|
||||
DEFAULT_INSTANCE = new com.google.api.CustomHttpPattern();
|
||||
}
|
||||
|
||||
public static com.google.api.CustomHttpPattern getDefaultInstance() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
private static final com.google.protobuf.Parser<CustomHttpPattern>
|
||||
PARSER = new com.google.protobuf.AbstractParser<CustomHttpPattern>() {
|
||||
@java.lang.Override
|
||||
public CustomHttpPattern parsePartialFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return new CustomHttpPattern(input, extensionRegistry);
|
||||
}
|
||||
};
|
||||
|
||||
public static com.google.protobuf.Parser<CustomHttpPattern> parser() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Parser<CustomHttpPattern> getParserForType() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.api.CustomHttpPattern getDefaultInstanceForType() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
}
|
||||
|
49
src/main/java/com/google/api/CustomHttpPatternOrBuilder.java
Normal file
49
src/main/java/com/google/api/CustomHttpPatternOrBuilder.java
Normal file
@ -0,0 +1,49 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/api/http.proto
|
||||
|
||||
package com.google.api;
|
||||
|
||||
public interface CustomHttpPatternOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:google.api.CustomHttpPattern)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* The name of this custom HTTP verb.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string kind = 1;</code>
|
||||
* @return The kind.
|
||||
*/
|
||||
java.lang.String getKind();
|
||||
/**
|
||||
* <pre>
|
||||
* The name of this custom HTTP verb.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string kind = 1;</code>
|
||||
* @return The bytes for kind.
|
||||
*/
|
||||
com.google.protobuf.ByteString
|
||||
getKindBytes();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* The path matched by this custom verb.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string path = 2;</code>
|
||||
* @return The path.
|
||||
*/
|
||||
java.lang.String getPath();
|
||||
/**
|
||||
* <pre>
|
||||
* The path matched by this custom verb.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string path = 2;</code>
|
||||
* @return The bytes for path.
|
||||
*/
|
||||
com.google.protobuf.ByteString
|
||||
getPathBytes();
|
||||
}
|
994
src/main/java/com/google/api/Http.java
Normal file
994
src/main/java/com/google/api/Http.java
Normal file
@ -0,0 +1,994 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/api/http.proto
|
||||
|
||||
package com.google.api;
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Defines the HTTP configuration for an API service. It contains a list of
|
||||
* [HttpRule][google.api.HttpRule], each specifying the mapping of an RPC method
|
||||
* to one or more HTTP REST API methods.
|
||||
* </pre>
|
||||
*
|
||||
* Protobuf type {@code google.api.Http}
|
||||
*/
|
||||
public final class Http extends
|
||||
com.google.protobuf.GeneratedMessageV3 implements
|
||||
// @@protoc_insertion_point(message_implements:google.api.Http)
|
||||
HttpOrBuilder {
|
||||
private static final long serialVersionUID = 0L;
|
||||
// Use Http.newBuilder() to construct.
|
||||
private Http(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
|
||||
super(builder);
|
||||
}
|
||||
private Http() {
|
||||
rules_ = java.util.Collections.emptyList();
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
@SuppressWarnings({"unused"})
|
||||
protected java.lang.Object newInstance(
|
||||
UnusedPrivateParameter unused) {
|
||||
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
|
||||
getDescriptor() {
|
||||
return com.google.api.HttpProto.internal_static_google_api_Http_descriptor;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return com.google.api.HttpProto.internal_static_google_api_Http_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
com.google.api.Http.class, com.google.api.Http.Builder.class);
|
||||
}
|
||||
|
||||
public static final int RULES_FIELD_NUMBER = 1;
|
||||
private java.util.List<com.google.api.HttpRule> rules_;
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
@java.lang.Override
|
||||
public java.util.List<com.google.api.HttpRule> getRulesList() {
|
||||
return rules_;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
@java.lang.Override
|
||||
public java.util.List<? extends com.google.api.HttpRuleOrBuilder>
|
||||
getRulesOrBuilderList() {
|
||||
return rules_;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
@java.lang.Override
|
||||
public int getRulesCount() {
|
||||
return rules_.size();
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
@java.lang.Override
|
||||
public com.google.api.HttpRule getRules(int index) {
|
||||
return rules_.get(index);
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
@java.lang.Override
|
||||
public com.google.api.HttpRuleOrBuilder getRulesOrBuilder(
|
||||
int index) {
|
||||
return rules_.get(index);
|
||||
}
|
||||
|
||||
public static final int FULLY_DECODE_RESERVED_EXPANSION_FIELD_NUMBER = 2;
|
||||
private boolean fullyDecodeReservedExpansion_;
|
||||
/**
|
||||
* <pre>
|
||||
* 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
|
||||
* left encoded.
|
||||
* The default behavior is to not decode RFC 6570 reserved characters in multi
|
||||
* segment matches.
|
||||
* </pre>
|
||||
*
|
||||
* <code>bool fully_decode_reserved_expansion = 2;</code>
|
||||
* @return The fullyDecodeReservedExpansion.
|
||||
*/
|
||||
@java.lang.Override
|
||||
public boolean getFullyDecodeReservedExpansion() {
|
||||
return fullyDecodeReservedExpansion_;
|
||||
}
|
||||
|
||||
private byte memoizedIsInitialized = -1;
|
||||
@java.lang.Override
|
||||
public final boolean isInitialized() {
|
||||
byte isInitialized = memoizedIsInitialized;
|
||||
if (isInitialized == 1) return true;
|
||||
if (isInitialized == 0) return false;
|
||||
|
||||
memoizedIsInitialized = 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
||||
throws java.io.IOException {
|
||||
for (int i = 0; i < rules_.size(); i++) {
|
||||
output.writeMessage(1, rules_.get(i));
|
||||
}
|
||||
if (fullyDecodeReservedExpansion_ != false) {
|
||||
output.writeBool(2, fullyDecodeReservedExpansion_);
|
||||
}
|
||||
unknownFields.writeTo(output);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public int getSerializedSize() {
|
||||
int size = memoizedSize;
|
||||
if (size != -1) return size;
|
||||
|
||||
size = 0;
|
||||
for (int i = 0; i < rules_.size(); i++) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeMessageSize(1, rules_.get(i));
|
||||
}
|
||||
if (fullyDecodeReservedExpansion_ != false) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeBoolSize(2, fullyDecodeReservedExpansion_);
|
||||
}
|
||||
size += unknownFields.getSerializedSize();
|
||||
memoizedSize = size;
|
||||
return size;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public boolean equals(final java.lang.Object obj) {
|
||||
if (obj == this) {
|
||||
return true;
|
||||
}
|
||||
if (!(obj instanceof com.google.api.Http)) {
|
||||
return super.equals(obj);
|
||||
}
|
||||
com.google.api.Http other = (com.google.api.Http) obj;
|
||||
|
||||
if (!getRulesList()
|
||||
.equals(other.getRulesList())) return false;
|
||||
if (getFullyDecodeReservedExpansion()
|
||||
!= other.getFullyDecodeReservedExpansion()) return false;
|
||||
if (!unknownFields.equals(other.unknownFields)) return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public int hashCode() {
|
||||
if (memoizedHashCode != 0) {
|
||||
return memoizedHashCode;
|
||||
}
|
||||
int hash = 41;
|
||||
hash = (19 * hash) + getDescriptor().hashCode();
|
||||
if (getRulesCount() > 0) {
|
||||
hash = (37 * hash) + RULES_FIELD_NUMBER;
|
||||
hash = (53 * hash) + getRulesList().hashCode();
|
||||
}
|
||||
hash = (37 * hash) + FULLY_DECODE_RESERVED_EXPANSION_FIELD_NUMBER;
|
||||
hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
|
||||
getFullyDecodeReservedExpansion());
|
||||
hash = (29 * hash) + unknownFields.hashCode();
|
||||
memoizedHashCode = hash;
|
||||
return hash;
|
||||
}
|
||||
|
||||
public static com.google.api.Http parseFrom(
|
||||
java.nio.ByteBuffer data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static com.google.api.Http parseFrom(
|
||||
java.nio.ByteBuffer data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static com.google.api.Http parseFrom(
|
||||
com.google.protobuf.ByteString data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static com.google.api.Http parseFrom(
|
||||
com.google.protobuf.ByteString data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static com.google.api.Http parseFrom(byte[] data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static com.google.api.Http parseFrom(
|
||||
byte[] data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static com.google.api.Http parseFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseWithIOException(PARSER, input);
|
||||
}
|
||||
public static com.google.api.Http parseFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
||||
}
|
||||
public static com.google.api.Http parseDelimitedFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseDelimitedWithIOException(PARSER, input);
|
||||
}
|
||||
public static com.google.api.Http parseDelimitedFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
|
||||
}
|
||||
public static com.google.api.Http parseFrom(
|
||||
com.google.protobuf.CodedInputStream input)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseWithIOException(PARSER, input);
|
||||
}
|
||||
public static com.google.api.Http parseFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public Builder newBuilderForType() { return newBuilder(); }
|
||||
public static Builder newBuilder() {
|
||||
return DEFAULT_INSTANCE.toBuilder();
|
||||
}
|
||||
public static Builder newBuilder(com.google.api.Http prototype) {
|
||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder toBuilder() {
|
||||
return this == DEFAULT_INSTANCE
|
||||
? new Builder() : new Builder().mergeFrom(this);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected Builder newBuilderForType(
|
||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
||||
Builder builder = new Builder(parent);
|
||||
return builder;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Defines the HTTP configuration for an API service. It contains a list of
|
||||
* [HttpRule][google.api.HttpRule], each specifying the mapping of an RPC method
|
||||
* to one or more HTTP REST API methods.
|
||||
* </pre>
|
||||
*
|
||||
* Protobuf type {@code google.api.Http}
|
||||
*/
|
||||
public static final class Builder extends
|
||||
com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
|
||||
// @@protoc_insertion_point(builder_implements:google.api.Http)
|
||||
com.google.api.HttpOrBuilder {
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return com.google.api.HttpProto.internal_static_google_api_Http_descriptor;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return com.google.api.HttpProto.internal_static_google_api_Http_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
com.google.api.Http.class, com.google.api.Http.Builder.class);
|
||||
}
|
||||
|
||||
// Construct using com.google.api.Http.newBuilder()
|
||||
private Builder() {
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
|
||||
private Builder(
|
||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
||||
super(parent);
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
private void maybeForceBuilderInitialization() {
|
||||
if (com.google.protobuf.GeneratedMessageV3
|
||||
.alwaysUseFieldBuilders) {
|
||||
getRulesFieldBuilder();
|
||||
}
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder clear() {
|
||||
super.clear();
|
||||
if (rulesBuilder_ == null) {
|
||||
rules_ = java.util.Collections.emptyList();
|
||||
bitField0_ = (bitField0_ & ~0x00000001);
|
||||
} else {
|
||||
rulesBuilder_.clear();
|
||||
}
|
||||
fullyDecodeReservedExpansion_ = false;
|
||||
|
||||
return this;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptorForType() {
|
||||
return com.google.api.HttpProto.internal_static_google_api_Http_descriptor;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.api.Http getDefaultInstanceForType() {
|
||||
return com.google.api.Http.getDefaultInstance();
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.api.Http build() {
|
||||
com.google.api.Http result = buildPartial();
|
||||
if (!result.isInitialized()) {
|
||||
throw newUninitializedMessageException(result);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.api.Http buildPartial() {
|
||||
com.google.api.Http result = new com.google.api.Http(this);
|
||||
int from_bitField0_ = bitField0_;
|
||||
if (rulesBuilder_ == null) {
|
||||
if (((bitField0_ & 0x00000001) != 0)) {
|
||||
rules_ = java.util.Collections.unmodifiableList(rules_);
|
||||
bitField0_ = (bitField0_ & ~0x00000001);
|
||||
}
|
||||
result.rules_ = rules_;
|
||||
} else {
|
||||
result.rules_ = rulesBuilder_.build();
|
||||
}
|
||||
result.fullyDecodeReservedExpansion_ = fullyDecodeReservedExpansion_;
|
||||
onBuilt();
|
||||
return result;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public Builder clone() {
|
||||
return super.clone();
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder setField(
|
||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
||||
java.lang.Object value) {
|
||||
return super.setField(field, value);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder clearField(
|
||||
com.google.protobuf.Descriptors.FieldDescriptor field) {
|
||||
return super.clearField(field);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder clearOneof(
|
||||
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
|
||||
return super.clearOneof(oneof);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder setRepeatedField(
|
||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
||||
int index, java.lang.Object value) {
|
||||
return super.setRepeatedField(field, index, value);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder addRepeatedField(
|
||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
||||
java.lang.Object value) {
|
||||
return super.addRepeatedField(field, value);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
||||
if (other instanceof com.google.api.Http) {
|
||||
return mergeFrom((com.google.api.Http)other);
|
||||
} else {
|
||||
super.mergeFrom(other);
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
public Builder mergeFrom(com.google.api.Http other) {
|
||||
if (other == com.google.api.Http.getDefaultInstance()) return this;
|
||||
if (rulesBuilder_ == null) {
|
||||
if (!other.rules_.isEmpty()) {
|
||||
if (rules_.isEmpty()) {
|
||||
rules_ = other.rules_;
|
||||
bitField0_ = (bitField0_ & ~0x00000001);
|
||||
} else {
|
||||
ensureRulesIsMutable();
|
||||
rules_.addAll(other.rules_);
|
||||
}
|
||||
onChanged();
|
||||
}
|
||||
} else {
|
||||
if (!other.rules_.isEmpty()) {
|
||||
if (rulesBuilder_.isEmpty()) {
|
||||
rulesBuilder_.dispose();
|
||||
rulesBuilder_ = null;
|
||||
rules_ = other.rules_;
|
||||
bitField0_ = (bitField0_ & ~0x00000001);
|
||||
rulesBuilder_ =
|
||||
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
|
||||
getRulesFieldBuilder() : null;
|
||||
} else {
|
||||
rulesBuilder_.addAllMessages(other.rules_);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (other.getFullyDecodeReservedExpansion() != false) {
|
||||
setFullyDecodeReservedExpansion(other.getFullyDecodeReservedExpansion());
|
||||
}
|
||||
this.mergeUnknownFields(other.unknownFields);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final boolean isInitialized() {
|
||||
return true;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public Builder mergeFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
com.google.api.Http parsedMessage = null;
|
||||
try {
|
||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
parsedMessage = (com.google.api.Http) e.getUnfinishedMessage();
|
||||
throw e.unwrapIOException();
|
||||
} finally {
|
||||
if (parsedMessage != null) {
|
||||
mergeFrom(parsedMessage);
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
private int bitField0_;
|
||||
|
||||
private java.util.List<com.google.api.HttpRule> rules_ =
|
||||
java.util.Collections.emptyList();
|
||||
private void ensureRulesIsMutable() {
|
||||
if (!((bitField0_ & 0x00000001) != 0)) {
|
||||
rules_ = new java.util.ArrayList<com.google.api.HttpRule>(rules_);
|
||||
bitField0_ |= 0x00000001;
|
||||
}
|
||||
}
|
||||
|
||||
private com.google.protobuf.RepeatedFieldBuilderV3<
|
||||
com.google.api.HttpRule, com.google.api.HttpRule.Builder, com.google.api.HttpRuleOrBuilder> rulesBuilder_;
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
public java.util.List<com.google.api.HttpRule> getRulesList() {
|
||||
if (rulesBuilder_ == null) {
|
||||
return java.util.Collections.unmodifiableList(rules_);
|
||||
} else {
|
||||
return rulesBuilder_.getMessageList();
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
public int getRulesCount() {
|
||||
if (rulesBuilder_ == null) {
|
||||
return rules_.size();
|
||||
} else {
|
||||
return rulesBuilder_.getCount();
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
public com.google.api.HttpRule getRules(int index) {
|
||||
if (rulesBuilder_ == null) {
|
||||
return rules_.get(index);
|
||||
} else {
|
||||
return rulesBuilder_.getMessage(index);
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
public Builder setRules(
|
||||
int index, com.google.api.HttpRule value) {
|
||||
if (rulesBuilder_ == null) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
ensureRulesIsMutable();
|
||||
rules_.set(index, value);
|
||||
onChanged();
|
||||
} else {
|
||||
rulesBuilder_.setMessage(index, value);
|
||||
}
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
public Builder setRules(
|
||||
int index, com.google.api.HttpRule.Builder builderForValue) {
|
||||
if (rulesBuilder_ == null) {
|
||||
ensureRulesIsMutable();
|
||||
rules_.set(index, builderForValue.build());
|
||||
onChanged();
|
||||
} else {
|
||||
rulesBuilder_.setMessage(index, builderForValue.build());
|
||||
}
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
public Builder addRules(com.google.api.HttpRule value) {
|
||||
if (rulesBuilder_ == null) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
ensureRulesIsMutable();
|
||||
rules_.add(value);
|
||||
onChanged();
|
||||
} else {
|
||||
rulesBuilder_.addMessage(value);
|
||||
}
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
public Builder addRules(
|
||||
int index, com.google.api.HttpRule value) {
|
||||
if (rulesBuilder_ == null) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
ensureRulesIsMutable();
|
||||
rules_.add(index, value);
|
||||
onChanged();
|
||||
} else {
|
||||
rulesBuilder_.addMessage(index, value);
|
||||
}
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
public Builder addRules(
|
||||
com.google.api.HttpRule.Builder builderForValue) {
|
||||
if (rulesBuilder_ == null) {
|
||||
ensureRulesIsMutable();
|
||||
rules_.add(builderForValue.build());
|
||||
onChanged();
|
||||
} else {
|
||||
rulesBuilder_.addMessage(builderForValue.build());
|
||||
}
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
public Builder addRules(
|
||||
int index, com.google.api.HttpRule.Builder builderForValue) {
|
||||
if (rulesBuilder_ == null) {
|
||||
ensureRulesIsMutable();
|
||||
rules_.add(index, builderForValue.build());
|
||||
onChanged();
|
||||
} else {
|
||||
rulesBuilder_.addMessage(index, builderForValue.build());
|
||||
}
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
public Builder addAllRules(
|
||||
java.lang.Iterable<? extends com.google.api.HttpRule> values) {
|
||||
if (rulesBuilder_ == null) {
|
||||
ensureRulesIsMutable();
|
||||
com.google.protobuf.AbstractMessageLite.Builder.addAll(
|
||||
values, rules_);
|
||||
onChanged();
|
||||
} else {
|
||||
rulesBuilder_.addAllMessages(values);
|
||||
}
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
public Builder clearRules() {
|
||||
if (rulesBuilder_ == null) {
|
||||
rules_ = java.util.Collections.emptyList();
|
||||
bitField0_ = (bitField0_ & ~0x00000001);
|
||||
onChanged();
|
||||
} else {
|
||||
rulesBuilder_.clear();
|
||||
}
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
public Builder removeRules(int index) {
|
||||
if (rulesBuilder_ == null) {
|
||||
ensureRulesIsMutable();
|
||||
rules_.remove(index);
|
||||
onChanged();
|
||||
} else {
|
||||
rulesBuilder_.remove(index);
|
||||
}
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
public com.google.api.HttpRule.Builder getRulesBuilder(
|
||||
int index) {
|
||||
return getRulesFieldBuilder().getBuilder(index);
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
public com.google.api.HttpRuleOrBuilder getRulesOrBuilder(
|
||||
int index) {
|
||||
if (rulesBuilder_ == null) {
|
||||
return rules_.get(index); } else {
|
||||
return rulesBuilder_.getMessageOrBuilder(index);
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
public java.util.List<? extends com.google.api.HttpRuleOrBuilder>
|
||||
getRulesOrBuilderList() {
|
||||
if (rulesBuilder_ != null) {
|
||||
return rulesBuilder_.getMessageOrBuilderList();
|
||||
} else {
|
||||
return java.util.Collections.unmodifiableList(rules_);
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
public com.google.api.HttpRule.Builder addRulesBuilder() {
|
||||
return getRulesFieldBuilder().addBuilder(
|
||||
com.google.api.HttpRule.getDefaultInstance());
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
public com.google.api.HttpRule.Builder addRulesBuilder(
|
||||
int index) {
|
||||
return getRulesFieldBuilder().addBuilder(
|
||||
index, com.google.api.HttpRule.getDefaultInstance());
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
public java.util.List<com.google.api.HttpRule.Builder>
|
||||
getRulesBuilderList() {
|
||||
return getRulesFieldBuilder().getBuilderList();
|
||||
}
|
||||
private com.google.protobuf.RepeatedFieldBuilderV3<
|
||||
com.google.api.HttpRule, com.google.api.HttpRule.Builder, com.google.api.HttpRuleOrBuilder>
|
||||
getRulesFieldBuilder() {
|
||||
if (rulesBuilder_ == null) {
|
||||
rulesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
|
||||
com.google.api.HttpRule, com.google.api.HttpRule.Builder, com.google.api.HttpRuleOrBuilder>(
|
||||
rules_,
|
||||
((bitField0_ & 0x00000001) != 0),
|
||||
getParentForChildren(),
|
||||
isClean());
|
||||
rules_ = null;
|
||||
}
|
||||
return rulesBuilder_;
|
||||
}
|
||||
|
||||
private boolean fullyDecodeReservedExpansion_ ;
|
||||
/**
|
||||
* <pre>
|
||||
* 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
|
||||
* left encoded.
|
||||
* The default behavior is to not decode RFC 6570 reserved characters in multi
|
||||
* segment matches.
|
||||
* </pre>
|
||||
*
|
||||
* <code>bool fully_decode_reserved_expansion = 2;</code>
|
||||
* @return The fullyDecodeReservedExpansion.
|
||||
*/
|
||||
@java.lang.Override
|
||||
public boolean getFullyDecodeReservedExpansion() {
|
||||
return fullyDecodeReservedExpansion_;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 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
|
||||
* left encoded.
|
||||
* The default behavior is to not decode RFC 6570 reserved characters in multi
|
||||
* segment matches.
|
||||
* </pre>
|
||||
*
|
||||
* <code>bool fully_decode_reserved_expansion = 2;</code>
|
||||
* @param value The fullyDecodeReservedExpansion to set.
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder setFullyDecodeReservedExpansion(boolean value) {
|
||||
|
||||
fullyDecodeReservedExpansion_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 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
|
||||
* left encoded.
|
||||
* The default behavior is to not decode RFC 6570 reserved characters in multi
|
||||
* segment matches.
|
||||
* </pre>
|
||||
*
|
||||
* <code>bool fully_decode_reserved_expansion = 2;</code>
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder clearFullyDecodeReservedExpansion() {
|
||||
|
||||
fullyDecodeReservedExpansion_ = false;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
@java.lang.Override
|
||||
public final Builder setUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return super.setUnknownFields(unknownFields);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final Builder mergeUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return super.mergeUnknownFields(unknownFields);
|
||||
}
|
||||
|
||||
|
||||
// @@protoc_insertion_point(builder_scope:google.api.Http)
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(class_scope:google.api.Http)
|
||||
private static final com.google.api.Http DEFAULT_INSTANCE;
|
||||
static {
|
||||
DEFAULT_INSTANCE = new com.google.api.Http();
|
||||
}
|
||||
|
||||
public static com.google.api.Http getDefaultInstance() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
private static final com.google.protobuf.Parser<Http>
|
||||
PARSER = new com.google.protobuf.AbstractParser<Http>() {
|
||||
@java.lang.Override
|
||||
public Http parsePartialFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return new Http(input, extensionRegistry);
|
||||
}
|
||||
};
|
||||
|
||||
public static com.google.protobuf.Parser<Http> parser() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Parser<Http> getParserForType() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.api.Http getDefaultInstanceForType() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
}
|
||||
|
1199
src/main/java/com/google/api/HttpBody.java
Normal file
1199
src/main/java/com/google/api/HttpBody.java
Normal file
File diff suppressed because it is too large
Load Diff
88
src/main/java/com/google/api/HttpBodyOrBuilder.java
Normal file
88
src/main/java/com/google/api/HttpBodyOrBuilder.java
Normal file
@ -0,0 +1,88 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/api/httpbody.proto
|
||||
|
||||
package com.google.api;
|
||||
|
||||
public interface HttpBodyOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:google.api.HttpBody)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* The HTTP Content-Type header value specifying the content type of the body.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string content_type = 1;</code>
|
||||
* @return The contentType.
|
||||
*/
|
||||
java.lang.String getContentType();
|
||||
/**
|
||||
* <pre>
|
||||
* The HTTP Content-Type header value specifying the content type of the body.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string content_type = 1;</code>
|
||||
* @return The bytes for contentType.
|
||||
*/
|
||||
com.google.protobuf.ByteString
|
||||
getContentTypeBytes();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* The HTTP request/response body as raw binary.
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes data = 2;</code>
|
||||
* @return The data.
|
||||
*/
|
||||
com.google.protobuf.ByteString getData();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Application specific response metadata. Must be set in the first response
|
||||
* for streaming APIs.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.protobuf.Any extensions = 3;</code>
|
||||
*/
|
||||
java.util.List<com.google.protobuf.Any>
|
||||
getExtensionsList();
|
||||
/**
|
||||
* <pre>
|
||||
* Application specific response metadata. Must be set in the first response
|
||||
* for streaming APIs.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.protobuf.Any extensions = 3;</code>
|
||||
*/
|
||||
com.google.protobuf.Any getExtensions(int index);
|
||||
/**
|
||||
* <pre>
|
||||
* Application specific response metadata. Must be set in the first response
|
||||
* for streaming APIs.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.protobuf.Any extensions = 3;</code>
|
||||
*/
|
||||
int getExtensionsCount();
|
||||
/**
|
||||
* <pre>
|
||||
* Application specific response metadata. Must be set in the first response
|
||||
* for streaming APIs.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.protobuf.Any extensions = 3;</code>
|
||||
*/
|
||||
java.util.List<? extends com.google.protobuf.AnyOrBuilder>
|
||||
getExtensionsOrBuilderList();
|
||||
/**
|
||||
* <pre>
|
||||
* Application specific response metadata. Must be set in the first response
|
||||
* for streaming APIs.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.protobuf.Any extensions = 3;</code>
|
||||
*/
|
||||
com.google.protobuf.AnyOrBuilder getExtensionsOrBuilder(
|
||||
int index);
|
||||
}
|
54
src/main/java/com/google/api/HttpBodyProto.java
Normal file
54
src/main/java/com/google/api/HttpBodyProto.java
Normal file
@ -0,0 +1,54 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/api/httpbody.proto
|
||||
|
||||
package com.google.api;
|
||||
|
||||
public final class HttpBodyProto {
|
||||
private HttpBodyProto() {}
|
||||
public static void registerAllExtensions(
|
||||
com.google.protobuf.ExtensionRegistryLite registry) {
|
||||
}
|
||||
|
||||
public static void registerAllExtensions(
|
||||
com.google.protobuf.ExtensionRegistry registry) {
|
||||
registerAllExtensions(
|
||||
(com.google.protobuf.ExtensionRegistryLite) registry);
|
||||
}
|
||||
static final com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_google_api_HttpBody_descriptor;
|
||||
static final
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internal_static_google_api_HttpBody_fieldAccessorTable;
|
||||
|
||||
public static com.google.protobuf.Descriptors.FileDescriptor
|
||||
getDescriptor() {
|
||||
return descriptor;
|
||||
}
|
||||
private static com.google.protobuf.Descriptors.FileDescriptor
|
||||
descriptor;
|
||||
static {
|
||||
java.lang.String[] descriptorData = {
|
||||
"\n\031google/api/httpbody.proto\022\ngoogle.api\032" +
|
||||
"\031google/protobuf/any.proto\"X\n\010HttpBody\022\024" +
|
||||
"\n\014content_type\030\001 \001(\t\022\014\n\004data\030\002 \001(\014\022(\n\nex" +
|
||||
"tensions\030\003 \003(\0132\024.google.protobuf.AnyBh\n\016" +
|
||||
"com.google.apiB\rHttpBodyProtoP\001Z;google." +
|
||||
"golang.org/genproto/googleapis/api/httpb" +
|
||||
"ody;httpbody\370\001\001\242\002\004GAPIb\006proto3"
|
||||
};
|
||||
descriptor = com.google.protobuf.Descriptors.FileDescriptor
|
||||
.internalBuildGeneratedFileFrom(descriptorData,
|
||||
new com.google.protobuf.Descriptors.FileDescriptor[] {
|
||||
com.google.protobuf.AnyProto.getDescriptor(),
|
||||
});
|
||||
internal_static_google_api_HttpBody_descriptor =
|
||||
getDescriptor().getMessageTypes().get(0);
|
||||
internal_static_google_api_HttpBody_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
||||
internal_static_google_api_HttpBody_descriptor,
|
||||
new java.lang.String[] { "ContentType", "Data", "Extensions", });
|
||||
com.google.protobuf.AnyProto.getDescriptor();
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(outer_class_scope)
|
||||
}
|
72
src/main/java/com/google/api/HttpOrBuilder.java
Normal file
72
src/main/java/com/google/api/HttpOrBuilder.java
Normal file
@ -0,0 +1,72 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/api/http.proto
|
||||
|
||||
package com.google.api;
|
||||
|
||||
public interface HttpOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:google.api.Http)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
java.util.List<com.google.api.HttpRule>
|
||||
getRulesList();
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
com.google.api.HttpRule getRules(int index);
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
int getRulesCount();
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
java.util.List<? extends com.google.api.HttpRuleOrBuilder>
|
||||
getRulesOrBuilderList();
|
||||
/**
|
||||
* <pre>
|
||||
* A list of HTTP configuration rules that apply to individual API methods.
|
||||
* **NOTE:** All service configuration rules follow "last one wins" order.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule rules = 1;</code>
|
||||
*/
|
||||
com.google.api.HttpRuleOrBuilder getRulesOrBuilder(
|
||||
int index);
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* 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
|
||||
* left encoded.
|
||||
* The default behavior is to not decode RFC 6570 reserved characters in multi
|
||||
* segment matches.
|
||||
* </pre>
|
||||
*
|
||||
* <code>bool fully_decode_reserved_expansion = 2;</code>
|
||||
* @return The fullyDecodeReservedExpansion.
|
||||
*/
|
||||
boolean getFullyDecodeReservedExpansion();
|
||||
}
|
81
src/main/java/com/google/api/HttpProto.java
Normal file
81
src/main/java/com/google/api/HttpProto.java
Normal file
@ -0,0 +1,81 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/api/http.proto
|
||||
|
||||
package com.google.api;
|
||||
|
||||
public final class HttpProto {
|
||||
private HttpProto() {}
|
||||
public static void registerAllExtensions(
|
||||
com.google.protobuf.ExtensionRegistryLite registry) {
|
||||
}
|
||||
|
||||
public static void registerAllExtensions(
|
||||
com.google.protobuf.ExtensionRegistry registry) {
|
||||
registerAllExtensions(
|
||||
(com.google.protobuf.ExtensionRegistryLite) registry);
|
||||
}
|
||||
static final com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_google_api_Http_descriptor;
|
||||
static final
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internal_static_google_api_Http_fieldAccessorTable;
|
||||
static final com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_google_api_HttpRule_descriptor;
|
||||
static final
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internal_static_google_api_HttpRule_fieldAccessorTable;
|
||||
static final com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_google_api_CustomHttpPattern_descriptor;
|
||||
static final
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internal_static_google_api_CustomHttpPattern_fieldAccessorTable;
|
||||
|
||||
public static com.google.protobuf.Descriptors.FileDescriptor
|
||||
getDescriptor() {
|
||||
return descriptor;
|
||||
}
|
||||
private static com.google.protobuf.Descriptors.FileDescriptor
|
||||
descriptor;
|
||||
static {
|
||||
java.lang.String[] descriptorData = {
|
||||
"\n\025google/api/http.proto\022\ngoogle.api\"T\n\004H" +
|
||||
"ttp\022#\n\005rules\030\001 \003(\0132\024.google.api.HttpRule" +
|
||||
"\022\'\n\037fully_decode_reserved_expansion\030\002 \001(" +
|
||||
"\010\"\201\002\n\010HttpRule\022\020\n\010selector\030\001 \001(\t\022\r\n\003get\030" +
|
||||
"\002 \001(\tH\000\022\r\n\003put\030\003 \001(\tH\000\022\016\n\004post\030\004 \001(\tH\000\022\020" +
|
||||
"\n\006delete\030\005 \001(\tH\000\022\017\n\005patch\030\006 \001(\tH\000\022/\n\006cus" +
|
||||
"tom\030\010 \001(\0132\035.google.api.CustomHttpPattern" +
|
||||
"H\000\022\014\n\004body\030\007 \001(\t\022\025\n\rresponse_body\030\014 \001(\t\022" +
|
||||
"1\n\023additional_bindings\030\013 \003(\0132\024.google.ap" +
|
||||
"i.HttpRuleB\t\n\007pattern\"/\n\021CustomHttpPatte" +
|
||||
"rn\022\014\n\004kind\030\001 \001(\t\022\014\n\004path\030\002 \001(\tBj\n\016com.go" +
|
||||
"ogle.apiB\tHttpProtoP\001ZAgoogle.golang.org" +
|
||||
"/genproto/googleapis/api/annotations;ann" +
|
||||
"otations\370\001\001\242\002\004GAPIb\006proto3"
|
||||
};
|
||||
descriptor = com.google.protobuf.Descriptors.FileDescriptor
|
||||
.internalBuildGeneratedFileFrom(descriptorData,
|
||||
new com.google.protobuf.Descriptors.FileDescriptor[] {
|
||||
});
|
||||
internal_static_google_api_Http_descriptor =
|
||||
getDescriptor().getMessageTypes().get(0);
|
||||
internal_static_google_api_Http_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
||||
internal_static_google_api_Http_descriptor,
|
||||
new java.lang.String[] { "Rules", "FullyDecodeReservedExpansion", });
|
||||
internal_static_google_api_HttpRule_descriptor =
|
||||
getDescriptor().getMessageTypes().get(1);
|
||||
internal_static_google_api_HttpRule_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
||||
internal_static_google_api_HttpRule_descriptor,
|
||||
new java.lang.String[] { "Selector", "Get", "Put", "Post", "Delete", "Patch", "Custom", "Body", "ResponseBody", "AdditionalBindings", "Pattern", });
|
||||
internal_static_google_api_CustomHttpPattern_descriptor =
|
||||
getDescriptor().getMessageTypes().get(2);
|
||||
internal_static_google_api_CustomHttpPattern_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
||||
internal_static_google_api_CustomHttpPattern_descriptor,
|
||||
new java.lang.String[] { "Kind", "Path", });
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(outer_class_scope)
|
||||
}
|
3134
src/main/java/com/google/api/HttpRule.java
Normal file
3134
src/main/java/com/google/api/HttpRule.java
Normal file
File diff suppressed because it is too large
Load Diff
273
src/main/java/com/google/api/HttpRuleOrBuilder.java
Normal file
273
src/main/java/com/google/api/HttpRuleOrBuilder.java
Normal file
@ -0,0 +1,273 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/api/http.proto
|
||||
|
||||
package com.google.api;
|
||||
|
||||
public interface HttpRuleOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:google.api.HttpRule)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Selects methods to which this rule applies.
|
||||
* Refer to [selector][google.api.DocumentationRule.selector] for syntax details.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string selector = 1;</code>
|
||||
* @return The selector.
|
||||
*/
|
||||
java.lang.String getSelector();
|
||||
/**
|
||||
* <pre>
|
||||
* Selects methods to which this rule applies.
|
||||
* Refer to [selector][google.api.DocumentationRule.selector] for syntax details.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string selector = 1;</code>
|
||||
* @return The bytes for selector.
|
||||
*/
|
||||
com.google.protobuf.ByteString
|
||||
getSelectorBytes();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Used for listing and getting information about resources.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string get = 2;</code>
|
||||
* @return The get.
|
||||
*/
|
||||
java.lang.String getGet();
|
||||
/**
|
||||
* <pre>
|
||||
* Used for listing and getting information about resources.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string get = 2;</code>
|
||||
* @return The bytes for get.
|
||||
*/
|
||||
com.google.protobuf.ByteString
|
||||
getGetBytes();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Used for updating a resource.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string put = 3;</code>
|
||||
* @return The put.
|
||||
*/
|
||||
java.lang.String getPut();
|
||||
/**
|
||||
* <pre>
|
||||
* Used for updating a resource.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string put = 3;</code>
|
||||
* @return The bytes for put.
|
||||
*/
|
||||
com.google.protobuf.ByteString
|
||||
getPutBytes();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Used for creating a resource.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string post = 4;</code>
|
||||
* @return The post.
|
||||
*/
|
||||
java.lang.String getPost();
|
||||
/**
|
||||
* <pre>
|
||||
* Used for creating a resource.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string post = 4;</code>
|
||||
* @return The bytes for post.
|
||||
*/
|
||||
com.google.protobuf.ByteString
|
||||
getPostBytes();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Used for deleting a resource.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string delete = 5;</code>
|
||||
* @return The delete.
|
||||
*/
|
||||
java.lang.String getDelete();
|
||||
/**
|
||||
* <pre>
|
||||
* Used for deleting a resource.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string delete = 5;</code>
|
||||
* @return The bytes for delete.
|
||||
*/
|
||||
com.google.protobuf.ByteString
|
||||
getDeleteBytes();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Used for updating a resource.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string patch = 6;</code>
|
||||
* @return The patch.
|
||||
*/
|
||||
java.lang.String getPatch();
|
||||
/**
|
||||
* <pre>
|
||||
* Used for updating a resource.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string patch = 6;</code>
|
||||
* @return The bytes for patch.
|
||||
*/
|
||||
com.google.protobuf.ByteString
|
||||
getPatchBytes();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* The custom pattern is used for specifying an HTTP method that is not
|
||||
* included in the `pattern` field, such as HEAD, or "*" to leave the
|
||||
* HTTP method unspecified for this rule. The wild-card rule is useful
|
||||
* for services that provide content to Web (HTML) clients.
|
||||
* </pre>
|
||||
*
|
||||
* <code>.google.api.CustomHttpPattern custom = 8;</code>
|
||||
* @return Whether the custom field is set.
|
||||
*/
|
||||
boolean hasCustom();
|
||||
/**
|
||||
* <pre>
|
||||
* The custom pattern is used for specifying an HTTP method that is not
|
||||
* included in the `pattern` field, such as HEAD, or "*" to leave the
|
||||
* HTTP method unspecified for this rule. The wild-card rule is useful
|
||||
* for services that provide content to Web (HTML) clients.
|
||||
* </pre>
|
||||
*
|
||||
* <code>.google.api.CustomHttpPattern custom = 8;</code>
|
||||
* @return The custom.
|
||||
*/
|
||||
com.google.api.CustomHttpPattern getCustom();
|
||||
/**
|
||||
* <pre>
|
||||
* The custom pattern is used for specifying an HTTP method that is not
|
||||
* included in the `pattern` field, such as HEAD, or "*" to leave the
|
||||
* HTTP method unspecified for this rule. The wild-card rule is useful
|
||||
* for services that provide content to Web (HTML) clients.
|
||||
* </pre>
|
||||
*
|
||||
* <code>.google.api.CustomHttpPattern custom = 8;</code>
|
||||
*/
|
||||
com.google.api.CustomHttpPatternOrBuilder getCustomOrBuilder();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* The name of the request field whose value is mapped to the HTTP body, or
|
||||
* `*` for mapping all fields not captured by the path pattern to the HTTP
|
||||
* body. NOTE: the referred field must not be a repeated field and must be
|
||||
* present at the top-level of request message type.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string body = 7;</code>
|
||||
* @return The body.
|
||||
*/
|
||||
java.lang.String getBody();
|
||||
/**
|
||||
* <pre>
|
||||
* The name of the request field whose value is mapped to the HTTP body, or
|
||||
* `*` for mapping all fields not captured by the path pattern to the HTTP
|
||||
* body. NOTE: the referred field must not be a repeated field and must be
|
||||
* present at the top-level of request message type.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string body = 7;</code>
|
||||
* @return The bytes for body.
|
||||
*/
|
||||
com.google.protobuf.ByteString
|
||||
getBodyBytes();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Optional. The name of the response field whose value is mapped to the HTTP
|
||||
* body of response. Other response fields are ignored. When
|
||||
* not set, the response message will be used as HTTP body of response.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string response_body = 12;</code>
|
||||
* @return The responseBody.
|
||||
*/
|
||||
java.lang.String getResponseBody();
|
||||
/**
|
||||
* <pre>
|
||||
* Optional. The name of the response field whose value is mapped to the HTTP
|
||||
* body of response. Other response fields are ignored. When
|
||||
* not set, the response message will be used as HTTP body of response.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string response_body = 12;</code>
|
||||
* @return The bytes for responseBody.
|
||||
*/
|
||||
com.google.protobuf.ByteString
|
||||
getResponseBodyBytes();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Additional HTTP bindings for the selector. Nested bindings must
|
||||
* not contain an `additional_bindings` field themselves (that is,
|
||||
* the nesting may only be one level deep).
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule additional_bindings = 11;</code>
|
||||
*/
|
||||
java.util.List<com.google.api.HttpRule>
|
||||
getAdditionalBindingsList();
|
||||
/**
|
||||
* <pre>
|
||||
* Additional HTTP bindings for the selector. Nested bindings must
|
||||
* not contain an `additional_bindings` field themselves (that is,
|
||||
* the nesting may only be one level deep).
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule additional_bindings = 11;</code>
|
||||
*/
|
||||
com.google.api.HttpRule getAdditionalBindings(int index);
|
||||
/**
|
||||
* <pre>
|
||||
* Additional HTTP bindings for the selector. Nested bindings must
|
||||
* not contain an `additional_bindings` field themselves (that is,
|
||||
* the nesting may only be one level deep).
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule additional_bindings = 11;</code>
|
||||
*/
|
||||
int getAdditionalBindingsCount();
|
||||
/**
|
||||
* <pre>
|
||||
* Additional HTTP bindings for the selector. Nested bindings must
|
||||
* not contain an `additional_bindings` field themselves (that is,
|
||||
* the nesting may only be one level deep).
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule additional_bindings = 11;</code>
|
||||
*/
|
||||
java.util.List<? extends com.google.api.HttpRuleOrBuilder>
|
||||
getAdditionalBindingsOrBuilderList();
|
||||
/**
|
||||
* <pre>
|
||||
* Additional HTTP bindings for the selector. Nested bindings must
|
||||
* not contain an `additional_bindings` field themselves (that is,
|
||||
* the nesting may only be one level deep).
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.api.HttpRule additional_bindings = 11;</code>
|
||||
*/
|
||||
com.google.api.HttpRuleOrBuilder getAdditionalBindingsOrBuilder(
|
||||
int index);
|
||||
|
||||
public com.google.api.HttpRule.PatternCase getPatternCase();
|
||||
}
|
1688
src/main/java/com/google/rpc/BadRequest.java
Normal file
1688
src/main/java/com/google/rpc/BadRequest.java
Normal file
File diff suppressed because it is too large
Load Diff
53
src/main/java/com/google/rpc/BadRequestOrBuilder.java
Normal file
53
src/main/java/com/google/rpc/BadRequestOrBuilder.java
Normal file
@ -0,0 +1,53 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/rpc/error_details.proto
|
||||
|
||||
package com.google.rpc;
|
||||
|
||||
public interface BadRequestOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:google.rpc.BadRequest)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Describes all violations in a client request.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.rpc.BadRequest.FieldViolation field_violations = 1;</code>
|
||||
*/
|
||||
java.util.List<com.google.rpc.BadRequest.FieldViolation>
|
||||
getFieldViolationsList();
|
||||
/**
|
||||
* <pre>
|
||||
* Describes all violations in a client request.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.rpc.BadRequest.FieldViolation field_violations = 1;</code>
|
||||
*/
|
||||
com.google.rpc.BadRequest.FieldViolation getFieldViolations(int index);
|
||||
/**
|
||||
* <pre>
|
||||
* Describes all violations in a client request.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.rpc.BadRequest.FieldViolation field_violations = 1;</code>
|
||||
*/
|
||||
int getFieldViolationsCount();
|
||||
/**
|
||||
* <pre>
|
||||
* Describes all violations in a client request.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.rpc.BadRequest.FieldViolation field_violations = 1;</code>
|
||||
*/
|
||||
java.util.List<? extends com.google.rpc.BadRequest.FieldViolationOrBuilder>
|
||||
getFieldViolationsOrBuilderList();
|
||||
/**
|
||||
* <pre>
|
||||
* Describes all violations in a client request.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.rpc.BadRequest.FieldViolation field_violations = 1;</code>
|
||||
*/
|
||||
com.google.rpc.BadRequest.FieldViolationOrBuilder getFieldViolationsOrBuilder(
|
||||
int index);
|
||||
}
|
550
src/main/java/com/google/rpc/Code.java
Normal file
550
src/main/java/com/google/rpc/Code.java
Normal file
@ -0,0 +1,550 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/rpc/code.proto
|
||||
|
||||
package com.google.rpc;
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* The canonical error codes for Google APIs.
|
||||
* Sometimes multiple error codes may apply. Services should return
|
||||
* the most specific error code that applies. For example, prefer
|
||||
* `OUT_OF_RANGE` over `FAILED_PRECONDITION` if both codes apply.
|
||||
* Similarly prefer `NOT_FOUND` or `ALREADY_EXISTS` over `FAILED_PRECONDITION`.
|
||||
* </pre>
|
||||
*
|
||||
* Protobuf enum {@code google.rpc.Code}
|
||||
*/
|
||||
public enum Code
|
||||
implements com.google.protobuf.ProtocolMessageEnum {
|
||||
/**
|
||||
* <pre>
|
||||
* Not an error; returned on success
|
||||
* HTTP Mapping: 200 OK
|
||||
* </pre>
|
||||
*
|
||||
* <code>OK = 0;</code>
|
||||
*/
|
||||
OK(0),
|
||||
/**
|
||||
* <pre>
|
||||
* The operation was cancelled, typically by the caller.
|
||||
* HTTP Mapping: 499 Client Closed Request
|
||||
* </pre>
|
||||
*
|
||||
* <code>CANCELLED = 1;</code>
|
||||
*/
|
||||
CANCELLED(1),
|
||||
/**
|
||||
* <pre>
|
||||
* Unknown error. For example, this error may be returned when
|
||||
* a `Status` value received from another address space belongs to
|
||||
* an error space that is not known in this address space. Also
|
||||
* errors raised by APIs that do not return enough error information
|
||||
* may be converted to this error.
|
||||
* HTTP Mapping: 500 Internal Server Error
|
||||
* </pre>
|
||||
*
|
||||
* <code>UNKNOWN = 2;</code>
|
||||
*/
|
||||
UNKNOWN(2),
|
||||
/**
|
||||
* <pre>
|
||||
* The client specified an invalid argument. Note that this differs
|
||||
* from `FAILED_PRECONDITION`. `INVALID_ARGUMENT` indicates arguments
|
||||
* that are problematic regardless of the state of the system
|
||||
* (e.g., a malformed file name).
|
||||
* HTTP Mapping: 400 Bad Request
|
||||
* </pre>
|
||||
*
|
||||
* <code>INVALID_ARGUMENT = 3;</code>
|
||||
*/
|
||||
INVALID_ARGUMENT(3),
|
||||
/**
|
||||
* <pre>
|
||||
* The deadline expired before the operation could complete. For operations
|
||||
* that change the state of the system, this error may be returned
|
||||
* even if the operation has completed successfully. For example, a
|
||||
* successful response from a server could have been delayed long
|
||||
* enough for the deadline to expire.
|
||||
* HTTP Mapping: 504 Gateway Timeout
|
||||
* </pre>
|
||||
*
|
||||
* <code>DEADLINE_EXCEEDED = 4;</code>
|
||||
*/
|
||||
DEADLINE_EXCEEDED(4),
|
||||
/**
|
||||
* <pre>
|
||||
* Some requested entity (e.g., file or directory) was not found.
|
||||
* Note to server developers: if a request is denied for an entire class
|
||||
* of users, such as gradual feature rollout or undocumented whitelist,
|
||||
* `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`
|
||||
* must be used.
|
||||
* HTTP Mapping: 404 Not Found
|
||||
* </pre>
|
||||
*
|
||||
* <code>NOT_FOUND = 5;</code>
|
||||
*/
|
||||
NOT_FOUND(5),
|
||||
/**
|
||||
* <pre>
|
||||
* The entity that a client attempted to create (e.g., file or directory)
|
||||
* already exists.
|
||||
* HTTP Mapping: 409 Conflict
|
||||
* </pre>
|
||||
*
|
||||
* <code>ALREADY_EXISTS = 6;</code>
|
||||
*/
|
||||
ALREADY_EXISTS(6),
|
||||
/**
|
||||
* <pre>
|
||||
* The caller does not have permission to execute the specified
|
||||
* operation. `PERMISSION_DENIED` must not be used for rejections
|
||||
* caused by exhausting some resource (use `RESOURCE_EXHAUSTED`
|
||||
* instead for those errors). `PERMISSION_DENIED` must not be
|
||||
* used if the caller can not be identified (use `UNAUTHENTICATED`
|
||||
* instead for those errors). This error code does not imply the
|
||||
* request is valid or the requested entity exists or satisfies
|
||||
* other pre-conditions.
|
||||
* HTTP Mapping: 403 Forbidden
|
||||
* </pre>
|
||||
*
|
||||
* <code>PERMISSION_DENIED = 7;</code>
|
||||
*/
|
||||
PERMISSION_DENIED(7),
|
||||
/**
|
||||
* <pre>
|
||||
* The request does not have valid authentication credentials for the
|
||||
* operation.
|
||||
* HTTP Mapping: 401 Unauthorized
|
||||
* </pre>
|
||||
*
|
||||
* <code>UNAUTHENTICATED = 16;</code>
|
||||
*/
|
||||
UNAUTHENTICATED(16),
|
||||
/**
|
||||
* <pre>
|
||||
* Some resource has been exhausted, perhaps a per-user quota, or
|
||||
* perhaps the entire file system is out of space.
|
||||
* HTTP Mapping: 429 Too Many Requests
|
||||
* </pre>
|
||||
*
|
||||
* <code>RESOURCE_EXHAUSTED = 8;</code>
|
||||
*/
|
||||
RESOURCE_EXHAUSTED(8),
|
||||
/**
|
||||
* <pre>
|
||||
* The operation was rejected because the system is not in a state
|
||||
* required for the operation's execution. For example, the directory
|
||||
* to be deleted is non-empty, an rmdir operation is applied to
|
||||
* a non-directory, etc.
|
||||
* Service implementors can use the following guidelines to decide
|
||||
* between `FAILED_PRECONDITION`, `ABORTED`, and `UNAVAILABLE`:
|
||||
* (a) Use `UNAVAILABLE` if the client can retry just the failing call.
|
||||
* (b) Use `ABORTED` if the client should retry at a higher level
|
||||
* (e.g., when a client-specified test-and-set fails, indicating the
|
||||
* client should restart a read-modify-write sequence).
|
||||
* (c) Use `FAILED_PRECONDITION` if the client should not retry until
|
||||
* the system state has been explicitly fixed. E.g., if an "rmdir"
|
||||
* fails because the directory is non-empty, `FAILED_PRECONDITION`
|
||||
* should be returned since the client should not retry unless
|
||||
* the files are deleted from the directory.
|
||||
* HTTP Mapping: 400 Bad Request
|
||||
* </pre>
|
||||
*
|
||||
* <code>FAILED_PRECONDITION = 9;</code>
|
||||
*/
|
||||
FAILED_PRECONDITION(9),
|
||||
/**
|
||||
* <pre>
|
||||
* The operation was aborted, typically due to a concurrency issue such as
|
||||
* a sequencer check failure or transaction abort.
|
||||
* See the guidelines above for deciding between `FAILED_PRECONDITION`,
|
||||
* `ABORTED`, and `UNAVAILABLE`.
|
||||
* HTTP Mapping: 409 Conflict
|
||||
* </pre>
|
||||
*
|
||||
* <code>ABORTED = 10;</code>
|
||||
*/
|
||||
ABORTED(10),
|
||||
/**
|
||||
* <pre>
|
||||
* The operation was attempted past the valid range. E.g., seeking or
|
||||
* reading past end-of-file.
|
||||
* Unlike `INVALID_ARGUMENT`, this error indicates a problem that may
|
||||
* be fixed if the system state changes. For example, a 32-bit file
|
||||
* 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
|
||||
* `OUT_OF_RANGE` if asked to read from an offset past the current
|
||||
* file size.
|
||||
* There is a fair bit of overlap between `FAILED_PRECONDITION` and
|
||||
* `OUT_OF_RANGE`. We recommend using `OUT_OF_RANGE` (the more specific
|
||||
* 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
|
||||
* they are done.
|
||||
* HTTP Mapping: 400 Bad Request
|
||||
* </pre>
|
||||
*
|
||||
* <code>OUT_OF_RANGE = 11;</code>
|
||||
*/
|
||||
OUT_OF_RANGE(11),
|
||||
/**
|
||||
* <pre>
|
||||
* The operation is not implemented or is not supported/enabled in this
|
||||
* service.
|
||||
* HTTP Mapping: 501 Not Implemented
|
||||
* </pre>
|
||||
*
|
||||
* <code>UNIMPLEMENTED = 12;</code>
|
||||
*/
|
||||
UNIMPLEMENTED(12),
|
||||
/**
|
||||
* <pre>
|
||||
* Internal errors. This means that some invariants expected by the
|
||||
* underlying system have been broken. This error code is reserved
|
||||
* for serious errors.
|
||||
* HTTP Mapping: 500 Internal Server Error
|
||||
* </pre>
|
||||
*
|
||||
* <code>INTERNAL = 13;</code>
|
||||
*/
|
||||
INTERNAL(13),
|
||||
/**
|
||||
* <pre>
|
||||
* The service is currently unavailable. This is most likely a
|
||||
* transient condition, which can be corrected by retrying with
|
||||
* a backoff.
|
||||
* See the guidelines above for deciding between `FAILED_PRECONDITION`,
|
||||
* `ABORTED`, and `UNAVAILABLE`.
|
||||
* HTTP Mapping: 503 Service Unavailable
|
||||
* </pre>
|
||||
*
|
||||
* <code>UNAVAILABLE = 14;</code>
|
||||
*/
|
||||
UNAVAILABLE(14),
|
||||
/**
|
||||
* <pre>
|
||||
* Unrecoverable data loss or corruption.
|
||||
* HTTP Mapping: 500 Internal Server Error
|
||||
* </pre>
|
||||
*
|
||||
* <code>DATA_LOSS = 15;</code>
|
||||
*/
|
||||
DATA_LOSS(15),
|
||||
UNRECOGNIZED(-1),
|
||||
;
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Not an error; returned on success
|
||||
* HTTP Mapping: 200 OK
|
||||
* </pre>
|
||||
*
|
||||
* <code>OK = 0;</code>
|
||||
*/
|
||||
public static final int OK_VALUE = 0;
|
||||
/**
|
||||
* <pre>
|
||||
* The operation was cancelled, typically by the caller.
|
||||
* HTTP Mapping: 499 Client Closed Request
|
||||
* </pre>
|
||||
*
|
||||
* <code>CANCELLED = 1;</code>
|
||||
*/
|
||||
public static final int CANCELLED_VALUE = 1;
|
||||
/**
|
||||
* <pre>
|
||||
* Unknown error. For example, this error may be returned when
|
||||
* a `Status` value received from another address space belongs to
|
||||
* an error space that is not known in this address space. Also
|
||||
* errors raised by APIs that do not return enough error information
|
||||
* may be converted to this error.
|
||||
* HTTP Mapping: 500 Internal Server Error
|
||||
* </pre>
|
||||
*
|
||||
* <code>UNKNOWN = 2;</code>
|
||||
*/
|
||||
public static final int UNKNOWN_VALUE = 2;
|
||||
/**
|
||||
* <pre>
|
||||
* The client specified an invalid argument. Note that this differs
|
||||
* from `FAILED_PRECONDITION`. `INVALID_ARGUMENT` indicates arguments
|
||||
* that are problematic regardless of the state of the system
|
||||
* (e.g., a malformed file name).
|
||||
* HTTP Mapping: 400 Bad Request
|
||||
* </pre>
|
||||
*
|
||||
* <code>INVALID_ARGUMENT = 3;</code>
|
||||
*/
|
||||
public static final int INVALID_ARGUMENT_VALUE = 3;
|
||||
/**
|
||||
* <pre>
|
||||
* The deadline expired before the operation could complete. For operations
|
||||
* that change the state of the system, this error may be returned
|
||||
* even if the operation has completed successfully. For example, a
|
||||
* successful response from a server could have been delayed long
|
||||
* enough for the deadline to expire.
|
||||
* HTTP Mapping: 504 Gateway Timeout
|
||||
* </pre>
|
||||
*
|
||||
* <code>DEADLINE_EXCEEDED = 4;</code>
|
||||
*/
|
||||
public static final int DEADLINE_EXCEEDED_VALUE = 4;
|
||||
/**
|
||||
* <pre>
|
||||
* Some requested entity (e.g., file or directory) was not found.
|
||||
* Note to server developers: if a request is denied for an entire class
|
||||
* of users, such as gradual feature rollout or undocumented whitelist,
|
||||
* `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`
|
||||
* must be used.
|
||||
* HTTP Mapping: 404 Not Found
|
||||
* </pre>
|
||||
*
|
||||
* <code>NOT_FOUND = 5;</code>
|
||||
*/
|
||||
public static final int NOT_FOUND_VALUE = 5;
|
||||
/**
|
||||
* <pre>
|
||||
* The entity that a client attempted to create (e.g., file or directory)
|
||||
* already exists.
|
||||
* HTTP Mapping: 409 Conflict
|
||||
* </pre>
|
||||
*
|
||||
* <code>ALREADY_EXISTS = 6;</code>
|
||||
*/
|
||||
public static final int ALREADY_EXISTS_VALUE = 6;
|
||||
/**
|
||||
* <pre>
|
||||
* The caller does not have permission to execute the specified
|
||||
* operation. `PERMISSION_DENIED` must not be used for rejections
|
||||
* caused by exhausting some resource (use `RESOURCE_EXHAUSTED`
|
||||
* instead for those errors). `PERMISSION_DENIED` must not be
|
||||
* used if the caller can not be identified (use `UNAUTHENTICATED`
|
||||
* instead for those errors). This error code does not imply the
|
||||
* request is valid or the requested entity exists or satisfies
|
||||
* other pre-conditions.
|
||||
* HTTP Mapping: 403 Forbidden
|
||||
* </pre>
|
||||
*
|
||||
* <code>PERMISSION_DENIED = 7;</code>
|
||||
*/
|
||||
public static final int PERMISSION_DENIED_VALUE = 7;
|
||||
/**
|
||||
* <pre>
|
||||
* The request does not have valid authentication credentials for the
|
||||
* operation.
|
||||
* HTTP Mapping: 401 Unauthorized
|
||||
* </pre>
|
||||
*
|
||||
* <code>UNAUTHENTICATED = 16;</code>
|
||||
*/
|
||||
public static final int UNAUTHENTICATED_VALUE = 16;
|
||||
/**
|
||||
* <pre>
|
||||
* Some resource has been exhausted, perhaps a per-user quota, or
|
||||
* perhaps the entire file system is out of space.
|
||||
* HTTP Mapping: 429 Too Many Requests
|
||||
* </pre>
|
||||
*
|
||||
* <code>RESOURCE_EXHAUSTED = 8;</code>
|
||||
*/
|
||||
public static final int RESOURCE_EXHAUSTED_VALUE = 8;
|
||||
/**
|
||||
* <pre>
|
||||
* The operation was rejected because the system is not in a state
|
||||
* required for the operation's execution. For example, the directory
|
||||
* to be deleted is non-empty, an rmdir operation is applied to
|
||||
* a non-directory, etc.
|
||||
* Service implementors can use the following guidelines to decide
|
||||
* between `FAILED_PRECONDITION`, `ABORTED`, and `UNAVAILABLE`:
|
||||
* (a) Use `UNAVAILABLE` if the client can retry just the failing call.
|
||||
* (b) Use `ABORTED` if the client should retry at a higher level
|
||||
* (e.g., when a client-specified test-and-set fails, indicating the
|
||||
* client should restart a read-modify-write sequence).
|
||||
* (c) Use `FAILED_PRECONDITION` if the client should not retry until
|
||||
* the system state has been explicitly fixed. E.g., if an "rmdir"
|
||||
* fails because the directory is non-empty, `FAILED_PRECONDITION`
|
||||
* should be returned since the client should not retry unless
|
||||
* the files are deleted from the directory.
|
||||
* HTTP Mapping: 400 Bad Request
|
||||
* </pre>
|
||||
*
|
||||
* <code>FAILED_PRECONDITION = 9;</code>
|
||||
*/
|
||||
public static final int FAILED_PRECONDITION_VALUE = 9;
|
||||
/**
|
||||
* <pre>
|
||||
* The operation was aborted, typically due to a concurrency issue such as
|
||||
* a sequencer check failure or transaction abort.
|
||||
* See the guidelines above for deciding between `FAILED_PRECONDITION`,
|
||||
* `ABORTED`, and `UNAVAILABLE`.
|
||||
* HTTP Mapping: 409 Conflict
|
||||
* </pre>
|
||||
*
|
||||
* <code>ABORTED = 10;</code>
|
||||
*/
|
||||
public static final int ABORTED_VALUE = 10;
|
||||
/**
|
||||
* <pre>
|
||||
* The operation was attempted past the valid range. E.g., seeking or
|
||||
* reading past end-of-file.
|
||||
* Unlike `INVALID_ARGUMENT`, this error indicates a problem that may
|
||||
* be fixed if the system state changes. For example, a 32-bit file
|
||||
* 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
|
||||
* `OUT_OF_RANGE` if asked to read from an offset past the current
|
||||
* file size.
|
||||
* There is a fair bit of overlap between `FAILED_PRECONDITION` and
|
||||
* `OUT_OF_RANGE`. We recommend using `OUT_OF_RANGE` (the more specific
|
||||
* 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
|
||||
* they are done.
|
||||
* HTTP Mapping: 400 Bad Request
|
||||
* </pre>
|
||||
*
|
||||
* <code>OUT_OF_RANGE = 11;</code>
|
||||
*/
|
||||
public static final int OUT_OF_RANGE_VALUE = 11;
|
||||
/**
|
||||
* <pre>
|
||||
* The operation is not implemented or is not supported/enabled in this
|
||||
* service.
|
||||
* HTTP Mapping: 501 Not Implemented
|
||||
* </pre>
|
||||
*
|
||||
* <code>UNIMPLEMENTED = 12;</code>
|
||||
*/
|
||||
public static final int UNIMPLEMENTED_VALUE = 12;
|
||||
/**
|
||||
* <pre>
|
||||
* Internal errors. This means that some invariants expected by the
|
||||
* underlying system have been broken. This error code is reserved
|
||||
* for serious errors.
|
||||
* HTTP Mapping: 500 Internal Server Error
|
||||
* </pre>
|
||||
*
|
||||
* <code>INTERNAL = 13;</code>
|
||||
*/
|
||||
public static final int INTERNAL_VALUE = 13;
|
||||
/**
|
||||
* <pre>
|
||||
* The service is currently unavailable. This is most likely a
|
||||
* transient condition, which can be corrected by retrying with
|
||||
* a backoff.
|
||||
* See the guidelines above for deciding between `FAILED_PRECONDITION`,
|
||||
* `ABORTED`, and `UNAVAILABLE`.
|
||||
* HTTP Mapping: 503 Service Unavailable
|
||||
* </pre>
|
||||
*
|
||||
* <code>UNAVAILABLE = 14;</code>
|
||||
*/
|
||||
public static final int UNAVAILABLE_VALUE = 14;
|
||||
/**
|
||||
* <pre>
|
||||
* Unrecoverable data loss or corruption.
|
||||
* HTTP Mapping: 500 Internal Server Error
|
||||
* </pre>
|
||||
*
|
||||
* <code>DATA_LOSS = 15;</code>
|
||||
*/
|
||||
public static final int DATA_LOSS_VALUE = 15;
|
||||
|
||||
|
||||
public final int getNumber() {
|
||||
if (this == UNRECOGNIZED) {
|
||||
throw new java.lang.IllegalArgumentException(
|
||||
"Can't get the number of an unknown enum value.");
|
||||
}
|
||||
return value;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param value The numeric wire value of the corresponding enum entry.
|
||||
* @return The enum associated with the given numeric wire value.
|
||||
* @deprecated Use {@link #forNumber(int)} instead.
|
||||
*/
|
||||
@java.lang.Deprecated
|
||||
public static Code valueOf(int value) {
|
||||
return forNumber(value);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param value The numeric wire value of the corresponding enum entry.
|
||||
* @return The enum associated with the given numeric wire value.
|
||||
*/
|
||||
public static Code forNumber(int value) {
|
||||
switch (value) {
|
||||
case 0: return OK;
|
||||
case 1: return CANCELLED;
|
||||
case 2: return UNKNOWN;
|
||||
case 3: return INVALID_ARGUMENT;
|
||||
case 4: return DEADLINE_EXCEEDED;
|
||||
case 5: return NOT_FOUND;
|
||||
case 6: return ALREADY_EXISTS;
|
||||
case 7: return PERMISSION_DENIED;
|
||||
case 16: return UNAUTHENTICATED;
|
||||
case 8: return RESOURCE_EXHAUSTED;
|
||||
case 9: return FAILED_PRECONDITION;
|
||||
case 10: return ABORTED;
|
||||
case 11: return OUT_OF_RANGE;
|
||||
case 12: return UNIMPLEMENTED;
|
||||
case 13: return INTERNAL;
|
||||
case 14: return UNAVAILABLE;
|
||||
case 15: return DATA_LOSS;
|
||||
default: return null;
|
||||
}
|
||||
}
|
||||
|
||||
public static com.google.protobuf.Internal.EnumLiteMap<Code>
|
||||
internalGetValueMap() {
|
||||
return internalValueMap;
|
||||
}
|
||||
private static final com.google.protobuf.Internal.EnumLiteMap<
|
||||
Code> internalValueMap =
|
||||
new com.google.protobuf.Internal.EnumLiteMap<Code>() {
|
||||
public Code findValueByNumber(int number) {
|
||||
return Code.forNumber(number);
|
||||
}
|
||||
};
|
||||
|
||||
public final com.google.protobuf.Descriptors.EnumValueDescriptor
|
||||
getValueDescriptor() {
|
||||
if (this == UNRECOGNIZED) {
|
||||
throw new java.lang.IllegalStateException(
|
||||
"Can't get the descriptor of an unrecognized enum value.");
|
||||
}
|
||||
return getDescriptor().getValues().get(ordinal());
|
||||
}
|
||||
public final com.google.protobuf.Descriptors.EnumDescriptor
|
||||
getDescriptorForType() {
|
||||
return getDescriptor();
|
||||
}
|
||||
public static final com.google.protobuf.Descriptors.EnumDescriptor
|
||||
getDescriptor() {
|
||||
return com.google.rpc.CodeProto.getDescriptor().getEnumTypes().get(0);
|
||||
}
|
||||
|
||||
private static final Code[] VALUES = values();
|
||||
|
||||
public static Code valueOf(
|
||||
com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
|
||||
if (desc.getType() != getDescriptor()) {
|
||||
throw new java.lang.IllegalArgumentException(
|
||||
"EnumValueDescriptor is not for this type.");
|
||||
}
|
||||
if (desc.getIndex() == -1) {
|
||||
return UNRECOGNIZED;
|
||||
}
|
||||
return VALUES[desc.getIndex()];
|
||||
}
|
||||
|
||||
private final int value;
|
||||
|
||||
private Code(int value) {
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(enum_scope:google.rpc.Code)
|
||||
}
|
||||
|
46
src/main/java/com/google/rpc/CodeProto.java
Normal file
46
src/main/java/com/google/rpc/CodeProto.java
Normal file
@ -0,0 +1,46 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/rpc/code.proto
|
||||
|
||||
package com.google.rpc;
|
||||
|
||||
public final class CodeProto {
|
||||
private CodeProto() {}
|
||||
public static void registerAllExtensions(
|
||||
com.google.protobuf.ExtensionRegistryLite registry) {
|
||||
}
|
||||
|
||||
public static void registerAllExtensions(
|
||||
com.google.protobuf.ExtensionRegistry registry) {
|
||||
registerAllExtensions(
|
||||
(com.google.protobuf.ExtensionRegistryLite) registry);
|
||||
}
|
||||
|
||||
public static com.google.protobuf.Descriptors.FileDescriptor
|
||||
getDescriptor() {
|
||||
return descriptor;
|
||||
}
|
||||
private static com.google.protobuf.Descriptors.FileDescriptor
|
||||
descriptor;
|
||||
static {
|
||||
java.lang.String[] descriptorData = {
|
||||
"\n\025google/rpc/code.proto\022\ngoogle.rpc*\267\002\n\004" +
|
||||
"Code\022\006\n\002OK\020\000\022\r\n\tCANCELLED\020\001\022\013\n\007UNKNOWN\020\002" +
|
||||
"\022\024\n\020INVALID_ARGUMENT\020\003\022\025\n\021DEADLINE_EXCEE" +
|
||||
"DED\020\004\022\r\n\tNOT_FOUND\020\005\022\022\n\016ALREADY_EXISTS\020\006" +
|
||||
"\022\025\n\021PERMISSION_DENIED\020\007\022\023\n\017UNAUTHENTICAT" +
|
||||
"ED\020\020\022\026\n\022RESOURCE_EXHAUSTED\020\010\022\027\n\023FAILED_P" +
|
||||
"RECONDITION\020\t\022\013\n\007ABORTED\020\n\022\020\n\014OUT_OF_RAN" +
|
||||
"GE\020\013\022\021\n\rUNIMPLEMENTED\020\014\022\014\n\010INTERNAL\020\r\022\017\n" +
|
||||
"\013UNAVAILABLE\020\016\022\r\n\tDATA_LOSS\020\017BX\n\016com.goo" +
|
||||
"gle.rpcB\tCodeProtoP\001Z3google.golang.org/" +
|
||||
"genproto/googleapis/rpc/code;code\242\002\003RPCb" +
|
||||
"\006proto3"
|
||||
};
|
||||
descriptor = com.google.protobuf.Descriptors.FileDescriptor
|
||||
.internalBuildGeneratedFileFrom(descriptorData,
|
||||
new com.google.protobuf.Descriptors.FileDescriptor[] {
|
||||
});
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(outer_class_scope)
|
||||
}
|
840
src/main/java/com/google/rpc/DebugInfo.java
Normal file
840
src/main/java/com/google/rpc/DebugInfo.java
Normal file
@ -0,0 +1,840 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/rpc/error_details.proto
|
||||
|
||||
package com.google.rpc;
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Describes additional debugging info.
|
||||
* </pre>
|
||||
*
|
||||
* Protobuf type {@code google.rpc.DebugInfo}
|
||||
*/
|
||||
public final class DebugInfo extends
|
||||
com.google.protobuf.GeneratedMessageV3 implements
|
||||
// @@protoc_insertion_point(message_implements:google.rpc.DebugInfo)
|
||||
DebugInfoOrBuilder {
|
||||
private static final long serialVersionUID = 0L;
|
||||
// Use DebugInfo.newBuilder() to construct.
|
||||
private DebugInfo(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
|
||||
super(builder);
|
||||
}
|
||||
private DebugInfo() {
|
||||
stackEntries_ = com.google.protobuf.LazyStringArrayList.EMPTY;
|
||||
detail_ = "";
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
@SuppressWarnings({"unused"})
|
||||
protected java.lang.Object newInstance(
|
||||
UnusedPrivateParameter unused) {
|
||||
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
|
||||
getDescriptor() {
|
||||
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_DebugInfo_descriptor;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_DebugInfo_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
com.google.rpc.DebugInfo.class, com.google.rpc.DebugInfo.Builder.class);
|
||||
}
|
||||
|
||||
public static final int STACK_ENTRIES_FIELD_NUMBER = 1;
|
||||
private com.google.protobuf.LazyStringList stackEntries_;
|
||||
/**
|
||||
* <pre>
|
||||
* The stack trace entries indicating where the error occurred.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string stack_entries = 1;</code>
|
||||
* @return A list containing the stackEntries.
|
||||
*/
|
||||
public com.google.protobuf.ProtocolStringList
|
||||
getStackEntriesList() {
|
||||
return stackEntries_;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The stack trace entries indicating where the error occurred.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string stack_entries = 1;</code>
|
||||
* @return The count of stackEntries.
|
||||
*/
|
||||
public int getStackEntriesCount() {
|
||||
return stackEntries_.size();
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The stack trace entries indicating where the error occurred.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string stack_entries = 1;</code>
|
||||
* @param index The index of the element to return.
|
||||
* @return The stackEntries at the given index.
|
||||
*/
|
||||
public java.lang.String getStackEntries(int index) {
|
||||
return stackEntries_.get(index);
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The stack trace entries indicating where the error occurred.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string stack_entries = 1;</code>
|
||||
* @param index The index of the value to return.
|
||||
* @return The bytes of the stackEntries at the given index.
|
||||
*/
|
||||
public com.google.protobuf.ByteString
|
||||
getStackEntriesBytes(int index) {
|
||||
return stackEntries_.getByteString(index);
|
||||
}
|
||||
|
||||
public static final int DETAIL_FIELD_NUMBER = 2;
|
||||
private volatile java.lang.Object detail_;
|
||||
/**
|
||||
* <pre>
|
||||
* Additional debugging information provided by the server.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string detail = 2;</code>
|
||||
* @return The detail.
|
||||
*/
|
||||
@java.lang.Override
|
||||
public java.lang.String getDetail() {
|
||||
java.lang.Object ref = detail_;
|
||||
if (ref instanceof java.lang.String) {
|
||||
return (java.lang.String) ref;
|
||||
} else {
|
||||
com.google.protobuf.ByteString bs =
|
||||
(com.google.protobuf.ByteString) ref;
|
||||
java.lang.String s = bs.toStringUtf8();
|
||||
detail_ = s;
|
||||
return s;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Additional debugging information provided by the server.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string detail = 2;</code>
|
||||
* @return The bytes for detail.
|
||||
*/
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.ByteString
|
||||
getDetailBytes() {
|
||||
java.lang.Object ref = detail_;
|
||||
if (ref instanceof java.lang.String) {
|
||||
com.google.protobuf.ByteString b =
|
||||
com.google.protobuf.ByteString.copyFromUtf8(
|
||||
(java.lang.String) ref);
|
||||
detail_ = b;
|
||||
return b;
|
||||
} else {
|
||||
return (com.google.protobuf.ByteString) ref;
|
||||
}
|
||||
}
|
||||
|
||||
private byte memoizedIsInitialized = -1;
|
||||
@java.lang.Override
|
||||
public final boolean isInitialized() {
|
||||
byte isInitialized = memoizedIsInitialized;
|
||||
if (isInitialized == 1) return true;
|
||||
if (isInitialized == 0) return false;
|
||||
|
||||
memoizedIsInitialized = 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
||||
throws java.io.IOException {
|
||||
for (int i = 0; i < stackEntries_.size(); i++) {
|
||||
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, stackEntries_.getRaw(i));
|
||||
}
|
||||
if (!getDetailBytes().isEmpty()) {
|
||||
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, detail_);
|
||||
}
|
||||
unknownFields.writeTo(output);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public int getSerializedSize() {
|
||||
int size = memoizedSize;
|
||||
if (size != -1) return size;
|
||||
|
||||
size = 0;
|
||||
{
|
||||
int dataSize = 0;
|
||||
for (int i = 0; i < stackEntries_.size(); i++) {
|
||||
dataSize += computeStringSizeNoTag(stackEntries_.getRaw(i));
|
||||
}
|
||||
size += dataSize;
|
||||
size += 1 * getStackEntriesList().size();
|
||||
}
|
||||
if (!getDetailBytes().isEmpty()) {
|
||||
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, detail_);
|
||||
}
|
||||
size += unknownFields.getSerializedSize();
|
||||
memoizedSize = size;
|
||||
return size;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public boolean equals(final java.lang.Object obj) {
|
||||
if (obj == this) {
|
||||
return true;
|
||||
}
|
||||
if (!(obj instanceof com.google.rpc.DebugInfo)) {
|
||||
return super.equals(obj);
|
||||
}
|
||||
com.google.rpc.DebugInfo other = (com.google.rpc.DebugInfo) obj;
|
||||
|
||||
if (!getStackEntriesList()
|
||||
.equals(other.getStackEntriesList())) return false;
|
||||
if (!getDetail()
|
||||
.equals(other.getDetail())) return false;
|
||||
if (!unknownFields.equals(other.unknownFields)) return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public int hashCode() {
|
||||
if (memoizedHashCode != 0) {
|
||||
return memoizedHashCode;
|
||||
}
|
||||
int hash = 41;
|
||||
hash = (19 * hash) + getDescriptor().hashCode();
|
||||
if (getStackEntriesCount() > 0) {
|
||||
hash = (37 * hash) + STACK_ENTRIES_FIELD_NUMBER;
|
||||
hash = (53 * hash) + getStackEntriesList().hashCode();
|
||||
}
|
||||
hash = (37 * hash) + DETAIL_FIELD_NUMBER;
|
||||
hash = (53 * hash) + getDetail().hashCode();
|
||||
hash = (29 * hash) + unknownFields.hashCode();
|
||||
memoizedHashCode = hash;
|
||||
return hash;
|
||||
}
|
||||
|
||||
public static com.google.rpc.DebugInfo parseFrom(
|
||||
java.nio.ByteBuffer data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static com.google.rpc.DebugInfo parseFrom(
|
||||
java.nio.ByteBuffer data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static com.google.rpc.DebugInfo parseFrom(
|
||||
com.google.protobuf.ByteString data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static com.google.rpc.DebugInfo parseFrom(
|
||||
com.google.protobuf.ByteString data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static com.google.rpc.DebugInfo parseFrom(byte[] data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static com.google.rpc.DebugInfo parseFrom(
|
||||
byte[] data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static com.google.rpc.DebugInfo parseFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseWithIOException(PARSER, input);
|
||||
}
|
||||
public static com.google.rpc.DebugInfo parseFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
||||
}
|
||||
public static com.google.rpc.DebugInfo parseDelimitedFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseDelimitedWithIOException(PARSER, input);
|
||||
}
|
||||
public static com.google.rpc.DebugInfo parseDelimitedFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
|
||||
}
|
||||
public static com.google.rpc.DebugInfo parseFrom(
|
||||
com.google.protobuf.CodedInputStream input)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseWithIOException(PARSER, input);
|
||||
}
|
||||
public static com.google.rpc.DebugInfo parseFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public Builder newBuilderForType() { return newBuilder(); }
|
||||
public static Builder newBuilder() {
|
||||
return DEFAULT_INSTANCE.toBuilder();
|
||||
}
|
||||
public static Builder newBuilder(com.google.rpc.DebugInfo prototype) {
|
||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder toBuilder() {
|
||||
return this == DEFAULT_INSTANCE
|
||||
? new Builder() : new Builder().mergeFrom(this);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected Builder newBuilderForType(
|
||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
||||
Builder builder = new Builder(parent);
|
||||
return builder;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Describes additional debugging info.
|
||||
* </pre>
|
||||
*
|
||||
* Protobuf type {@code google.rpc.DebugInfo}
|
||||
*/
|
||||
public static final class Builder extends
|
||||
com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
|
||||
// @@protoc_insertion_point(builder_implements:google.rpc.DebugInfo)
|
||||
com.google.rpc.DebugInfoOrBuilder {
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_DebugInfo_descriptor;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_DebugInfo_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
com.google.rpc.DebugInfo.class, com.google.rpc.DebugInfo.Builder.class);
|
||||
}
|
||||
|
||||
// Construct using com.google.rpc.DebugInfo.newBuilder()
|
||||
private Builder() {
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
|
||||
private Builder(
|
||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
||||
super(parent);
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
private void maybeForceBuilderInitialization() {
|
||||
if (com.google.protobuf.GeneratedMessageV3
|
||||
.alwaysUseFieldBuilders) {
|
||||
}
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder clear() {
|
||||
super.clear();
|
||||
stackEntries_ = com.google.protobuf.LazyStringArrayList.EMPTY;
|
||||
bitField0_ = (bitField0_ & ~0x00000001);
|
||||
detail_ = "";
|
||||
|
||||
return this;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptorForType() {
|
||||
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_DebugInfo_descriptor;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.rpc.DebugInfo getDefaultInstanceForType() {
|
||||
return com.google.rpc.DebugInfo.getDefaultInstance();
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.rpc.DebugInfo build() {
|
||||
com.google.rpc.DebugInfo result = buildPartial();
|
||||
if (!result.isInitialized()) {
|
||||
throw newUninitializedMessageException(result);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.rpc.DebugInfo buildPartial() {
|
||||
com.google.rpc.DebugInfo result = new com.google.rpc.DebugInfo(this);
|
||||
int from_bitField0_ = bitField0_;
|
||||
if (((bitField0_ & 0x00000001) != 0)) {
|
||||
stackEntries_ = stackEntries_.getUnmodifiableView();
|
||||
bitField0_ = (bitField0_ & ~0x00000001);
|
||||
}
|
||||
result.stackEntries_ = stackEntries_;
|
||||
result.detail_ = detail_;
|
||||
onBuilt();
|
||||
return result;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public Builder clone() {
|
||||
return super.clone();
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder setField(
|
||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
||||
java.lang.Object value) {
|
||||
return super.setField(field, value);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder clearField(
|
||||
com.google.protobuf.Descriptors.FieldDescriptor field) {
|
||||
return super.clearField(field);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder clearOneof(
|
||||
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
|
||||
return super.clearOneof(oneof);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder setRepeatedField(
|
||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
||||
int index, java.lang.Object value) {
|
||||
return super.setRepeatedField(field, index, value);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder addRepeatedField(
|
||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
||||
java.lang.Object value) {
|
||||
return super.addRepeatedField(field, value);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
||||
if (other instanceof com.google.rpc.DebugInfo) {
|
||||
return mergeFrom((com.google.rpc.DebugInfo)other);
|
||||
} else {
|
||||
super.mergeFrom(other);
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
public Builder mergeFrom(com.google.rpc.DebugInfo other) {
|
||||
if (other == com.google.rpc.DebugInfo.getDefaultInstance()) return this;
|
||||
if (!other.stackEntries_.isEmpty()) {
|
||||
if (stackEntries_.isEmpty()) {
|
||||
stackEntries_ = other.stackEntries_;
|
||||
bitField0_ = (bitField0_ & ~0x00000001);
|
||||
} else {
|
||||
ensureStackEntriesIsMutable();
|
||||
stackEntries_.addAll(other.stackEntries_);
|
||||
}
|
||||
onChanged();
|
||||
}
|
||||
if (!other.getDetail().isEmpty()) {
|
||||
detail_ = other.detail_;
|
||||
onChanged();
|
||||
}
|
||||
this.mergeUnknownFields(other.unknownFields);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final boolean isInitialized() {
|
||||
return true;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public Builder mergeFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
com.google.rpc.DebugInfo parsedMessage = null;
|
||||
try {
|
||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
parsedMessage = (com.google.rpc.DebugInfo) e.getUnfinishedMessage();
|
||||
throw e.unwrapIOException();
|
||||
} finally {
|
||||
if (parsedMessage != null) {
|
||||
mergeFrom(parsedMessage);
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
private int bitField0_;
|
||||
|
||||
private com.google.protobuf.LazyStringList stackEntries_ = com.google.protobuf.LazyStringArrayList.EMPTY;
|
||||
private void ensureStackEntriesIsMutable() {
|
||||
if (!((bitField0_ & 0x00000001) != 0)) {
|
||||
stackEntries_ = new com.google.protobuf.LazyStringArrayList(stackEntries_);
|
||||
bitField0_ |= 0x00000001;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The stack trace entries indicating where the error occurred.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string stack_entries = 1;</code>
|
||||
* @return A list containing the stackEntries.
|
||||
*/
|
||||
public com.google.protobuf.ProtocolStringList
|
||||
getStackEntriesList() {
|
||||
return stackEntries_.getUnmodifiableView();
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The stack trace entries indicating where the error occurred.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string stack_entries = 1;</code>
|
||||
* @return The count of stackEntries.
|
||||
*/
|
||||
public int getStackEntriesCount() {
|
||||
return stackEntries_.size();
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The stack trace entries indicating where the error occurred.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string stack_entries = 1;</code>
|
||||
* @param index The index of the element to return.
|
||||
* @return The stackEntries at the given index.
|
||||
*/
|
||||
public java.lang.String getStackEntries(int index) {
|
||||
return stackEntries_.get(index);
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The stack trace entries indicating where the error occurred.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string stack_entries = 1;</code>
|
||||
* @param index The index of the value to return.
|
||||
* @return The bytes of the stackEntries at the given index.
|
||||
*/
|
||||
public com.google.protobuf.ByteString
|
||||
getStackEntriesBytes(int index) {
|
||||
return stackEntries_.getByteString(index);
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The stack trace entries indicating where the error occurred.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string stack_entries = 1;</code>
|
||||
* @param index The index to set the value at.
|
||||
* @param value The stackEntries to set.
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder setStackEntries(
|
||||
int index, java.lang.String value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
ensureStackEntriesIsMutable();
|
||||
stackEntries_.set(index, value);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The stack trace entries indicating where the error occurred.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string stack_entries = 1;</code>
|
||||
* @param value The stackEntries to add.
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder addStackEntries(
|
||||
java.lang.String value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
ensureStackEntriesIsMutable();
|
||||
stackEntries_.add(value);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The stack trace entries indicating where the error occurred.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string stack_entries = 1;</code>
|
||||
* @param values The stackEntries to add.
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder addAllStackEntries(
|
||||
java.lang.Iterable<java.lang.String> values) {
|
||||
ensureStackEntriesIsMutable();
|
||||
com.google.protobuf.AbstractMessageLite.Builder.addAll(
|
||||
values, stackEntries_);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The stack trace entries indicating where the error occurred.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string stack_entries = 1;</code>
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder clearStackEntries() {
|
||||
stackEntries_ = com.google.protobuf.LazyStringArrayList.EMPTY;
|
||||
bitField0_ = (bitField0_ & ~0x00000001);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The stack trace entries indicating where the error occurred.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string stack_entries = 1;</code>
|
||||
* @param value The bytes of the stackEntries to add.
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder addStackEntriesBytes(
|
||||
com.google.protobuf.ByteString value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
checkByteStringIsUtf8(value);
|
||||
ensureStackEntriesIsMutable();
|
||||
stackEntries_.add(value);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private java.lang.Object detail_ = "";
|
||||
/**
|
||||
* <pre>
|
||||
* Additional debugging information provided by the server.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string detail = 2;</code>
|
||||
* @return The detail.
|
||||
*/
|
||||
public java.lang.String getDetail() {
|
||||
java.lang.Object ref = detail_;
|
||||
if (!(ref instanceof java.lang.String)) {
|
||||
com.google.protobuf.ByteString bs =
|
||||
(com.google.protobuf.ByteString) ref;
|
||||
java.lang.String s = bs.toStringUtf8();
|
||||
detail_ = s;
|
||||
return s;
|
||||
} else {
|
||||
return (java.lang.String) ref;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Additional debugging information provided by the server.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string detail = 2;</code>
|
||||
* @return The bytes for detail.
|
||||
*/
|
||||
public com.google.protobuf.ByteString
|
||||
getDetailBytes() {
|
||||
java.lang.Object ref = detail_;
|
||||
if (ref instanceof String) {
|
||||
com.google.protobuf.ByteString b =
|
||||
com.google.protobuf.ByteString.copyFromUtf8(
|
||||
(java.lang.String) ref);
|
||||
detail_ = b;
|
||||
return b;
|
||||
} else {
|
||||
return (com.google.protobuf.ByteString) ref;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Additional debugging information provided by the server.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string detail = 2;</code>
|
||||
* @param value The detail to set.
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder setDetail(
|
||||
java.lang.String value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
|
||||
detail_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Additional debugging information provided by the server.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string detail = 2;</code>
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder clearDetail() {
|
||||
|
||||
detail_ = getDefaultInstance().getDetail();
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Additional debugging information provided by the server.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string detail = 2;</code>
|
||||
* @param value The bytes for detail to set.
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder setDetailBytes(
|
||||
com.google.protobuf.ByteString value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
checkByteStringIsUtf8(value);
|
||||
|
||||
detail_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
@java.lang.Override
|
||||
public final Builder setUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return super.setUnknownFields(unknownFields);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final Builder mergeUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return super.mergeUnknownFields(unknownFields);
|
||||
}
|
||||
|
||||
|
||||
// @@protoc_insertion_point(builder_scope:google.rpc.DebugInfo)
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(class_scope:google.rpc.DebugInfo)
|
||||
private static final com.google.rpc.DebugInfo DEFAULT_INSTANCE;
|
||||
static {
|
||||
DEFAULT_INSTANCE = new com.google.rpc.DebugInfo();
|
||||
}
|
||||
|
||||
public static com.google.rpc.DebugInfo getDefaultInstance() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
private static final com.google.protobuf.Parser<DebugInfo>
|
||||
PARSER = new com.google.protobuf.AbstractParser<DebugInfo>() {
|
||||
@java.lang.Override
|
||||
public DebugInfo parsePartialFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return new DebugInfo(input, extensionRegistry);
|
||||
}
|
||||
};
|
||||
|
||||
public static com.google.protobuf.Parser<DebugInfo> parser() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Parser<DebugInfo> getParserForType() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.rpc.DebugInfo getDefaultInstanceForType() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
}
|
||||
|
70
src/main/java/com/google/rpc/DebugInfoOrBuilder.java
Normal file
70
src/main/java/com/google/rpc/DebugInfoOrBuilder.java
Normal file
@ -0,0 +1,70 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/rpc/error_details.proto
|
||||
|
||||
package com.google.rpc;
|
||||
|
||||
public interface DebugInfoOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:google.rpc.DebugInfo)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* The stack trace entries indicating where the error occurred.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string stack_entries = 1;</code>
|
||||
* @return A list containing the stackEntries.
|
||||
*/
|
||||
java.util.List<java.lang.String>
|
||||
getStackEntriesList();
|
||||
/**
|
||||
* <pre>
|
||||
* The stack trace entries indicating where the error occurred.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string stack_entries = 1;</code>
|
||||
* @return The count of stackEntries.
|
||||
*/
|
||||
int getStackEntriesCount();
|
||||
/**
|
||||
* <pre>
|
||||
* The stack trace entries indicating where the error occurred.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string stack_entries = 1;</code>
|
||||
* @param index The index of the element to return.
|
||||
* @return The stackEntries at the given index.
|
||||
*/
|
||||
java.lang.String getStackEntries(int index);
|
||||
/**
|
||||
* <pre>
|
||||
* The stack trace entries indicating where the error occurred.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string stack_entries = 1;</code>
|
||||
* @param index The index of the value to return.
|
||||
* @return The bytes of the stackEntries at the given index.
|
||||
*/
|
||||
com.google.protobuf.ByteString
|
||||
getStackEntriesBytes(int index);
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Additional debugging information provided by the server.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string detail = 2;</code>
|
||||
* @return The detail.
|
||||
*/
|
||||
java.lang.String getDetail();
|
||||
/**
|
||||
* <pre>
|
||||
* Additional debugging information provided by the server.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string detail = 2;</code>
|
||||
* @return The bytes for detail.
|
||||
*/
|
||||
com.google.protobuf.ByteString
|
||||
getDetailBytes();
|
||||
}
|
205
src/main/java/com/google/rpc/ErrorDetailsProto.java
Normal file
205
src/main/java/com/google/rpc/ErrorDetailsProto.java
Normal file
@ -0,0 +1,205 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/rpc/error_details.proto
|
||||
|
||||
package com.google.rpc;
|
||||
|
||||
public final class ErrorDetailsProto {
|
||||
private ErrorDetailsProto() {}
|
||||
public static void registerAllExtensions(
|
||||
com.google.protobuf.ExtensionRegistryLite registry) {
|
||||
}
|
||||
|
||||
public static void registerAllExtensions(
|
||||
com.google.protobuf.ExtensionRegistry registry) {
|
||||
registerAllExtensions(
|
||||
(com.google.protobuf.ExtensionRegistryLite) registry);
|
||||
}
|
||||
static final com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_google_rpc_RetryInfo_descriptor;
|
||||
static final
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internal_static_google_rpc_RetryInfo_fieldAccessorTable;
|
||||
static final com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_google_rpc_DebugInfo_descriptor;
|
||||
static final
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internal_static_google_rpc_DebugInfo_fieldAccessorTable;
|
||||
static final com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_google_rpc_QuotaFailure_descriptor;
|
||||
static final
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internal_static_google_rpc_QuotaFailure_fieldAccessorTable;
|
||||
static final com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_google_rpc_QuotaFailure_Violation_descriptor;
|
||||
static final
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internal_static_google_rpc_QuotaFailure_Violation_fieldAccessorTable;
|
||||
static final com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_google_rpc_PreconditionFailure_descriptor;
|
||||
static final
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internal_static_google_rpc_PreconditionFailure_fieldAccessorTable;
|
||||
static final com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_google_rpc_PreconditionFailure_Violation_descriptor;
|
||||
static final
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internal_static_google_rpc_PreconditionFailure_Violation_fieldAccessorTable;
|
||||
static final com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_google_rpc_BadRequest_descriptor;
|
||||
static final
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internal_static_google_rpc_BadRequest_fieldAccessorTable;
|
||||
static final com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_google_rpc_BadRequest_FieldViolation_descriptor;
|
||||
static final
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internal_static_google_rpc_BadRequest_FieldViolation_fieldAccessorTable;
|
||||
static final com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_google_rpc_RequestInfo_descriptor;
|
||||
static final
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internal_static_google_rpc_RequestInfo_fieldAccessorTable;
|
||||
static final com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_google_rpc_ResourceInfo_descriptor;
|
||||
static final
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internal_static_google_rpc_ResourceInfo_fieldAccessorTable;
|
||||
static final com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_google_rpc_Help_descriptor;
|
||||
static final
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internal_static_google_rpc_Help_fieldAccessorTable;
|
||||
static final com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_google_rpc_Help_Link_descriptor;
|
||||
static final
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internal_static_google_rpc_Help_Link_fieldAccessorTable;
|
||||
static final com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_google_rpc_LocalizedMessage_descriptor;
|
||||
static final
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internal_static_google_rpc_LocalizedMessage_fieldAccessorTable;
|
||||
|
||||
public static com.google.protobuf.Descriptors.FileDescriptor
|
||||
getDescriptor() {
|
||||
return descriptor;
|
||||
}
|
||||
private static com.google.protobuf.Descriptors.FileDescriptor
|
||||
descriptor;
|
||||
static {
|
||||
java.lang.String[] descriptorData = {
|
||||
"\n\036google/rpc/error_details.proto\022\ngoogle" +
|
||||
".rpc\032\036google/protobuf/duration.proto\";\n\t" +
|
||||
"RetryInfo\022.\n\013retry_delay\030\001 \001(\0132\031.google." +
|
||||
"protobuf.Duration\"2\n\tDebugInfo\022\025\n\rstack_" +
|
||||
"entries\030\001 \003(\t\022\016\n\006detail\030\002 \001(\t\"y\n\014QuotaFa" +
|
||||
"ilure\0226\n\nviolations\030\001 \003(\0132\".google.rpc.Q" +
|
||||
"uotaFailure.Violation\0321\n\tViolation\022\017\n\007su" +
|
||||
"bject\030\001 \001(\t\022\023\n\013description\030\002 \001(\t\"\225\001\n\023Pre" +
|
||||
"conditionFailure\022=\n\nviolations\030\001 \003(\0132).g" +
|
||||
"oogle.rpc.PreconditionFailure.Violation\032" +
|
||||
"?\n\tViolation\022\014\n\004type\030\001 \001(\t\022\017\n\007subject\030\002 " +
|
||||
"\001(\t\022\023\n\013description\030\003 \001(\t\"\203\001\n\nBadRequest\022" +
|
||||
"?\n\020field_violations\030\001 \003(\0132%.google.rpc.B" +
|
||||
"adRequest.FieldViolation\0324\n\016FieldViolati" +
|
||||
"on\022\r\n\005field\030\001 \001(\t\022\023\n\013description\030\002 \001(\t\"7" +
|
||||
"\n\013RequestInfo\022\022\n\nrequest_id\030\001 \001(\t\022\024\n\014ser" +
|
||||
"ving_data\030\002 \001(\t\"`\n\014ResourceInfo\022\025\n\rresou" +
|
||||
"rce_type\030\001 \001(\t\022\025\n\rresource_name\030\002 \001(\t\022\r\n" +
|
||||
"\005owner\030\003 \001(\t\022\023\n\013description\030\004 \001(\t\"V\n\004Hel" +
|
||||
"p\022$\n\005links\030\001 \003(\0132\025.google.rpc.Help.Link\032" +
|
||||
"(\n\004Link\022\023\n\013description\030\001 \001(\t\022\013\n\003url\030\002 \001(" +
|
||||
"\t\"3\n\020LocalizedMessage\022\016\n\006locale\030\001 \001(\t\022\017\n" +
|
||||
"\007message\030\002 \001(\tBl\n\016com.google.rpcB\021ErrorD" +
|
||||
"etailsProtoP\001Z?google.golang.org/genprot" +
|
||||
"o/googleapis/rpc/errdetails;errdetails\242\002" +
|
||||
"\003RPCb\006proto3"
|
||||
};
|
||||
descriptor = com.google.protobuf.Descriptors.FileDescriptor
|
||||
.internalBuildGeneratedFileFrom(descriptorData,
|
||||
new com.google.protobuf.Descriptors.FileDescriptor[] {
|
||||
com.google.protobuf.DurationProto.getDescriptor(),
|
||||
});
|
||||
internal_static_google_rpc_RetryInfo_descriptor =
|
||||
getDescriptor().getMessageTypes().get(0);
|
||||
internal_static_google_rpc_RetryInfo_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
||||
internal_static_google_rpc_RetryInfo_descriptor,
|
||||
new java.lang.String[] { "RetryDelay", });
|
||||
internal_static_google_rpc_DebugInfo_descriptor =
|
||||
getDescriptor().getMessageTypes().get(1);
|
||||
internal_static_google_rpc_DebugInfo_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
||||
internal_static_google_rpc_DebugInfo_descriptor,
|
||||
new java.lang.String[] { "StackEntries", "Detail", });
|
||||
internal_static_google_rpc_QuotaFailure_descriptor =
|
||||
getDescriptor().getMessageTypes().get(2);
|
||||
internal_static_google_rpc_QuotaFailure_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
||||
internal_static_google_rpc_QuotaFailure_descriptor,
|
||||
new java.lang.String[] { "Violations", });
|
||||
internal_static_google_rpc_QuotaFailure_Violation_descriptor =
|
||||
internal_static_google_rpc_QuotaFailure_descriptor.getNestedTypes().get(0);
|
||||
internal_static_google_rpc_QuotaFailure_Violation_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
||||
internal_static_google_rpc_QuotaFailure_Violation_descriptor,
|
||||
new java.lang.String[] { "Subject", "Description", });
|
||||
internal_static_google_rpc_PreconditionFailure_descriptor =
|
||||
getDescriptor().getMessageTypes().get(3);
|
||||
internal_static_google_rpc_PreconditionFailure_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
||||
internal_static_google_rpc_PreconditionFailure_descriptor,
|
||||
new java.lang.String[] { "Violations", });
|
||||
internal_static_google_rpc_PreconditionFailure_Violation_descriptor =
|
||||
internal_static_google_rpc_PreconditionFailure_descriptor.getNestedTypes().get(0);
|
||||
internal_static_google_rpc_PreconditionFailure_Violation_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
||||
internal_static_google_rpc_PreconditionFailure_Violation_descriptor,
|
||||
new java.lang.String[] { "Type", "Subject", "Description", });
|
||||
internal_static_google_rpc_BadRequest_descriptor =
|
||||
getDescriptor().getMessageTypes().get(4);
|
||||
internal_static_google_rpc_BadRequest_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
||||
internal_static_google_rpc_BadRequest_descriptor,
|
||||
new java.lang.String[] { "FieldViolations", });
|
||||
internal_static_google_rpc_BadRequest_FieldViolation_descriptor =
|
||||
internal_static_google_rpc_BadRequest_descriptor.getNestedTypes().get(0);
|
||||
internal_static_google_rpc_BadRequest_FieldViolation_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
||||
internal_static_google_rpc_BadRequest_FieldViolation_descriptor,
|
||||
new java.lang.String[] { "Field", "Description", });
|
||||
internal_static_google_rpc_RequestInfo_descriptor =
|
||||
getDescriptor().getMessageTypes().get(5);
|
||||
internal_static_google_rpc_RequestInfo_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
||||
internal_static_google_rpc_RequestInfo_descriptor,
|
||||
new java.lang.String[] { "RequestId", "ServingData", });
|
||||
internal_static_google_rpc_ResourceInfo_descriptor =
|
||||
getDescriptor().getMessageTypes().get(6);
|
||||
internal_static_google_rpc_ResourceInfo_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
||||
internal_static_google_rpc_ResourceInfo_descriptor,
|
||||
new java.lang.String[] { "ResourceType", "ResourceName", "Owner", "Description", });
|
||||
internal_static_google_rpc_Help_descriptor =
|
||||
getDescriptor().getMessageTypes().get(7);
|
||||
internal_static_google_rpc_Help_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
||||
internal_static_google_rpc_Help_descriptor,
|
||||
new java.lang.String[] { "Links", });
|
||||
internal_static_google_rpc_Help_Link_descriptor =
|
||||
internal_static_google_rpc_Help_descriptor.getNestedTypes().get(0);
|
||||
internal_static_google_rpc_Help_Link_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
||||
internal_static_google_rpc_Help_Link_descriptor,
|
||||
new java.lang.String[] { "Description", "Url", });
|
||||
internal_static_google_rpc_LocalizedMessage_descriptor =
|
||||
getDescriptor().getMessageTypes().get(8);
|
||||
internal_static_google_rpc_LocalizedMessage_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
||||
internal_static_google_rpc_LocalizedMessage_descriptor,
|
||||
new java.lang.String[] { "Locale", "Message", });
|
||||
com.google.protobuf.DurationProto.getDescriptor();
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(outer_class_scope)
|
||||
}
|
1674
src/main/java/com/google/rpc/Help.java
Normal file
1674
src/main/java/com/google/rpc/Help.java
Normal file
File diff suppressed because it is too large
Load Diff
53
src/main/java/com/google/rpc/HelpOrBuilder.java
Normal file
53
src/main/java/com/google/rpc/HelpOrBuilder.java
Normal file
@ -0,0 +1,53 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/rpc/error_details.proto
|
||||
|
||||
package com.google.rpc;
|
||||
|
||||
public interface HelpOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:google.rpc.Help)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* URL(s) pointing to additional information on handling the current error.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.rpc.Help.Link links = 1;</code>
|
||||
*/
|
||||
java.util.List<com.google.rpc.Help.Link>
|
||||
getLinksList();
|
||||
/**
|
||||
* <pre>
|
||||
* URL(s) pointing to additional information on handling the current error.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.rpc.Help.Link links = 1;</code>
|
||||
*/
|
||||
com.google.rpc.Help.Link getLinks(int index);
|
||||
/**
|
||||
* <pre>
|
||||
* URL(s) pointing to additional information on handling the current error.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.rpc.Help.Link links = 1;</code>
|
||||
*/
|
||||
int getLinksCount();
|
||||
/**
|
||||
* <pre>
|
||||
* URL(s) pointing to additional information on handling the current error.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.rpc.Help.Link links = 1;</code>
|
||||
*/
|
||||
java.util.List<? extends com.google.rpc.Help.LinkOrBuilder>
|
||||
getLinksOrBuilderList();
|
||||
/**
|
||||
* <pre>
|
||||
* URL(s) pointing to additional information on handling the current error.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.rpc.Help.Link links = 1;</code>
|
||||
*/
|
||||
com.google.rpc.Help.LinkOrBuilder getLinksOrBuilder(
|
||||
int index);
|
||||
}
|
775
src/main/java/com/google/rpc/LocalizedMessage.java
Normal file
775
src/main/java/com/google/rpc/LocalizedMessage.java
Normal file
@ -0,0 +1,775 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/rpc/error_details.proto
|
||||
|
||||
package com.google.rpc;
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Provides a localized error message that is safe to return to the user
|
||||
* which can be attached to an RPC error.
|
||||
* </pre>
|
||||
*
|
||||
* Protobuf type {@code google.rpc.LocalizedMessage}
|
||||
*/
|
||||
public final class LocalizedMessage extends
|
||||
com.google.protobuf.GeneratedMessageV3 implements
|
||||
// @@protoc_insertion_point(message_implements:google.rpc.LocalizedMessage)
|
||||
LocalizedMessageOrBuilder {
|
||||
private static final long serialVersionUID = 0L;
|
||||
// Use LocalizedMessage.newBuilder() to construct.
|
||||
private LocalizedMessage(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
|
||||
super(builder);
|
||||
}
|
||||
private LocalizedMessage() {
|
||||
locale_ = "";
|
||||
message_ = "";
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
@SuppressWarnings({"unused"})
|
||||
protected java.lang.Object newInstance(
|
||||
UnusedPrivateParameter unused) {
|
||||
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
|
||||
getDescriptor() {
|
||||
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_LocalizedMessage_descriptor;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_LocalizedMessage_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
com.google.rpc.LocalizedMessage.class, com.google.rpc.LocalizedMessage.Builder.class);
|
||||
}
|
||||
|
||||
public static final int LOCALE_FIELD_NUMBER = 1;
|
||||
private volatile java.lang.Object locale_;
|
||||
/**
|
||||
* <pre>
|
||||
* The locale used following the specification defined at
|
||||
* http://www.rfc-editor.org/rfc/bcp/bcp47.txt.
|
||||
* Examples are: "en-US", "fr-CH", "es-MX"
|
||||
* </pre>
|
||||
*
|
||||
* <code>string locale = 1;</code>
|
||||
* @return The locale.
|
||||
*/
|
||||
@java.lang.Override
|
||||
public java.lang.String getLocale() {
|
||||
java.lang.Object ref = locale_;
|
||||
if (ref instanceof java.lang.String) {
|
||||
return (java.lang.String) ref;
|
||||
} else {
|
||||
com.google.protobuf.ByteString bs =
|
||||
(com.google.protobuf.ByteString) ref;
|
||||
java.lang.String s = bs.toStringUtf8();
|
||||
locale_ = s;
|
||||
return s;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The locale used following the specification defined at
|
||||
* http://www.rfc-editor.org/rfc/bcp/bcp47.txt.
|
||||
* Examples are: "en-US", "fr-CH", "es-MX"
|
||||
* </pre>
|
||||
*
|
||||
* <code>string locale = 1;</code>
|
||||
* @return The bytes for locale.
|
||||
*/
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.ByteString
|
||||
getLocaleBytes() {
|
||||
java.lang.Object ref = locale_;
|
||||
if (ref instanceof java.lang.String) {
|
||||
com.google.protobuf.ByteString b =
|
||||
com.google.protobuf.ByteString.copyFromUtf8(
|
||||
(java.lang.String) ref);
|
||||
locale_ = b;
|
||||
return b;
|
||||
} else {
|
||||
return (com.google.protobuf.ByteString) ref;
|
||||
}
|
||||
}
|
||||
|
||||
public static final int MESSAGE_FIELD_NUMBER = 2;
|
||||
private volatile java.lang.Object message_;
|
||||
/**
|
||||
* <pre>
|
||||
* The localized error message in the above locale.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string message = 2;</code>
|
||||
* @return The message.
|
||||
*/
|
||||
@java.lang.Override
|
||||
public java.lang.String getMessage() {
|
||||
java.lang.Object ref = message_;
|
||||
if (ref instanceof java.lang.String) {
|
||||
return (java.lang.String) ref;
|
||||
} else {
|
||||
com.google.protobuf.ByteString bs =
|
||||
(com.google.protobuf.ByteString) ref;
|
||||
java.lang.String s = bs.toStringUtf8();
|
||||
message_ = s;
|
||||
return s;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The localized error message in the above locale.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string message = 2;</code>
|
||||
* @return The bytes for message.
|
||||
*/
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.ByteString
|
||||
getMessageBytes() {
|
||||
java.lang.Object ref = message_;
|
||||
if (ref instanceof java.lang.String) {
|
||||
com.google.protobuf.ByteString b =
|
||||
com.google.protobuf.ByteString.copyFromUtf8(
|
||||
(java.lang.String) ref);
|
||||
message_ = b;
|
||||
return b;
|
||||
} else {
|
||||
return (com.google.protobuf.ByteString) ref;
|
||||
}
|
||||
}
|
||||
|
||||
private byte memoizedIsInitialized = -1;
|
||||
@java.lang.Override
|
||||
public final boolean isInitialized() {
|
||||
byte isInitialized = memoizedIsInitialized;
|
||||
if (isInitialized == 1) return true;
|
||||
if (isInitialized == 0) return false;
|
||||
|
||||
memoizedIsInitialized = 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
||||
throws java.io.IOException {
|
||||
if (!getLocaleBytes().isEmpty()) {
|
||||
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, locale_);
|
||||
}
|
||||
if (!getMessageBytes().isEmpty()) {
|
||||
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, message_);
|
||||
}
|
||||
unknownFields.writeTo(output);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public int getSerializedSize() {
|
||||
int size = memoizedSize;
|
||||
if (size != -1) return size;
|
||||
|
||||
size = 0;
|
||||
if (!getLocaleBytes().isEmpty()) {
|
||||
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, locale_);
|
||||
}
|
||||
if (!getMessageBytes().isEmpty()) {
|
||||
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, message_);
|
||||
}
|
||||
size += unknownFields.getSerializedSize();
|
||||
memoizedSize = size;
|
||||
return size;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public boolean equals(final java.lang.Object obj) {
|
||||
if (obj == this) {
|
||||
return true;
|
||||
}
|
||||
if (!(obj instanceof com.google.rpc.LocalizedMessage)) {
|
||||
return super.equals(obj);
|
||||
}
|
||||
com.google.rpc.LocalizedMessage other = (com.google.rpc.LocalizedMessage) obj;
|
||||
|
||||
if (!getLocale()
|
||||
.equals(other.getLocale())) return false;
|
||||
if (!getMessage()
|
||||
.equals(other.getMessage())) return false;
|
||||
if (!unknownFields.equals(other.unknownFields)) return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public int hashCode() {
|
||||
if (memoizedHashCode != 0) {
|
||||
return memoizedHashCode;
|
||||
}
|
||||
int hash = 41;
|
||||
hash = (19 * hash) + getDescriptor().hashCode();
|
||||
hash = (37 * hash) + LOCALE_FIELD_NUMBER;
|
||||
hash = (53 * hash) + getLocale().hashCode();
|
||||
hash = (37 * hash) + MESSAGE_FIELD_NUMBER;
|
||||
hash = (53 * hash) + getMessage().hashCode();
|
||||
hash = (29 * hash) + unknownFields.hashCode();
|
||||
memoizedHashCode = hash;
|
||||
return hash;
|
||||
}
|
||||
|
||||
public static com.google.rpc.LocalizedMessage parseFrom(
|
||||
java.nio.ByteBuffer data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static com.google.rpc.LocalizedMessage parseFrom(
|
||||
java.nio.ByteBuffer data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static com.google.rpc.LocalizedMessage parseFrom(
|
||||
com.google.protobuf.ByteString data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static com.google.rpc.LocalizedMessage parseFrom(
|
||||
com.google.protobuf.ByteString data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static com.google.rpc.LocalizedMessage parseFrom(byte[] data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static com.google.rpc.LocalizedMessage parseFrom(
|
||||
byte[] data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static com.google.rpc.LocalizedMessage parseFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseWithIOException(PARSER, input);
|
||||
}
|
||||
public static com.google.rpc.LocalizedMessage parseFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
||||
}
|
||||
public static com.google.rpc.LocalizedMessage parseDelimitedFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseDelimitedWithIOException(PARSER, input);
|
||||
}
|
||||
public static com.google.rpc.LocalizedMessage parseDelimitedFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
|
||||
}
|
||||
public static com.google.rpc.LocalizedMessage parseFrom(
|
||||
com.google.protobuf.CodedInputStream input)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseWithIOException(PARSER, input);
|
||||
}
|
||||
public static com.google.rpc.LocalizedMessage parseFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public Builder newBuilderForType() { return newBuilder(); }
|
||||
public static Builder newBuilder() {
|
||||
return DEFAULT_INSTANCE.toBuilder();
|
||||
}
|
||||
public static Builder newBuilder(com.google.rpc.LocalizedMessage prototype) {
|
||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder toBuilder() {
|
||||
return this == DEFAULT_INSTANCE
|
||||
? new Builder() : new Builder().mergeFrom(this);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected Builder newBuilderForType(
|
||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
||||
Builder builder = new Builder(parent);
|
||||
return builder;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Provides a localized error message that is safe to return to the user
|
||||
* which can be attached to an RPC error.
|
||||
* </pre>
|
||||
*
|
||||
* Protobuf type {@code google.rpc.LocalizedMessage}
|
||||
*/
|
||||
public static final class Builder extends
|
||||
com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
|
||||
// @@protoc_insertion_point(builder_implements:google.rpc.LocalizedMessage)
|
||||
com.google.rpc.LocalizedMessageOrBuilder {
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_LocalizedMessage_descriptor;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_LocalizedMessage_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
com.google.rpc.LocalizedMessage.class, com.google.rpc.LocalizedMessage.Builder.class);
|
||||
}
|
||||
|
||||
// Construct using com.google.rpc.LocalizedMessage.newBuilder()
|
||||
private Builder() {
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
|
||||
private Builder(
|
||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
||||
super(parent);
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
private void maybeForceBuilderInitialization() {
|
||||
if (com.google.protobuf.GeneratedMessageV3
|
||||
.alwaysUseFieldBuilders) {
|
||||
}
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder clear() {
|
||||
super.clear();
|
||||
locale_ = "";
|
||||
|
||||
message_ = "";
|
||||
|
||||
return this;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptorForType() {
|
||||
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_LocalizedMessage_descriptor;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.rpc.LocalizedMessage getDefaultInstanceForType() {
|
||||
return com.google.rpc.LocalizedMessage.getDefaultInstance();
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.rpc.LocalizedMessage build() {
|
||||
com.google.rpc.LocalizedMessage result = buildPartial();
|
||||
if (!result.isInitialized()) {
|
||||
throw newUninitializedMessageException(result);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.rpc.LocalizedMessage buildPartial() {
|
||||
com.google.rpc.LocalizedMessage result = new com.google.rpc.LocalizedMessage(this);
|
||||
result.locale_ = locale_;
|
||||
result.message_ = message_;
|
||||
onBuilt();
|
||||
return result;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public Builder clone() {
|
||||
return super.clone();
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder setField(
|
||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
||||
java.lang.Object value) {
|
||||
return super.setField(field, value);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder clearField(
|
||||
com.google.protobuf.Descriptors.FieldDescriptor field) {
|
||||
return super.clearField(field);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder clearOneof(
|
||||
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
|
||||
return super.clearOneof(oneof);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder setRepeatedField(
|
||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
||||
int index, java.lang.Object value) {
|
||||
return super.setRepeatedField(field, index, value);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder addRepeatedField(
|
||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
||||
java.lang.Object value) {
|
||||
return super.addRepeatedField(field, value);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
||||
if (other instanceof com.google.rpc.LocalizedMessage) {
|
||||
return mergeFrom((com.google.rpc.LocalizedMessage)other);
|
||||
} else {
|
||||
super.mergeFrom(other);
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
public Builder mergeFrom(com.google.rpc.LocalizedMessage other) {
|
||||
if (other == com.google.rpc.LocalizedMessage.getDefaultInstance()) return this;
|
||||
if (!other.getLocale().isEmpty()) {
|
||||
locale_ = other.locale_;
|
||||
onChanged();
|
||||
}
|
||||
if (!other.getMessage().isEmpty()) {
|
||||
message_ = other.message_;
|
||||
onChanged();
|
||||
}
|
||||
this.mergeUnknownFields(other.unknownFields);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final boolean isInitialized() {
|
||||
return true;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public Builder mergeFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
com.google.rpc.LocalizedMessage parsedMessage = null;
|
||||
try {
|
||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
parsedMessage = (com.google.rpc.LocalizedMessage) e.getUnfinishedMessage();
|
||||
throw e.unwrapIOException();
|
||||
} finally {
|
||||
if (parsedMessage != null) {
|
||||
mergeFrom(parsedMessage);
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
private java.lang.Object locale_ = "";
|
||||
/**
|
||||
* <pre>
|
||||
* The locale used following the specification defined at
|
||||
* http://www.rfc-editor.org/rfc/bcp/bcp47.txt.
|
||||
* Examples are: "en-US", "fr-CH", "es-MX"
|
||||
* </pre>
|
||||
*
|
||||
* <code>string locale = 1;</code>
|
||||
* @return The locale.
|
||||
*/
|
||||
public java.lang.String getLocale() {
|
||||
java.lang.Object ref = locale_;
|
||||
if (!(ref instanceof java.lang.String)) {
|
||||
com.google.protobuf.ByteString bs =
|
||||
(com.google.protobuf.ByteString) ref;
|
||||
java.lang.String s = bs.toStringUtf8();
|
||||
locale_ = s;
|
||||
return s;
|
||||
} else {
|
||||
return (java.lang.String) ref;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The locale used following the specification defined at
|
||||
* http://www.rfc-editor.org/rfc/bcp/bcp47.txt.
|
||||
* Examples are: "en-US", "fr-CH", "es-MX"
|
||||
* </pre>
|
||||
*
|
||||
* <code>string locale = 1;</code>
|
||||
* @return The bytes for locale.
|
||||
*/
|
||||
public com.google.protobuf.ByteString
|
||||
getLocaleBytes() {
|
||||
java.lang.Object ref = locale_;
|
||||
if (ref instanceof String) {
|
||||
com.google.protobuf.ByteString b =
|
||||
com.google.protobuf.ByteString.copyFromUtf8(
|
||||
(java.lang.String) ref);
|
||||
locale_ = b;
|
||||
return b;
|
||||
} else {
|
||||
return (com.google.protobuf.ByteString) ref;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The locale used following the specification defined at
|
||||
* http://www.rfc-editor.org/rfc/bcp/bcp47.txt.
|
||||
* Examples are: "en-US", "fr-CH", "es-MX"
|
||||
* </pre>
|
||||
*
|
||||
* <code>string locale = 1;</code>
|
||||
* @param value The locale to set.
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder setLocale(
|
||||
java.lang.String value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
|
||||
locale_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The locale used following the specification defined at
|
||||
* http://www.rfc-editor.org/rfc/bcp/bcp47.txt.
|
||||
* Examples are: "en-US", "fr-CH", "es-MX"
|
||||
* </pre>
|
||||
*
|
||||
* <code>string locale = 1;</code>
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder clearLocale() {
|
||||
|
||||
locale_ = getDefaultInstance().getLocale();
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The locale used following the specification defined at
|
||||
* http://www.rfc-editor.org/rfc/bcp/bcp47.txt.
|
||||
* Examples are: "en-US", "fr-CH", "es-MX"
|
||||
* </pre>
|
||||
*
|
||||
* <code>string locale = 1;</code>
|
||||
* @param value The bytes for locale to set.
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder setLocaleBytes(
|
||||
com.google.protobuf.ByteString value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
checkByteStringIsUtf8(value);
|
||||
|
||||
locale_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private java.lang.Object message_ = "";
|
||||
/**
|
||||
* <pre>
|
||||
* The localized error message in the above locale.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string message = 2;</code>
|
||||
* @return The message.
|
||||
*/
|
||||
public java.lang.String getMessage() {
|
||||
java.lang.Object ref = message_;
|
||||
if (!(ref instanceof java.lang.String)) {
|
||||
com.google.protobuf.ByteString bs =
|
||||
(com.google.protobuf.ByteString) ref;
|
||||
java.lang.String s = bs.toStringUtf8();
|
||||
message_ = s;
|
||||
return s;
|
||||
} else {
|
||||
return (java.lang.String) ref;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The localized error message in the above locale.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string message = 2;</code>
|
||||
* @return The bytes for message.
|
||||
*/
|
||||
public com.google.protobuf.ByteString
|
||||
getMessageBytes() {
|
||||
java.lang.Object ref = message_;
|
||||
if (ref instanceof String) {
|
||||
com.google.protobuf.ByteString b =
|
||||
com.google.protobuf.ByteString.copyFromUtf8(
|
||||
(java.lang.String) ref);
|
||||
message_ = b;
|
||||
return b;
|
||||
} else {
|
||||
return (com.google.protobuf.ByteString) ref;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The localized error message in the above locale.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string message = 2;</code>
|
||||
* @param value The message to set.
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder setMessage(
|
||||
java.lang.String value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
|
||||
message_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The localized error message in the above locale.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string message = 2;</code>
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder clearMessage() {
|
||||
|
||||
message_ = getDefaultInstance().getMessage();
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* The localized error message in the above locale.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string message = 2;</code>
|
||||
* @param value The bytes for message to set.
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder setMessageBytes(
|
||||
com.google.protobuf.ByteString value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
checkByteStringIsUtf8(value);
|
||||
|
||||
message_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
@java.lang.Override
|
||||
public final Builder setUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return super.setUnknownFields(unknownFields);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final Builder mergeUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return super.mergeUnknownFields(unknownFields);
|
||||
}
|
||||
|
||||
|
||||
// @@protoc_insertion_point(builder_scope:google.rpc.LocalizedMessage)
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(class_scope:google.rpc.LocalizedMessage)
|
||||
private static final com.google.rpc.LocalizedMessage DEFAULT_INSTANCE;
|
||||
static {
|
||||
DEFAULT_INSTANCE = new com.google.rpc.LocalizedMessage();
|
||||
}
|
||||
|
||||
public static com.google.rpc.LocalizedMessage getDefaultInstance() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
private static final com.google.protobuf.Parser<LocalizedMessage>
|
||||
PARSER = new com.google.protobuf.AbstractParser<LocalizedMessage>() {
|
||||
@java.lang.Override
|
||||
public LocalizedMessage parsePartialFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return new LocalizedMessage(input, extensionRegistry);
|
||||
}
|
||||
};
|
||||
|
||||
public static com.google.protobuf.Parser<LocalizedMessage> parser() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Parser<LocalizedMessage> getParserForType() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.rpc.LocalizedMessage getDefaultInstanceForType() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
}
|
||||
|
53
src/main/java/com/google/rpc/LocalizedMessageOrBuilder.java
Normal file
53
src/main/java/com/google/rpc/LocalizedMessageOrBuilder.java
Normal file
@ -0,0 +1,53 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/rpc/error_details.proto
|
||||
|
||||
package com.google.rpc;
|
||||
|
||||
public interface LocalizedMessageOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:google.rpc.LocalizedMessage)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* The locale used following the specification defined at
|
||||
* http://www.rfc-editor.org/rfc/bcp/bcp47.txt.
|
||||
* Examples are: "en-US", "fr-CH", "es-MX"
|
||||
* </pre>
|
||||
*
|
||||
* <code>string locale = 1;</code>
|
||||
* @return The locale.
|
||||
*/
|
||||
java.lang.String getLocale();
|
||||
/**
|
||||
* <pre>
|
||||
* The locale used following the specification defined at
|
||||
* http://www.rfc-editor.org/rfc/bcp/bcp47.txt.
|
||||
* Examples are: "en-US", "fr-CH", "es-MX"
|
||||
* </pre>
|
||||
*
|
||||
* <code>string locale = 1;</code>
|
||||
* @return The bytes for locale.
|
||||
*/
|
||||
com.google.protobuf.ByteString
|
||||
getLocaleBytes();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* The localized error message in the above locale.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string message = 2;</code>
|
||||
* @return The message.
|
||||
*/
|
||||
java.lang.String getMessage();
|
||||
/**
|
||||
* <pre>
|
||||
* The localized error message in the above locale.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string message = 2;</code>
|
||||
* @return The bytes for message.
|
||||
*/
|
||||
com.google.protobuf.ByteString
|
||||
getMessageBytes();
|
||||
}
|
1914
src/main/java/com/google/rpc/PreconditionFailure.java
Normal file
1914
src/main/java/com/google/rpc/PreconditionFailure.java
Normal file
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,53 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/rpc/error_details.proto
|
||||
|
||||
package com.google.rpc;
|
||||
|
||||
public interface PreconditionFailureOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:google.rpc.PreconditionFailure)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Describes all precondition violations.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.rpc.PreconditionFailure.Violation violations = 1;</code>
|
||||
*/
|
||||
java.util.List<com.google.rpc.PreconditionFailure.Violation>
|
||||
getViolationsList();
|
||||
/**
|
||||
* <pre>
|
||||
* Describes all precondition violations.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.rpc.PreconditionFailure.Violation violations = 1;</code>
|
||||
*/
|
||||
com.google.rpc.PreconditionFailure.Violation getViolations(int index);
|
||||
/**
|
||||
* <pre>
|
||||
* Describes all precondition violations.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.rpc.PreconditionFailure.Violation violations = 1;</code>
|
||||
*/
|
||||
int getViolationsCount();
|
||||
/**
|
||||
* <pre>
|
||||
* Describes all precondition violations.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.rpc.PreconditionFailure.Violation violations = 1;</code>
|
||||
*/
|
||||
java.util.List<? extends com.google.rpc.PreconditionFailure.ViolationOrBuilder>
|
||||
getViolationsOrBuilderList();
|
||||
/**
|
||||
* <pre>
|
||||
* Describes all precondition violations.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.rpc.PreconditionFailure.Violation violations = 1;</code>
|
||||
*/
|
||||
com.google.rpc.PreconditionFailure.ViolationOrBuilder getViolationsOrBuilder(
|
||||
int index);
|
||||
}
|
1749
src/main/java/com/google/rpc/QuotaFailure.java
Normal file
1749
src/main/java/com/google/rpc/QuotaFailure.java
Normal file
File diff suppressed because it is too large
Load Diff
53
src/main/java/com/google/rpc/QuotaFailureOrBuilder.java
Normal file
53
src/main/java/com/google/rpc/QuotaFailureOrBuilder.java
Normal file
@ -0,0 +1,53 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/rpc/error_details.proto
|
||||
|
||||
package com.google.rpc;
|
||||
|
||||
public interface QuotaFailureOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:google.rpc.QuotaFailure)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Describes all quota violations.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.rpc.QuotaFailure.Violation violations = 1;</code>
|
||||
*/
|
||||
java.util.List<com.google.rpc.QuotaFailure.Violation>
|
||||
getViolationsList();
|
||||
/**
|
||||
* <pre>
|
||||
* Describes all quota violations.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.rpc.QuotaFailure.Violation violations = 1;</code>
|
||||
*/
|
||||
com.google.rpc.QuotaFailure.Violation getViolations(int index);
|
||||
/**
|
||||
* <pre>
|
||||
* Describes all quota violations.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.rpc.QuotaFailure.Violation violations = 1;</code>
|
||||
*/
|
||||
int getViolationsCount();
|
||||
/**
|
||||
* <pre>
|
||||
* Describes all quota violations.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.rpc.QuotaFailure.Violation violations = 1;</code>
|
||||
*/
|
||||
java.util.List<? extends com.google.rpc.QuotaFailure.ViolationOrBuilder>
|
||||
getViolationsOrBuilderList();
|
||||
/**
|
||||
* <pre>
|
||||
* Describes all quota violations.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.rpc.QuotaFailure.Violation violations = 1;</code>
|
||||
*/
|
||||
com.google.rpc.QuotaFailure.ViolationOrBuilder getViolationsOrBuilder(
|
||||
int index);
|
||||
}
|
775
src/main/java/com/google/rpc/RequestInfo.java
Normal file
775
src/main/java/com/google/rpc/RequestInfo.java
Normal file
@ -0,0 +1,775 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/rpc/error_details.proto
|
||||
|
||||
package com.google.rpc;
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Contains metadata about the request that clients can attach when filing a bug
|
||||
* or providing other forms of feedback.
|
||||
* </pre>
|
||||
*
|
||||
* Protobuf type {@code google.rpc.RequestInfo}
|
||||
*/
|
||||
public final class RequestInfo extends
|
||||
com.google.protobuf.GeneratedMessageV3 implements
|
||||
// @@protoc_insertion_point(message_implements:google.rpc.RequestInfo)
|
||||
RequestInfoOrBuilder {
|
||||
private static final long serialVersionUID = 0L;
|
||||
// Use RequestInfo.newBuilder() to construct.
|
||||
private RequestInfo(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
|
||||
super(builder);
|
||||
}
|
||||
private RequestInfo() {
|
||||
requestId_ = "";
|
||||
servingData_ = "";
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
@SuppressWarnings({"unused"})
|
||||
protected java.lang.Object newInstance(
|
||||
UnusedPrivateParameter unused) {
|
||||
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
|
||||
getDescriptor() {
|
||||
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_RequestInfo_descriptor;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_RequestInfo_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
com.google.rpc.RequestInfo.class, com.google.rpc.RequestInfo.Builder.class);
|
||||
}
|
||||
|
||||
public static final int REQUEST_ID_FIELD_NUMBER = 1;
|
||||
private volatile java.lang.Object requestId_;
|
||||
/**
|
||||
* <pre>
|
||||
* An opaque string that should only be interpreted by the service generating
|
||||
* it. For example, it can be used to identify requests in the service's logs.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string request_id = 1;</code>
|
||||
* @return The requestId.
|
||||
*/
|
||||
@java.lang.Override
|
||||
public java.lang.String getRequestId() {
|
||||
java.lang.Object ref = requestId_;
|
||||
if (ref instanceof java.lang.String) {
|
||||
return (java.lang.String) ref;
|
||||
} else {
|
||||
com.google.protobuf.ByteString bs =
|
||||
(com.google.protobuf.ByteString) ref;
|
||||
java.lang.String s = bs.toStringUtf8();
|
||||
requestId_ = s;
|
||||
return s;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* An opaque string that should only be interpreted by the service generating
|
||||
* it. For example, it can be used to identify requests in the service's logs.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string request_id = 1;</code>
|
||||
* @return The bytes for requestId.
|
||||
*/
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.ByteString
|
||||
getRequestIdBytes() {
|
||||
java.lang.Object ref = requestId_;
|
||||
if (ref instanceof java.lang.String) {
|
||||
com.google.protobuf.ByteString b =
|
||||
com.google.protobuf.ByteString.copyFromUtf8(
|
||||
(java.lang.String) ref);
|
||||
requestId_ = b;
|
||||
return b;
|
||||
} else {
|
||||
return (com.google.protobuf.ByteString) ref;
|
||||
}
|
||||
}
|
||||
|
||||
public static final int SERVING_DATA_FIELD_NUMBER = 2;
|
||||
private volatile java.lang.Object servingData_;
|
||||
/**
|
||||
* <pre>
|
||||
* Any data that was used to serve this request. For example, an encrypted
|
||||
* stack trace that can be sent back to the service provider for debugging.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string serving_data = 2;</code>
|
||||
* @return The servingData.
|
||||
*/
|
||||
@java.lang.Override
|
||||
public java.lang.String getServingData() {
|
||||
java.lang.Object ref = servingData_;
|
||||
if (ref instanceof java.lang.String) {
|
||||
return (java.lang.String) ref;
|
||||
} else {
|
||||
com.google.protobuf.ByteString bs =
|
||||
(com.google.protobuf.ByteString) ref;
|
||||
java.lang.String s = bs.toStringUtf8();
|
||||
servingData_ = s;
|
||||
return s;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Any data that was used to serve this request. For example, an encrypted
|
||||
* stack trace that can be sent back to the service provider for debugging.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string serving_data = 2;</code>
|
||||
* @return The bytes for servingData.
|
||||
*/
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.ByteString
|
||||
getServingDataBytes() {
|
||||
java.lang.Object ref = servingData_;
|
||||
if (ref instanceof java.lang.String) {
|
||||
com.google.protobuf.ByteString b =
|
||||
com.google.protobuf.ByteString.copyFromUtf8(
|
||||
(java.lang.String) ref);
|
||||
servingData_ = b;
|
||||
return b;
|
||||
} else {
|
||||
return (com.google.protobuf.ByteString) ref;
|
||||
}
|
||||
}
|
||||
|
||||
private byte memoizedIsInitialized = -1;
|
||||
@java.lang.Override
|
||||
public final boolean isInitialized() {
|
||||
byte isInitialized = memoizedIsInitialized;
|
||||
if (isInitialized == 1) return true;
|
||||
if (isInitialized == 0) return false;
|
||||
|
||||
memoizedIsInitialized = 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
||||
throws java.io.IOException {
|
||||
if (!getRequestIdBytes().isEmpty()) {
|
||||
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, requestId_);
|
||||
}
|
||||
if (!getServingDataBytes().isEmpty()) {
|
||||
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, servingData_);
|
||||
}
|
||||
unknownFields.writeTo(output);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public int getSerializedSize() {
|
||||
int size = memoizedSize;
|
||||
if (size != -1) return size;
|
||||
|
||||
size = 0;
|
||||
if (!getRequestIdBytes().isEmpty()) {
|
||||
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, requestId_);
|
||||
}
|
||||
if (!getServingDataBytes().isEmpty()) {
|
||||
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, servingData_);
|
||||
}
|
||||
size += unknownFields.getSerializedSize();
|
||||
memoizedSize = size;
|
||||
return size;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public boolean equals(final java.lang.Object obj) {
|
||||
if (obj == this) {
|
||||
return true;
|
||||
}
|
||||
if (!(obj instanceof com.google.rpc.RequestInfo)) {
|
||||
return super.equals(obj);
|
||||
}
|
||||
com.google.rpc.RequestInfo other = (com.google.rpc.RequestInfo) obj;
|
||||
|
||||
if (!getRequestId()
|
||||
.equals(other.getRequestId())) return false;
|
||||
if (!getServingData()
|
||||
.equals(other.getServingData())) return false;
|
||||
if (!unknownFields.equals(other.unknownFields)) return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public int hashCode() {
|
||||
if (memoizedHashCode != 0) {
|
||||
return memoizedHashCode;
|
||||
}
|
||||
int hash = 41;
|
||||
hash = (19 * hash) + getDescriptor().hashCode();
|
||||
hash = (37 * hash) + REQUEST_ID_FIELD_NUMBER;
|
||||
hash = (53 * hash) + getRequestId().hashCode();
|
||||
hash = (37 * hash) + SERVING_DATA_FIELD_NUMBER;
|
||||
hash = (53 * hash) + getServingData().hashCode();
|
||||
hash = (29 * hash) + unknownFields.hashCode();
|
||||
memoizedHashCode = hash;
|
||||
return hash;
|
||||
}
|
||||
|
||||
public static com.google.rpc.RequestInfo parseFrom(
|
||||
java.nio.ByteBuffer data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static com.google.rpc.RequestInfo parseFrom(
|
||||
java.nio.ByteBuffer data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static com.google.rpc.RequestInfo parseFrom(
|
||||
com.google.protobuf.ByteString data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static com.google.rpc.RequestInfo parseFrom(
|
||||
com.google.protobuf.ByteString data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static com.google.rpc.RequestInfo parseFrom(byte[] data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static com.google.rpc.RequestInfo parseFrom(
|
||||
byte[] data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static com.google.rpc.RequestInfo parseFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseWithIOException(PARSER, input);
|
||||
}
|
||||
public static com.google.rpc.RequestInfo parseFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
||||
}
|
||||
public static com.google.rpc.RequestInfo parseDelimitedFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseDelimitedWithIOException(PARSER, input);
|
||||
}
|
||||
public static com.google.rpc.RequestInfo parseDelimitedFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
|
||||
}
|
||||
public static com.google.rpc.RequestInfo parseFrom(
|
||||
com.google.protobuf.CodedInputStream input)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseWithIOException(PARSER, input);
|
||||
}
|
||||
public static com.google.rpc.RequestInfo parseFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public Builder newBuilderForType() { return newBuilder(); }
|
||||
public static Builder newBuilder() {
|
||||
return DEFAULT_INSTANCE.toBuilder();
|
||||
}
|
||||
public static Builder newBuilder(com.google.rpc.RequestInfo prototype) {
|
||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder toBuilder() {
|
||||
return this == DEFAULT_INSTANCE
|
||||
? new Builder() : new Builder().mergeFrom(this);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected Builder newBuilderForType(
|
||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
||||
Builder builder = new Builder(parent);
|
||||
return builder;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Contains metadata about the request that clients can attach when filing a bug
|
||||
* or providing other forms of feedback.
|
||||
* </pre>
|
||||
*
|
||||
* Protobuf type {@code google.rpc.RequestInfo}
|
||||
*/
|
||||
public static final class Builder extends
|
||||
com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
|
||||
// @@protoc_insertion_point(builder_implements:google.rpc.RequestInfo)
|
||||
com.google.rpc.RequestInfoOrBuilder {
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_RequestInfo_descriptor;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_RequestInfo_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
com.google.rpc.RequestInfo.class, com.google.rpc.RequestInfo.Builder.class);
|
||||
}
|
||||
|
||||
// Construct using com.google.rpc.RequestInfo.newBuilder()
|
||||
private Builder() {
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
|
||||
private Builder(
|
||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
||||
super(parent);
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
private void maybeForceBuilderInitialization() {
|
||||
if (com.google.protobuf.GeneratedMessageV3
|
||||
.alwaysUseFieldBuilders) {
|
||||
}
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder clear() {
|
||||
super.clear();
|
||||
requestId_ = "";
|
||||
|
||||
servingData_ = "";
|
||||
|
||||
return this;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptorForType() {
|
||||
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_RequestInfo_descriptor;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.rpc.RequestInfo getDefaultInstanceForType() {
|
||||
return com.google.rpc.RequestInfo.getDefaultInstance();
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.rpc.RequestInfo build() {
|
||||
com.google.rpc.RequestInfo result = buildPartial();
|
||||
if (!result.isInitialized()) {
|
||||
throw newUninitializedMessageException(result);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.rpc.RequestInfo buildPartial() {
|
||||
com.google.rpc.RequestInfo result = new com.google.rpc.RequestInfo(this);
|
||||
result.requestId_ = requestId_;
|
||||
result.servingData_ = servingData_;
|
||||
onBuilt();
|
||||
return result;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public Builder clone() {
|
||||
return super.clone();
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder setField(
|
||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
||||
java.lang.Object value) {
|
||||
return super.setField(field, value);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder clearField(
|
||||
com.google.protobuf.Descriptors.FieldDescriptor field) {
|
||||
return super.clearField(field);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder clearOneof(
|
||||
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
|
||||
return super.clearOneof(oneof);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder setRepeatedField(
|
||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
||||
int index, java.lang.Object value) {
|
||||
return super.setRepeatedField(field, index, value);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder addRepeatedField(
|
||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
||||
java.lang.Object value) {
|
||||
return super.addRepeatedField(field, value);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
||||
if (other instanceof com.google.rpc.RequestInfo) {
|
||||
return mergeFrom((com.google.rpc.RequestInfo)other);
|
||||
} else {
|
||||
super.mergeFrom(other);
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
public Builder mergeFrom(com.google.rpc.RequestInfo other) {
|
||||
if (other == com.google.rpc.RequestInfo.getDefaultInstance()) return this;
|
||||
if (!other.getRequestId().isEmpty()) {
|
||||
requestId_ = other.requestId_;
|
||||
onChanged();
|
||||
}
|
||||
if (!other.getServingData().isEmpty()) {
|
||||
servingData_ = other.servingData_;
|
||||
onChanged();
|
||||
}
|
||||
this.mergeUnknownFields(other.unknownFields);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final boolean isInitialized() {
|
||||
return true;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public Builder mergeFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
com.google.rpc.RequestInfo parsedMessage = null;
|
||||
try {
|
||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
parsedMessage = (com.google.rpc.RequestInfo) e.getUnfinishedMessage();
|
||||
throw e.unwrapIOException();
|
||||
} finally {
|
||||
if (parsedMessage != null) {
|
||||
mergeFrom(parsedMessage);
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
private java.lang.Object requestId_ = "";
|
||||
/**
|
||||
* <pre>
|
||||
* An opaque string that should only be interpreted by the service generating
|
||||
* it. For example, it can be used to identify requests in the service's logs.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string request_id = 1;</code>
|
||||
* @return The requestId.
|
||||
*/
|
||||
public java.lang.String getRequestId() {
|
||||
java.lang.Object ref = requestId_;
|
||||
if (!(ref instanceof java.lang.String)) {
|
||||
com.google.protobuf.ByteString bs =
|
||||
(com.google.protobuf.ByteString) ref;
|
||||
java.lang.String s = bs.toStringUtf8();
|
||||
requestId_ = s;
|
||||
return s;
|
||||
} else {
|
||||
return (java.lang.String) ref;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* An opaque string that should only be interpreted by the service generating
|
||||
* it. For example, it can be used to identify requests in the service's logs.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string request_id = 1;</code>
|
||||
* @return The bytes for requestId.
|
||||
*/
|
||||
public com.google.protobuf.ByteString
|
||||
getRequestIdBytes() {
|
||||
java.lang.Object ref = requestId_;
|
||||
if (ref instanceof String) {
|
||||
com.google.protobuf.ByteString b =
|
||||
com.google.protobuf.ByteString.copyFromUtf8(
|
||||
(java.lang.String) ref);
|
||||
requestId_ = b;
|
||||
return b;
|
||||
} else {
|
||||
return (com.google.protobuf.ByteString) ref;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* An opaque string that should only be interpreted by the service generating
|
||||
* it. For example, it can be used to identify requests in the service's logs.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string request_id = 1;</code>
|
||||
* @param value The requestId to set.
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder setRequestId(
|
||||
java.lang.String value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
|
||||
requestId_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* An opaque string that should only be interpreted by the service generating
|
||||
* it. For example, it can be used to identify requests in the service's logs.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string request_id = 1;</code>
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder clearRequestId() {
|
||||
|
||||
requestId_ = getDefaultInstance().getRequestId();
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* An opaque string that should only be interpreted by the service generating
|
||||
* it. For example, it can be used to identify requests in the service's logs.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string request_id = 1;</code>
|
||||
* @param value The bytes for requestId to set.
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder setRequestIdBytes(
|
||||
com.google.protobuf.ByteString value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
checkByteStringIsUtf8(value);
|
||||
|
||||
requestId_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private java.lang.Object servingData_ = "";
|
||||
/**
|
||||
* <pre>
|
||||
* Any data that was used to serve this request. For example, an encrypted
|
||||
* stack trace that can be sent back to the service provider for debugging.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string serving_data = 2;</code>
|
||||
* @return The servingData.
|
||||
*/
|
||||
public java.lang.String getServingData() {
|
||||
java.lang.Object ref = servingData_;
|
||||
if (!(ref instanceof java.lang.String)) {
|
||||
com.google.protobuf.ByteString bs =
|
||||
(com.google.protobuf.ByteString) ref;
|
||||
java.lang.String s = bs.toStringUtf8();
|
||||
servingData_ = s;
|
||||
return s;
|
||||
} else {
|
||||
return (java.lang.String) ref;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Any data that was used to serve this request. For example, an encrypted
|
||||
* stack trace that can be sent back to the service provider for debugging.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string serving_data = 2;</code>
|
||||
* @return The bytes for servingData.
|
||||
*/
|
||||
public com.google.protobuf.ByteString
|
||||
getServingDataBytes() {
|
||||
java.lang.Object ref = servingData_;
|
||||
if (ref instanceof String) {
|
||||
com.google.protobuf.ByteString b =
|
||||
com.google.protobuf.ByteString.copyFromUtf8(
|
||||
(java.lang.String) ref);
|
||||
servingData_ = b;
|
||||
return b;
|
||||
} else {
|
||||
return (com.google.protobuf.ByteString) ref;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Any data that was used to serve this request. For example, an encrypted
|
||||
* stack trace that can be sent back to the service provider for debugging.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string serving_data = 2;</code>
|
||||
* @param value The servingData to set.
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder setServingData(
|
||||
java.lang.String value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
|
||||
servingData_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Any data that was used to serve this request. For example, an encrypted
|
||||
* stack trace that can be sent back to the service provider for debugging.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string serving_data = 2;</code>
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder clearServingData() {
|
||||
|
||||
servingData_ = getDefaultInstance().getServingData();
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Any data that was used to serve this request. For example, an encrypted
|
||||
* stack trace that can be sent back to the service provider for debugging.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string serving_data = 2;</code>
|
||||
* @param value The bytes for servingData to set.
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder setServingDataBytes(
|
||||
com.google.protobuf.ByteString value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
checkByteStringIsUtf8(value);
|
||||
|
||||
servingData_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
@java.lang.Override
|
||||
public final Builder setUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return super.setUnknownFields(unknownFields);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final Builder mergeUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return super.mergeUnknownFields(unknownFields);
|
||||
}
|
||||
|
||||
|
||||
// @@protoc_insertion_point(builder_scope:google.rpc.RequestInfo)
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(class_scope:google.rpc.RequestInfo)
|
||||
private static final com.google.rpc.RequestInfo DEFAULT_INSTANCE;
|
||||
static {
|
||||
DEFAULT_INSTANCE = new com.google.rpc.RequestInfo();
|
||||
}
|
||||
|
||||
public static com.google.rpc.RequestInfo getDefaultInstance() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
private static final com.google.protobuf.Parser<RequestInfo>
|
||||
PARSER = new com.google.protobuf.AbstractParser<RequestInfo>() {
|
||||
@java.lang.Override
|
||||
public RequestInfo parsePartialFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return new RequestInfo(input, extensionRegistry);
|
||||
}
|
||||
};
|
||||
|
||||
public static com.google.protobuf.Parser<RequestInfo> parser() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Parser<RequestInfo> getParserForType() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.rpc.RequestInfo getDefaultInstanceForType() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
}
|
||||
|
53
src/main/java/com/google/rpc/RequestInfoOrBuilder.java
Normal file
53
src/main/java/com/google/rpc/RequestInfoOrBuilder.java
Normal file
@ -0,0 +1,53 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/rpc/error_details.proto
|
||||
|
||||
package com.google.rpc;
|
||||
|
||||
public interface RequestInfoOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:google.rpc.RequestInfo)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* An opaque string that should only be interpreted by the service generating
|
||||
* it. For example, it can be used to identify requests in the service's logs.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string request_id = 1;</code>
|
||||
* @return The requestId.
|
||||
*/
|
||||
java.lang.String getRequestId();
|
||||
/**
|
||||
* <pre>
|
||||
* An opaque string that should only be interpreted by the service generating
|
||||
* it. For example, it can be used to identify requests in the service's logs.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string request_id = 1;</code>
|
||||
* @return The bytes for requestId.
|
||||
*/
|
||||
com.google.protobuf.ByteString
|
||||
getRequestIdBytes();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Any data that was used to serve this request. For example, an encrypted
|
||||
* stack trace that can be sent back to the service provider for debugging.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string serving_data = 2;</code>
|
||||
* @return The servingData.
|
||||
*/
|
||||
java.lang.String getServingData();
|
||||
/**
|
||||
* <pre>
|
||||
* Any data that was used to serve this request. For example, an encrypted
|
||||
* stack trace that can be sent back to the service provider for debugging.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string serving_data = 2;</code>
|
||||
* @return The bytes for servingData.
|
||||
*/
|
||||
com.google.protobuf.ByteString
|
||||
getServingDataBytes();
|
||||
}
|
1147
src/main/java/com/google/rpc/ResourceInfo.java
Normal file
1147
src/main/java/com/google/rpc/ResourceInfo.java
Normal file
File diff suppressed because it is too large
Load Diff
105
src/main/java/com/google/rpc/ResourceInfoOrBuilder.java
Normal file
105
src/main/java/com/google/rpc/ResourceInfoOrBuilder.java
Normal file
@ -0,0 +1,105 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/rpc/error_details.proto
|
||||
|
||||
package com.google.rpc;
|
||||
|
||||
public interface ResourceInfoOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:google.rpc.ResourceInfo)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* A name for the type of resource being accessed, e.g. "sql table",
|
||||
* "cloud storage bucket", "file", "Google calendar"; or the type URL
|
||||
* of the resource: e.g. "type.googleapis.com/google.pubsub.v1.Topic".
|
||||
* </pre>
|
||||
*
|
||||
* <code>string resource_type = 1;</code>
|
||||
* @return The resourceType.
|
||||
*/
|
||||
java.lang.String getResourceType();
|
||||
/**
|
||||
* <pre>
|
||||
* A name for the type of resource being accessed, e.g. "sql table",
|
||||
* "cloud storage bucket", "file", "Google calendar"; or the type URL
|
||||
* of the resource: e.g. "type.googleapis.com/google.pubsub.v1.Topic".
|
||||
* </pre>
|
||||
*
|
||||
* <code>string resource_type = 1;</code>
|
||||
* @return The bytes for resourceType.
|
||||
*/
|
||||
com.google.protobuf.ByteString
|
||||
getResourceTypeBytes();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* The name of the resource being accessed. For example, a shared calendar
|
||||
* name: "example.com_4fghdhgsrgh@group.calendar.google.com", if the current
|
||||
* error is [google.rpc.Code.PERMISSION_DENIED][google.rpc.Code.PERMISSION_DENIED].
|
||||
* </pre>
|
||||
*
|
||||
* <code>string resource_name = 2;</code>
|
||||
* @return The resourceName.
|
||||
*/
|
||||
java.lang.String getResourceName();
|
||||
/**
|
||||
* <pre>
|
||||
* The name of the resource being accessed. For example, a shared calendar
|
||||
* name: "example.com_4fghdhgsrgh@group.calendar.google.com", if the current
|
||||
* error is [google.rpc.Code.PERMISSION_DENIED][google.rpc.Code.PERMISSION_DENIED].
|
||||
* </pre>
|
||||
*
|
||||
* <code>string resource_name = 2;</code>
|
||||
* @return The bytes for resourceName.
|
||||
*/
|
||||
com.google.protobuf.ByteString
|
||||
getResourceNameBytes();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* The owner of the resource (optional).
|
||||
* For example, "user:<owner email>" or "project:<Google developer project
|
||||
* id>".
|
||||
* </pre>
|
||||
*
|
||||
* <code>string owner = 3;</code>
|
||||
* @return The owner.
|
||||
*/
|
||||
java.lang.String getOwner();
|
||||
/**
|
||||
* <pre>
|
||||
* The owner of the resource (optional).
|
||||
* For example, "user:<owner email>" or "project:<Google developer project
|
||||
* id>".
|
||||
* </pre>
|
||||
*
|
||||
* <code>string owner = 3;</code>
|
||||
* @return The bytes for owner.
|
||||
*/
|
||||
com.google.protobuf.ByteString
|
||||
getOwnerBytes();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Describes what error is encountered when accessing this resource.
|
||||
* For example, updating a cloud project may require the `writer` permission
|
||||
* on the developer console project.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string description = 4;</code>
|
||||
* @return The description.
|
||||
*/
|
||||
java.lang.String getDescription();
|
||||
/**
|
||||
* <pre>
|
||||
* Describes what error is encountered when accessing this resource.
|
||||
* For example, updating a cloud project may require the `writer` permission
|
||||
* on the developer console project.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string description = 4;</code>
|
||||
* @return The bytes for description.
|
||||
*/
|
||||
com.google.protobuf.ByteString
|
||||
getDescriptionBytes();
|
||||
}
|
683
src/main/java/com/google/rpc/RetryInfo.java
Normal file
683
src/main/java/com/google/rpc/RetryInfo.java
Normal file
@ -0,0 +1,683 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/rpc/error_details.proto
|
||||
|
||||
package com.google.rpc;
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Describes when the clients can retry a failed request. Clients could ignore
|
||||
* the recommendation here or retry when this information is missing from error
|
||||
* responses.
|
||||
* It's always recommended that clients should use exponential backoff when
|
||||
* retrying.
|
||||
* Clients should wait until `retry_delay` amount of time has passed since
|
||||
* receiving the error response before retrying. If retrying requests also
|
||||
* fail, clients should use an exponential backoff scheme to gradually increase
|
||||
* the delay between retries based on `retry_delay`, until either a maximum
|
||||
* number of retires have been reached or a maximum retry delay cap has been
|
||||
* reached.
|
||||
* </pre>
|
||||
*
|
||||
* Protobuf type {@code google.rpc.RetryInfo}
|
||||
*/
|
||||
public final class RetryInfo extends
|
||||
com.google.protobuf.GeneratedMessageV3 implements
|
||||
// @@protoc_insertion_point(message_implements:google.rpc.RetryInfo)
|
||||
RetryInfoOrBuilder {
|
||||
private static final long serialVersionUID = 0L;
|
||||
// Use RetryInfo.newBuilder() to construct.
|
||||
private RetryInfo(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
|
||||
super(builder);
|
||||
}
|
||||
private RetryInfo() {
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
@SuppressWarnings({"unused"})
|
||||
protected java.lang.Object newInstance(
|
||||
UnusedPrivateParameter unused) {
|
||||
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
|
||||
getDescriptor() {
|
||||
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_RetryInfo_descriptor;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_RetryInfo_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
com.google.rpc.RetryInfo.class, com.google.rpc.RetryInfo.Builder.class);
|
||||
}
|
||||
|
||||
public static final int RETRY_DELAY_FIELD_NUMBER = 1;
|
||||
private com.google.protobuf.Duration retryDelay_;
|
||||
/**
|
||||
* <pre>
|
||||
* Clients should wait at least this long between retrying the same request.
|
||||
* </pre>
|
||||
*
|
||||
* <code>.google.protobuf.Duration retry_delay = 1;</code>
|
||||
* @return Whether the retryDelay field is set.
|
||||
*/
|
||||
@java.lang.Override
|
||||
public boolean hasRetryDelay() {
|
||||
return retryDelay_ != null;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Clients should wait at least this long between retrying the same request.
|
||||
* </pre>
|
||||
*
|
||||
* <code>.google.protobuf.Duration retry_delay = 1;</code>
|
||||
* @return The retryDelay.
|
||||
*/
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Duration getRetryDelay() {
|
||||
return retryDelay_ == null ? com.google.protobuf.Duration.getDefaultInstance() : retryDelay_;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Clients should wait at least this long between retrying the same request.
|
||||
* </pre>
|
||||
*
|
||||
* <code>.google.protobuf.Duration retry_delay = 1;</code>
|
||||
*/
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.DurationOrBuilder getRetryDelayOrBuilder() {
|
||||
return getRetryDelay();
|
||||
}
|
||||
|
||||
private byte memoizedIsInitialized = -1;
|
||||
@java.lang.Override
|
||||
public final boolean isInitialized() {
|
||||
byte isInitialized = memoizedIsInitialized;
|
||||
if (isInitialized == 1) return true;
|
||||
if (isInitialized == 0) return false;
|
||||
|
||||
memoizedIsInitialized = 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
||||
throws java.io.IOException {
|
||||
if (retryDelay_ != null) {
|
||||
output.writeMessage(1, getRetryDelay());
|
||||
}
|
||||
unknownFields.writeTo(output);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public int getSerializedSize() {
|
||||
int size = memoizedSize;
|
||||
if (size != -1) return size;
|
||||
|
||||
size = 0;
|
||||
if (retryDelay_ != null) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeMessageSize(1, getRetryDelay());
|
||||
}
|
||||
size += unknownFields.getSerializedSize();
|
||||
memoizedSize = size;
|
||||
return size;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public boolean equals(final java.lang.Object obj) {
|
||||
if (obj == this) {
|
||||
return true;
|
||||
}
|
||||
if (!(obj instanceof com.google.rpc.RetryInfo)) {
|
||||
return super.equals(obj);
|
||||
}
|
||||
com.google.rpc.RetryInfo other = (com.google.rpc.RetryInfo) obj;
|
||||
|
||||
if (hasRetryDelay() != other.hasRetryDelay()) return false;
|
||||
if (hasRetryDelay()) {
|
||||
if (!getRetryDelay()
|
||||
.equals(other.getRetryDelay())) return false;
|
||||
}
|
||||
if (!unknownFields.equals(other.unknownFields)) return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public int hashCode() {
|
||||
if (memoizedHashCode != 0) {
|
||||
return memoizedHashCode;
|
||||
}
|
||||
int hash = 41;
|
||||
hash = (19 * hash) + getDescriptor().hashCode();
|
||||
if (hasRetryDelay()) {
|
||||
hash = (37 * hash) + RETRY_DELAY_FIELD_NUMBER;
|
||||
hash = (53 * hash) + getRetryDelay().hashCode();
|
||||
}
|
||||
hash = (29 * hash) + unknownFields.hashCode();
|
||||
memoizedHashCode = hash;
|
||||
return hash;
|
||||
}
|
||||
|
||||
public static com.google.rpc.RetryInfo parseFrom(
|
||||
java.nio.ByteBuffer data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static com.google.rpc.RetryInfo parseFrom(
|
||||
java.nio.ByteBuffer data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static com.google.rpc.RetryInfo parseFrom(
|
||||
com.google.protobuf.ByteString data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static com.google.rpc.RetryInfo parseFrom(
|
||||
com.google.protobuf.ByteString data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static com.google.rpc.RetryInfo parseFrom(byte[] data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static com.google.rpc.RetryInfo parseFrom(
|
||||
byte[] data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static com.google.rpc.RetryInfo parseFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseWithIOException(PARSER, input);
|
||||
}
|
||||
public static com.google.rpc.RetryInfo parseFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
||||
}
|
||||
public static com.google.rpc.RetryInfo parseDelimitedFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseDelimitedWithIOException(PARSER, input);
|
||||
}
|
||||
public static com.google.rpc.RetryInfo parseDelimitedFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
|
||||
}
|
||||
public static com.google.rpc.RetryInfo parseFrom(
|
||||
com.google.protobuf.CodedInputStream input)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseWithIOException(PARSER, input);
|
||||
}
|
||||
public static com.google.rpc.RetryInfo parseFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return com.google.protobuf.GeneratedMessageV3
|
||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public Builder newBuilderForType() { return newBuilder(); }
|
||||
public static Builder newBuilder() {
|
||||
return DEFAULT_INSTANCE.toBuilder();
|
||||
}
|
||||
public static Builder newBuilder(com.google.rpc.RetryInfo prototype) {
|
||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder toBuilder() {
|
||||
return this == DEFAULT_INSTANCE
|
||||
? new Builder() : new Builder().mergeFrom(this);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected Builder newBuilderForType(
|
||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
||||
Builder builder = new Builder(parent);
|
||||
return builder;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Describes when the clients can retry a failed request. Clients could ignore
|
||||
* the recommendation here or retry when this information is missing from error
|
||||
* responses.
|
||||
* It's always recommended that clients should use exponential backoff when
|
||||
* retrying.
|
||||
* Clients should wait until `retry_delay` amount of time has passed since
|
||||
* receiving the error response before retrying. If retrying requests also
|
||||
* fail, clients should use an exponential backoff scheme to gradually increase
|
||||
* the delay between retries based on `retry_delay`, until either a maximum
|
||||
* number of retires have been reached or a maximum retry delay cap has been
|
||||
* reached.
|
||||
* </pre>
|
||||
*
|
||||
* Protobuf type {@code google.rpc.RetryInfo}
|
||||
*/
|
||||
public static final class Builder extends
|
||||
com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
|
||||
// @@protoc_insertion_point(builder_implements:google.rpc.RetryInfo)
|
||||
com.google.rpc.RetryInfoOrBuilder {
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_RetryInfo_descriptor;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_RetryInfo_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
com.google.rpc.RetryInfo.class, com.google.rpc.RetryInfo.Builder.class);
|
||||
}
|
||||
|
||||
// Construct using com.google.rpc.RetryInfo.newBuilder()
|
||||
private Builder() {
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
|
||||
private Builder(
|
||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
||||
super(parent);
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
private void maybeForceBuilderInitialization() {
|
||||
if (com.google.protobuf.GeneratedMessageV3
|
||||
.alwaysUseFieldBuilders) {
|
||||
}
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder clear() {
|
||||
super.clear();
|
||||
if (retryDelayBuilder_ == null) {
|
||||
retryDelay_ = null;
|
||||
} else {
|
||||
retryDelay_ = null;
|
||||
retryDelayBuilder_ = null;
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptorForType() {
|
||||
return com.google.rpc.ErrorDetailsProto.internal_static_google_rpc_RetryInfo_descriptor;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.rpc.RetryInfo getDefaultInstanceForType() {
|
||||
return com.google.rpc.RetryInfo.getDefaultInstance();
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.rpc.RetryInfo build() {
|
||||
com.google.rpc.RetryInfo result = buildPartial();
|
||||
if (!result.isInitialized()) {
|
||||
throw newUninitializedMessageException(result);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.rpc.RetryInfo buildPartial() {
|
||||
com.google.rpc.RetryInfo result = new com.google.rpc.RetryInfo(this);
|
||||
if (retryDelayBuilder_ == null) {
|
||||
result.retryDelay_ = retryDelay_;
|
||||
} else {
|
||||
result.retryDelay_ = retryDelayBuilder_.build();
|
||||
}
|
||||
onBuilt();
|
||||
return result;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public Builder clone() {
|
||||
return super.clone();
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder setField(
|
||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
||||
java.lang.Object value) {
|
||||
return super.setField(field, value);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder clearField(
|
||||
com.google.protobuf.Descriptors.FieldDescriptor field) {
|
||||
return super.clearField(field);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder clearOneof(
|
||||
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
|
||||
return super.clearOneof(oneof);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder setRepeatedField(
|
||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
||||
int index, java.lang.Object value) {
|
||||
return super.setRepeatedField(field, index, value);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder addRepeatedField(
|
||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
||||
java.lang.Object value) {
|
||||
return super.addRepeatedField(field, value);
|
||||
}
|
||||
@java.lang.Override
|
||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
||||
if (other instanceof com.google.rpc.RetryInfo) {
|
||||
return mergeFrom((com.google.rpc.RetryInfo)other);
|
||||
} else {
|
||||
super.mergeFrom(other);
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
public Builder mergeFrom(com.google.rpc.RetryInfo other) {
|
||||
if (other == com.google.rpc.RetryInfo.getDefaultInstance()) return this;
|
||||
if (other.hasRetryDelay()) {
|
||||
mergeRetryDelay(other.getRetryDelay());
|
||||
}
|
||||
this.mergeUnknownFields(other.unknownFields);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final boolean isInitialized() {
|
||||
return true;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public Builder mergeFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
com.google.rpc.RetryInfo parsedMessage = null;
|
||||
try {
|
||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
parsedMessage = (com.google.rpc.RetryInfo) e.getUnfinishedMessage();
|
||||
throw e.unwrapIOException();
|
||||
} finally {
|
||||
if (parsedMessage != null) {
|
||||
mergeFrom(parsedMessage);
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
private com.google.protobuf.Duration retryDelay_;
|
||||
private com.google.protobuf.SingleFieldBuilderV3<
|
||||
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder> retryDelayBuilder_;
|
||||
/**
|
||||
* <pre>
|
||||
* Clients should wait at least this long between retrying the same request.
|
||||
* </pre>
|
||||
*
|
||||
* <code>.google.protobuf.Duration retry_delay = 1;</code>
|
||||
* @return Whether the retryDelay field is set.
|
||||
*/
|
||||
public boolean hasRetryDelay() {
|
||||
return retryDelayBuilder_ != null || retryDelay_ != null;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Clients should wait at least this long between retrying the same request.
|
||||
* </pre>
|
||||
*
|
||||
* <code>.google.protobuf.Duration retry_delay = 1;</code>
|
||||
* @return The retryDelay.
|
||||
*/
|
||||
public com.google.protobuf.Duration getRetryDelay() {
|
||||
if (retryDelayBuilder_ == null) {
|
||||
return retryDelay_ == null ? com.google.protobuf.Duration.getDefaultInstance() : retryDelay_;
|
||||
} else {
|
||||
return retryDelayBuilder_.getMessage();
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Clients should wait at least this long between retrying the same request.
|
||||
* </pre>
|
||||
*
|
||||
* <code>.google.protobuf.Duration retry_delay = 1;</code>
|
||||
*/
|
||||
public Builder setRetryDelay(com.google.protobuf.Duration value) {
|
||||
if (retryDelayBuilder_ == null) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
retryDelay_ = value;
|
||||
onChanged();
|
||||
} else {
|
||||
retryDelayBuilder_.setMessage(value);
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Clients should wait at least this long between retrying the same request.
|
||||
* </pre>
|
||||
*
|
||||
* <code>.google.protobuf.Duration retry_delay = 1;</code>
|
||||
*/
|
||||
public Builder setRetryDelay(
|
||||
com.google.protobuf.Duration.Builder builderForValue) {
|
||||
if (retryDelayBuilder_ == null) {
|
||||
retryDelay_ = builderForValue.build();
|
||||
onChanged();
|
||||
} else {
|
||||
retryDelayBuilder_.setMessage(builderForValue.build());
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Clients should wait at least this long between retrying the same request.
|
||||
* </pre>
|
||||
*
|
||||
* <code>.google.protobuf.Duration retry_delay = 1;</code>
|
||||
*/
|
||||
public Builder mergeRetryDelay(com.google.protobuf.Duration value) {
|
||||
if (retryDelayBuilder_ == null) {
|
||||
if (retryDelay_ != null) {
|
||||
retryDelay_ =
|
||||
com.google.protobuf.Duration.newBuilder(retryDelay_).mergeFrom(value).buildPartial();
|
||||
} else {
|
||||
retryDelay_ = value;
|
||||
}
|
||||
onChanged();
|
||||
} else {
|
||||
retryDelayBuilder_.mergeFrom(value);
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Clients should wait at least this long between retrying the same request.
|
||||
* </pre>
|
||||
*
|
||||
* <code>.google.protobuf.Duration retry_delay = 1;</code>
|
||||
*/
|
||||
public Builder clearRetryDelay() {
|
||||
if (retryDelayBuilder_ == null) {
|
||||
retryDelay_ = null;
|
||||
onChanged();
|
||||
} else {
|
||||
retryDelay_ = null;
|
||||
retryDelayBuilder_ = null;
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Clients should wait at least this long between retrying the same request.
|
||||
* </pre>
|
||||
*
|
||||
* <code>.google.protobuf.Duration retry_delay = 1;</code>
|
||||
*/
|
||||
public com.google.protobuf.Duration.Builder getRetryDelayBuilder() {
|
||||
|
||||
onChanged();
|
||||
return getRetryDelayFieldBuilder().getBuilder();
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Clients should wait at least this long between retrying the same request.
|
||||
* </pre>
|
||||
*
|
||||
* <code>.google.protobuf.Duration retry_delay = 1;</code>
|
||||
*/
|
||||
public com.google.protobuf.DurationOrBuilder getRetryDelayOrBuilder() {
|
||||
if (retryDelayBuilder_ != null) {
|
||||
return retryDelayBuilder_.getMessageOrBuilder();
|
||||
} else {
|
||||
return retryDelay_ == null ?
|
||||
com.google.protobuf.Duration.getDefaultInstance() : retryDelay_;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Clients should wait at least this long between retrying the same request.
|
||||
* </pre>
|
||||
*
|
||||
* <code>.google.protobuf.Duration retry_delay = 1;</code>
|
||||
*/
|
||||
private com.google.protobuf.SingleFieldBuilderV3<
|
||||
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>
|
||||
getRetryDelayFieldBuilder() {
|
||||
if (retryDelayBuilder_ == null) {
|
||||
retryDelayBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
|
||||
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>(
|
||||
getRetryDelay(),
|
||||
getParentForChildren(),
|
||||
isClean());
|
||||
retryDelay_ = null;
|
||||
}
|
||||
return retryDelayBuilder_;
|
||||
}
|
||||
@java.lang.Override
|
||||
public final Builder setUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return super.setUnknownFields(unknownFields);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final Builder mergeUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return super.mergeUnknownFields(unknownFields);
|
||||
}
|
||||
|
||||
|
||||
// @@protoc_insertion_point(builder_scope:google.rpc.RetryInfo)
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(class_scope:google.rpc.RetryInfo)
|
||||
private static final com.google.rpc.RetryInfo DEFAULT_INSTANCE;
|
||||
static {
|
||||
DEFAULT_INSTANCE = new com.google.rpc.RetryInfo();
|
||||
}
|
||||
|
||||
public static com.google.rpc.RetryInfo getDefaultInstance() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
private static final com.google.protobuf.Parser<RetryInfo>
|
||||
PARSER = new com.google.protobuf.AbstractParser<RetryInfo>() {
|
||||
@java.lang.Override
|
||||
public RetryInfo parsePartialFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return new RetryInfo(input, extensionRegistry);
|
||||
}
|
||||
};
|
||||
|
||||
public static com.google.protobuf.Parser<RetryInfo> parser() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Parser<RetryInfo> getParserForType() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.rpc.RetryInfo getDefaultInstanceForType() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
}
|
||||
|
36
src/main/java/com/google/rpc/RetryInfoOrBuilder.java
Normal file
36
src/main/java/com/google/rpc/RetryInfoOrBuilder.java
Normal file
@ -0,0 +1,36 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/rpc/error_details.proto
|
||||
|
||||
package com.google.rpc;
|
||||
|
||||
public interface RetryInfoOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:google.rpc.RetryInfo)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Clients should wait at least this long between retrying the same request.
|
||||
* </pre>
|
||||
*
|
||||
* <code>.google.protobuf.Duration retry_delay = 1;</code>
|
||||
* @return Whether the retryDelay field is set.
|
||||
*/
|
||||
boolean hasRetryDelay();
|
||||
/**
|
||||
* <pre>
|
||||
* Clients should wait at least this long between retrying the same request.
|
||||
* </pre>
|
||||
*
|
||||
* <code>.google.protobuf.Duration retry_delay = 1;</code>
|
||||
* @return The retryDelay.
|
||||
*/
|
||||
com.google.protobuf.Duration getRetryDelay();
|
||||
/**
|
||||
* <pre>
|
||||
* Clients should wait at least this long between retrying the same request.
|
||||
* </pre>
|
||||
*
|
||||
* <code>.google.protobuf.Duration retry_delay = 1;</code>
|
||||
*/
|
||||
com.google.protobuf.DurationOrBuilder getRetryDelayOrBuilder();
|
||||
}
|
1229
src/main/java/com/google/rpc/Status.java
Normal file
1229
src/main/java/com/google/rpc/Status.java
Normal file
File diff suppressed because it is too large
Load Diff
92
src/main/java/com/google/rpc/StatusOrBuilder.java
Normal file
92
src/main/java/com/google/rpc/StatusOrBuilder.java
Normal file
@ -0,0 +1,92 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/rpc/status.proto
|
||||
|
||||
package com.google.rpc;
|
||||
|
||||
public interface StatusOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:google.rpc.Status)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* The status code, which should be an enum value of [google.rpc.Code][google.rpc.Code].
|
||||
* </pre>
|
||||
*
|
||||
* <code>int32 code = 1;</code>
|
||||
* @return The code.
|
||||
*/
|
||||
int getCode();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* A developer-facing error message, which should be in English. Any
|
||||
* user-facing error message should be localized and sent in the
|
||||
* [google.rpc.Status.details][google.rpc.Status.details] field, or localized by the client.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string message = 2;</code>
|
||||
* @return The message.
|
||||
*/
|
||||
java.lang.String getMessage();
|
||||
/**
|
||||
* <pre>
|
||||
* A developer-facing error message, which should be in English. Any
|
||||
* user-facing error message should be localized and sent in the
|
||||
* [google.rpc.Status.details][google.rpc.Status.details] field, or localized by the client.
|
||||
* </pre>
|
||||
*
|
||||
* <code>string message = 2;</code>
|
||||
* @return The bytes for message.
|
||||
*/
|
||||
com.google.protobuf.ByteString
|
||||
getMessageBytes();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* A list of messages that carry the error details. There is a common set of
|
||||
* message types for APIs to use.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.protobuf.Any details = 3;</code>
|
||||
*/
|
||||
java.util.List<com.google.protobuf.Any>
|
||||
getDetailsList();
|
||||
/**
|
||||
* <pre>
|
||||
* A list of messages that carry the error details. There is a common set of
|
||||
* message types for APIs to use.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.protobuf.Any details = 3;</code>
|
||||
*/
|
||||
com.google.protobuf.Any getDetails(int index);
|
||||
/**
|
||||
* <pre>
|
||||
* A list of messages that carry the error details. There is a common set of
|
||||
* message types for APIs to use.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.protobuf.Any details = 3;</code>
|
||||
*/
|
||||
int getDetailsCount();
|
||||
/**
|
||||
* <pre>
|
||||
* A list of messages that carry the error details. There is a common set of
|
||||
* message types for APIs to use.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.protobuf.Any details = 3;</code>
|
||||
*/
|
||||
java.util.List<? extends com.google.protobuf.AnyOrBuilder>
|
||||
getDetailsOrBuilderList();
|
||||
/**
|
||||
* <pre>
|
||||
* A list of messages that carry the error details. There is a common set of
|
||||
* message types for APIs to use.
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated .google.protobuf.Any details = 3;</code>
|
||||
*/
|
||||
com.google.protobuf.AnyOrBuilder getDetailsOrBuilder(
|
||||
int index);
|
||||
}
|
54
src/main/java/com/google/rpc/StatusProto.java
Normal file
54
src/main/java/com/google/rpc/StatusProto.java
Normal file
@ -0,0 +1,54 @@
|
||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: google/rpc/status.proto
|
||||
|
||||
package com.google.rpc;
|
||||
|
||||
public final class StatusProto {
|
||||
private StatusProto() {}
|
||||
public static void registerAllExtensions(
|
||||
com.google.protobuf.ExtensionRegistryLite registry) {
|
||||
}
|
||||
|
||||
public static void registerAllExtensions(
|
||||
com.google.protobuf.ExtensionRegistry registry) {
|
||||
registerAllExtensions(
|
||||
(com.google.protobuf.ExtensionRegistryLite) registry);
|
||||
}
|
||||
static final com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_google_rpc_Status_descriptor;
|
||||
static final
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||
internal_static_google_rpc_Status_fieldAccessorTable;
|
||||
|
||||
public static com.google.protobuf.Descriptors.FileDescriptor
|
||||
getDescriptor() {
|
||||
return descriptor;
|
||||
}
|
||||
private static com.google.protobuf.Descriptors.FileDescriptor
|
||||
descriptor;
|
||||
static {
|
||||
java.lang.String[] descriptorData = {
|
||||
"\n\027google/rpc/status.proto\022\ngoogle.rpc\032\031g" +
|
||||
"oogle/protobuf/any.proto\"N\n\006Status\022\014\n\004co" +
|
||||
"de\030\001 \001(\005\022\017\n\007message\030\002 \001(\t\022%\n\007details\030\003 \003" +
|
||||
"(\0132\024.google.protobuf.AnyB^\n\016com.google.r" +
|
||||
"pcB\013StatusProtoP\001Z7google.golang.org/gen" +
|
||||
"proto/googleapis/rpc/status;status\242\002\003RPC" +
|
||||
"b\006proto3"
|
||||
};
|
||||
descriptor = com.google.protobuf.Descriptors.FileDescriptor
|
||||
.internalBuildGeneratedFileFrom(descriptorData,
|
||||
new com.google.protobuf.Descriptors.FileDescriptor[] {
|
||||
com.google.protobuf.AnyProto.getDescriptor(),
|
||||
});
|
||||
internal_static_google_rpc_Status_descriptor =
|
||||
getDescriptor().getMessageTypes().get(0);
|
||||
internal_static_google_rpc_Status_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
||||
internal_static_google_rpc_Status_descriptor,
|
||||
new java.lang.String[] { "Code", "Message", "Details", });
|
||||
com.google.protobuf.AnyProto.getDescriptor();
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(outer_class_scope)
|
||||
}
|
@ -1956,7 +1956,7 @@ public final class CommonProto {
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* 20字节的交易哈希的数组,或为空
|
||||
* 20字节的事务哈希的数组,或为空
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes transaction_hashes = 11;</code>
|
||||
@ -1965,7 +1965,7 @@ public final class CommonProto {
|
||||
java.util.List<com.google.protobuf.ByteString> getTransactionHashesList();
|
||||
/**
|
||||
* <pre>
|
||||
* 20字节的交易哈希的数组,或为空
|
||||
* 20字节的事务哈希的数组,或为空
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes transaction_hashes = 11;</code>
|
||||
@ -1974,7 +1974,7 @@ public final class CommonProto {
|
||||
int getTransactionHashesCount();
|
||||
/**
|
||||
* <pre>
|
||||
* 20字节的交易哈希的数组,或为空
|
||||
* 20字节的事务哈希的数组,或为空
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes transaction_hashes = 11;</code>
|
||||
@ -1982,6 +1982,45 @@ public final class CommonProto {
|
||||
* @return The transactionHashes at the given index.
|
||||
*/
|
||||
com.google.protobuf.ByteString getTransactionHashes(int index);
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* 产块者签名
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes creator_signature = 12;</code>
|
||||
* @return The creatorSignature.
|
||||
*/
|
||||
com.google.protobuf.ByteString getCreatorSignature();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* 见证者签名
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes witness_signatures = 13;</code>
|
||||
* @return A list containing the witnessSignatures.
|
||||
*/
|
||||
java.util.List<com.google.protobuf.ByteString> getWitnessSignaturesList();
|
||||
/**
|
||||
* <pre>
|
||||
* 见证者签名
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes witness_signatures = 13;</code>
|
||||
* @return The count of witnessSignatures.
|
||||
*/
|
||||
int getWitnessSignaturesCount();
|
||||
/**
|
||||
* <pre>
|
||||
* 见证者签名
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes witness_signatures = 13;</code>
|
||||
* @param index The index of the element to return.
|
||||
* @return The witnessSignatures at the given index.
|
||||
*/
|
||||
com.google.protobuf.ByteString getWitnessSignatures(int index);
|
||||
}
|
||||
/**
|
||||
* Protobuf type {@code bdware.bdledger.api.Block}
|
||||
@ -2003,6 +2042,8 @@ public final class CommonProto {
|
||||
transactionsRoot_ = com.google.protobuf.ByteString.EMPTY;
|
||||
transactions_ = java.util.Collections.emptyList();
|
||||
transactionHashes_ = java.util.Collections.emptyList();
|
||||
creatorSignature_ = com.google.protobuf.ByteString.EMPTY;
|
||||
witnessSignatures_ = java.util.Collections.emptyList();
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
@ -2104,6 +2145,19 @@ public final class CommonProto {
|
||||
transactionHashes_.add(input.readBytes());
|
||||
break;
|
||||
}
|
||||
case 98: {
|
||||
|
||||
creatorSignature_ = input.readBytes();
|
||||
break;
|
||||
}
|
||||
case 106: {
|
||||
if (!((mutable_bitField0_ & 0x00000010) != 0)) {
|
||||
witnessSignatures_ = new java.util.ArrayList<com.google.protobuf.ByteString>();
|
||||
mutable_bitField0_ |= 0x00000010;
|
||||
}
|
||||
witnessSignatures_.add(input.readBytes());
|
||||
break;
|
||||
}
|
||||
default: {
|
||||
if (!parseUnknownField(
|
||||
input, unknownFields, extensionRegistry, tag)) {
|
||||
@ -2131,6 +2185,9 @@ public final class CommonProto {
|
||||
if (((mutable_bitField0_ & 0x00000008) != 0)) {
|
||||
transactionHashes_ = java.util.Collections.unmodifiableList(transactionHashes_); // C
|
||||
}
|
||||
if (((mutable_bitField0_ & 0x00000010) != 0)) {
|
||||
witnessSignatures_ = java.util.Collections.unmodifiableList(witnessSignatures_); // C
|
||||
}
|
||||
this.unknownFields = unknownFields.build();
|
||||
makeExtensionsImmutable();
|
||||
}
|
||||
@ -2395,7 +2452,7 @@ public final class CommonProto {
|
||||
private java.util.List<com.google.protobuf.ByteString> transactionHashes_;
|
||||
/**
|
||||
* <pre>
|
||||
* 20字节的交易哈希的数组,或为空
|
||||
* 20字节的事务哈希的数组,或为空
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes transaction_hashes = 11;</code>
|
||||
@ -2408,7 +2465,7 @@ public final class CommonProto {
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 20字节的交易哈希的数组,或为空
|
||||
* 20字节的事务哈希的数组,或为空
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes transaction_hashes = 11;</code>
|
||||
@ -2419,7 +2476,7 @@ public final class CommonProto {
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 20字节的交易哈希的数组,或为空
|
||||
* 20字节的事务哈希的数组,或为空
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes transaction_hashes = 11;</code>
|
||||
@ -2430,6 +2487,60 @@ public final class CommonProto {
|
||||
return transactionHashes_.get(index);
|
||||
}
|
||||
|
||||
public static final int CREATOR_SIGNATURE_FIELD_NUMBER = 12;
|
||||
private com.google.protobuf.ByteString creatorSignature_;
|
||||
/**
|
||||
* <pre>
|
||||
* 产块者签名
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes creator_signature = 12;</code>
|
||||
* @return The creatorSignature.
|
||||
*/
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.ByteString getCreatorSignature() {
|
||||
return creatorSignature_;
|
||||
}
|
||||
|
||||
public static final int WITNESS_SIGNATURES_FIELD_NUMBER = 13;
|
||||
private java.util.List<com.google.protobuf.ByteString> witnessSignatures_;
|
||||
/**
|
||||
* <pre>
|
||||
* 见证者签名
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes witness_signatures = 13;</code>
|
||||
* @return A list containing the witnessSignatures.
|
||||
*/
|
||||
@java.lang.Override
|
||||
public java.util.List<com.google.protobuf.ByteString>
|
||||
getWitnessSignaturesList() {
|
||||
return witnessSignatures_;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 见证者签名
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes witness_signatures = 13;</code>
|
||||
* @return The count of witnessSignatures.
|
||||
*/
|
||||
public int getWitnessSignaturesCount() {
|
||||
return witnessSignatures_.size();
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 见证者签名
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes witness_signatures = 13;</code>
|
||||
* @param index The index of the element to return.
|
||||
* @return The witnessSignatures at the given index.
|
||||
*/
|
||||
public com.google.protobuf.ByteString getWitnessSignatures(int index) {
|
||||
return witnessSignatures_.get(index);
|
||||
}
|
||||
|
||||
private byte memoizedIsInitialized = -1;
|
||||
@java.lang.Override
|
||||
public final boolean isInitialized() {
|
||||
@ -2477,6 +2588,12 @@ public final class CommonProto {
|
||||
for (int i = 0; i < transactionHashes_.size(); i++) {
|
||||
output.writeBytes(11, transactionHashes_.get(i));
|
||||
}
|
||||
if (!creatorSignature_.isEmpty()) {
|
||||
output.writeBytes(12, creatorSignature_);
|
||||
}
|
||||
for (int i = 0; i < witnessSignatures_.size(); i++) {
|
||||
output.writeBytes(13, witnessSignatures_.get(i));
|
||||
}
|
||||
unknownFields.writeTo(output);
|
||||
}
|
||||
|
||||
@ -2545,6 +2662,19 @@ public final class CommonProto {
|
||||
size += dataSize;
|
||||
size += 1 * getTransactionHashesList().size();
|
||||
}
|
||||
if (!creatorSignature_.isEmpty()) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeBytesSize(12, creatorSignature_);
|
||||
}
|
||||
{
|
||||
int dataSize = 0;
|
||||
for (int i = 0; i < witnessSignatures_.size(); i++) {
|
||||
dataSize += com.google.protobuf.CodedOutputStream
|
||||
.computeBytesSizeNoTag(witnessSignatures_.get(i));
|
||||
}
|
||||
size += dataSize;
|
||||
size += 1 * getWitnessSignaturesList().size();
|
||||
}
|
||||
size += unknownFields.getSerializedSize();
|
||||
memoizedSize = size;
|
||||
return size;
|
||||
@ -2582,6 +2712,10 @@ public final class CommonProto {
|
||||
.equals(other.getTransactionsList())) return false;
|
||||
if (!getTransactionHashesList()
|
||||
.equals(other.getTransactionHashesList())) return false;
|
||||
if (!getCreatorSignature()
|
||||
.equals(other.getCreatorSignature())) return false;
|
||||
if (!getWitnessSignaturesList()
|
||||
.equals(other.getWitnessSignaturesList())) return false;
|
||||
if (!unknownFields.equals(other.unknownFields)) return false;
|
||||
return true;
|
||||
}
|
||||
@ -2626,6 +2760,12 @@ public final class CommonProto {
|
||||
hash = (37 * hash) + TRANSACTION_HASHES_FIELD_NUMBER;
|
||||
hash = (53 * hash) + getTransactionHashesList().hashCode();
|
||||
}
|
||||
hash = (37 * hash) + CREATOR_SIGNATURE_FIELD_NUMBER;
|
||||
hash = (53 * hash) + getCreatorSignature().hashCode();
|
||||
if (getWitnessSignaturesCount() > 0) {
|
||||
hash = (37 * hash) + WITNESS_SIGNATURES_FIELD_NUMBER;
|
||||
hash = (53 * hash) + getWitnessSignaturesList().hashCode();
|
||||
}
|
||||
hash = (29 * hash) + unknownFields.hashCode();
|
||||
memoizedHashCode = hash;
|
||||
return hash;
|
||||
@ -2786,6 +2926,10 @@ public final class CommonProto {
|
||||
}
|
||||
transactionHashes_ = java.util.Collections.emptyList();
|
||||
bitField0_ = (bitField0_ & ~0x00000008);
|
||||
creatorSignature_ = com.google.protobuf.ByteString.EMPTY;
|
||||
|
||||
witnessSignatures_ = java.util.Collections.emptyList();
|
||||
bitField0_ = (bitField0_ & ~0x00000010);
|
||||
return this;
|
||||
}
|
||||
|
||||
@ -2844,6 +2988,12 @@ public final class CommonProto {
|
||||
bitField0_ = (bitField0_ & ~0x00000008);
|
||||
}
|
||||
result.transactionHashes_ = transactionHashes_;
|
||||
result.creatorSignature_ = creatorSignature_;
|
||||
if (((bitField0_ & 0x00000010) != 0)) {
|
||||
witnessSignatures_ = java.util.Collections.unmodifiableList(witnessSignatures_);
|
||||
bitField0_ = (bitField0_ & ~0x00000010);
|
||||
}
|
||||
result.witnessSignatures_ = witnessSignatures_;
|
||||
onBuilt();
|
||||
return result;
|
||||
}
|
||||
@ -2969,6 +3119,19 @@ public final class CommonProto {
|
||||
}
|
||||
onChanged();
|
||||
}
|
||||
if (other.getCreatorSignature() != com.google.protobuf.ByteString.EMPTY) {
|
||||
setCreatorSignature(other.getCreatorSignature());
|
||||
}
|
||||
if (!other.witnessSignatures_.isEmpty()) {
|
||||
if (witnessSignatures_.isEmpty()) {
|
||||
witnessSignatures_ = other.witnessSignatures_;
|
||||
bitField0_ = (bitField0_ & ~0x00000010);
|
||||
} else {
|
||||
ensureWitnessSignaturesIsMutable();
|
||||
witnessSignatures_.addAll(other.witnessSignatures_);
|
||||
}
|
||||
onChanged();
|
||||
}
|
||||
this.mergeUnknownFields(other.unknownFields);
|
||||
onChanged();
|
||||
return this;
|
||||
@ -3856,7 +4019,7 @@ public final class CommonProto {
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 20字节的交易哈希的数组,或为空
|
||||
* 20字节的事务哈希的数组,或为空
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes transaction_hashes = 11;</code>
|
||||
@ -3869,7 +4032,7 @@ public final class CommonProto {
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 20字节的交易哈希的数组,或为空
|
||||
* 20字节的事务哈希的数组,或为空
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes transaction_hashes = 11;</code>
|
||||
@ -3880,7 +4043,7 @@ public final class CommonProto {
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 20字节的交易哈希的数组,或为空
|
||||
* 20字节的事务哈希的数组,或为空
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes transaction_hashes = 11;</code>
|
||||
@ -3892,7 +4055,7 @@ public final class CommonProto {
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 20字节的交易哈希的数组,或为空
|
||||
* 20字节的事务哈希的数组,或为空
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes transaction_hashes = 11;</code>
|
||||
@ -3912,7 +4075,7 @@ public final class CommonProto {
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 20字节的交易哈希的数组,或为空
|
||||
* 20字节的事务哈希的数组,或为空
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes transaction_hashes = 11;</code>
|
||||
@ -3930,7 +4093,7 @@ public final class CommonProto {
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 20字节的交易哈希的数组,或为空
|
||||
* 20字节的事务哈希的数组,或为空
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes transaction_hashes = 11;</code>
|
||||
@ -3947,7 +4110,7 @@ public final class CommonProto {
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 20字节的交易哈希的数组,或为空
|
||||
* 20字节的事务哈希的数组,或为空
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes transaction_hashes = 11;</code>
|
||||
@ -3959,6 +4122,165 @@ public final class CommonProto {
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private com.google.protobuf.ByteString creatorSignature_ = com.google.protobuf.ByteString.EMPTY;
|
||||
/**
|
||||
* <pre>
|
||||
* 产块者签名
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes creator_signature = 12;</code>
|
||||
* @return The creatorSignature.
|
||||
*/
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.ByteString getCreatorSignature() {
|
||||
return creatorSignature_;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 产块者签名
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes creator_signature = 12;</code>
|
||||
* @param value The creatorSignature to set.
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder setCreatorSignature(com.google.protobuf.ByteString value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
|
||||
creatorSignature_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 产块者签名
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes creator_signature = 12;</code>
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder clearCreatorSignature() {
|
||||
|
||||
creatorSignature_ = getDefaultInstance().getCreatorSignature();
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private java.util.List<com.google.protobuf.ByteString> witnessSignatures_ = java.util.Collections.emptyList();
|
||||
private void ensureWitnessSignaturesIsMutable() {
|
||||
if (!((bitField0_ & 0x00000010) != 0)) {
|
||||
witnessSignatures_ = new java.util.ArrayList<com.google.protobuf.ByteString>(witnessSignatures_);
|
||||
bitField0_ |= 0x00000010;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 见证者签名
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes witness_signatures = 13;</code>
|
||||
* @return A list containing the witnessSignatures.
|
||||
*/
|
||||
public java.util.List<com.google.protobuf.ByteString>
|
||||
getWitnessSignaturesList() {
|
||||
return ((bitField0_ & 0x00000010) != 0) ?
|
||||
java.util.Collections.unmodifiableList(witnessSignatures_) : witnessSignatures_;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 见证者签名
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes witness_signatures = 13;</code>
|
||||
* @return The count of witnessSignatures.
|
||||
*/
|
||||
public int getWitnessSignaturesCount() {
|
||||
return witnessSignatures_.size();
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 见证者签名
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes witness_signatures = 13;</code>
|
||||
* @param index The index of the element to return.
|
||||
* @return The witnessSignatures at the given index.
|
||||
*/
|
||||
public com.google.protobuf.ByteString getWitnessSignatures(int index) {
|
||||
return witnessSignatures_.get(index);
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 见证者签名
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes witness_signatures = 13;</code>
|
||||
* @param index The index to set the value at.
|
||||
* @param value The witnessSignatures to set.
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder setWitnessSignatures(
|
||||
int index, com.google.protobuf.ByteString value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
ensureWitnessSignaturesIsMutable();
|
||||
witnessSignatures_.set(index, value);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 见证者签名
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes witness_signatures = 13;</code>
|
||||
* @param value The witnessSignatures to add.
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder addWitnessSignatures(com.google.protobuf.ByteString value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
ensureWitnessSignaturesIsMutable();
|
||||
witnessSignatures_.add(value);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 见证者签名
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes witness_signatures = 13;</code>
|
||||
* @param values The witnessSignatures to add.
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder addAllWitnessSignatures(
|
||||
java.lang.Iterable<? extends com.google.protobuf.ByteString> values) {
|
||||
ensureWitnessSignaturesIsMutable();
|
||||
com.google.protobuf.AbstractMessageLite.Builder.addAll(
|
||||
values, witnessSignatures_);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 见证者签名
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated bytes witness_signatures = 13;</code>
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
public Builder clearWitnessSignatures() {
|
||||
witnessSignatures_ = java.util.Collections.emptyList();
|
||||
bitField0_ = (bitField0_ & ~0x00000010);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
@java.lang.Override
|
||||
public final Builder setUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
@ -5304,26 +5626,28 @@ public final class CommonProto {
|
||||
"$.bdware.bdledger.api.TransactionType\022\014\n" +
|
||||
"\004from\030\006 \001(\014\022\r\n\005nonce\030\007 \001(\004\022\n\n\002to\030\010 \001(\014\022\014" +
|
||||
"\n\004data\030\t \001(\014\022\t\n\001v\030\n \001(\014\022\t\n\001r\030\013 \001(\014\022\t\n\001s\030" +
|
||||
"\014 \001(\014\"\212\002\n\005Block\022\014\n\004hash\030\001 \001(\014\022\017\n\007creator" +
|
||||
"\014 \001(\014\"\301\002\n\005Block\022\014\n\004hash\030\001 \001(\014\022\017\n\007creator" +
|
||||
"\030\002 \001(\014\022\r\n\005nonce\030\003 \001(\004\022\025\n\rparent_hashes\030\004" +
|
||||
" \003(\014\022\021\n\twitnesses\030\005 \003(\014\022\021\n\ttimestamp\030\006 \001" +
|
||||
"(\003\022\014\n\004size\030\007 \001(\004\022\031\n\021transaction_count\030\010 " +
|
||||
"\001(\r\022\031\n\021transactions_root\030\t \001(\014\0226\n\014transa" +
|
||||
"ctions\030\n \003(\0132 .bdware.bdledger.api.Trans" +
|
||||
"action\022\032\n\022transaction_hashes\030\013 \003(\014\"\253\002\n\010C" +
|
||||
"ontract\022\024\n\014contractName\030\001 \001(\014\022\021\n\trandomN" +
|
||||
"um\030\002 \001(\r\022\021\n\toperation\030\003 \001(\014\022\013\n\003arg\030\004 \001(\014" +
|
||||
"\022\014\n\004path\030\005 \001(\014\022\017\n\007content\030\006 \001(\014\022\016\n\006pubke" +
|
||||
"y\030\007 \001(\014\"\246\001\n\027ContractUnitRequestType\022\t\n\005S" +
|
||||
"TART\020\000\022\010\n\004STOP\020\001\022\013\n\007EXECUTE\020\002\022\t\n\005REPLY\020\003" +
|
||||
"\022\013\n\007REQUEST\020\004\022\016\n\nPREPREPARE\020\005\022\013\n\007PREPARE" +
|
||||
"\020\006\022\n\n\006COMMIT\020\007\022\013\n\007ADDPEER\020\010\022\014\n\010DROPPEER\020" +
|
||||
"\t\022\r\n\tSTATESYNC\020\n*o\n\017TransactionType\022\n\n\006R" +
|
||||
"ECORD\020\000\022\013\n\007MESSAGE\020\001\022\025\n\021CONTRACT_CREATIO" +
|
||||
"N\020\002\022\027\n\023CONTRACT_INVOCATION\020\003\022\023\n\017CONTRACT" +
|
||||
"_STATUS\020\004BY\n\037org.bdware.bdledger.api.grp" +
|
||||
"c.pbB\013CommonProtoZ)bdware.org/bdledger/p" +
|
||||
"kg/api/grpc/pb;apipbb\006proto3"
|
||||
"action\022\032\n\022transaction_hashes\030\013 \003(\014\022\031\n\021cr" +
|
||||
"eator_signature\030\014 \001(\014\022\032\n\022witness_signatu" +
|
||||
"res\030\r \003(\014\"\253\002\n\010Contract\022\024\n\014contractName\030\001" +
|
||||
" \001(\014\022\021\n\trandomNum\030\002 \001(\r\022\021\n\toperation\030\003 \001" +
|
||||
"(\014\022\013\n\003arg\030\004 \001(\014\022\014\n\004path\030\005 \001(\014\022\017\n\007content" +
|
||||
"\030\006 \001(\014\022\016\n\006pubkey\030\007 \001(\014\"\246\001\n\027ContractUnitR" +
|
||||
"equestType\022\t\n\005START\020\000\022\010\n\004STOP\020\001\022\013\n\007EXECU" +
|
||||
"TE\020\002\022\t\n\005REPLY\020\003\022\013\n\007REQUEST\020\004\022\016\n\nPREPREPA" +
|
||||
"RE\020\005\022\013\n\007PREPARE\020\006\022\n\n\006COMMIT\020\007\022\013\n\007ADDPEER" +
|
||||
"\020\010\022\014\n\010DROPPEER\020\t\022\r\n\tSTATESYNC\020\n*o\n\017Trans" +
|
||||
"actionType\022\n\n\006RECORD\020\000\022\013\n\007MESSAGE\020\001\022\025\n\021C" +
|
||||
"ONTRACT_CREATION\020\002\022\027\n\023CONTRACT_INVOCATIO" +
|
||||
"N\020\003\022\023\n\017CONTRACT_STATUS\020\004BY\n\037org.bdware.b" +
|
||||
"dledger.api.grpc.pbB\013CommonProtoZ)bdware" +
|
||||
".org/bdledger/pkg/api/grpc/pb;apipbb\006pro" +
|
||||
"to3"
|
||||
};
|
||||
descriptor = com.google.protobuf.Descriptors.FileDescriptor
|
||||
.internalBuildGeneratedFileFrom(descriptorData,
|
||||
@ -5340,7 +5664,7 @@ public final class CommonProto {
|
||||
internal_static_bdware_bdledger_api_Block_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
||||
internal_static_bdware_bdledger_api_Block_descriptor,
|
||||
new java.lang.String[] { "Hash", "Creator", "Nonce", "ParentHashes", "Witnesses", "Timestamp", "Size", "TransactionCount", "TransactionsRoot", "Transactions", "TransactionHashes", });
|
||||
new java.lang.String[] { "Hash", "Creator", "Nonce", "ParentHashes", "Witnesses", "Timestamp", "Size", "TransactionCount", "TransactionsRoot", "Transactions", "TransactionHashes", "CreatorSignature", "WitnessSignatures", });
|
||||
internal_static_bdware_bdledger_api_Contract_descriptor =
|
||||
getDescriptor().getMessageTypes().get(2);
|
||||
internal_static_bdware_bdledger_api_Contract_fieldAccessorTable = new
|
||||
|
@ -1,25 +1,13 @@
|
||||
package org.bdware.bdledger.api.grpc.pb;
|
||||
|
||||
import static io.grpc.MethodDescriptor.generateFullMethodName;
|
||||
import static io.grpc.stub.ClientCalls.asyncBidiStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.asyncClientStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.asyncServerStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.asyncUnaryCall;
|
||||
import static io.grpc.stub.ClientCalls.blockingServerStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.blockingUnaryCall;
|
||||
import static io.grpc.stub.ClientCalls.futureUnaryCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncBidiStreamingCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncClientStreamingCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncServerStreamingCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncUnaryCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncUnimplementedStreamingCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall;
|
||||
|
||||
/**
|
||||
*/
|
||||
@javax.annotation.Generated(
|
||||
value = "by gRPC proto compiler (version 1.32.1)",
|
||||
value = "by gRPC proto compiler (version 1.41.0)",
|
||||
comments = "Source: bdware/bdledger/api/ledger.proto")
|
||||
@io.grpc.stub.annotations.GrpcGenerated
|
||||
public final class LedgerGrpc {
|
||||
|
||||
private LedgerGrpc() {}
|
||||
@ -177,7 +165,7 @@ public final class LedgerGrpc {
|
||||
*/
|
||||
public void createLedger(org.bdware.bdledger.api.grpc.pb.LedgerProto.CreateLedgerRequest request,
|
||||
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.LedgerProto.CreateLedgerResponse> responseObserver) {
|
||||
asyncUnimplementedUnaryCall(getCreateLedgerMethod(), responseObserver);
|
||||
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getCreateLedgerMethod(), responseObserver);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -189,7 +177,7 @@ public final class LedgerGrpc {
|
||||
*/
|
||||
public void getLedgers(com.google.protobuf.Empty request,
|
||||
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.LedgerProto.GetLedgersResponse> responseObserver) {
|
||||
asyncUnimplementedUnaryCall(getGetLedgersMethod(), responseObserver);
|
||||
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetLedgersMethod(), responseObserver);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -201,28 +189,28 @@ public final class LedgerGrpc {
|
||||
*/
|
||||
public void sendTransaction(org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionRequest request,
|
||||
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionResponse> responseObserver) {
|
||||
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(),
|
||||
asyncUnaryCall(
|
||||
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(),
|
||||
asyncUnaryCall(
|
||||
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(),
|
||||
asyncUnaryCall(
|
||||
io.grpc.stub.ServerCalls.asyncUnaryCall(
|
||||
new MethodHandlers<
|
||||
org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionRequest,
|
||||
org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionResponse>(
|
||||
@ -254,7 +242,7 @@ public final class LedgerGrpc {
|
||||
*/
|
||||
public void createLedger(org.bdware.bdledger.api.grpc.pb.LedgerProto.CreateLedgerRequest request,
|
||||
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.LedgerProto.CreateLedgerResponse> responseObserver) {
|
||||
asyncUnaryCall(
|
||||
io.grpc.stub.ClientCalls.asyncUnaryCall(
|
||||
getChannel().newCall(getCreateLedgerMethod(), getCallOptions()), request, responseObserver);
|
||||
}
|
||||
|
||||
@ -267,7 +255,7 @@ public final class LedgerGrpc {
|
||||
*/
|
||||
public void getLedgers(com.google.protobuf.Empty request,
|
||||
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.LedgerProto.GetLedgersResponse> responseObserver) {
|
||||
asyncUnaryCall(
|
||||
io.grpc.stub.ClientCalls.asyncUnaryCall(
|
||||
getChannel().newCall(getGetLedgersMethod(), getCallOptions()), request, responseObserver);
|
||||
}
|
||||
|
||||
@ -280,7 +268,7 @@ public final class LedgerGrpc {
|
||||
*/
|
||||
public void sendTransaction(org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionRequest request,
|
||||
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionResponse> responseObserver) {
|
||||
asyncUnaryCall(
|
||||
io.grpc.stub.ClientCalls.asyncUnaryCall(
|
||||
getChannel().newCall(getSendTransactionMethod(), getCallOptions()), request, responseObserver);
|
||||
}
|
||||
}
|
||||
@ -307,7 +295,7 @@ public final class LedgerGrpc {
|
||||
* </pre>
|
||||
*/
|
||||
public org.bdware.bdledger.api.grpc.pb.LedgerProto.CreateLedgerResponse createLedger(org.bdware.bdledger.api.grpc.pb.LedgerProto.CreateLedgerRequest request) {
|
||||
return blockingUnaryCall(
|
||||
return io.grpc.stub.ClientCalls.blockingUnaryCall(
|
||||
getChannel(), getCreateLedgerMethod(), getCallOptions(), request);
|
||||
}
|
||||
|
||||
@ -319,7 +307,7 @@ public final class LedgerGrpc {
|
||||
* </pre>
|
||||
*/
|
||||
public org.bdware.bdledger.api.grpc.pb.LedgerProto.GetLedgersResponse getLedgers(com.google.protobuf.Empty request) {
|
||||
return blockingUnaryCall(
|
||||
return io.grpc.stub.ClientCalls.blockingUnaryCall(
|
||||
getChannel(), getGetLedgersMethod(), getCallOptions(), request);
|
||||
}
|
||||
|
||||
@ -331,7 +319,7 @@ public final class LedgerGrpc {
|
||||
* </pre>
|
||||
*/
|
||||
public org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionResponse sendTransaction(org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionRequest request) {
|
||||
return blockingUnaryCall(
|
||||
return io.grpc.stub.ClientCalls.blockingUnaryCall(
|
||||
getChannel(), getSendTransactionMethod(), getCallOptions(), request);
|
||||
}
|
||||
}
|
||||
@ -359,7 +347,7 @@ public final class LedgerGrpc {
|
||||
*/
|
||||
public com.google.common.util.concurrent.ListenableFuture<org.bdware.bdledger.api.grpc.pb.LedgerProto.CreateLedgerResponse> createLedger(
|
||||
org.bdware.bdledger.api.grpc.pb.LedgerProto.CreateLedgerRequest request) {
|
||||
return futureUnaryCall(
|
||||
return io.grpc.stub.ClientCalls.futureUnaryCall(
|
||||
getChannel().newCall(getCreateLedgerMethod(), getCallOptions()), request);
|
||||
}
|
||||
|
||||
@ -372,7 +360,7 @@ public final class LedgerGrpc {
|
||||
*/
|
||||
public com.google.common.util.concurrent.ListenableFuture<org.bdware.bdledger.api.grpc.pb.LedgerProto.GetLedgersResponse> getLedgers(
|
||||
com.google.protobuf.Empty request) {
|
||||
return futureUnaryCall(
|
||||
return io.grpc.stub.ClientCalls.futureUnaryCall(
|
||||
getChannel().newCall(getGetLedgersMethod(), getCallOptions()), request);
|
||||
}
|
||||
|
||||
@ -385,7 +373,7 @@ public final class LedgerGrpc {
|
||||
*/
|
||||
public com.google.common.util.concurrent.ListenableFuture<org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionResponse> sendTransaction(
|
||||
org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionRequest request) {
|
||||
return futureUnaryCall(
|
||||
return io.grpc.stub.ClientCalls.futureUnaryCall(
|
||||
getChannel().newCall(getSendTransactionMethod(), getCallOptions()), request);
|
||||
}
|
||||
}
|
||||
|
@ -19,11 +19,21 @@ public final class LedgerProto {
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Ledger name
|
||||
* 账本名称
|
||||
* </pre>
|
||||
*
|
||||
* <code>string name = 1;</code>
|
||||
* @return The name.
|
||||
*/
|
||||
java.lang.String getName();
|
||||
/**
|
||||
* <pre>
|
||||
* Ledger name
|
||||
* 账本名称
|
||||
* </pre>
|
||||
*
|
||||
* <code>string name = 1;</code>
|
||||
* @return The bytes for name.
|
||||
*/
|
||||
@ -117,6 +127,11 @@ public final class LedgerProto {
|
||||
public static final int NAME_FIELD_NUMBER = 1;
|
||||
private volatile java.lang.Object name_;
|
||||
/**
|
||||
* <pre>
|
||||
* Ledger name
|
||||
* 账本名称
|
||||
* </pre>
|
||||
*
|
||||
* <code>string name = 1;</code>
|
||||
* @return The name.
|
||||
*/
|
||||
@ -134,6 +149,11 @@ public final class LedgerProto {
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Ledger name
|
||||
* 账本名称
|
||||
* </pre>
|
||||
*
|
||||
* <code>string name = 1;</code>
|
||||
* @return The bytes for name.
|
||||
*/
|
||||
@ -456,6 +476,11 @@ public final class LedgerProto {
|
||||
|
||||
private java.lang.Object name_ = "";
|
||||
/**
|
||||
* <pre>
|
||||
* Ledger name
|
||||
* 账本名称
|
||||
* </pre>
|
||||
*
|
||||
* <code>string name = 1;</code>
|
||||
* @return The name.
|
||||
*/
|
||||
@ -472,6 +497,11 @@ public final class LedgerProto {
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Ledger name
|
||||
* 账本名称
|
||||
* </pre>
|
||||
*
|
||||
* <code>string name = 1;</code>
|
||||
* @return The bytes for name.
|
||||
*/
|
||||
@ -489,6 +519,11 @@ public final class LedgerProto {
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Ledger name
|
||||
* 账本名称
|
||||
* </pre>
|
||||
*
|
||||
* <code>string name = 1;</code>
|
||||
* @param value The name to set.
|
||||
* @return This builder for chaining.
|
||||
@ -504,6 +539,11 @@ public final class LedgerProto {
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Ledger name
|
||||
* 账本名称
|
||||
* </pre>
|
||||
*
|
||||
* <code>string name = 1;</code>
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
@ -514,6 +554,11 @@ public final class LedgerProto {
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Ledger name
|
||||
* 账本名称
|
||||
* </pre>
|
||||
*
|
||||
* <code>string name = 1;</code>
|
||||
* @param value The bytes for name to set.
|
||||
* @return This builder for chaining.
|
||||
@ -587,6 +632,11 @@ public final class LedgerProto {
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Boolean value indicating if the ledger is successfully created
|
||||
* 是否创建成功
|
||||
* </pre>
|
||||
*
|
||||
* <code>bool ok = 1;</code>
|
||||
* @return The ok.
|
||||
*/
|
||||
@ -677,6 +727,11 @@ public final class LedgerProto {
|
||||
public static final int OK_FIELD_NUMBER = 1;
|
||||
private boolean ok_;
|
||||
/**
|
||||
* <pre>
|
||||
* Boolean value indicating if the ledger is successfully created
|
||||
* 是否创建成功
|
||||
* </pre>
|
||||
*
|
||||
* <code>bool ok = 1;</code>
|
||||
* @return The ok.
|
||||
*/
|
||||
@ -990,6 +1045,11 @@ public final class LedgerProto {
|
||||
|
||||
private boolean ok_ ;
|
||||
/**
|
||||
* <pre>
|
||||
* Boolean value indicating if the ledger is successfully created
|
||||
* 是否创建成功
|
||||
* </pre>
|
||||
*
|
||||
* <code>bool ok = 1;</code>
|
||||
* @return The ok.
|
||||
*/
|
||||
@ -998,6 +1058,11 @@ public final class LedgerProto {
|
||||
return ok_;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Boolean value indicating if the ledger is successfully created
|
||||
* 是否创建成功
|
||||
* </pre>
|
||||
*
|
||||
* <code>bool ok = 1;</code>
|
||||
* @param value The ok to set.
|
||||
* @return This builder for chaining.
|
||||
@ -1009,6 +1074,11 @@ public final class LedgerProto {
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Boolean value indicating if the ledger is successfully created
|
||||
* 是否创建成功
|
||||
* </pre>
|
||||
*
|
||||
* <code>bool ok = 1;</code>
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
@ -1076,23 +1146,43 @@ public final class LedgerProto {
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* List of ledger names
|
||||
* 帐本名称列表
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string ledgers = 1;</code>
|
||||
* @return A list containing the ledgers.
|
||||
*/
|
||||
java.util.List<java.lang.String>
|
||||
getLedgersList();
|
||||
/**
|
||||
* <pre>
|
||||
* List of ledger names
|
||||
* 帐本名称列表
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string ledgers = 1;</code>
|
||||
* @return The count of ledgers.
|
||||
*/
|
||||
int getLedgersCount();
|
||||
/**
|
||||
* <pre>
|
||||
* List of ledger names
|
||||
* 帐本名称列表
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string ledgers = 1;</code>
|
||||
* @param index The index of the element to return.
|
||||
* @return The ledgers at the given index.
|
||||
*/
|
||||
java.lang.String getLedgers(int index);
|
||||
/**
|
||||
* <pre>
|
||||
* List of ledger names
|
||||
* 帐本名称列表
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string ledgers = 1;</code>
|
||||
* @param index The index of the value to return.
|
||||
* @return The bytes of the ledgers at the given index.
|
||||
@ -1194,6 +1284,11 @@ public final class LedgerProto {
|
||||
public static final int LEDGERS_FIELD_NUMBER = 1;
|
||||
private com.google.protobuf.LazyStringList ledgers_;
|
||||
/**
|
||||
* <pre>
|
||||
* List of ledger names
|
||||
* 帐本名称列表
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string ledgers = 1;</code>
|
||||
* @return A list containing the ledgers.
|
||||
*/
|
||||
@ -1202,6 +1297,11 @@ public final class LedgerProto {
|
||||
return ledgers_;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* List of ledger names
|
||||
* 帐本名称列表
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string ledgers = 1;</code>
|
||||
* @return The count of ledgers.
|
||||
*/
|
||||
@ -1209,6 +1309,11 @@ public final class LedgerProto {
|
||||
return ledgers_.size();
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* List of ledger names
|
||||
* 帐本名称列表
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string ledgers = 1;</code>
|
||||
* @param index The index of the element to return.
|
||||
* @return The ledgers at the given index.
|
||||
@ -1217,6 +1322,11 @@ public final class LedgerProto {
|
||||
return ledgers_.get(index);
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* List of ledger names
|
||||
* 帐本名称列表
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string ledgers = 1;</code>
|
||||
* @param index The index of the value to return.
|
||||
* @return The bytes of the ledgers at the given index.
|
||||
@ -1555,6 +1665,11 @@ public final class LedgerProto {
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* List of ledger names
|
||||
* 帐本名称列表
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string ledgers = 1;</code>
|
||||
* @return A list containing the ledgers.
|
||||
*/
|
||||
@ -1563,6 +1678,11 @@ public final class LedgerProto {
|
||||
return ledgers_.getUnmodifiableView();
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* List of ledger names
|
||||
* 帐本名称列表
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string ledgers = 1;</code>
|
||||
* @return The count of ledgers.
|
||||
*/
|
||||
@ -1570,6 +1690,11 @@ public final class LedgerProto {
|
||||
return ledgers_.size();
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* List of ledger names
|
||||
* 帐本名称列表
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string ledgers = 1;</code>
|
||||
* @param index The index of the element to return.
|
||||
* @return The ledgers at the given index.
|
||||
@ -1578,6 +1703,11 @@ public final class LedgerProto {
|
||||
return ledgers_.get(index);
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* List of ledger names
|
||||
* 帐本名称列表
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string ledgers = 1;</code>
|
||||
* @param index The index of the value to return.
|
||||
* @return The bytes of the ledgers at the given index.
|
||||
@ -1587,6 +1717,11 @@ public final class LedgerProto {
|
||||
return ledgers_.getByteString(index);
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* List of ledger names
|
||||
* 帐本名称列表
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string ledgers = 1;</code>
|
||||
* @param index The index to set the value at.
|
||||
* @param value The ledgers to set.
|
||||
@ -1603,6 +1738,11 @@ public final class LedgerProto {
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* List of ledger names
|
||||
* 帐本名称列表
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string ledgers = 1;</code>
|
||||
* @param value The ledgers to add.
|
||||
* @return This builder for chaining.
|
||||
@ -1618,6 +1758,11 @@ public final class LedgerProto {
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* List of ledger names
|
||||
* 帐本名称列表
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string ledgers = 1;</code>
|
||||
* @param values The ledgers to add.
|
||||
* @return This builder for chaining.
|
||||
@ -1631,6 +1776,11 @@ public final class LedgerProto {
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* List of ledger names
|
||||
* 帐本名称列表
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string ledgers = 1;</code>
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
@ -1641,6 +1791,11 @@ public final class LedgerProto {
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* List of ledger names
|
||||
* 帐本名称列表
|
||||
* </pre>
|
||||
*
|
||||
* <code>repeated string ledgers = 1;</code>
|
||||
* @param value The bytes of the ledgers to add.
|
||||
* @return This builder for chaining.
|
||||
@ -1714,11 +1869,21 @@ public final class LedgerProto {
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Ledger name
|
||||
* 账本名称
|
||||
* </pre>
|
||||
*
|
||||
* <code>string ledger = 1;</code>
|
||||
* @return The ledger.
|
||||
*/
|
||||
java.lang.String getLedger();
|
||||
/**
|
||||
* <pre>
|
||||
* Ledger name
|
||||
* 账本名称
|
||||
* </pre>
|
||||
*
|
||||
* <code>string ledger = 1;</code>
|
||||
* @return The bytes for ledger.
|
||||
*/
|
||||
@ -1726,16 +1891,31 @@ public final class LedgerProto {
|
||||
getLedgerBytes();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Transaction info
|
||||
* 事务信息
|
||||
* </pre>
|
||||
*
|
||||
* <code>.bdware.bdledger.api.SendTransactionRequest.Transaction transaction = 2;</code>
|
||||
* @return Whether the transaction field is set.
|
||||
*/
|
||||
boolean hasTransaction();
|
||||
/**
|
||||
* <pre>
|
||||
* Transaction info
|
||||
* 事务信息
|
||||
* </pre>
|
||||
*
|
||||
* <code>.bdware.bdledger.api.SendTransactionRequest.Transaction transaction = 2;</code>
|
||||
* @return The transaction.
|
||||
*/
|
||||
org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionRequest.Transaction getTransaction();
|
||||
/**
|
||||
* <pre>
|
||||
* Transaction info
|
||||
* 事务信息
|
||||
* </pre>
|
||||
*
|
||||
* <code>.bdware.bdledger.api.SendTransactionRequest.Transaction transaction = 2;</code>
|
||||
*/
|
||||
org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionRequest.TransactionOrBuilder getTransactionOrBuilder();
|
||||
@ -1842,35 +2022,59 @@ public final class LedgerProto {
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* 事务类型,目前仅支持通用数据记录,即type为RECORD (0)
|
||||
* </pre>
|
||||
*
|
||||
* <code>.bdware.bdledger.api.TransactionType type = 1;</code>
|
||||
* @return The enum numeric value on the wire for type.
|
||||
*/
|
||||
int getTypeValue();
|
||||
/**
|
||||
* <pre>
|
||||
* 事务类型,目前仅支持通用数据记录,即type为RECORD (0)
|
||||
* </pre>
|
||||
*
|
||||
* <code>.bdware.bdledger.api.TransactionType type = 1;</code>
|
||||
* @return The type.
|
||||
*/
|
||||
org.bdware.bdledger.api.grpc.pb.CommonProto.TransactionType getType();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* 任意20字节的地址,用于区分使用同一节点的事务发起者
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes from = 2;</code>
|
||||
* @return The from.
|
||||
*/
|
||||
com.google.protobuf.ByteString getFrom();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* 正整数,同一from每个nonce应只使用一次,防止重复的事务(可以每次发送事务+1)
|
||||
* </pre>
|
||||
*
|
||||
* <code>uint64 nonce = 3;</code>
|
||||
* @return The nonce.
|
||||
*/
|
||||
long getNonce();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* 对于通用数据记录不需传递,无意义
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes to = 4;</code>
|
||||
* @return The to.
|
||||
*/
|
||||
com.google.protobuf.ByteString getTo();
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* 事务数据内容,字节数组
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes data = 5;</code>
|
||||
* @return The data.
|
||||
*/
|
||||
@ -1986,6 +2190,10 @@ public final class LedgerProto {
|
||||
public static final int TYPE_FIELD_NUMBER = 1;
|
||||
private int type_;
|
||||
/**
|
||||
* <pre>
|
||||
* 事务类型,目前仅支持通用数据记录,即type为RECORD (0)
|
||||
* </pre>
|
||||
*
|
||||
* <code>.bdware.bdledger.api.TransactionType type = 1;</code>
|
||||
* @return The enum numeric value on the wire for type.
|
||||
*/
|
||||
@ -1993,6 +2201,10 @@ public final class LedgerProto {
|
||||
return type_;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 事务类型,目前仅支持通用数据记录,即type为RECORD (0)
|
||||
* </pre>
|
||||
*
|
||||
* <code>.bdware.bdledger.api.TransactionType type = 1;</code>
|
||||
* @return The type.
|
||||
*/
|
||||
@ -2005,6 +2217,10 @@ public final class LedgerProto {
|
||||
public static final int FROM_FIELD_NUMBER = 2;
|
||||
private com.google.protobuf.ByteString from_;
|
||||
/**
|
||||
* <pre>
|
||||
* 任意20字节的地址,用于区分使用同一节点的事务发起者
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes from = 2;</code>
|
||||
* @return The from.
|
||||
*/
|
||||
@ -2016,6 +2232,10 @@ public final class LedgerProto {
|
||||
public static final int NONCE_FIELD_NUMBER = 3;
|
||||
private long nonce_;
|
||||
/**
|
||||
* <pre>
|
||||
* 正整数,同一from每个nonce应只使用一次,防止重复的事务(可以每次发送事务+1)
|
||||
* </pre>
|
||||
*
|
||||
* <code>uint64 nonce = 3;</code>
|
||||
* @return The nonce.
|
||||
*/
|
||||
@ -2027,6 +2247,10 @@ public final class LedgerProto {
|
||||
public static final int TO_FIELD_NUMBER = 4;
|
||||
private com.google.protobuf.ByteString to_;
|
||||
/**
|
||||
* <pre>
|
||||
* 对于通用数据记录不需传递,无意义
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes to = 4;</code>
|
||||
* @return The to.
|
||||
*/
|
||||
@ -2038,6 +2262,10 @@ public final class LedgerProto {
|
||||
public static final int DATA_FIELD_NUMBER = 5;
|
||||
private com.google.protobuf.ByteString data_;
|
||||
/**
|
||||
* <pre>
|
||||
* 事务数据内容,字节数组
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes data = 5;</code>
|
||||
* @return The data.
|
||||
*/
|
||||
@ -2418,6 +2646,10 @@ public final class LedgerProto {
|
||||
|
||||
private int type_ = 0;
|
||||
/**
|
||||
* <pre>
|
||||
* 事务类型,目前仅支持通用数据记录,即type为RECORD (0)
|
||||
* </pre>
|
||||
*
|
||||
* <code>.bdware.bdledger.api.TransactionType type = 1;</code>
|
||||
* @return The enum numeric value on the wire for type.
|
||||
*/
|
||||
@ -2425,6 +2657,10 @@ public final class LedgerProto {
|
||||
return type_;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 事务类型,目前仅支持通用数据记录,即type为RECORD (0)
|
||||
* </pre>
|
||||
*
|
||||
* <code>.bdware.bdledger.api.TransactionType type = 1;</code>
|
||||
* @param value The enum numeric value on the wire for type to set.
|
||||
* @return This builder for chaining.
|
||||
@ -2436,6 +2672,10 @@ public final class LedgerProto {
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 事务类型,目前仅支持通用数据记录,即type为RECORD (0)
|
||||
* </pre>
|
||||
*
|
||||
* <code>.bdware.bdledger.api.TransactionType type = 1;</code>
|
||||
* @return The type.
|
||||
*/
|
||||
@ -2446,6 +2686,10 @@ public final class LedgerProto {
|
||||
return result == null ? org.bdware.bdledger.api.grpc.pb.CommonProto.TransactionType.UNRECOGNIZED : result;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 事务类型,目前仅支持通用数据记录,即type为RECORD (0)
|
||||
* </pre>
|
||||
*
|
||||
* <code>.bdware.bdledger.api.TransactionType type = 1;</code>
|
||||
* @param value The type to set.
|
||||
* @return This builder for chaining.
|
||||
@ -2460,6 +2704,10 @@ public final class LedgerProto {
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 事务类型,目前仅支持通用数据记录,即type为RECORD (0)
|
||||
* </pre>
|
||||
*
|
||||
* <code>.bdware.bdledger.api.TransactionType type = 1;</code>
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
@ -2472,6 +2720,10 @@ public final class LedgerProto {
|
||||
|
||||
private com.google.protobuf.ByteString from_ = com.google.protobuf.ByteString.EMPTY;
|
||||
/**
|
||||
* <pre>
|
||||
* 任意20字节的地址,用于区分使用同一节点的事务发起者
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes from = 2;</code>
|
||||
* @return The from.
|
||||
*/
|
||||
@ -2480,6 +2732,10 @@ public final class LedgerProto {
|
||||
return from_;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 任意20字节的地址,用于区分使用同一节点的事务发起者
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes from = 2;</code>
|
||||
* @param value The from to set.
|
||||
* @return This builder for chaining.
|
||||
@ -2494,6 +2750,10 @@ public final class LedgerProto {
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 任意20字节的地址,用于区分使用同一节点的事务发起者
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes from = 2;</code>
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
@ -2506,6 +2766,10 @@ public final class LedgerProto {
|
||||
|
||||
private long nonce_ ;
|
||||
/**
|
||||
* <pre>
|
||||
* 正整数,同一from每个nonce应只使用一次,防止重复的事务(可以每次发送事务+1)
|
||||
* </pre>
|
||||
*
|
||||
* <code>uint64 nonce = 3;</code>
|
||||
* @return The nonce.
|
||||
*/
|
||||
@ -2514,6 +2778,10 @@ public final class LedgerProto {
|
||||
return nonce_;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 正整数,同一from每个nonce应只使用一次,防止重复的事务(可以每次发送事务+1)
|
||||
* </pre>
|
||||
*
|
||||
* <code>uint64 nonce = 3;</code>
|
||||
* @param value The nonce to set.
|
||||
* @return This builder for chaining.
|
||||
@ -2525,6 +2793,10 @@ public final class LedgerProto {
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 正整数,同一from每个nonce应只使用一次,防止重复的事务(可以每次发送事务+1)
|
||||
* </pre>
|
||||
*
|
||||
* <code>uint64 nonce = 3;</code>
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
@ -2537,6 +2809,10 @@ public final class LedgerProto {
|
||||
|
||||
private com.google.protobuf.ByteString to_ = com.google.protobuf.ByteString.EMPTY;
|
||||
/**
|
||||
* <pre>
|
||||
* 对于通用数据记录不需传递,无意义
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes to = 4;</code>
|
||||
* @return The to.
|
||||
*/
|
||||
@ -2545,6 +2821,10 @@ public final class LedgerProto {
|
||||
return to_;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 对于通用数据记录不需传递,无意义
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes to = 4;</code>
|
||||
* @param value The to to set.
|
||||
* @return This builder for chaining.
|
||||
@ -2559,6 +2839,10 @@ public final class LedgerProto {
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 对于通用数据记录不需传递,无意义
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes to = 4;</code>
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
@ -2571,6 +2855,10 @@ public final class LedgerProto {
|
||||
|
||||
private com.google.protobuf.ByteString data_ = com.google.protobuf.ByteString.EMPTY;
|
||||
/**
|
||||
* <pre>
|
||||
* 事务数据内容,字节数组
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes data = 5;</code>
|
||||
* @return The data.
|
||||
*/
|
||||
@ -2579,6 +2867,10 @@ public final class LedgerProto {
|
||||
return data_;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 事务数据内容,字节数组
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes data = 5;</code>
|
||||
* @param value The data to set.
|
||||
* @return This builder for chaining.
|
||||
@ -2593,6 +2885,10 @@ public final class LedgerProto {
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* 事务数据内容,字节数组
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes data = 5;</code>
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
@ -2658,6 +2954,11 @@ public final class LedgerProto {
|
||||
public static final int LEDGER_FIELD_NUMBER = 1;
|
||||
private volatile java.lang.Object ledger_;
|
||||
/**
|
||||
* <pre>
|
||||
* Ledger name
|
||||
* 账本名称
|
||||
* </pre>
|
||||
*
|
||||
* <code>string ledger = 1;</code>
|
||||
* @return The ledger.
|
||||
*/
|
||||
@ -2675,6 +2976,11 @@ public final class LedgerProto {
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Ledger name
|
||||
* 账本名称
|
||||
* </pre>
|
||||
*
|
||||
* <code>string ledger = 1;</code>
|
||||
* @return The bytes for ledger.
|
||||
*/
|
||||
@ -2696,6 +3002,11 @@ public final class LedgerProto {
|
||||
public static final int TRANSACTION_FIELD_NUMBER = 2;
|
||||
private org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionRequest.Transaction transaction_;
|
||||
/**
|
||||
* <pre>
|
||||
* Transaction info
|
||||
* 事务信息
|
||||
* </pre>
|
||||
*
|
||||
* <code>.bdware.bdledger.api.SendTransactionRequest.Transaction transaction = 2;</code>
|
||||
* @return Whether the transaction field is set.
|
||||
*/
|
||||
@ -2704,6 +3015,11 @@ public final class LedgerProto {
|
||||
return transaction_ != null;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Transaction info
|
||||
* 事务信息
|
||||
* </pre>
|
||||
*
|
||||
* <code>.bdware.bdledger.api.SendTransactionRequest.Transaction transaction = 2;</code>
|
||||
* @return The transaction.
|
||||
*/
|
||||
@ -2712,6 +3028,11 @@ public final class LedgerProto {
|
||||
return transaction_ == null ? org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionRequest.Transaction.getDefaultInstance() : transaction_;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Transaction info
|
||||
* 事务信息
|
||||
* </pre>
|
||||
*
|
||||
* <code>.bdware.bdledger.api.SendTransactionRequest.Transaction transaction = 2;</code>
|
||||
*/
|
||||
@java.lang.Override
|
||||
@ -3053,6 +3374,11 @@ public final class LedgerProto {
|
||||
|
||||
private java.lang.Object ledger_ = "";
|
||||
/**
|
||||
* <pre>
|
||||
* Ledger name
|
||||
* 账本名称
|
||||
* </pre>
|
||||
*
|
||||
* <code>string ledger = 1;</code>
|
||||
* @return The ledger.
|
||||
*/
|
||||
@ -3069,6 +3395,11 @@ public final class LedgerProto {
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Ledger name
|
||||
* 账本名称
|
||||
* </pre>
|
||||
*
|
||||
* <code>string ledger = 1;</code>
|
||||
* @return The bytes for ledger.
|
||||
*/
|
||||
@ -3086,6 +3417,11 @@ public final class LedgerProto {
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Ledger name
|
||||
* 账本名称
|
||||
* </pre>
|
||||
*
|
||||
* <code>string ledger = 1;</code>
|
||||
* @param value The ledger to set.
|
||||
* @return This builder for chaining.
|
||||
@ -3101,6 +3437,11 @@ public final class LedgerProto {
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Ledger name
|
||||
* 账本名称
|
||||
* </pre>
|
||||
*
|
||||
* <code>string ledger = 1;</code>
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
@ -3111,6 +3452,11 @@ public final class LedgerProto {
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Ledger name
|
||||
* 账本名称
|
||||
* </pre>
|
||||
*
|
||||
* <code>string ledger = 1;</code>
|
||||
* @param value The bytes for ledger to set.
|
||||
* @return This builder for chaining.
|
||||
@ -3131,6 +3477,11 @@ public final class LedgerProto {
|
||||
private com.google.protobuf.SingleFieldBuilderV3<
|
||||
org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionRequest.Transaction, org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionRequest.Transaction.Builder, org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionRequest.TransactionOrBuilder> transactionBuilder_;
|
||||
/**
|
||||
* <pre>
|
||||
* Transaction info
|
||||
* 事务信息
|
||||
* </pre>
|
||||
*
|
||||
* <code>.bdware.bdledger.api.SendTransactionRequest.Transaction transaction = 2;</code>
|
||||
* @return Whether the transaction field is set.
|
||||
*/
|
||||
@ -3138,6 +3489,11 @@ public final class LedgerProto {
|
||||
return transactionBuilder_ != null || transaction_ != null;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Transaction info
|
||||
* 事务信息
|
||||
* </pre>
|
||||
*
|
||||
* <code>.bdware.bdledger.api.SendTransactionRequest.Transaction transaction = 2;</code>
|
||||
* @return The transaction.
|
||||
*/
|
||||
@ -3149,6 +3505,11 @@ public final class LedgerProto {
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Transaction info
|
||||
* 事务信息
|
||||
* </pre>
|
||||
*
|
||||
* <code>.bdware.bdledger.api.SendTransactionRequest.Transaction transaction = 2;</code>
|
||||
*/
|
||||
public Builder setTransaction(org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionRequest.Transaction value) {
|
||||
@ -3165,6 +3526,11 @@ public final class LedgerProto {
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Transaction info
|
||||
* 事务信息
|
||||
* </pre>
|
||||
*
|
||||
* <code>.bdware.bdledger.api.SendTransactionRequest.Transaction transaction = 2;</code>
|
||||
*/
|
||||
public Builder setTransaction(
|
||||
@ -3179,6 +3545,11 @@ public final class LedgerProto {
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Transaction info
|
||||
* 事务信息
|
||||
* </pre>
|
||||
*
|
||||
* <code>.bdware.bdledger.api.SendTransactionRequest.Transaction transaction = 2;</code>
|
||||
*/
|
||||
public Builder mergeTransaction(org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionRequest.Transaction value) {
|
||||
@ -3197,6 +3568,11 @@ public final class LedgerProto {
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Transaction info
|
||||
* 事务信息
|
||||
* </pre>
|
||||
*
|
||||
* <code>.bdware.bdledger.api.SendTransactionRequest.Transaction transaction = 2;</code>
|
||||
*/
|
||||
public Builder clearTransaction() {
|
||||
@ -3211,6 +3587,11 @@ public final class LedgerProto {
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Transaction info
|
||||
* 事务信息
|
||||
* </pre>
|
||||
*
|
||||
* <code>.bdware.bdledger.api.SendTransactionRequest.Transaction transaction = 2;</code>
|
||||
*/
|
||||
public org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionRequest.Transaction.Builder getTransactionBuilder() {
|
||||
@ -3219,6 +3600,11 @@ public final class LedgerProto {
|
||||
return getTransactionFieldBuilder().getBuilder();
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Transaction info
|
||||
* 事务信息
|
||||
* </pre>
|
||||
*
|
||||
* <code>.bdware.bdledger.api.SendTransactionRequest.Transaction transaction = 2;</code>
|
||||
*/
|
||||
public org.bdware.bdledger.api.grpc.pb.LedgerProto.SendTransactionRequest.TransactionOrBuilder getTransactionOrBuilder() {
|
||||
@ -3230,6 +3616,11 @@ public final class LedgerProto {
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Transaction info
|
||||
* 事务信息
|
||||
* </pre>
|
||||
*
|
||||
* <code>.bdware.bdledger.api.SendTransactionRequest.Transaction transaction = 2;</code>
|
||||
*/
|
||||
private com.google.protobuf.SingleFieldBuilderV3<
|
||||
@ -3303,6 +3694,11 @@ public final class LedgerProto {
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Hash of the created transaction
|
||||
* 事务哈希
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes hash = 1;</code>
|
||||
* @return The hash.
|
||||
*/
|
||||
@ -3394,6 +3790,11 @@ public final class LedgerProto {
|
||||
public static final int HASH_FIELD_NUMBER = 1;
|
||||
private com.google.protobuf.ByteString hash_;
|
||||
/**
|
||||
* <pre>
|
||||
* Hash of the created transaction
|
||||
* 事务哈希
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes hash = 1;</code>
|
||||
* @return The hash.
|
||||
*/
|
||||
@ -3706,6 +4107,11 @@ public final class LedgerProto {
|
||||
|
||||
private com.google.protobuf.ByteString hash_ = com.google.protobuf.ByteString.EMPTY;
|
||||
/**
|
||||
* <pre>
|
||||
* Hash of the created transaction
|
||||
* 事务哈希
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes hash = 1;</code>
|
||||
* @return The hash.
|
||||
*/
|
||||
@ -3714,6 +4120,11 @@ public final class LedgerProto {
|
||||
return hash_;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Hash of the created transaction
|
||||
* 事务哈希
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes hash = 1;</code>
|
||||
* @param value The hash to set.
|
||||
* @return This builder for chaining.
|
||||
@ -3728,6 +4139,11 @@ public final class LedgerProto {
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Hash of the created transaction
|
||||
* 事务哈希
|
||||
* </pre>
|
||||
*
|
||||
* <code>bytes hash = 1;</code>
|
||||
* @return This builder for chaining.
|
||||
*/
|
||||
|
@ -1,25 +1,13 @@
|
||||
package org.bdware.bdledger.api.grpc.pb;
|
||||
|
||||
import static io.grpc.MethodDescriptor.generateFullMethodName;
|
||||
import static io.grpc.stub.ClientCalls.asyncBidiStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.asyncClientStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.asyncServerStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.asyncUnaryCall;
|
||||
import static io.grpc.stub.ClientCalls.blockingServerStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.blockingUnaryCall;
|
||||
import static io.grpc.stub.ClientCalls.futureUnaryCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncBidiStreamingCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncClientStreamingCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncServerStreamingCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncUnaryCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncUnimplementedStreamingCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall;
|
||||
|
||||
/**
|
||||
*/
|
||||
@javax.annotation.Generated(
|
||||
value = "by gRPC proto compiler (version 1.32.1)",
|
||||
value = "by gRPC proto compiler (version 1.41.0)",
|
||||
comments = "Source: bdware/bdledger/api/node.proto")
|
||||
@io.grpc.stub.annotations.GrpcGenerated
|
||||
public final class NodeGrpc {
|
||||
|
||||
private NodeGrpc() {}
|
||||
@ -115,14 +103,14 @@ public final class NodeGrpc {
|
||||
*/
|
||||
public void clientVersion(com.google.protobuf.Empty request,
|
||||
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse> responseObserver) {
|
||||
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(),
|
||||
asyncUnaryCall(
|
||||
io.grpc.stub.ServerCalls.asyncUnaryCall(
|
||||
new MethodHandlers<
|
||||
com.google.protobuf.Empty,
|
||||
org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse>(
|
||||
@ -154,7 +142,7 @@ public final class NodeGrpc {
|
||||
*/
|
||||
public void clientVersion(com.google.protobuf.Empty request,
|
||||
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse> responseObserver) {
|
||||
asyncUnaryCall(
|
||||
io.grpc.stub.ClientCalls.asyncUnaryCall(
|
||||
getChannel().newCall(getClientVersionMethod(), getCallOptions()), request, responseObserver);
|
||||
}
|
||||
}
|
||||
@ -181,7 +169,7 @@ public final class NodeGrpc {
|
||||
* </pre>
|
||||
*/
|
||||
public org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse clientVersion(com.google.protobuf.Empty request) {
|
||||
return blockingUnaryCall(
|
||||
return io.grpc.stub.ClientCalls.blockingUnaryCall(
|
||||
getChannel(), getClientVersionMethod(), getCallOptions(), request);
|
||||
}
|
||||
}
|
||||
@ -209,7 +197,7 @@ public final class NodeGrpc {
|
||||
*/
|
||||
public com.google.common.util.concurrent.ListenableFuture<org.bdware.bdledger.api.grpc.pb.NodeProto.ClientVersionResponse> clientVersion(
|
||||
com.google.protobuf.Empty request) {
|
||||
return futureUnaryCall(
|
||||
return io.grpc.stub.ClientCalls.futureUnaryCall(
|
||||
getChannel().newCall(getClientVersionMethod(), getCallOptions()), request);
|
||||
}
|
||||
}
|
||||
|
@ -20,6 +20,7 @@ public final class NodeProto {
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Client version
|
||||
* 节点客户端版本
|
||||
* </pre>
|
||||
*
|
||||
@ -29,6 +30,7 @@ public final class NodeProto {
|
||||
java.lang.String getVersion();
|
||||
/**
|
||||
* <pre>
|
||||
* Client version
|
||||
* 节点客户端版本
|
||||
* </pre>
|
||||
*
|
||||
@ -126,6 +128,7 @@ public final class NodeProto {
|
||||
private volatile java.lang.Object version_;
|
||||
/**
|
||||
* <pre>
|
||||
* Client version
|
||||
* 节点客户端版本
|
||||
* </pre>
|
||||
*
|
||||
@ -147,6 +150,7 @@ public final class NodeProto {
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Client version
|
||||
* 节点客户端版本
|
||||
* </pre>
|
||||
*
|
||||
@ -473,6 +477,7 @@ public final class NodeProto {
|
||||
private java.lang.Object version_ = "";
|
||||
/**
|
||||
* <pre>
|
||||
* Client version
|
||||
* 节点客户端版本
|
||||
* </pre>
|
||||
*
|
||||
@ -493,6 +498,7 @@ public final class NodeProto {
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Client version
|
||||
* 节点客户端版本
|
||||
* </pre>
|
||||
*
|
||||
@ -514,6 +520,7 @@ public final class NodeProto {
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Client version
|
||||
* 节点客户端版本
|
||||
* </pre>
|
||||
*
|
||||
@ -533,6 +540,7 @@ public final class NodeProto {
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Client version
|
||||
* 节点客户端版本
|
||||
* </pre>
|
||||
*
|
||||
@ -547,6 +555,7 @@ public final class NodeProto {
|
||||
}
|
||||
/**
|
||||
* <pre>
|
||||
* Client version
|
||||
* 节点客户端版本
|
||||
* </pre>
|
||||
*
|
||||
|
@ -1,25 +1,13 @@
|
||||
package org.bdware.bdledger.api.grpc.pb;
|
||||
|
||||
import static io.grpc.MethodDescriptor.generateFullMethodName;
|
||||
import static io.grpc.stub.ClientCalls.asyncBidiStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.asyncClientStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.asyncServerStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.asyncUnaryCall;
|
||||
import static io.grpc.stub.ClientCalls.blockingServerStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.blockingUnaryCall;
|
||||
import static io.grpc.stub.ClientCalls.futureUnaryCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncBidiStreamingCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncClientStreamingCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncServerStreamingCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncUnaryCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncUnimplementedStreamingCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall;
|
||||
|
||||
/**
|
||||
*/
|
||||
@javax.annotation.Generated(
|
||||
value = "by gRPC proto compiler (version 1.32.1)",
|
||||
value = "by gRPC proto compiler (version 1.41.0)",
|
||||
comments = "Source: bdware/bdledger/api/query.proto")
|
||||
@io.grpc.stub.annotations.GrpcGenerated
|
||||
public final class QueryGrpc {
|
||||
|
||||
private QueryGrpc() {}
|
||||
@ -332,7 +320,7 @@ public final class QueryGrpc {
|
||||
*/
|
||||
public void getBlockByHash(org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlockByHashRequest request,
|
||||
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlockByHashResponse> responseObserver) {
|
||||
asyncUnimplementedUnaryCall(getGetBlockByHashMethod(), responseObserver);
|
||||
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetBlockByHashMethod(), responseObserver);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -340,12 +328,20 @@ public final class QueryGrpc {
|
||||
**
|
||||
* Get blocks in a timestamp range
|
||||
* 查询时间范围内的区块
|
||||
* start_timestamp is required
|
||||
* Requirement: start_timestamp <= 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 > 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 void getBlocks(org.bdware.bdledger.api.grpc.pb.QueryProto.BlocksRequest request,
|
||||
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlocksResponse> responseObserver) {
|
||||
asyncUnimplementedUnaryCall(getGetBlocksMethod(), responseObserver);
|
||||
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetBlocksMethod(), responseObserver);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -353,23 +349,29 @@ public final class QueryGrpc {
|
||||
**
|
||||
* Count all blocks in a ledger, or blocks in a timestamp range
|
||||
* 查询帐本中的所有区块数量,或时间范围内的区块数量
|
||||
* Requirement: start_timestamp <= 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 void countBlocks(org.bdware.bdledger.api.grpc.pb.QueryProto.BlocksRequest request,
|
||||
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.CountBlocksResponse> responseObserver) {
|
||||
asyncUnimplementedUnaryCall(getCountBlocksMethod(), responseObserver);
|
||||
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getCountBlocksMethod(), responseObserver);
|
||||
}
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
**
|
||||
* Get recent 'count' blocks (Only support IncludeTransactions=NONE for now)
|
||||
* 查询最新的n个区块
|
||||
* 查询最新的 'count' 个区块
|
||||
* </pre>
|
||||
*/
|
||||
public void getRecentBlocks(org.bdware.bdledger.api.grpc.pb.QueryProto.RecentBlocksRequest request,
|
||||
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlocksResponse> responseObserver) {
|
||||
asyncUnimplementedUnaryCall(getGetRecentBlocksMethod(), responseObserver);
|
||||
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetRecentBlocksMethod(), responseObserver);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -381,7 +383,7 @@ public final class QueryGrpc {
|
||||
*/
|
||||
public void getTransactionByHash(org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByHashRequest request,
|
||||
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByHashResponse> responseObserver) {
|
||||
asyncUnimplementedUnaryCall(getGetTransactionByHashMethod(), responseObserver);
|
||||
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetTransactionByHashMethod(), responseObserver);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -393,7 +395,7 @@ public final class QueryGrpc {
|
||||
*/
|
||||
public void getTransactionByBlockHashAndIndex(org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByBlockHashAndIndexRequest request,
|
||||
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByBlockHashAndIndexResponse> responseObserver) {
|
||||
asyncUnimplementedUnaryCall(getGetTransactionByBlockHashAndIndexMethod(), responseObserver);
|
||||
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetTransactionByBlockHashAndIndexMethod(), responseObserver);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -401,11 +403,12 @@ public final class QueryGrpc {
|
||||
**
|
||||
* Get transactions in a timestamp range
|
||||
* 查询时间范围内的事务
|
||||
* 'start_timestamp' and 'end_timestamp' follow the same requirements and rules as in 'GetBlocks'.
|
||||
* </pre>
|
||||
*/
|
||||
public void getTransactions(org.bdware.bdledger.api.grpc.pb.QueryProto.TransactionsRequest request,
|
||||
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionsResponse> responseObserver) {
|
||||
asyncUnimplementedUnaryCall(getGetTransactionsMethod(), responseObserver);
|
||||
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetTransactionsMethod(), responseObserver);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -413,68 +416,68 @@ public final class QueryGrpc {
|
||||
**
|
||||
* Count all transactions in a ledger, or transactions in a timestamp range
|
||||
* 查询帐本中的所有事务数量,或时间范围内的事务数量
|
||||
* start_timestamp is required
|
||||
* 'start_timestamp' and 'end_timestamp' follow the same requirements and rules as in 'CountBlocks'.
|
||||
* </pre>
|
||||
*/
|
||||
public void countTransactions(org.bdware.bdledger.api.grpc.pb.QueryProto.TransactionsRequest request,
|
||||
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.CountTransactionsResponse> responseObserver) {
|
||||
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(),
|
||||
asyncUnaryCall(
|
||||
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(),
|
||||
asyncUnaryCall(
|
||||
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(),
|
||||
asyncUnaryCall(
|
||||
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(),
|
||||
asyncUnaryCall(
|
||||
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(),
|
||||
asyncUnaryCall(
|
||||
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(),
|
||||
asyncUnaryCall(
|
||||
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(),
|
||||
asyncUnaryCall(
|
||||
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(),
|
||||
asyncUnaryCall(
|
||||
io.grpc.stub.ServerCalls.asyncUnaryCall(
|
||||
new MethodHandlers<
|
||||
org.bdware.bdledger.api.grpc.pb.QueryProto.TransactionsRequest,
|
||||
org.bdware.bdledger.api.grpc.pb.QueryProto.CountTransactionsResponse>(
|
||||
@ -506,7 +509,7 @@ public final class QueryGrpc {
|
||||
*/
|
||||
public void getBlockByHash(org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlockByHashRequest request,
|
||||
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlockByHashResponse> responseObserver) {
|
||||
asyncUnaryCall(
|
||||
io.grpc.stub.ClientCalls.asyncUnaryCall(
|
||||
getChannel().newCall(getGetBlockByHashMethod(), getCallOptions()), request, responseObserver);
|
||||
}
|
||||
|
||||
@ -515,12 +518,20 @@ public final class QueryGrpc {
|
||||
**
|
||||
* Get blocks in a timestamp range
|
||||
* 查询时间范围内的区块
|
||||
* start_timestamp is required
|
||||
* Requirement: start_timestamp <= 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 > 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 void getBlocks(org.bdware.bdledger.api.grpc.pb.QueryProto.BlocksRequest request,
|
||||
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlocksResponse> responseObserver) {
|
||||
asyncUnaryCall(
|
||||
io.grpc.stub.ClientCalls.asyncUnaryCall(
|
||||
getChannel().newCall(getGetBlocksMethod(), getCallOptions()), request, responseObserver);
|
||||
}
|
||||
|
||||
@ -529,11 +540,17 @@ public final class QueryGrpc {
|
||||
**
|
||||
* Count all blocks in a ledger, or blocks in a timestamp range
|
||||
* 查询帐本中的所有区块数量,或时间范围内的区块数量
|
||||
* Requirement: start_timestamp <= 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 void countBlocks(org.bdware.bdledger.api.grpc.pb.QueryProto.BlocksRequest request,
|
||||
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.CountBlocksResponse> responseObserver) {
|
||||
asyncUnaryCall(
|
||||
io.grpc.stub.ClientCalls.asyncUnaryCall(
|
||||
getChannel().newCall(getCountBlocksMethod(), getCallOptions()), request, responseObserver);
|
||||
}
|
||||
|
||||
@ -541,12 +558,12 @@ public final class QueryGrpc {
|
||||
* <pre>
|
||||
**
|
||||
* Get recent 'count' blocks (Only support IncludeTransactions=NONE for now)
|
||||
* 查询最新的n个区块
|
||||
* 查询最新的 'count' 个区块
|
||||
* </pre>
|
||||
*/
|
||||
public void getRecentBlocks(org.bdware.bdledger.api.grpc.pb.QueryProto.RecentBlocksRequest request,
|
||||
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlocksResponse> responseObserver) {
|
||||
asyncUnaryCall(
|
||||
io.grpc.stub.ClientCalls.asyncUnaryCall(
|
||||
getChannel().newCall(getGetRecentBlocksMethod(), getCallOptions()), request, responseObserver);
|
||||
}
|
||||
|
||||
@ -559,7 +576,7 @@ public final class QueryGrpc {
|
||||
*/
|
||||
public void getTransactionByHash(org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByHashRequest request,
|
||||
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByHashResponse> responseObserver) {
|
||||
asyncUnaryCall(
|
||||
io.grpc.stub.ClientCalls.asyncUnaryCall(
|
||||
getChannel().newCall(getGetTransactionByHashMethod(), getCallOptions()), request, responseObserver);
|
||||
}
|
||||
|
||||
@ -572,7 +589,7 @@ public final class QueryGrpc {
|
||||
*/
|
||||
public void getTransactionByBlockHashAndIndex(org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByBlockHashAndIndexRequest request,
|
||||
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByBlockHashAndIndexResponse> responseObserver) {
|
||||
asyncUnaryCall(
|
||||
io.grpc.stub.ClientCalls.asyncUnaryCall(
|
||||
getChannel().newCall(getGetTransactionByBlockHashAndIndexMethod(), getCallOptions()), request, responseObserver);
|
||||
}
|
||||
|
||||
@ -581,11 +598,12 @@ public final class QueryGrpc {
|
||||
**
|
||||
* Get transactions in a timestamp range
|
||||
* 查询时间范围内的事务
|
||||
* 'start_timestamp' and 'end_timestamp' follow the same requirements and rules as in 'GetBlocks'.
|
||||
* </pre>
|
||||
*/
|
||||
public void getTransactions(org.bdware.bdledger.api.grpc.pb.QueryProto.TransactionsRequest request,
|
||||
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionsResponse> responseObserver) {
|
||||
asyncUnaryCall(
|
||||
io.grpc.stub.ClientCalls.asyncUnaryCall(
|
||||
getChannel().newCall(getGetTransactionsMethod(), getCallOptions()), request, responseObserver);
|
||||
}
|
||||
|
||||
@ -594,12 +612,12 @@ public final class QueryGrpc {
|
||||
**
|
||||
* Count all transactions in a ledger, or transactions in a timestamp range
|
||||
* 查询帐本中的所有事务数量,或时间范围内的事务数量
|
||||
* start_timestamp is required
|
||||
* 'start_timestamp' and 'end_timestamp' follow the same requirements and rules as in 'CountBlocks'.
|
||||
* </pre>
|
||||
*/
|
||||
public void countTransactions(org.bdware.bdledger.api.grpc.pb.QueryProto.TransactionsRequest request,
|
||||
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryProto.CountTransactionsResponse> responseObserver) {
|
||||
asyncUnaryCall(
|
||||
io.grpc.stub.ClientCalls.asyncUnaryCall(
|
||||
getChannel().newCall(getCountTransactionsMethod(), getCallOptions()), request, responseObserver);
|
||||
}
|
||||
}
|
||||
@ -626,7 +644,7 @@ public final class QueryGrpc {
|
||||
* </pre>
|
||||
*/
|
||||
public org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlockByHashResponse getBlockByHash(org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlockByHashRequest request) {
|
||||
return blockingUnaryCall(
|
||||
return io.grpc.stub.ClientCalls.blockingUnaryCall(
|
||||
getChannel(), getGetBlockByHashMethod(), getCallOptions(), request);
|
||||
}
|
||||
|
||||
@ -635,11 +653,19 @@ public final class QueryGrpc {
|
||||
**
|
||||
* Get blocks in a timestamp range
|
||||
* 查询时间范围内的区块
|
||||
* start_timestamp is required
|
||||
* Requirement: start_timestamp <= 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 > 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 blockingUnaryCall(
|
||||
return io.grpc.stub.ClientCalls.blockingUnaryCall(
|
||||
getChannel(), getGetBlocksMethod(), getCallOptions(), request);
|
||||
}
|
||||
|
||||
@ -648,10 +674,16 @@ public final class QueryGrpc {
|
||||
**
|
||||
* Count all blocks in a ledger, or blocks in a timestamp range
|
||||
* 查询帐本中的所有区块数量,或时间范围内的区块数量
|
||||
* Requirement: start_timestamp <= 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 blockingUnaryCall(
|
||||
return io.grpc.stub.ClientCalls.blockingUnaryCall(
|
||||
getChannel(), getCountBlocksMethod(), getCallOptions(), request);
|
||||
}
|
||||
|
||||
@ -659,11 +691,11 @@ public final class QueryGrpc {
|
||||
* <pre>
|
||||
**
|
||||
* Get recent 'count' blocks (Only support IncludeTransactions=NONE for now)
|
||||
* 查询最新的n个区块
|
||||
* 查询最新的 'count' 个区块
|
||||
* </pre>
|
||||
*/
|
||||
public org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlocksResponse getRecentBlocks(org.bdware.bdledger.api.grpc.pb.QueryProto.RecentBlocksRequest request) {
|
||||
return blockingUnaryCall(
|
||||
return io.grpc.stub.ClientCalls.blockingUnaryCall(
|
||||
getChannel(), getGetRecentBlocksMethod(), getCallOptions(), request);
|
||||
}
|
||||
|
||||
@ -675,7 +707,7 @@ public final class QueryGrpc {
|
||||
* </pre>
|
||||
*/
|
||||
public org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByHashResponse getTransactionByHash(org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByHashRequest request) {
|
||||
return blockingUnaryCall(
|
||||
return io.grpc.stub.ClientCalls.blockingUnaryCall(
|
||||
getChannel(), getGetTransactionByHashMethod(), getCallOptions(), request);
|
||||
}
|
||||
|
||||
@ -687,7 +719,7 @@ public final class QueryGrpc {
|
||||
* </pre>
|
||||
*/
|
||||
public org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByBlockHashAndIndexResponse getTransactionByBlockHashAndIndex(org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByBlockHashAndIndexRequest request) {
|
||||
return blockingUnaryCall(
|
||||
return io.grpc.stub.ClientCalls.blockingUnaryCall(
|
||||
getChannel(), getGetTransactionByBlockHashAndIndexMethod(), getCallOptions(), request);
|
||||
}
|
||||
|
||||
@ -696,10 +728,11 @@ public final class QueryGrpc {
|
||||
**
|
||||
* 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 blockingUnaryCall(
|
||||
return io.grpc.stub.ClientCalls.blockingUnaryCall(
|
||||
getChannel(), getGetTransactionsMethod(), getCallOptions(), request);
|
||||
}
|
||||
|
||||
@ -708,11 +741,11 @@ public final class QueryGrpc {
|
||||
**
|
||||
* Count all transactions in a ledger, or transactions in a timestamp range
|
||||
* 查询帐本中的所有事务数量,或时间范围内的事务数量
|
||||
* start_timestamp is required
|
||||
* '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 blockingUnaryCall(
|
||||
return io.grpc.stub.ClientCalls.blockingUnaryCall(
|
||||
getChannel(), getCountTransactionsMethod(), getCallOptions(), request);
|
||||
}
|
||||
}
|
||||
@ -740,7 +773,7 @@ public final class QueryGrpc {
|
||||
*/
|
||||
public com.google.common.util.concurrent.ListenableFuture<org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlockByHashResponse> getBlockByHash(
|
||||
org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlockByHashRequest request) {
|
||||
return futureUnaryCall(
|
||||
return io.grpc.stub.ClientCalls.futureUnaryCall(
|
||||
getChannel().newCall(getGetBlockByHashMethod(), getCallOptions()), request);
|
||||
}
|
||||
|
||||
@ -749,12 +782,20 @@ public final class QueryGrpc {
|
||||
**
|
||||
* Get blocks in a timestamp range
|
||||
* 查询时间范围内的区块
|
||||
* start_timestamp is required
|
||||
* Requirement: start_timestamp <= 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 > 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 com.google.common.util.concurrent.ListenableFuture<org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlocksResponse> getBlocks(
|
||||
org.bdware.bdledger.api.grpc.pb.QueryProto.BlocksRequest request) {
|
||||
return futureUnaryCall(
|
||||
return io.grpc.stub.ClientCalls.futureUnaryCall(
|
||||
getChannel().newCall(getGetBlocksMethod(), getCallOptions()), request);
|
||||
}
|
||||
|
||||
@ -763,11 +804,17 @@ public final class QueryGrpc {
|
||||
**
|
||||
* Count all blocks in a ledger, or blocks in a timestamp range
|
||||
* 查询帐本中的所有区块数量,或时间范围内的区块数量
|
||||
* Requirement: start_timestamp <= 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 com.google.common.util.concurrent.ListenableFuture<org.bdware.bdledger.api.grpc.pb.QueryProto.CountBlocksResponse> countBlocks(
|
||||
org.bdware.bdledger.api.grpc.pb.QueryProto.BlocksRequest request) {
|
||||
return futureUnaryCall(
|
||||
return io.grpc.stub.ClientCalls.futureUnaryCall(
|
||||
getChannel().newCall(getCountBlocksMethod(), getCallOptions()), request);
|
||||
}
|
||||
|
||||
@ -775,12 +822,12 @@ public final class QueryGrpc {
|
||||
* <pre>
|
||||
**
|
||||
* Get recent 'count' blocks (Only support IncludeTransactions=NONE for now)
|
||||
* 查询最新的n个区块
|
||||
* 查询最新的 'count' 个区块
|
||||
* </pre>
|
||||
*/
|
||||
public com.google.common.util.concurrent.ListenableFuture<org.bdware.bdledger.api.grpc.pb.QueryProto.GetBlocksResponse> getRecentBlocks(
|
||||
org.bdware.bdledger.api.grpc.pb.QueryProto.RecentBlocksRequest request) {
|
||||
return futureUnaryCall(
|
||||
return io.grpc.stub.ClientCalls.futureUnaryCall(
|
||||
getChannel().newCall(getGetRecentBlocksMethod(), getCallOptions()), request);
|
||||
}
|
||||
|
||||
@ -793,7 +840,7 @@ public final class QueryGrpc {
|
||||
*/
|
||||
public com.google.common.util.concurrent.ListenableFuture<org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByHashResponse> getTransactionByHash(
|
||||
org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByHashRequest request) {
|
||||
return futureUnaryCall(
|
||||
return io.grpc.stub.ClientCalls.futureUnaryCall(
|
||||
getChannel().newCall(getGetTransactionByHashMethod(), getCallOptions()), request);
|
||||
}
|
||||
|
||||
@ -806,7 +853,7 @@ public final class QueryGrpc {
|
||||
*/
|
||||
public com.google.common.util.concurrent.ListenableFuture<org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByBlockHashAndIndexResponse> getTransactionByBlockHashAndIndex(
|
||||
org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionByBlockHashAndIndexRequest request) {
|
||||
return futureUnaryCall(
|
||||
return io.grpc.stub.ClientCalls.futureUnaryCall(
|
||||
getChannel().newCall(getGetTransactionByBlockHashAndIndexMethod(), getCallOptions()), request);
|
||||
}
|
||||
|
||||
@ -815,11 +862,12 @@ public final class QueryGrpc {
|
||||
**
|
||||
* Get transactions in a timestamp range
|
||||
* 查询时间范围内的事务
|
||||
* 'start_timestamp' and 'end_timestamp' follow the same requirements and rules as in 'GetBlocks'.
|
||||
* </pre>
|
||||
*/
|
||||
public com.google.common.util.concurrent.ListenableFuture<org.bdware.bdledger.api.grpc.pb.QueryProto.GetTransactionsResponse> getTransactions(
|
||||
org.bdware.bdledger.api.grpc.pb.QueryProto.TransactionsRequest request) {
|
||||
return futureUnaryCall(
|
||||
return io.grpc.stub.ClientCalls.futureUnaryCall(
|
||||
getChannel().newCall(getGetTransactionsMethod(), getCallOptions()), request);
|
||||
}
|
||||
|
||||
@ -828,12 +876,12 @@ public final class QueryGrpc {
|
||||
**
|
||||
* Count all transactions in a ledger, or transactions in a timestamp range
|
||||
* 查询帐本中的所有事务数量,或时间范围内的事务数量
|
||||
* start_timestamp is required
|
||||
* 'start_timestamp' and 'end_timestamp' follow the same requirements and rules as in 'CountBlocks'.
|
||||
* </pre>
|
||||
*/
|
||||
public com.google.common.util.concurrent.ListenableFuture<org.bdware.bdledger.api.grpc.pb.QueryProto.CountTransactionsResponse> countTransactions(
|
||||
org.bdware.bdledger.api.grpc.pb.QueryProto.TransactionsRequest request) {
|
||||
return futureUnaryCall(
|
||||
return io.grpc.stub.ClientCalls.futureUnaryCall(
|
||||
getChannel().newCall(getCountTransactionsMethod(), getCallOptions()), request);
|
||||
}
|
||||
}
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -94,10 +94,10 @@ class ClientTests {
|
||||
|
||||
private static Client client;
|
||||
|
||||
// @BeforeAll
|
||||
// static void initAll() {
|
||||
// client = new Client("localhost", 10000);
|
||||
// }
|
||||
@BeforeAll
|
||||
static void initAll() {
|
||||
client = new Client("localhost", 2401);
|
||||
}
|
||||
//
|
||||
// @Test
|
||||
// @DisplayName("ClientVersion#1")
|
||||
|
30
src/test/java/org/bdware/bdledger/api/grpc/Test.java
Normal file
30
src/test/java/org/bdware/bdledger/api/grpc/Test.java
Normal file
@ -0,0 +1,30 @@
|
||||
package org.bdware.bdledger.api.grpc;
|
||||
|
||||
import org.bdware.bdledger.api.grpc.pb.LedgerProto.*;
|
||||
import org.bdware.bdledger.api.grpc.pb.QueryProto.*;
|
||||
import com.google.protobuf.ByteString;
|
||||
import io.grpc.Status;
|
||||
import org.bdware.bdledger.api.grpc.pb.CommonProto.Block;
|
||||
import org.bdware.bdledger.api.grpc.pb.CommonProto.Transaction;
|
||||
import org.bdware.bdledger.api.grpc.pb.CommonProto.TransactionType;
|
||||
import org.bdware.bdledger.api.grpc.pb.LedgerProto.GetLedgersResponse;
|
||||
import org.junit.jupiter.api.*;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.concurrent.ExecutionException;
|
||||
import java.util.stream.Collectors;
|
||||
import java.util.stream.IntStream;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
|
||||
public class Test {
|
||||
public static void main(String[] args) {
|
||||
Client client = new Client("localhost", 2401);
|
||||
GetBlocksResponse res = client.getRecentBlocksSync("test", 0, IncludeTransactions.NONE);
|
||||
System.out.println(res.getBlocks(0).getCreator());
|
||||
System.out.println(res.getBlocks(0).getCreatorSignature());
|
||||
System.out.println(res.getBlocks(0).getWitnesses(0));
|
||||
System.out.println(res.getBlocks(0).getWitnessSignatures(0));
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user