1// Code generated by protoc-gen-go-grpc. DO NOT EDIT. 2 3package gitalypb 4 5import ( 6 context "context" 7 grpc "google.golang.org/grpc" 8 codes "google.golang.org/grpc/codes" 9 status "google.golang.org/grpc/status" 10) 11 12// This is a compile-time assertion to ensure that this generated file 13// is compatible with the grpc package it is being compiled against. 14// Requires gRPC-Go v1.32.0 or later. 15const _ = grpc.SupportPackageIsVersion7 16 17// ServerServiceClient is the client API for ServerService service. 18// 19// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. 20type ServerServiceClient interface { 21 ServerInfo(ctx context.Context, in *ServerInfoRequest, opts ...grpc.CallOption) (*ServerInfoResponse, error) 22 DiskStatistics(ctx context.Context, in *DiskStatisticsRequest, opts ...grpc.CallOption) (*DiskStatisticsResponse, error) 23} 24 25type serverServiceClient struct { 26 cc grpc.ClientConnInterface 27} 28 29func NewServerServiceClient(cc grpc.ClientConnInterface) ServerServiceClient { 30 return &serverServiceClient{cc} 31} 32 33func (c *serverServiceClient) ServerInfo(ctx context.Context, in *ServerInfoRequest, opts ...grpc.CallOption) (*ServerInfoResponse, error) { 34 out := new(ServerInfoResponse) 35 err := c.cc.Invoke(ctx, "/gitaly.ServerService/ServerInfo", in, out, opts...) 36 if err != nil { 37 return nil, err 38 } 39 return out, nil 40} 41 42func (c *serverServiceClient) DiskStatistics(ctx context.Context, in *DiskStatisticsRequest, opts ...grpc.CallOption) (*DiskStatisticsResponse, error) { 43 out := new(DiskStatisticsResponse) 44 err := c.cc.Invoke(ctx, "/gitaly.ServerService/DiskStatistics", in, out, opts...) 45 if err != nil { 46 return nil, err 47 } 48 return out, nil 49} 50 51// ServerServiceServer is the server API for ServerService service. 52// All implementations must embed UnimplementedServerServiceServer 53// for forward compatibility 54type ServerServiceServer interface { 55 ServerInfo(context.Context, *ServerInfoRequest) (*ServerInfoResponse, error) 56 DiskStatistics(context.Context, *DiskStatisticsRequest) (*DiskStatisticsResponse, error) 57 mustEmbedUnimplementedServerServiceServer() 58} 59 60// UnimplementedServerServiceServer must be embedded to have forward compatible implementations. 61type UnimplementedServerServiceServer struct { 62} 63 64func (UnimplementedServerServiceServer) ServerInfo(context.Context, *ServerInfoRequest) (*ServerInfoResponse, error) { 65 return nil, status.Errorf(codes.Unimplemented, "method ServerInfo not implemented") 66} 67func (UnimplementedServerServiceServer) DiskStatistics(context.Context, *DiskStatisticsRequest) (*DiskStatisticsResponse, error) { 68 return nil, status.Errorf(codes.Unimplemented, "method DiskStatistics not implemented") 69} 70func (UnimplementedServerServiceServer) mustEmbedUnimplementedServerServiceServer() {} 71 72// UnsafeServerServiceServer may be embedded to opt out of forward compatibility for this service. 73// Use of this interface is not recommended, as added methods to ServerServiceServer will 74// result in compilation errors. 75type UnsafeServerServiceServer interface { 76 mustEmbedUnimplementedServerServiceServer() 77} 78 79func RegisterServerServiceServer(s grpc.ServiceRegistrar, srv ServerServiceServer) { 80 s.RegisterService(&ServerService_ServiceDesc, srv) 81} 82 83func _ServerService_ServerInfo_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { 84 in := new(ServerInfoRequest) 85 if err := dec(in); err != nil { 86 return nil, err 87 } 88 if interceptor == nil { 89 return srv.(ServerServiceServer).ServerInfo(ctx, in) 90 } 91 info := &grpc.UnaryServerInfo{ 92 Server: srv, 93 FullMethod: "/gitaly.ServerService/ServerInfo", 94 } 95 handler := func(ctx context.Context, req interface{}) (interface{}, error) { 96 return srv.(ServerServiceServer).ServerInfo(ctx, req.(*ServerInfoRequest)) 97 } 98 return interceptor(ctx, in, info, handler) 99} 100 101func _ServerService_DiskStatistics_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { 102 in := new(DiskStatisticsRequest) 103 if err := dec(in); err != nil { 104 return nil, err 105 } 106 if interceptor == nil { 107 return srv.(ServerServiceServer).DiskStatistics(ctx, in) 108 } 109 info := &grpc.UnaryServerInfo{ 110 Server: srv, 111 FullMethod: "/gitaly.ServerService/DiskStatistics", 112 } 113 handler := func(ctx context.Context, req interface{}) (interface{}, error) { 114 return srv.(ServerServiceServer).DiskStatistics(ctx, req.(*DiskStatisticsRequest)) 115 } 116 return interceptor(ctx, in, info, handler) 117} 118 119// ServerService_ServiceDesc is the grpc.ServiceDesc for ServerService service. 120// It's only intended for direct use with grpc.RegisterService, 121// and not to be introspected or modified (even as a copy) 122var ServerService_ServiceDesc = grpc.ServiceDesc{ 123 ServiceName: "gitaly.ServerService", 124 HandlerType: (*ServerServiceServer)(nil), 125 Methods: []grpc.MethodDesc{ 126 { 127 MethodName: "ServerInfo", 128 Handler: _ServerService_ServerInfo_Handler, 129 }, 130 { 131 MethodName: "DiskStatistics", 132 Handler: _ServerService_DiskStatistics_Handler, 133 }, 134 }, 135 Streams: []grpc.StreamDesc{}, 136 Metadata: "server.proto", 137} 138