// Code generated by protoc-gen-go-grpc. DO NOT EDIT. // versions: // - protoc-gen-go-grpc v1.2.0 // - protoc v5.27.1 // source: plugin.proto package __ 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 // PluginClient is the client API for Plugin 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 PluginClient interface { Alive(ctx context.Context, in *AliveIn, opts ...grpc.CallOption) (*AliveOut, error) Exec(ctx context.Context, in *ExecIn, opts ...grpc.CallOption) (*ExecOut, error) List(ctx context.Context, in *ListIn, opts ...grpc.CallOption) (*ListOut, error) } type pluginClient struct { cc grpc.ClientConnInterface } func NewPluginClient(cc grpc.ClientConnInterface) PluginClient { return &pluginClient{cc} } func (c *pluginClient) Alive(ctx context.Context, in *AliveIn, opts ...grpc.CallOption) (*AliveOut, error) { out := new(AliveOut) err := c.cc.Invoke(ctx, "/plugin.Plugin/Alive", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *pluginClient) Exec(ctx context.Context, in *ExecIn, opts ...grpc.CallOption) (*ExecOut, error) { out := new(ExecOut) err := c.cc.Invoke(ctx, "/plugin.Plugin/Exec", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *pluginClient) List(ctx context.Context, in *ListIn, opts ...grpc.CallOption) (*ListOut, error) { out := new(ListOut) err := c.cc.Invoke(ctx, "/plugin.Plugin/List", in, out, opts...) if err != nil { return nil, err } return out, nil } // PluginServer is the server API for Plugin service. // All implementations must embed UnimplementedPluginServer // for forward compatibility type PluginServer interface { Alive(context.Context, *AliveIn) (*AliveOut, error) Exec(context.Context, *ExecIn) (*ExecOut, error) List(context.Context, *ListIn) (*ListOut, error) mustEmbedUnimplementedPluginServer() } // UnimplementedPluginServer must be embedded to have forward compatible implementations. type UnimplementedPluginServer struct { } func (UnimplementedPluginServer) Alive(context.Context, *AliveIn) (*AliveOut, error) { return nil, status.Errorf(codes.Unimplemented, "method Alive not implemented") } func (UnimplementedPluginServer) Exec(context.Context, *ExecIn) (*ExecOut, error) { return nil, status.Errorf(codes.Unimplemented, "method Exec not implemented") } func (UnimplementedPluginServer) List(context.Context, *ListIn) (*ListOut, error) { return nil, status.Errorf(codes.Unimplemented, "method List not implemented") } func (UnimplementedPluginServer) mustEmbedUnimplementedPluginServer() {} // UnsafePluginServer may be embedded to opt out of forward compatibility for this service. // Use of this interface is not recommended, as added methods to PluginServer will // result in compilation errors. type UnsafePluginServer interface { mustEmbedUnimplementedPluginServer() } func RegisterPluginServer(s grpc.ServiceRegistrar, srv PluginServer) { s.RegisterService(&Plugin_ServiceDesc, srv) } func _Plugin_Alive_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(AliveIn) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(PluginServer).Alive(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/plugin.Plugin/Alive", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(PluginServer).Alive(ctx, req.(*AliveIn)) } return interceptor(ctx, in, info, handler) } func _Plugin_Exec_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(ExecIn) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(PluginServer).Exec(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/plugin.Plugin/Exec", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(PluginServer).Exec(ctx, req.(*ExecIn)) } return interceptor(ctx, in, info, handler) } func _Plugin_List_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(ListIn) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(PluginServer).List(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/plugin.Plugin/List", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(PluginServer).List(ctx, req.(*ListIn)) } return interceptor(ctx, in, info, handler) } // Plugin_ServiceDesc is the grpc.ServiceDesc for Plugin service. // It's only intended for direct use with grpc.RegisterService, // and not to be introspected or modified (even as a copy) var Plugin_ServiceDesc = grpc.ServiceDesc{ ServiceName: "plugin.Plugin", HandlerType: (*PluginServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Alive", Handler: _Plugin_Alive_Handler, }, { MethodName: "Exec", Handler: _Plugin_Exec_Handler, }, { MethodName: "List", Handler: _Plugin_List_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "plugin.proto", }