You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

100 lines
3.4 KiB

  1. // Code generated by protoc-gen-go-grpc. DO NOT EDIT.
  2. package s3_pb
  3. import (
  4. context "context"
  5. grpc "google.golang.org/grpc"
  6. codes "google.golang.org/grpc/codes"
  7. status "google.golang.org/grpc/status"
  8. )
  9. // This is a compile-time assertion to ensure that this generated file
  10. // is compatible with the grpc package it is being compiled against.
  11. const _ = grpc.SupportPackageIsVersion7
  12. // SeaweedS3Client is the client API for SeaweedS3 service.
  13. //
  14. // 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.
  15. type SeaweedS3Client interface {
  16. Configure(ctx context.Context, in *S3ConfigureRequest, opts ...grpc.CallOption) (*S3ConfigureResponse, error)
  17. }
  18. type seaweedS3Client struct {
  19. cc grpc.ClientConnInterface
  20. }
  21. func NewSeaweedS3Client(cc grpc.ClientConnInterface) SeaweedS3Client {
  22. return &seaweedS3Client{cc}
  23. }
  24. func (c *seaweedS3Client) Configure(ctx context.Context, in *S3ConfigureRequest, opts ...grpc.CallOption) (*S3ConfigureResponse, error) {
  25. out := new(S3ConfigureResponse)
  26. err := c.cc.Invoke(ctx, "/messaging_pb.SeaweedS3/Configure", in, out, opts...)
  27. if err != nil {
  28. return nil, err
  29. }
  30. return out, nil
  31. }
  32. // SeaweedS3Server is the server API for SeaweedS3 service.
  33. // All implementations must embed UnimplementedSeaweedS3Server
  34. // for forward compatibility
  35. type SeaweedS3Server interface {
  36. Configure(context.Context, *S3ConfigureRequest) (*S3ConfigureResponse, error)
  37. mustEmbedUnimplementedSeaweedS3Server()
  38. }
  39. // UnimplementedSeaweedS3Server must be embedded to have forward compatible implementations.
  40. type UnimplementedSeaweedS3Server struct {
  41. }
  42. func (UnimplementedSeaweedS3Server) Configure(context.Context, *S3ConfigureRequest) (*S3ConfigureResponse, error) {
  43. return nil, status.Errorf(codes.Unimplemented, "method Configure not implemented")
  44. }
  45. func (UnimplementedSeaweedS3Server) mustEmbedUnimplementedSeaweedS3Server() {}
  46. // UnsafeSeaweedS3Server may be embedded to opt out of forward compatibility for this service.
  47. // Use of this interface is not recommended, as added methods to SeaweedS3Server will
  48. // result in compilation errors.
  49. type UnsafeSeaweedS3Server interface {
  50. mustEmbedUnimplementedSeaweedS3Server()
  51. }
  52. func RegisterSeaweedS3Server(s grpc.ServiceRegistrar, srv SeaweedS3Server) {
  53. s.RegisterService(&SeaweedS3_ServiceDesc, srv)
  54. }
  55. func _SeaweedS3_Configure_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  56. in := new(S3ConfigureRequest)
  57. if err := dec(in); err != nil {
  58. return nil, err
  59. }
  60. if interceptor == nil {
  61. return srv.(SeaweedS3Server).Configure(ctx, in)
  62. }
  63. info := &grpc.UnaryServerInfo{
  64. Server: srv,
  65. FullMethod: "/messaging_pb.SeaweedS3/Configure",
  66. }
  67. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  68. return srv.(SeaweedS3Server).Configure(ctx, req.(*S3ConfigureRequest))
  69. }
  70. return interceptor(ctx, in, info, handler)
  71. }
  72. // SeaweedS3_ServiceDesc is the grpc.ServiceDesc for SeaweedS3 service.
  73. // It's only intended for direct use with grpc.RegisterService,
  74. // and not to be introspected or modified (even as a copy)
  75. var SeaweedS3_ServiceDesc = grpc.ServiceDesc{
  76. ServiceName: "messaging_pb.SeaweedS3",
  77. HandlerType: (*SeaweedS3Server)(nil),
  78. Methods: []grpc.MethodDesc{
  79. {
  80. MethodName: "Configure",
  81. Handler: _SeaweedS3_Configure_Handler,
  82. },
  83. },
  84. Streams: []grpc.StreamDesc{},
  85. Metadata: "s3.proto",
  86. }