blob: fd650cb8fcfc91e6fc2fd2fbaa59fc7eed05d102 [file] [log] [blame]
// Copyright 2010 The Goma Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
// goma file service API
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.25.0
// protoc v3.13.0
// source: file/file_service.proto
package file
import (
context "context"
proto "github.com/golang/protobuf/proto"
api "go.chromium.org/goma/server/proto/api"
grpc "google.golang.org/grpc"
codes "google.golang.org/grpc/codes"
status "google.golang.org/grpc/status"
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
reflect "reflect"
)
const (
// Verify that this generated code is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
// Verify that runtime/protoimpl is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)
// This is a compile-time assertion that a sufficiently up-to-date version
// of the legacy proto package is being used.
const _ = proto.ProtoPackageIsVersion4
var File_file_file_service_proto protoreflect.FileDescriptor
var file_file_file_service_proto_rawDesc = []byte{
0x0a, 0x17, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x5f, 0x73, 0x65, 0x72, 0x76,
0x69, 0x63, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0d, 0x64, 0x65, 0x76, 0x74, 0x6f,
0x6f, 0x6c, 0x73, 0x5f, 0x67, 0x6f, 0x6d, 0x61, 0x1a, 0x13, 0x61, 0x70, 0x69, 0x2f, 0x67, 0x6f,
0x6d, 0x61, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x32, 0xa4, 0x01,
0x0a, 0x0b, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x48, 0x0a,
0x09, 0x53, 0x74, 0x6f, 0x72, 0x65, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x1b, 0x2e, 0x64, 0x65, 0x76,
0x74, 0x6f, 0x6f, 0x6c, 0x73, 0x5f, 0x67, 0x6f, 0x6d, 0x61, 0x2e, 0x53, 0x74, 0x6f, 0x72, 0x65,
0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x1a, 0x1c, 0x2e, 0x64, 0x65, 0x76, 0x74, 0x6f, 0x6f,
0x6c, 0x73, 0x5f, 0x67, 0x6f, 0x6d, 0x61, 0x2e, 0x53, 0x74, 0x6f, 0x72, 0x65, 0x46, 0x69, 0x6c,
0x65, 0x52, 0x65, 0x73, 0x70, 0x22, 0x00, 0x12, 0x4b, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75,
0x70, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x1c, 0x2e, 0x64, 0x65, 0x76, 0x74, 0x6f, 0x6f, 0x6c, 0x73,
0x5f, 0x67, 0x6f, 0x6d, 0x61, 0x2e, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x46, 0x69, 0x6c, 0x65,
0x52, 0x65, 0x71, 0x1a, 0x1d, 0x2e, 0x64, 0x65, 0x76, 0x74, 0x6f, 0x6f, 0x6c, 0x73, 0x5f, 0x67,
0x6f, 0x6d, 0x61, 0x2e, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65,
0x73, 0x70, 0x22, 0x00, 0x42, 0x31, 0x5a, 0x26, 0x67, 0x6f, 0x2e, 0x63, 0x68, 0x72, 0x6f, 0x6d,
0x69, 0x75, 0x6d, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x67, 0x6f, 0x6d, 0x61, 0x2f, 0x73, 0x65, 0x72,
0x76, 0x65, 0x72, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x80, 0x01,
0x00, 0x88, 0x01, 0x00, 0x90, 0x01, 0x00,
}
var file_file_file_service_proto_goTypes = []interface{}{
(*api.StoreFileReq)(nil), // 0: devtools_goma.StoreFileReq
(*api.LookupFileReq)(nil), // 1: devtools_goma.LookupFileReq
(*api.StoreFileResp)(nil), // 2: devtools_goma.StoreFileResp
(*api.LookupFileResp)(nil), // 3: devtools_goma.LookupFileResp
}
var file_file_file_service_proto_depIdxs = []int32{
0, // 0: devtools_goma.FileService.StoreFile:input_type -> devtools_goma.StoreFileReq
1, // 1: devtools_goma.FileService.LookupFile:input_type -> devtools_goma.LookupFileReq
2, // 2: devtools_goma.FileService.StoreFile:output_type -> devtools_goma.StoreFileResp
3, // 3: devtools_goma.FileService.LookupFile:output_type -> devtools_goma.LookupFileResp
2, // [2:4] is the sub-list for method output_type
0, // [0:2] is the sub-list for method input_type
0, // [0:0] is the sub-list for extension type_name
0, // [0:0] is the sub-list for extension extendee
0, // [0:0] is the sub-list for field type_name
}
func init() { file_file_file_service_proto_init() }
func file_file_file_service_proto_init() {
if File_file_file_service_proto != nil {
return
}
type x struct{}
out := protoimpl.TypeBuilder{
File: protoimpl.DescBuilder{
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: file_file_file_service_proto_rawDesc,
NumEnums: 0,
NumMessages: 0,
NumExtensions: 0,
NumServices: 1,
},
GoTypes: file_file_file_service_proto_goTypes,
DependencyIndexes: file_file_file_service_proto_depIdxs,
}.Build()
File_file_file_service_proto = out.File
file_file_file_service_proto_rawDesc = nil
file_file_file_service_proto_goTypes = nil
file_file_file_service_proto_depIdxs = nil
}
// Reference imports to suppress errors if they are not otherwise used.
var _ context.Context
var _ grpc.ClientConnInterface
// 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.SupportPackageIsVersion6
// FileServiceClient is the client API for FileService service.
//
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
type FileServiceClient interface {
StoreFile(ctx context.Context, in *api.StoreFileReq, opts ...grpc.CallOption) (*api.StoreFileResp, error)
LookupFile(ctx context.Context, in *api.LookupFileReq, opts ...grpc.CallOption) (*api.LookupFileResp, error)
}
type fileServiceClient struct {
cc grpc.ClientConnInterface
}
func NewFileServiceClient(cc grpc.ClientConnInterface) FileServiceClient {
return &fileServiceClient{cc}
}
func (c *fileServiceClient) StoreFile(ctx context.Context, in *api.StoreFileReq, opts ...grpc.CallOption) (*api.StoreFileResp, error) {
out := new(api.StoreFileResp)
err := c.cc.Invoke(ctx, "/devtools_goma.FileService/StoreFile", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *fileServiceClient) LookupFile(ctx context.Context, in *api.LookupFileReq, opts ...grpc.CallOption) (*api.LookupFileResp, error) {
out := new(api.LookupFileResp)
err := c.cc.Invoke(ctx, "/devtools_goma.FileService/LookupFile", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
// FileServiceServer is the server API for FileService service.
type FileServiceServer interface {
StoreFile(context.Context, *api.StoreFileReq) (*api.StoreFileResp, error)
LookupFile(context.Context, *api.LookupFileReq) (*api.LookupFileResp, error)
}
// UnimplementedFileServiceServer can be embedded to have forward compatible implementations.
type UnimplementedFileServiceServer struct {
}
func (*UnimplementedFileServiceServer) StoreFile(context.Context, *api.StoreFileReq) (*api.StoreFileResp, error) {
return nil, status.Errorf(codes.Unimplemented, "method StoreFile not implemented")
}
func (*UnimplementedFileServiceServer) LookupFile(context.Context, *api.LookupFileReq) (*api.LookupFileResp, error) {
return nil, status.Errorf(codes.Unimplemented, "method LookupFile not implemented")
}
func RegisterFileServiceServer(s *grpc.Server, srv FileServiceServer) {
s.RegisterService(&_FileService_serviceDesc, srv)
}
func _FileService_StoreFile_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(api.StoreFileReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(FileServiceServer).StoreFile(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/devtools_goma.FileService/StoreFile",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(FileServiceServer).StoreFile(ctx, req.(*api.StoreFileReq))
}
return interceptor(ctx, in, info, handler)
}
func _FileService_LookupFile_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(api.LookupFileReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(FileServiceServer).LookupFile(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/devtools_goma.FileService/LookupFile",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(FileServiceServer).LookupFile(ctx, req.(*api.LookupFileReq))
}
return interceptor(ctx, in, info, handler)
}
var _FileService_serviceDesc = grpc.ServiceDesc{
ServiceName: "devtools_goma.FileService",
HandlerType: (*FileServiceServer)(nil),
Methods: []grpc.MethodDesc{
{
MethodName: "StoreFile",
Handler: _FileService_StoreFile_Handler,
},
{
MethodName: "LookupFile",
Handler: _FileService_LookupFile_Handler,
},
},
Streams: []grpc.StreamDesc{},
Metadata: "file/file_service.proto",
}