-
Notifications
You must be signed in to change notification settings - Fork 0
/
file_manager_service_grpc.pb.go
259 lines (230 loc) · 9.9 KB
/
file_manager_service_grpc.pb.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
// Code generated by protoc-gen-go-grpc. DO NOT EDIT.
package v1
import (
context "context"
grpc "google.golang.org/grpc"
codes "google.golang.org/grpc/codes"
status "google.golang.org/grpc/status"
)
// This is a compile-time assertion to ensure that this generated file
// is compatible with the grpc package it is being compiled against.
// Requires gRPC-Go v1.32.0 or later.
const _ = grpc.SupportPackageIsVersion7
// FilesServiceClient is the client API for FilesService service.
//
// 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.
type FilesServiceClient interface {
ListFiles(ctx context.Context, in *ListFilesRequest, opts ...grpc.CallOption) (*ListFilesResponse, error)
GetFile(ctx context.Context, in *GetFileRequest, opts ...grpc.CallOption) (*File, error)
DeleteFile(ctx context.Context, in *DeleteFileRequest, opts ...grpc.CallOption) (*DeleteFileResponse, error)
}
type filesServiceClient struct {
cc grpc.ClientConnInterface
}
func NewFilesServiceClient(cc grpc.ClientConnInterface) FilesServiceClient {
return &filesServiceClient{cc}
}
func (c *filesServiceClient) ListFiles(ctx context.Context, in *ListFilesRequest, opts ...grpc.CallOption) (*ListFilesResponse, error) {
out := new(ListFilesResponse)
err := c.cc.Invoke(ctx, "/llmoperator.files.server.v1.FilesService/ListFiles", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *filesServiceClient) GetFile(ctx context.Context, in *GetFileRequest, opts ...grpc.CallOption) (*File, error) {
out := new(File)
err := c.cc.Invoke(ctx, "/llmoperator.files.server.v1.FilesService/GetFile", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *filesServiceClient) DeleteFile(ctx context.Context, in *DeleteFileRequest, opts ...grpc.CallOption) (*DeleteFileResponse, error) {
out := new(DeleteFileResponse)
err := c.cc.Invoke(ctx, "/llmoperator.files.server.v1.FilesService/DeleteFile", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
// FilesServiceServer is the server API for FilesService service.
// All implementations must embed UnimplementedFilesServiceServer
// for forward compatibility
type FilesServiceServer interface {
ListFiles(context.Context, *ListFilesRequest) (*ListFilesResponse, error)
GetFile(context.Context, *GetFileRequest) (*File, error)
DeleteFile(context.Context, *DeleteFileRequest) (*DeleteFileResponse, error)
mustEmbedUnimplementedFilesServiceServer()
}
// UnimplementedFilesServiceServer must be embedded to have forward compatible implementations.
type UnimplementedFilesServiceServer struct {
}
func (UnimplementedFilesServiceServer) ListFiles(context.Context, *ListFilesRequest) (*ListFilesResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method ListFiles not implemented")
}
func (UnimplementedFilesServiceServer) GetFile(context.Context, *GetFileRequest) (*File, error) {
return nil, status.Errorf(codes.Unimplemented, "method GetFile not implemented")
}
func (UnimplementedFilesServiceServer) DeleteFile(context.Context, *DeleteFileRequest) (*DeleteFileResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method DeleteFile not implemented")
}
func (UnimplementedFilesServiceServer) mustEmbedUnimplementedFilesServiceServer() {}
// UnsafeFilesServiceServer may be embedded to opt out of forward compatibility for this service.
// Use of this interface is not recommended, as added methods to FilesServiceServer will
// result in compilation errors.
type UnsafeFilesServiceServer interface {
mustEmbedUnimplementedFilesServiceServer()
}
func RegisterFilesServiceServer(s grpc.ServiceRegistrar, srv FilesServiceServer) {
s.RegisterService(&FilesService_ServiceDesc, srv)
}
func _FilesService_ListFiles_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(ListFilesRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(FilesServiceServer).ListFiles(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/llmoperator.files.server.v1.FilesService/ListFiles",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(FilesServiceServer).ListFiles(ctx, req.(*ListFilesRequest))
}
return interceptor(ctx, in, info, handler)
}
func _FilesService_GetFile_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(GetFileRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(FilesServiceServer).GetFile(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/llmoperator.files.server.v1.FilesService/GetFile",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(FilesServiceServer).GetFile(ctx, req.(*GetFileRequest))
}
return interceptor(ctx, in, info, handler)
}
func _FilesService_DeleteFile_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(DeleteFileRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(FilesServiceServer).DeleteFile(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/llmoperator.files.server.v1.FilesService/DeleteFile",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(FilesServiceServer).DeleteFile(ctx, req.(*DeleteFileRequest))
}
return interceptor(ctx, in, info, handler)
}
// FilesService_ServiceDesc is the grpc.ServiceDesc for FilesService service.
// It's only intended for direct use with grpc.RegisterService,
// and not to be introspected or modified (even as a copy)
var FilesService_ServiceDesc = grpc.ServiceDesc{
ServiceName: "llmoperator.files.server.v1.FilesService",
HandlerType: (*FilesServiceServer)(nil),
Methods: []grpc.MethodDesc{
{
MethodName: "ListFiles",
Handler: _FilesService_ListFiles_Handler,
},
{
MethodName: "GetFile",
Handler: _FilesService_GetFile_Handler,
},
{
MethodName: "DeleteFile",
Handler: _FilesService_DeleteFile_Handler,
},
},
Streams: []grpc.StreamDesc{},
Metadata: "api/v1/file_manager_service.proto",
}
// FilesInternalServiceClient is the client API for FilesInternalService service.
//
// 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.
type FilesInternalServiceClient interface {
GetFilePath(ctx context.Context, in *GetFilePathRequest, opts ...grpc.CallOption) (*GetFilePathResponse, error)
}
type filesInternalServiceClient struct {
cc grpc.ClientConnInterface
}
func NewFilesInternalServiceClient(cc grpc.ClientConnInterface) FilesInternalServiceClient {
return &filesInternalServiceClient{cc}
}
func (c *filesInternalServiceClient) GetFilePath(ctx context.Context, in *GetFilePathRequest, opts ...grpc.CallOption) (*GetFilePathResponse, error) {
out := new(GetFilePathResponse)
err := c.cc.Invoke(ctx, "/llmoperator.files.server.v1.FilesInternalService/GetFilePath", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
// FilesInternalServiceServer is the server API for FilesInternalService service.
// All implementations must embed UnimplementedFilesInternalServiceServer
// for forward compatibility
type FilesInternalServiceServer interface {
GetFilePath(context.Context, *GetFilePathRequest) (*GetFilePathResponse, error)
mustEmbedUnimplementedFilesInternalServiceServer()
}
// UnimplementedFilesInternalServiceServer must be embedded to have forward compatible implementations.
type UnimplementedFilesInternalServiceServer struct {
}
func (UnimplementedFilesInternalServiceServer) GetFilePath(context.Context, *GetFilePathRequest) (*GetFilePathResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method GetFilePath not implemented")
}
func (UnimplementedFilesInternalServiceServer) mustEmbedUnimplementedFilesInternalServiceServer() {}
// UnsafeFilesInternalServiceServer may be embedded to opt out of forward compatibility for this service.
// Use of this interface is not recommended, as added methods to FilesInternalServiceServer will
// result in compilation errors.
type UnsafeFilesInternalServiceServer interface {
mustEmbedUnimplementedFilesInternalServiceServer()
}
func RegisterFilesInternalServiceServer(s grpc.ServiceRegistrar, srv FilesInternalServiceServer) {
s.RegisterService(&FilesInternalService_ServiceDesc, srv)
}
func _FilesInternalService_GetFilePath_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(GetFilePathRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(FilesInternalServiceServer).GetFilePath(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/llmoperator.files.server.v1.FilesInternalService/GetFilePath",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(FilesInternalServiceServer).GetFilePath(ctx, req.(*GetFilePathRequest))
}
return interceptor(ctx, in, info, handler)
}
// FilesInternalService_ServiceDesc is the grpc.ServiceDesc for FilesInternalService service.
// It's only intended for direct use with grpc.RegisterService,
// and not to be introspected or modified (even as a copy)
var FilesInternalService_ServiceDesc = grpc.ServiceDesc{
ServiceName: "llmoperator.files.server.v1.FilesInternalService",
HandlerType: (*FilesInternalServiceServer)(nil),
Methods: []grpc.MethodDesc{
{
MethodName: "GetFilePath",
Handler: _FilesInternalService_GetFilePath_Handler,
},
},
Streams: []grpc.StreamDesc{},
Metadata: "api/v1/file_manager_service.proto",
}