// Code generated by protoc-gen-go. DO NOT EDIT. // source: service.proto package pb import ( context "context" fmt "fmt" proto "github.com/golang/protobuf/proto" grpc "google.golang.org/grpc" math "math" ) // 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.ProtoPackageIsVersion3 // please upgrade the proto package type Request struct { BucketID string `protobuf:"bytes,1,opt,name=bucketID,proto3" json:"bucketID,omitempty"` ObjectName string `protobuf:"bytes,2,opt,name=objectName,proto3" json:"objectName,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *Request) Reset() { *m = Request{} } func (m *Request) String() string { return proto.CompactTextString(m) } func (*Request) ProtoMessage() {} func (*Request) Descriptor() ([]byte, []int) { return fileDescriptor_a0b84a42fa06f626, []int{0} } func (m *Request) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_Request.Unmarshal(m, b) } func (m *Request) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_Request.Marshal(b, m, deterministic) } func (m *Request) XXX_Merge(src proto.Message) { xxx_messageInfo_Request.Merge(m, src) } func (m *Request) XXX_Size() int { return xxx_messageInfo_Request.Size(m) } func (m *Request) XXX_DiscardUnknown() { xxx_messageInfo_Request.DiscardUnknown(m) } var xxx_messageInfo_Request proto.InternalMessageInfo func (m *Request) GetBucketID() string { if m != nil { return m.BucketID } return "" } func (m *Request) GetObjectName() string { if m != nil { return m.ObjectName } return "" } type Response struct { Data []byte `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"` ErrorCode int64 `protobuf:"varint,2,opt,name=errorCode,proto3" json:"errorCode,omitempty"` ErrorMsg string `protobuf:"bytes,3,opt,name=errorMsg,proto3" json:"errorMsg,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *Response) Reset() { *m = Response{} } func (m *Response) String() string { return proto.CompactTextString(m) } func (*Response) ProtoMessage() {} func (*Response) Descriptor() ([]byte, []int) { return fileDescriptor_a0b84a42fa06f626, []int{1} } func (m *Response) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_Response.Unmarshal(m, b) } func (m *Response) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_Response.Marshal(b, m, deterministic) } func (m *Response) XXX_Merge(src proto.Message) { xxx_messageInfo_Response.Merge(m, src) } func (m *Response) XXX_Size() int { return xxx_messageInfo_Response.Size(m) } func (m *Response) XXX_DiscardUnknown() { xxx_messageInfo_Response.DiscardUnknown(m) } var xxx_messageInfo_Response proto.InternalMessageInfo func (m *Response) GetData() []byte { if m != nil { return m.Data } return nil } func (m *Response) GetErrorCode() int64 { if m != nil { return m.ErrorCode } return 0 } func (m *Response) GetErrorMsg() string { if m != nil { return m.ErrorMsg } return "" } func init() { proto.RegisterType((*Request)(nil), "protobuf.Request") proto.RegisterType((*Response)(nil), "protobuf.Response") } func init() { proto.RegisterFile("service.proto", fileDescriptor_a0b84a42fa06f626) } var fileDescriptor_a0b84a42fa06f626 = []byte{ // 204 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xe2, 0x2d, 0x4e, 0x2d, 0x2a, 0xcb, 0x4c, 0x4e, 0xd5, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0xe2, 0x00, 0x53, 0x49, 0xa5, 0x69, 0x4a, 0xae, 0x5c, 0xec, 0x41, 0xa9, 0x85, 0xa5, 0xa9, 0xc5, 0x25, 0x42, 0x52, 0x5c, 0x1c, 0x49, 0xa5, 0xc9, 0xd9, 0xa9, 0x25, 0x9e, 0x2e, 0x12, 0x8c, 0x0a, 0x8c, 0x1a, 0x9c, 0x41, 0x70, 0xbe, 0x90, 0x1c, 0x17, 0x57, 0x7e, 0x52, 0x56, 0x6a, 0x72, 0x89, 0x5f, 0x62, 0x6e, 0xaa, 0x04, 0x13, 0x58, 0x16, 0x49, 0x44, 0x29, 0x82, 0x8b, 0x23, 0x28, 0xb5, 0xb8, 0x20, 0x3f, 0xaf, 0x38, 0x55, 0x48, 0x88, 0x8b, 0x25, 0x25, 0xb1, 0x24, 0x11, 0x6c, 0x06, 0x4f, 0x10, 0x98, 0x2d, 0x24, 0xc3, 0xc5, 0x99, 0x5a, 0x54, 0x94, 0x5f, 0xe4, 0x9c, 0x9f, 0x02, 0xd1, 0xce, 0x1c, 0x84, 0x10, 0x00, 0xd9, 0x0c, 0xe6, 0xf8, 0x16, 0xa7, 0x4b, 0x30, 0x43, 0x6c, 0x86, 0xf1, 0x8d, 0xec, 0xb8, 0xd8, 0x83, 0x21, 0x6e, 0x17, 0x32, 0xe6, 0xe2, 0x70, 0xc9, 0x2f, 0xcf, 0xcb, 0xc9, 0x4f, 0x4c, 0x11, 0x12, 0xd4, 0x83, 0x79, 0x41, 0x0f, 0xea, 0x7e, 0x29, 0x21, 0x64, 0x21, 0x88, 0x5b, 0x0c, 0x18, 0x9d, 0xd8, 0xa3, 0x58, 0xf5, 0xf4, 0xf4, 0x0b, 0x92, 0x92, 0xd8, 0xc0, 0xb2, 0xc6, 0x80, 0x00, 0x00, 0x00, 0xff, 0xff, 0xbe, 0xb8, 0x80, 0x00, 0x0b, 0x01, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. var _ context.Context var _ grpc.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 _ = grpc.SupportPackageIsVersion4 // ServiceClient is the client API for Service service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type ServiceClient interface { Download(ctx context.Context, in *Request, opts ...grpc.CallOption) (Service_DownloadClient, error) } type serviceClient struct { cc *grpc.ClientConn } func NewServiceClient(cc *grpc.ClientConn) ServiceClient { return &serviceClient{cc} } func (c *serviceClient) Download(ctx context.Context, in *Request, opts ...grpc.CallOption) (Service_DownloadClient, error) { stream, err := c.cc.NewStream(ctx, &_Service_serviceDesc.Streams[0], "/protobuf.Service/Download", opts...) if err != nil { return nil, err } x := &serviceDownloadClient{stream} if err := x.ClientStream.SendMsg(in); err != nil { return nil, err } if err := x.ClientStream.CloseSend(); err != nil { return nil, err } return x, nil } type Service_DownloadClient interface { Recv() (*Response, error) grpc.ClientStream } type serviceDownloadClient struct { grpc.ClientStream } func (x *serviceDownloadClient) Recv() (*Response, error) { m := new(Response) if err := x.ClientStream.RecvMsg(m); err != nil { return nil, err } return m, nil } // ServiceServer is the server API for Service service. type ServiceServer interface { Download(*Request, Service_DownloadServer) error } func RegisterServiceServer(s *grpc.Server, srv ServiceServer) { s.RegisterService(&_Service_serviceDesc, srv) } func _Service_Download_Handler(srv interface{}, stream grpc.ServerStream) error { m := new(Request) if err := stream.RecvMsg(m); err != nil { return err } return srv.(ServiceServer).Download(m, &serviceDownloadServer{stream}) } type Service_DownloadServer interface { Send(*Response) error grpc.ServerStream } type serviceDownloadServer struct { grpc.ServerStream } func (x *serviceDownloadServer) Send(m *Response) error { return x.ServerStream.SendMsg(m) } var _Service_serviceDesc = grpc.ServiceDesc{ ServiceName: "protobuf.Service", HandlerType: (*ServiceServer)(nil), Methods: []grpc.MethodDesc{}, Streams: []grpc.StreamDesc{ { StreamName: "Download", Handler: _Service_Download_Handler, ServerStreams: true, }, }, Metadata: "service.proto", }