154 lines
4.9 KiB
Go
154 lines
4.9 KiB
Go
// Code generated by protoc-gen-gogo. DO NOT EDIT.
|
|
// source: syncproto/proto/service.proto
|
|
|
|
package syncproto
|
|
|
|
import (
|
|
context "context"
|
|
fmt "fmt"
|
|
proto "github.com/gogo/protobuf/proto"
|
|
grpc "google.golang.org/grpc"
|
|
codes "google.golang.org/grpc/codes"
|
|
status "google.golang.org/grpc/status"
|
|
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.GoGoProtoPackageIsVersion3 // please upgrade the proto package
|
|
|
|
func init() { proto.RegisterFile("syncproto/proto/service.proto", fileDescriptor_bc194c2299f43729) }
|
|
|
|
var fileDescriptor_bc194c2299f43729 = []byte{
|
|
// 156 bytes of a gzipped FileDescriptorProto
|
|
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x2d, 0xae, 0xcc, 0x4b,
|
|
0x2e, 0x28, 0xca, 0x2f, 0xc9, 0xd7, 0x87, 0x90, 0xc5, 0xa9, 0x45, 0x65, 0x99, 0xc9, 0xa9, 0x7a,
|
|
0x60, 0x9e, 0x10, 0x7b, 0x62, 0x5e, 0x65, 0x49, 0x65, 0x41, 0xaa, 0x94, 0x1c, 0xba, 0xba, 0xe4,
|
|
0xfc, 0xdc, 0xdc, 0xc4, 0xbc, 0x94, 0x62, 0x88, 0x42, 0x23, 0x0f, 0x2e, 0x6e, 0x47, 0x88, 0xd2,
|
|
0xe0, 0xca, 0xbc, 0x64, 0x21, 0x4b, 0x2e, 0x96, 0x80, 0xcc, 0xbc, 0x74, 0x21, 0x51, 0x3d, 0xa8,
|
|
0x01, 0x7a, 0x20, 0xae, 0x5e, 0x50, 0x6a, 0x61, 0x69, 0x6a, 0x71, 0x89, 0x94, 0x18, 0xba, 0x70,
|
|
0x71, 0x41, 0x7e, 0x5e, 0x71, 0xaa, 0x06, 0xa3, 0x01, 0xa3, 0x93, 0xf2, 0x89, 0x47, 0x72, 0x8c,
|
|
0x17, 0x1e, 0xc9, 0x31, 0x3e, 0x78, 0x24, 0xc7, 0x38, 0xe1, 0xb1, 0x1c, 0xc3, 0x85, 0xc7, 0x72,
|
|
0x0c, 0x37, 0x1e, 0xcb, 0x31, 0x44, 0x71, 0xc2, 0xdd, 0x90, 0xc4, 0x06, 0xa6, 0x8c, 0x01, 0x01,
|
|
0x00, 0x00, 0xff, 0xff, 0x4d, 0x33, 0xde, 0xf8, 0xbf, 0x00, 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
|
|
|
|
// AnytypeSyncClient is the client API for AnytypeSync service.
|
|
//
|
|
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
|
|
type AnytypeSyncClient interface {
|
|
Ping(ctx context.Context, opts ...grpc.CallOption) (AnytypeSync_PingClient, error)
|
|
}
|
|
|
|
type anytypeSyncClient struct {
|
|
cc *grpc.ClientConn
|
|
}
|
|
|
|
func NewAnytypeSyncClient(cc *grpc.ClientConn) AnytypeSyncClient {
|
|
return &anytypeSyncClient{cc}
|
|
}
|
|
|
|
func (c *anytypeSyncClient) Ping(ctx context.Context, opts ...grpc.CallOption) (AnytypeSync_PingClient, error) {
|
|
stream, err := c.cc.NewStream(ctx, &_AnytypeSync_serviceDesc.Streams[0], "/anytype.AnytypeSync/Ping", opts...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
x := &anytypeSyncPingClient{stream}
|
|
return x, nil
|
|
}
|
|
|
|
type AnytypeSync_PingClient interface {
|
|
Send(*PingRequest) error
|
|
Recv() (*PingResponse, error)
|
|
grpc.ClientStream
|
|
}
|
|
|
|
type anytypeSyncPingClient struct {
|
|
grpc.ClientStream
|
|
}
|
|
|
|
func (x *anytypeSyncPingClient) Send(m *PingRequest) error {
|
|
return x.ClientStream.SendMsg(m)
|
|
}
|
|
|
|
func (x *anytypeSyncPingClient) Recv() (*PingResponse, error) {
|
|
m := new(PingResponse)
|
|
if err := x.ClientStream.RecvMsg(m); err != nil {
|
|
return nil, err
|
|
}
|
|
return m, nil
|
|
}
|
|
|
|
// AnytypeSyncServer is the server API for AnytypeSync service.
|
|
type AnytypeSyncServer interface {
|
|
Ping(AnytypeSync_PingServer) error
|
|
}
|
|
|
|
// UnimplementedAnytypeSyncServer can be embedded to have forward compatible implementations.
|
|
type UnimplementedAnytypeSyncServer struct {
|
|
}
|
|
|
|
func (*UnimplementedAnytypeSyncServer) Ping(srv AnytypeSync_PingServer) error {
|
|
return status.Errorf(codes.Unimplemented, "method Ping not implemented")
|
|
}
|
|
|
|
func RegisterAnytypeSyncServer(s *grpc.Server, srv AnytypeSyncServer) {
|
|
s.RegisterService(&_AnytypeSync_serviceDesc, srv)
|
|
}
|
|
|
|
func _AnytypeSync_Ping_Handler(srv interface{}, stream grpc.ServerStream) error {
|
|
return srv.(AnytypeSyncServer).Ping(&anytypeSyncPingServer{stream})
|
|
}
|
|
|
|
type AnytypeSync_PingServer interface {
|
|
Send(*PingResponse) error
|
|
Recv() (*PingRequest, error)
|
|
grpc.ServerStream
|
|
}
|
|
|
|
type anytypeSyncPingServer struct {
|
|
grpc.ServerStream
|
|
}
|
|
|
|
func (x *anytypeSyncPingServer) Send(m *PingResponse) error {
|
|
return x.ServerStream.SendMsg(m)
|
|
}
|
|
|
|
func (x *anytypeSyncPingServer) Recv() (*PingRequest, error) {
|
|
m := new(PingRequest)
|
|
if err := x.ServerStream.RecvMsg(m); err != nil {
|
|
return nil, err
|
|
}
|
|
return m, nil
|
|
}
|
|
|
|
var _AnytypeSync_serviceDesc = grpc.ServiceDesc{
|
|
ServiceName: "anytype.AnytypeSync",
|
|
HandlerType: (*AnytypeSyncServer)(nil),
|
|
Methods: []grpc.MethodDesc{},
|
|
Streams: []grpc.StreamDesc{
|
|
{
|
|
StreamName: "Ping",
|
|
Handler: _AnytypeSync_Ping_Handler,
|
|
ServerStreams: true,
|
|
ClientStreams: true,
|
|
},
|
|
},
|
|
Metadata: "syncproto/proto/service.proto",
|
|
}
|