github.com/Hyperledger-TWGC/tjfoc-gm@v1.4.0/gmtls/gmcredentials/echo/echo.pb.go (about)

     1  // Code generated by protoc-gen-go. DO NOT EDIT.
     2  // source: echo.proto
     3  
     4  /*
     5  Package echo is a generated protocol buffer package.
     6  
     7  It is generated from these files:
     8  	echo.proto
     9  
    10  It has these top-level messages:
    11  	EchoRequest
    12  	EchoResponse
    13  */
    14  package echo
    15  
    16  import proto "github.com/golang/protobuf/proto"
    17  import fmt "fmt"
    18  import math "math"
    19  
    20  import (
    21  	context "golang.org/x/net/context"
    22  	grpc "google.golang.org/grpc"
    23  )
    24  
    25  // Reference imports to suppress errors if they are not otherwise used.
    26  var _ = proto.Marshal
    27  var _ = fmt.Errorf
    28  var _ = math.Inf
    29  
    30  // This is a compile-time assertion to ensure that this generated file
    31  // is compatible with the proto package it is being compiled against.
    32  // A compilation error at this line likely means your copy of the
    33  // proto package needs to be updated.
    34  const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
    35  
    36  type EchoRequest struct {
    37  	Req string `protobuf:"bytes,1,opt,name=req" json:"req,omitempty"`
    38  }
    39  
    40  func (m *EchoRequest) Reset()                    { *m = EchoRequest{} }
    41  func (m *EchoRequest) String() string            { return proto.CompactTextString(m) }
    42  func (*EchoRequest) ProtoMessage()               {}
    43  func (*EchoRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
    44  
    45  func (m *EchoRequest) GetReq() string {
    46  	if m != nil {
    47  		return m.Req
    48  	}
    49  	return ""
    50  }
    51  
    52  type EchoResponse struct {
    53  	Result string `protobuf:"bytes,1,opt,name=result" json:"result,omitempty"`
    54  }
    55  
    56  func (m *EchoResponse) Reset()                    { *m = EchoResponse{} }
    57  func (m *EchoResponse) String() string            { return proto.CompactTextString(m) }
    58  func (*EchoResponse) ProtoMessage()               {}
    59  func (*EchoResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
    60  
    61  func (m *EchoResponse) GetResult() string {
    62  	if m != nil {
    63  		return m.Result
    64  	}
    65  	return ""
    66  }
    67  
    68  func init() {
    69  	proto.RegisterType((*EchoRequest)(nil), "echo.EchoRequest")
    70  	proto.RegisterType((*EchoResponse)(nil), "echo.EchoResponse")
    71  }
    72  
    73  // Reference imports to suppress errors if they are not otherwise used.
    74  var _ context.Context
    75  var _ grpc.ClientConn
    76  
    77  // This is a compile-time assertion to ensure that this generated file
    78  // is compatible with the grpc package it is being compiled against.
    79  const _ = grpc.SupportPackageIsVersion4
    80  
    81  // Client API for Echo service
    82  
    83  type EchoClient interface {
    84  	Echo(ctx context.Context, in *EchoRequest, opts ...grpc.CallOption) (*EchoResponse, error)
    85  }
    86  
    87  type echoClient struct {
    88  	cc *grpc.ClientConn
    89  }
    90  
    91  func NewEchoClient(cc *grpc.ClientConn) EchoClient {
    92  	return &echoClient{cc}
    93  }
    94  
    95  func (c *echoClient) Echo(ctx context.Context, in *EchoRequest, opts ...grpc.CallOption) (*EchoResponse, error) {
    96  	out := new(EchoResponse)
    97  	err := grpc.Invoke(ctx, "/echo.Echo/Echo", in, out, c.cc, opts...)
    98  	if err != nil {
    99  		return nil, err
   100  	}
   101  	return out, nil
   102  }
   103  
   104  // Server API for Echo service
   105  
   106  type EchoServer interface {
   107  	Echo(context.Context, *EchoRequest) (*EchoResponse, error)
   108  }
   109  
   110  func RegisterEchoServer(s *grpc.Server, srv EchoServer) {
   111  	s.RegisterService(&_Echo_serviceDesc, srv)
   112  }
   113  
   114  func _Echo_Echo_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
   115  	in := new(EchoRequest)
   116  	if err := dec(in); err != nil {
   117  		return nil, err
   118  	}
   119  	if interceptor == nil {
   120  		return srv.(EchoServer).Echo(ctx, in)
   121  	}
   122  	info := &grpc.UnaryServerInfo{
   123  		Server:     srv,
   124  		FullMethod: "/echo.Echo/Echo",
   125  	}
   126  	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
   127  		return srv.(EchoServer).Echo(ctx, req.(*EchoRequest))
   128  	}
   129  	return interceptor(ctx, in, info, handler)
   130  }
   131  
   132  var _Echo_serviceDesc = grpc.ServiceDesc{
   133  	ServiceName: "echo.Echo",
   134  	HandlerType: (*EchoServer)(nil),
   135  	Methods: []grpc.MethodDesc{
   136  		{
   137  			MethodName: "Echo",
   138  			Handler:    _Echo_Echo_Handler,
   139  		},
   140  	},
   141  	Streams:  []grpc.StreamDesc{},
   142  	Metadata: "echo.proto",
   143  }
   144  
   145  func init() { proto.RegisterFile("echo.proto", fileDescriptor0) }
   146  
   147  var fileDescriptor0 = []byte{
   148  	// 126 bytes of a gzipped FileDescriptorProto
   149  	0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xe2, 0x4a, 0x4d, 0xce, 0xc8,
   150  	0xd7, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x62, 0x01, 0xb1, 0x95, 0xe4, 0xb9, 0xb8, 0x5d, 0x93,
   151  	0x33, 0xf2, 0x83, 0x52, 0x0b, 0x4b, 0x53, 0x8b, 0x4b, 0x84, 0x04, 0xb8, 0x98, 0x8b, 0x52, 0x0b,
   152  	0x25, 0x18, 0x15, 0x18, 0x35, 0x38, 0x83, 0x40, 0x4c, 0x25, 0x35, 0x2e, 0x1e, 0x88, 0x82, 0xe2,
   153  	0x82, 0xfc, 0xbc, 0xe2, 0x54, 0x21, 0x31, 0x2e, 0xb6, 0xa2, 0xd4, 0xe2, 0xd2, 0x9c, 0x12, 0xa8,
   154  	0x22, 0x28, 0xcf, 0xc8, 0x9c, 0x8b, 0x05, 0xa4, 0x4e, 0x48, 0x1f, 0x4a, 0x0b, 0xea, 0x81, 0xed,
   155  	0x42, 0x32, 0x5c, 0x4a, 0x08, 0x59, 0x08, 0x62, 0x9c, 0x12, 0x43, 0x12, 0x1b, 0xd8, 0x39, 0xc6,
   156  	0x80, 0x00, 0x00, 0x00, 0xff, 0xff, 0x1b, 0x48, 0x20, 0x0f, 0x9c, 0x00, 0x00, 0x00,
   157  }