From eb6863d641612b2c55c1b8cb5ae3e22f04f7058f Mon Sep 17 00:00:00 2001 From: "insanity@loafle.com" Date: Thu, 25 May 2017 19:09:26 +0900 Subject: [PATCH] overflow db proxy grpc proto --- build/golang/grpc.pb.go | 180 ++ .../java/com/loafle/overflow/db/api/Grpc.java | 1558 +++++++++++++++++ 2 files changed, 1738 insertions(+) create mode 100644 build/golang/grpc.pb.go create mode 100644 build/java/com/loafle/overflow/db/api/Grpc.java diff --git a/build/golang/grpc.pb.go b/build/golang/grpc.pb.go new file mode 100644 index 0000000..1391622 --- /dev/null +++ b/build/golang/grpc.pb.go @@ -0,0 +1,180 @@ +// Code generated by protoc-gen-go. DO NOT EDIT. +// source: grpc.proto + +/* +Package grpc is a generated protocol buffer package. + +It is generated from these files: + grpc.proto + +It has these top-level messages: + DBInput + DBOutput +*/ +package grpc + +import proto "github.com/golang/protobuf/proto" +import fmt "fmt" +import math "math" + +import ( + context "golang.org/x/net/context" + grpc1 "google.golang.org/grpc" +) + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package + +type DBInput struct { + TargetDao string `protobuf:"bytes,1,opt,name=targetDao" json:"targetDao,omitempty"` + Method string `protobuf:"bytes,2,opt,name=method" json:"method,omitempty"` + Param map[string]string `protobuf:"bytes,3,rep,name=param" json:"param,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"` +} + +func (m *DBInput) Reset() { *m = DBInput{} } +func (m *DBInput) String() string { return proto.CompactTextString(m) } +func (*DBInput) ProtoMessage() {} +func (*DBInput) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} } + +func (m *DBInput) GetTargetDao() string { + if m != nil { + return m.TargetDao + } + return "" +} + +func (m *DBInput) GetMethod() string { + if m != nil { + return m.Method + } + return "" +} + +func (m *DBInput) GetParam() map[string]string { + if m != nil { + return m.Param + } + return nil +} + +type DBOutput struct { + Result string `protobuf:"bytes,1,opt,name=result" json:"result,omitempty"` +} + +func (m *DBOutput) Reset() { *m = DBOutput{} } +func (m *DBOutput) String() string { return proto.CompactTextString(m) } +func (*DBOutput) ProtoMessage() {} +func (*DBOutput) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} } + +func (m *DBOutput) GetResult() string { + if m != nil { + return m.Result + } + return "" +} + +func init() { + proto.RegisterType((*DBInput)(nil), "DBInput") + proto.RegisterType((*DBOutput)(nil), "DBOutput") +} + +// Reference imports to suppress errors if they are not otherwise used. +var _ context.Context +var _ grpc1.ClientConn + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +const _ = grpc1.SupportPackageIsVersion4 + +// Client API for DB service + +type DBClient interface { + Exec(ctx context.Context, in *DBInput, opts ...grpc1.CallOption) (*DBOutput, error) +} + +type dBClient struct { + cc *grpc1.ClientConn +} + +func NewDBClient(cc *grpc1.ClientConn) DBClient { + return &dBClient{cc} +} + +func (c *dBClient) Exec(ctx context.Context, in *DBInput, opts ...grpc1.CallOption) (*DBOutput, error) { + out := new(DBOutput) + err := grpc1.Invoke(ctx, "/DB/exec", in, out, c.cc, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// Server API for DB service + +type DBServer interface { + Exec(context.Context, *DBInput) (*DBOutput, error) +} + +func RegisterDBServer(s *grpc1.Server, srv DBServer) { + s.RegisterService(&_DB_serviceDesc, srv) +} + +func _DB_Exec_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc1.UnaryServerInterceptor) (interface{}, error) { + in := new(DBInput) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(DBServer).Exec(ctx, in) + } + info := &grpc1.UnaryServerInfo{ + Server: srv, + FullMethod: "/DB/Exec", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(DBServer).Exec(ctx, req.(*DBInput)) + } + return interceptor(ctx, in, info, handler) +} + +var _DB_serviceDesc = grpc1.ServiceDesc{ + ServiceName: "DB", + HandlerType: (*DBServer)(nil), + Methods: []grpc1.MethodDesc{ + { + MethodName: "exec", + Handler: _DB_Exec_Handler, + }, + }, + Streams: []grpc1.StreamDesc{}, + Metadata: "grpc.proto", +} + +func init() { proto.RegisterFile("grpc.proto", fileDescriptor0) } + +var fileDescriptor0 = []byte{ + // 233 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x44, 0x90, 0x41, 0x4f, 0xc2, 0x40, + 0x10, 0x85, 0x6d, 0x2b, 0x95, 0x8e, 0x17, 0xb3, 0x1a, 0xd2, 0x34, 0x98, 0x90, 0x7a, 0xc1, 0xcb, + 0x1c, 0xf0, 0x42, 0x3c, 0x36, 0xeb, 0xc1, 0x93, 0x86, 0x7f, 0xb0, 0x94, 0x01, 0x8d, 0x5b, 0x66, + 0xb3, 0xce, 0xa2, 0xfc, 0x1f, 0x7f, 0xa8, 0x29, 0x2c, 0xe1, 0xb6, 0xef, 0xdb, 0x79, 0xf3, 0x5e, + 0x06, 0x60, 0xe3, 0x5d, 0x8b, 0xce, 0xb3, 0x70, 0xfd, 0x97, 0xc0, 0x95, 0x6e, 0x5e, 0xb7, 0x2e, + 0x88, 0x1a, 0x43, 0x21, 0xc6, 0x6f, 0x48, 0xb4, 0xe1, 0x32, 0x99, 0x24, 0xd3, 0x62, 0x71, 0x06, + 0x6a, 0x04, 0x79, 0x47, 0xf2, 0xc1, 0xab, 0x32, 0x3d, 0x7c, 0x45, 0xa5, 0x1e, 0x61, 0xe0, 0x8c, + 0x37, 0x5d, 0x99, 0x4d, 0xb2, 0xe9, 0xf5, 0xec, 0x16, 0xe3, 0x3a, 0x7c, 0xef, 0xe9, 0xcb, 0x56, + 0xfc, 0x7e, 0x71, 0x9c, 0xa8, 0xe6, 0x00, 0x67, 0xa8, 0x6e, 0x20, 0xfb, 0xa2, 0x7d, 0x0c, 0xea, + 0x9f, 0xea, 0x0e, 0x06, 0x3b, 0x63, 0x03, 0xc5, 0x84, 0xa3, 0x78, 0x4e, 0xe7, 0x49, 0x5d, 0xc3, + 0x50, 0x37, 0x6f, 0x41, 0xfa, 0x9a, 0x23, 0xc8, 0x3d, 0x7d, 0x07, 0x2b, 0xd1, 0x1a, 0xd5, 0xec, + 0x01, 0x52, 0xdd, 0xa8, 0x7b, 0xb8, 0xa4, 0x5f, 0x6a, 0xd5, 0xf0, 0xd4, 0xa3, 0x2a, 0xf0, 0x64, + 0xad, 0x2f, 0x9a, 0x31, 0x54, 0x2d, 0x77, 0x68, 0xd9, 0xac, 0x2d, 0x21, 0xef, 0xc8, 0xaf, 0x2d, + 0xff, 0xe0, 0x6a, 0x89, 0xc6, 0x7d, 0x2e, 0xf3, 0xc3, 0x51, 0x9e, 0xfe, 0x03, 0x00, 0x00, 0xff, + 0xff, 0x2f, 0xe5, 0x6c, 0xa7, 0x22, 0x01, 0x00, 0x00, +} diff --git a/build/java/com/loafle/overflow/db/api/Grpc.java b/build/java/com/loafle/overflow/db/api/Grpc.java new file mode 100644 index 0000000..0224648 --- /dev/null +++ b/build/java/com/loafle/overflow/db/api/Grpc.java @@ -0,0 +1,1558 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: grpc.proto + +package com.loafle.overflow.db.api; + +public final class Grpc { + private Grpc() {} + 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 interface DBInputOrBuilder extends + // @@protoc_insertion_point(interface_extends:DBInput) + com.google.protobuf.MessageOrBuilder { + + /** + * string targetDao = 1; + */ + java.lang.String getTargetDao(); + /** + * string targetDao = 1; + */ + com.google.protobuf.ByteString + getTargetDaoBytes(); + + /** + * string method = 2; + */ + java.lang.String getMethod(); + /** + * string method = 2; + */ + com.google.protobuf.ByteString + getMethodBytes(); + + /** + * map<string, string> param = 3; + */ + int getParamCount(); + /** + * map<string, string> param = 3; + */ + boolean containsParam( + java.lang.String key); + /** + * Use {@link #getParamMap()} instead. + */ + @java.lang.Deprecated + java.util.Map + getParam(); + /** + * map<string, string> param = 3; + */ + java.util.Map + getParamMap(); + /** + * map<string, string> param = 3; + */ + + java.lang.String getParamOrDefault( + java.lang.String key, + java.lang.String defaultValue); + /** + * map<string, string> param = 3; + */ + + java.lang.String getParamOrThrow( + java.lang.String key); + } + /** + * Protobuf type {@code DBInput} + */ + public static final class DBInput extends + com.google.protobuf.GeneratedMessageV3 implements + // @@protoc_insertion_point(message_implements:DBInput) + DBInputOrBuilder { + // Use DBInput.newBuilder() to construct. + private DBInput(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + private DBInput() { + targetDao_ = ""; + method_ = ""; + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet + getUnknownFields() { + return com.google.protobuf.UnknownFieldSet.getDefaultInstance(); + } + private DBInput( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + int mutable_bitField0_ = 0; + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + default: { + if (!input.skipField(tag)) { + done = true; + } + break; + } + case 10: { + java.lang.String s = input.readStringRequireUtf8(); + + targetDao_ = s; + break; + } + case 18: { + java.lang.String s = input.readStringRequireUtf8(); + + method_ = s; + break; + } + case 26: { + if (!((mutable_bitField0_ & 0x00000004) == 0x00000004)) { + param_ = com.google.protobuf.MapField.newMapField( + ParamDefaultEntryHolder.defaultEntry); + mutable_bitField0_ |= 0x00000004; + } + com.google.protobuf.MapEntry + param__ = input.readMessage( + ParamDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry); + param_.getMutableMap().put( + param__.getKey(), param__.getValue()); + 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 { + makeExtensionsImmutable(); + } + } + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return com.loafle.overflow.db.api.Grpc.internal_static_DBInput_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapField internalGetMapField( + int number) { + switch (number) { + case 3: + return internalGetParam(); + default: + throw new RuntimeException( + "Invalid map field number: " + number); + } + } + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.loafle.overflow.db.api.Grpc.internal_static_DBInput_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.loafle.overflow.db.api.Grpc.DBInput.class, com.loafle.overflow.db.api.Grpc.DBInput.Builder.class); + } + + private int bitField0_; + public static final int TARGETDAO_FIELD_NUMBER = 1; + private volatile java.lang.Object targetDao_; + /** + * string targetDao = 1; + */ + public java.lang.String getTargetDao() { + java.lang.Object ref = targetDao_; + 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(); + targetDao_ = s; + return s; + } + } + /** + * string targetDao = 1; + */ + public com.google.protobuf.ByteString + getTargetDaoBytes() { + java.lang.Object ref = targetDao_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8( + (java.lang.String) ref); + targetDao_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int METHOD_FIELD_NUMBER = 2; + private volatile java.lang.Object method_; + /** + * string method = 2; + */ + public java.lang.String getMethod() { + java.lang.Object ref = method_; + 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(); + method_ = s; + return s; + } + } + /** + * string method = 2; + */ + public com.google.protobuf.ByteString + getMethodBytes() { + java.lang.Object ref = method_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8( + (java.lang.String) ref); + method_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PARAM_FIELD_NUMBER = 3; + private static final class ParamDefaultEntryHolder { + static final com.google.protobuf.MapEntry< + java.lang.String, java.lang.String> defaultEntry = + com.google.protobuf.MapEntry + .newDefaultInstance( + com.loafle.overflow.db.api.Grpc.internal_static_DBInput_ParamEntry_descriptor, + com.google.protobuf.WireFormat.FieldType.STRING, + "", + com.google.protobuf.WireFormat.FieldType.STRING, + ""); + } + private com.google.protobuf.MapField< + java.lang.String, java.lang.String> param_; + private com.google.protobuf.MapField + internalGetParam() { + if (param_ == null) { + return com.google.protobuf.MapField.emptyMapField( + ParamDefaultEntryHolder.defaultEntry); + } + return param_; + } + + public int getParamCount() { + return internalGetParam().getMap().size(); + } + /** + * map<string, string> param = 3; + */ + + public boolean containsParam( + java.lang.String key) { + if (key == null) { throw new java.lang.NullPointerException(); } + return internalGetParam().getMap().containsKey(key); + } + /** + * Use {@link #getParamMap()} instead. + */ + @java.lang.Deprecated + public java.util.Map getParam() { + return getParamMap(); + } + /** + * map<string, string> param = 3; + */ + + public java.util.Map getParamMap() { + return internalGetParam().getMap(); + } + /** + * map<string, string> param = 3; + */ + + public java.lang.String getParamOrDefault( + java.lang.String key, + java.lang.String defaultValue) { + if (key == null) { throw new java.lang.NullPointerException(); } + java.util.Map map = + internalGetParam().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + /** + * map<string, string> param = 3; + */ + + public java.lang.String getParamOrThrow( + java.lang.String key) { + if (key == null) { throw new java.lang.NullPointerException(); } + java.util.Map map = + internalGetParam().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + private byte memoizedIsInitialized = -1; + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + public void writeTo(com.google.protobuf.CodedOutputStream output) + throws java.io.IOException { + if (!getTargetDaoBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, targetDao_); + } + if (!getMethodBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, method_); + } + com.google.protobuf.GeneratedMessageV3 + .serializeStringMapTo( + output, + internalGetParam(), + ParamDefaultEntryHolder.defaultEntry, + 3); + } + + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getTargetDaoBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, targetDao_); + } + if (!getMethodBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, method_); + } + for (java.util.Map.Entry entry + : internalGetParam().getMap().entrySet()) { + com.google.protobuf.MapEntry + param__ = ParamDefaultEntryHolder.defaultEntry.newBuilderForType() + .setKey(entry.getKey()) + .setValue(entry.getValue()) + .build(); + size += com.google.protobuf.CodedOutputStream + .computeMessageSize(3, param__); + } + memoizedSize = size; + return size; + } + + private static final long serialVersionUID = 0L; + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.loafle.overflow.db.api.Grpc.DBInput)) { + return super.equals(obj); + } + com.loafle.overflow.db.api.Grpc.DBInput other = (com.loafle.overflow.db.api.Grpc.DBInput) obj; + + boolean result = true; + result = result && getTargetDao() + .equals(other.getTargetDao()); + result = result && getMethod() + .equals(other.getMethod()); + result = result && internalGetParam().equals( + other.internalGetParam()); + return result; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + TARGETDAO_FIELD_NUMBER; + hash = (53 * hash) + getTargetDao().hashCode(); + hash = (37 * hash) + METHOD_FIELD_NUMBER; + hash = (53 * hash) + getMethod().hashCode(); + if (!internalGetParam().getMap().isEmpty()) { + hash = (37 * hash) + PARAM_FIELD_NUMBER; + hash = (53 * hash) + internalGetParam().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.loafle.overflow.db.api.Grpc.DBInput parseFrom( + java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.loafle.overflow.db.api.Grpc.DBInput parseFrom( + java.nio.ByteBuffer data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static com.loafle.overflow.db.api.Grpc.DBInput parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.loafle.overflow.db.api.Grpc.DBInput parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static com.loafle.overflow.db.api.Grpc.DBInput parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.loafle.overflow.db.api.Grpc.DBInput parseFrom( + byte[] data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static com.loafle.overflow.db.api.Grpc.DBInput parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static com.loafle.overflow.db.api.Grpc.DBInput 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.loafle.overflow.db.api.Grpc.DBInput parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseDelimitedWithIOException(PARSER, input); + } + public static com.loafle.overflow.db.api.Grpc.DBInput 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.loafle.overflow.db.api.Grpc.DBInput parseFrom( + com.google.protobuf.CodedInputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static com.loafle.overflow.db.api.Grpc.DBInput parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input, extensionRegistry); + } + + public Builder newBuilderForType() { return newBuilder(); } + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + public static Builder newBuilder(com.loafle.overflow.db.api.Grpc.DBInput prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + 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; + } + /** + * Protobuf type {@code DBInput} + */ + public static final class Builder extends + com.google.protobuf.GeneratedMessageV3.Builder implements + // @@protoc_insertion_point(builder_implements:DBInput) + com.loafle.overflow.db.api.Grpc.DBInputOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return com.loafle.overflow.db.api.Grpc.internal_static_DBInput_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapField internalGetMapField( + int number) { + switch (number) { + case 3: + return internalGetParam(); + default: + throw new RuntimeException( + "Invalid map field number: " + number); + } + } + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapField internalGetMutableMapField( + int number) { + switch (number) { + case 3: + return internalGetMutableParam(); + default: + throw new RuntimeException( + "Invalid map field number: " + number); + } + } + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.loafle.overflow.db.api.Grpc.internal_static_DBInput_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.loafle.overflow.db.api.Grpc.DBInput.class, com.loafle.overflow.db.api.Grpc.DBInput.Builder.class); + } + + // Construct using com.loafle.overflow.db.api.Grpc.DBInput.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3 + .alwaysUseFieldBuilders) { + } + } + public Builder clear() { + super.clear(); + targetDao_ = ""; + + method_ = ""; + + internalGetMutableParam().clear(); + return this; + } + + public com.google.protobuf.Descriptors.Descriptor + getDescriptorForType() { + return com.loafle.overflow.db.api.Grpc.internal_static_DBInput_descriptor; + } + + public com.loafle.overflow.db.api.Grpc.DBInput getDefaultInstanceForType() { + return com.loafle.overflow.db.api.Grpc.DBInput.getDefaultInstance(); + } + + public com.loafle.overflow.db.api.Grpc.DBInput build() { + com.loafle.overflow.db.api.Grpc.DBInput result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + public com.loafle.overflow.db.api.Grpc.DBInput buildPartial() { + com.loafle.overflow.db.api.Grpc.DBInput result = new com.loafle.overflow.db.api.Grpc.DBInput(this); + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + result.targetDao_ = targetDao_; + result.method_ = method_; + result.param_ = internalGetParam(); + result.param_.makeImmutable(); + result.bitField0_ = to_bitField0_; + onBuilt(); + return result; + } + + public Builder clone() { + return (Builder) super.clone(); + } + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, + Object value) { + return (Builder) super.setField(field, value); + } + public Builder clearField( + com.google.protobuf.Descriptors.FieldDescriptor field) { + return (Builder) super.clearField(field); + } + public Builder clearOneof( + com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return (Builder) super.clearOneof(oneof); + } + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, Object value) { + return (Builder) super.setRepeatedField(field, index, value); + } + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + Object value) { + return (Builder) super.addRepeatedField(field, value); + } + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.loafle.overflow.db.api.Grpc.DBInput) { + return mergeFrom((com.loafle.overflow.db.api.Grpc.DBInput)other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.loafle.overflow.db.api.Grpc.DBInput other) { + if (other == com.loafle.overflow.db.api.Grpc.DBInput.getDefaultInstance()) return this; + if (!other.getTargetDao().isEmpty()) { + targetDao_ = other.targetDao_; + onChanged(); + } + if (!other.getMethod().isEmpty()) { + method_ = other.method_; + onChanged(); + } + internalGetMutableParam().mergeFrom( + other.internalGetParam()); + onChanged(); + return this; + } + + public final boolean isInitialized() { + return true; + } + + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.loafle.overflow.db.api.Grpc.DBInput parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.loafle.overflow.db.api.Grpc.DBInput) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + private int bitField0_; + + private java.lang.Object targetDao_ = ""; + /** + * string targetDao = 1; + */ + public java.lang.String getTargetDao() { + java.lang.Object ref = targetDao_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = + (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + targetDao_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * string targetDao = 1; + */ + public com.google.protobuf.ByteString + getTargetDaoBytes() { + java.lang.Object ref = targetDao_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8( + (java.lang.String) ref); + targetDao_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * string targetDao = 1; + */ + public Builder setTargetDao( + java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + targetDao_ = value; + onChanged(); + return this; + } + /** + * string targetDao = 1; + */ + public Builder clearTargetDao() { + + targetDao_ = getDefaultInstance().getTargetDao(); + onChanged(); + return this; + } + /** + * string targetDao = 1; + */ + public Builder setTargetDaoBytes( + com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + targetDao_ = value; + onChanged(); + return this; + } + + private java.lang.Object method_ = ""; + /** + * string method = 2; + */ + public java.lang.String getMethod() { + java.lang.Object ref = method_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = + (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + method_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * string method = 2; + */ + public com.google.protobuf.ByteString + getMethodBytes() { + java.lang.Object ref = method_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8( + (java.lang.String) ref); + method_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * string method = 2; + */ + public Builder setMethod( + java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + method_ = value; + onChanged(); + return this; + } + /** + * string method = 2; + */ + public Builder clearMethod() { + + method_ = getDefaultInstance().getMethod(); + onChanged(); + return this; + } + /** + * string method = 2; + */ + public Builder setMethodBytes( + com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + method_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.MapField< + java.lang.String, java.lang.String> param_; + private com.google.protobuf.MapField + internalGetParam() { + if (param_ == null) { + return com.google.protobuf.MapField.emptyMapField( + ParamDefaultEntryHolder.defaultEntry); + } + return param_; + } + private com.google.protobuf.MapField + internalGetMutableParam() { + onChanged();; + if (param_ == null) { + param_ = com.google.protobuf.MapField.newMapField( + ParamDefaultEntryHolder.defaultEntry); + } + if (!param_.isMutable()) { + param_ = param_.copy(); + } + return param_; + } + + public int getParamCount() { + return internalGetParam().getMap().size(); + } + /** + * map<string, string> param = 3; + */ + + public boolean containsParam( + java.lang.String key) { + if (key == null) { throw new java.lang.NullPointerException(); } + return internalGetParam().getMap().containsKey(key); + } + /** + * Use {@link #getParamMap()} instead. + */ + @java.lang.Deprecated + public java.util.Map getParam() { + return getParamMap(); + } + /** + * map<string, string> param = 3; + */ + + public java.util.Map getParamMap() { + return internalGetParam().getMap(); + } + /** + * map<string, string> param = 3; + */ + + public java.lang.String getParamOrDefault( + java.lang.String key, + java.lang.String defaultValue) { + if (key == null) { throw new java.lang.NullPointerException(); } + java.util.Map map = + internalGetParam().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + /** + * map<string, string> param = 3; + */ + + public java.lang.String getParamOrThrow( + java.lang.String key) { + if (key == null) { throw new java.lang.NullPointerException(); } + java.util.Map map = + internalGetParam().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + public Builder clearParam() { + internalGetMutableParam().getMutableMap() + .clear(); + return this; + } + /** + * map<string, string> param = 3; + */ + + public Builder removeParam( + java.lang.String key) { + if (key == null) { throw new java.lang.NullPointerException(); } + internalGetMutableParam().getMutableMap() + .remove(key); + return this; + } + /** + * Use alternate mutation accessors instead. + */ + @java.lang.Deprecated + public java.util.Map + getMutableParam() { + return internalGetMutableParam().getMutableMap(); + } + /** + * map<string, string> param = 3; + */ + public Builder putParam( + java.lang.String key, + java.lang.String value) { + if (key == null) { throw new java.lang.NullPointerException(); } + if (value == null) { throw new java.lang.NullPointerException(); } + internalGetMutableParam().getMutableMap() + .put(key, value); + return this; + } + /** + * map<string, string> param = 3; + */ + + public Builder putAllParam( + java.util.Map values) { + internalGetMutableParam().getMutableMap() + .putAll(values); + return this; + } + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return this; + } + + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return this; + } + + + // @@protoc_insertion_point(builder_scope:DBInput) + } + + // @@protoc_insertion_point(class_scope:DBInput) + private static final com.loafle.overflow.db.api.Grpc.DBInput DEFAULT_INSTANCE; + static { + DEFAULT_INSTANCE = new com.loafle.overflow.db.api.Grpc.DBInput(); + } + + public static com.loafle.overflow.db.api.Grpc.DBInput getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser + PARSER = new com.google.protobuf.AbstractParser() { + public DBInput parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new DBInput(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + public com.loafle.overflow.db.api.Grpc.DBInput getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + + } + + public interface DBOutputOrBuilder extends + // @@protoc_insertion_point(interface_extends:DBOutput) + com.google.protobuf.MessageOrBuilder { + + /** + * string result = 1; + */ + java.lang.String getResult(); + /** + * string result = 1; + */ + com.google.protobuf.ByteString + getResultBytes(); + } + /** + * Protobuf type {@code DBOutput} + */ + public static final class DBOutput extends + com.google.protobuf.GeneratedMessageV3 implements + // @@protoc_insertion_point(message_implements:DBOutput) + DBOutputOrBuilder { + // Use DBOutput.newBuilder() to construct. + private DBOutput(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + private DBOutput() { + result_ = ""; + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet + getUnknownFields() { + return com.google.protobuf.UnknownFieldSet.getDefaultInstance(); + } + private DBOutput( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + int mutable_bitField0_ = 0; + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + default: { + if (!input.skipField(tag)) { + done = true; + } + break; + } + case 10: { + java.lang.String s = input.readStringRequireUtf8(); + + result_ = s; + 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 { + makeExtensionsImmutable(); + } + } + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return com.loafle.overflow.db.api.Grpc.internal_static_DBOutput_descriptor; + } + + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.loafle.overflow.db.api.Grpc.internal_static_DBOutput_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.loafle.overflow.db.api.Grpc.DBOutput.class, com.loafle.overflow.db.api.Grpc.DBOutput.Builder.class); + } + + public static final int RESULT_FIELD_NUMBER = 1; + private volatile java.lang.Object result_; + /** + * string result = 1; + */ + public java.lang.String getResult() { + java.lang.Object ref = result_; + 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(); + result_ = s; + return s; + } + } + /** + * string result = 1; + */ + public com.google.protobuf.ByteString + getResultBytes() { + java.lang.Object ref = result_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8( + (java.lang.String) ref); + result_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + public void writeTo(com.google.protobuf.CodedOutputStream output) + throws java.io.IOException { + if (!getResultBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, result_); + } + } + + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getResultBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, result_); + } + memoizedSize = size; + return size; + } + + private static final long serialVersionUID = 0L; + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.loafle.overflow.db.api.Grpc.DBOutput)) { + return super.equals(obj); + } + com.loafle.overflow.db.api.Grpc.DBOutput other = (com.loafle.overflow.db.api.Grpc.DBOutput) obj; + + boolean result = true; + result = result && getResult() + .equals(other.getResult()); + return result; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + RESULT_FIELD_NUMBER; + hash = (53 * hash) + getResult().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.loafle.overflow.db.api.Grpc.DBOutput parseFrom( + java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.loafle.overflow.db.api.Grpc.DBOutput parseFrom( + java.nio.ByteBuffer data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static com.loafle.overflow.db.api.Grpc.DBOutput parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.loafle.overflow.db.api.Grpc.DBOutput parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static com.loafle.overflow.db.api.Grpc.DBOutput parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.loafle.overflow.db.api.Grpc.DBOutput parseFrom( + byte[] data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static com.loafle.overflow.db.api.Grpc.DBOutput parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static com.loafle.overflow.db.api.Grpc.DBOutput 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.loafle.overflow.db.api.Grpc.DBOutput parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseDelimitedWithIOException(PARSER, input); + } + public static com.loafle.overflow.db.api.Grpc.DBOutput 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.loafle.overflow.db.api.Grpc.DBOutput parseFrom( + com.google.protobuf.CodedInputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static com.loafle.overflow.db.api.Grpc.DBOutput parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input, extensionRegistry); + } + + public Builder newBuilderForType() { return newBuilder(); } + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + public static Builder newBuilder(com.loafle.overflow.db.api.Grpc.DBOutput prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + 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; + } + /** + * Protobuf type {@code DBOutput} + */ + public static final class Builder extends + com.google.protobuf.GeneratedMessageV3.Builder implements + // @@protoc_insertion_point(builder_implements:DBOutput) + com.loafle.overflow.db.api.Grpc.DBOutputOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return com.loafle.overflow.db.api.Grpc.internal_static_DBOutput_descriptor; + } + + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.loafle.overflow.db.api.Grpc.internal_static_DBOutput_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.loafle.overflow.db.api.Grpc.DBOutput.class, com.loafle.overflow.db.api.Grpc.DBOutput.Builder.class); + } + + // Construct using com.loafle.overflow.db.api.Grpc.DBOutput.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3 + .alwaysUseFieldBuilders) { + } + } + public Builder clear() { + super.clear(); + result_ = ""; + + return this; + } + + public com.google.protobuf.Descriptors.Descriptor + getDescriptorForType() { + return com.loafle.overflow.db.api.Grpc.internal_static_DBOutput_descriptor; + } + + public com.loafle.overflow.db.api.Grpc.DBOutput getDefaultInstanceForType() { + return com.loafle.overflow.db.api.Grpc.DBOutput.getDefaultInstance(); + } + + public com.loafle.overflow.db.api.Grpc.DBOutput build() { + com.loafle.overflow.db.api.Grpc.DBOutput result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + public com.loafle.overflow.db.api.Grpc.DBOutput buildPartial() { + com.loafle.overflow.db.api.Grpc.DBOutput result = new com.loafle.overflow.db.api.Grpc.DBOutput(this); + result.result_ = result_; + onBuilt(); + return result; + } + + public Builder clone() { + return (Builder) super.clone(); + } + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, + Object value) { + return (Builder) super.setField(field, value); + } + public Builder clearField( + com.google.protobuf.Descriptors.FieldDescriptor field) { + return (Builder) super.clearField(field); + } + public Builder clearOneof( + com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return (Builder) super.clearOneof(oneof); + } + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, Object value) { + return (Builder) super.setRepeatedField(field, index, value); + } + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + Object value) { + return (Builder) super.addRepeatedField(field, value); + } + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.loafle.overflow.db.api.Grpc.DBOutput) { + return mergeFrom((com.loafle.overflow.db.api.Grpc.DBOutput)other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.loafle.overflow.db.api.Grpc.DBOutput other) { + if (other == com.loafle.overflow.db.api.Grpc.DBOutput.getDefaultInstance()) return this; + if (!other.getResult().isEmpty()) { + result_ = other.result_; + onChanged(); + } + onChanged(); + return this; + } + + public final boolean isInitialized() { + return true; + } + + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.loafle.overflow.db.api.Grpc.DBOutput parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.loafle.overflow.db.api.Grpc.DBOutput) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object result_ = ""; + /** + * string result = 1; + */ + public java.lang.String getResult() { + java.lang.Object ref = result_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = + (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + result_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * string result = 1; + */ + public com.google.protobuf.ByteString + getResultBytes() { + java.lang.Object ref = result_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8( + (java.lang.String) ref); + result_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * string result = 1; + */ + public Builder setResult( + java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + result_ = value; + onChanged(); + return this; + } + /** + * string result = 1; + */ + public Builder clearResult() { + + result_ = getDefaultInstance().getResult(); + onChanged(); + return this; + } + /** + * string result = 1; + */ + public Builder setResultBytes( + com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + result_ = value; + onChanged(); + return this; + } + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return this; + } + + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return this; + } + + + // @@protoc_insertion_point(builder_scope:DBOutput) + } + + // @@protoc_insertion_point(class_scope:DBOutput) + private static final com.loafle.overflow.db.api.Grpc.DBOutput DEFAULT_INSTANCE; + static { + DEFAULT_INSTANCE = new com.loafle.overflow.db.api.Grpc.DBOutput(); + } + + public static com.loafle.overflow.db.api.Grpc.DBOutput getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser + PARSER = new com.google.protobuf.AbstractParser() { + public DBOutput parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new DBOutput(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + public com.loafle.overflow.db.api.Grpc.DBOutput getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + + } + + private static final com.google.protobuf.Descriptors.Descriptor + internal_static_DBInput_descriptor; + private static final + com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_DBInput_fieldAccessorTable; + private static final com.google.protobuf.Descriptors.Descriptor + internal_static_DBInput_ParamEntry_descriptor; + private static final + com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_DBInput_ParamEntry_fieldAccessorTable; + private static final com.google.protobuf.Descriptors.Descriptor + internal_static_DBOutput_descriptor; + private static final + com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_DBOutput_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\ngrpc.proto\"~\n\007DBInput\022\021\n\ttargetDao\030\001 \001" + + "(\t\022\016\n\006method\030\002 \001(\t\022\"\n\005param\030\003 \003(\0132\023.DBIn" + + "put.ParamEntry\032,\n\nParamEntry\022\013\n\003key\030\001 \001(" + + "\t\022\r\n\005value\030\002 \001(\t:\0028\001\"\032\n\010DBOutput\022\016\n\006resu" + + "lt\030\001 \001(\t2#\n\002DB\022\035\n\004exec\022\010.DBInput\032\t.DBOut" + + "put\"\000B\034\n\032com.loafle.overflow.db.apib\006pro" + + "to3" + }; + com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner = + new com.google.protobuf.Descriptors.FileDescriptor. InternalDescriptorAssigner() { + public com.google.protobuf.ExtensionRegistry assignDescriptors( + com.google.protobuf.Descriptors.FileDescriptor root) { + descriptor = root; + return null; + } + }; + com.google.protobuf.Descriptors.FileDescriptor + .internalBuildGeneratedFileFrom(descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + }, assigner); + internal_static_DBInput_descriptor = + getDescriptor().getMessageTypes().get(0); + internal_static_DBInput_fieldAccessorTable = new + com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_DBInput_descriptor, + new java.lang.String[] { "TargetDao", "Method", "Param", }); + internal_static_DBInput_ParamEntry_descriptor = + internal_static_DBInput_descriptor.getNestedTypes().get(0); + internal_static_DBInput_ParamEntry_fieldAccessorTable = new + com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_DBInput_ParamEntry_descriptor, + new java.lang.String[] { "Key", "Value", }); + internal_static_DBOutput_descriptor = + getDescriptor().getMessageTypes().get(1); + internal_static_DBOutput_fieldAccessorTable = new + com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_DBOutput_descriptor, + new java.lang.String[] { "Result", }); + } + + // @@protoc_insertion_point(outer_class_scope) +}