go.chromium.org/luci@v0.0.0-20240309015107-7cdc2e660f33/auth_service/api/rpcpb/changelogs_grpc.pb.go (about) 1 // Copyright 2022 The LUCI Authors. 2 // 3 // Licensed under the Apache License, Version 2.0 (the "License"); 4 // you may not use this file except in compliance with the License. 5 // You may obtain a copy of the License at 6 // 7 // http://www.apache.org/licenses/LICENSE-2.0 8 // 9 // Unless required by applicable law or agreed to in writing, software 10 // distributed under the License is distributed on an "AS IS" BASIS, 11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 // See the License for the specific language governing permissions and 13 // limitations under the License. 14 15 // Code generated by protoc-gen-go-grpc. DO NOT EDIT. 16 // versions: 17 // - protoc-gen-go-grpc v1.3.0 18 // - protoc v3.21.7 19 // source: go.chromium.org/luci/auth_service/api/rpcpb/changelogs.proto 20 21 package rpcpb 22 23 import ( 24 context "context" 25 grpc "google.golang.org/grpc" 26 codes "google.golang.org/grpc/codes" 27 status "google.golang.org/grpc/status" 28 ) 29 30 // This is a compile-time assertion to ensure that this generated file 31 // is compatible with the grpc package it is being compiled against. 32 // Requires gRPC-Go v1.32.0 or later. 33 const _ = grpc.SupportPackageIsVersion7 34 35 const ( 36 ChangeLogs_ListChangeLogs_FullMethodName = "/auth.service.ChangeLogs/ListChangeLogs" 37 ) 38 39 // ChangeLogsClient is the client API for ChangeLogs service. 40 // 41 // 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. 42 type ChangeLogsClient interface { 43 // ListChangeLogs returns all the change logs in Datastore. 44 ListChangeLogs(ctx context.Context, in *ListChangeLogsRequest, opts ...grpc.CallOption) (*ListChangeLogsResponse, error) 45 } 46 47 type changeLogsClient struct { 48 cc grpc.ClientConnInterface 49 } 50 51 func NewChangeLogsClient(cc grpc.ClientConnInterface) ChangeLogsClient { 52 return &changeLogsClient{cc} 53 } 54 55 func (c *changeLogsClient) ListChangeLogs(ctx context.Context, in *ListChangeLogsRequest, opts ...grpc.CallOption) (*ListChangeLogsResponse, error) { 56 out := new(ListChangeLogsResponse) 57 err := c.cc.Invoke(ctx, ChangeLogs_ListChangeLogs_FullMethodName, in, out, opts...) 58 if err != nil { 59 return nil, err 60 } 61 return out, nil 62 } 63 64 // ChangeLogsServer is the server API for ChangeLogs service. 65 // All implementations must embed UnimplementedChangeLogsServer 66 // for forward compatibility 67 type ChangeLogsServer interface { 68 // ListChangeLogs returns all the change logs in Datastore. 69 ListChangeLogs(context.Context, *ListChangeLogsRequest) (*ListChangeLogsResponse, error) 70 mustEmbedUnimplementedChangeLogsServer() 71 } 72 73 // UnimplementedChangeLogsServer must be embedded to have forward compatible implementations. 74 type UnimplementedChangeLogsServer struct { 75 } 76 77 func (UnimplementedChangeLogsServer) ListChangeLogs(context.Context, *ListChangeLogsRequest) (*ListChangeLogsResponse, error) { 78 return nil, status.Errorf(codes.Unimplemented, "method ListChangeLogs not implemented") 79 } 80 func (UnimplementedChangeLogsServer) mustEmbedUnimplementedChangeLogsServer() {} 81 82 // UnsafeChangeLogsServer may be embedded to opt out of forward compatibility for this service. 83 // Use of this interface is not recommended, as added methods to ChangeLogsServer will 84 // result in compilation errors. 85 type UnsafeChangeLogsServer interface { 86 mustEmbedUnimplementedChangeLogsServer() 87 } 88 89 func RegisterChangeLogsServer(s grpc.ServiceRegistrar, srv ChangeLogsServer) { 90 s.RegisterService(&ChangeLogs_ServiceDesc, srv) 91 } 92 93 func _ChangeLogs_ListChangeLogs_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { 94 in := new(ListChangeLogsRequest) 95 if err := dec(in); err != nil { 96 return nil, err 97 } 98 if interceptor == nil { 99 return srv.(ChangeLogsServer).ListChangeLogs(ctx, in) 100 } 101 info := &grpc.UnaryServerInfo{ 102 Server: srv, 103 FullMethod: ChangeLogs_ListChangeLogs_FullMethodName, 104 } 105 handler := func(ctx context.Context, req interface{}) (interface{}, error) { 106 return srv.(ChangeLogsServer).ListChangeLogs(ctx, req.(*ListChangeLogsRequest)) 107 } 108 return interceptor(ctx, in, info, handler) 109 } 110 111 // ChangeLogs_ServiceDesc is the grpc.ServiceDesc for ChangeLogs service. 112 // It's only intended for direct use with grpc.RegisterService, 113 // and not to be introspected or modified (even as a copy) 114 var ChangeLogs_ServiceDesc = grpc.ServiceDesc{ 115 ServiceName: "auth.service.ChangeLogs", 116 HandlerType: (*ChangeLogsServer)(nil), 117 Methods: []grpc.MethodDesc{ 118 { 119 MethodName: "ListChangeLogs", 120 Handler: _ChangeLogs_ListChangeLogs_Handler, 121 }, 122 }, 123 Streams: []grpc.StreamDesc{}, 124 Metadata: "go.chromium.org/luci/auth_service/api/rpcpb/changelogs.proto", 125 }