12345678910111213141516171819202122232425262728293031323334353637 |
- // Code generated by goctlwt. DO NOT EDIT!
- // Source: hello.proto
- package client
- import (
- "context"
- "github.com/wuntsong-org/go-zero-plus/tools/goctlwt/example/rpc/hello/pb/hello"
- "github.com/wuntsong-org/go-zero-plus/zrpc"
- "google.golang.org/grpc"
- )
- type (
- HelloReq = hello.HelloReq
- HelloResp = hello.HelloResp
- Greet interface {
- SayHello(ctx context.Context, in *HelloReq, opts ...grpc.CallOption) (*HelloResp, error)
- }
- defaultGreet struct {
- cli zrpc.Client
- }
- )
- func NewGreet(cli zrpc.Client) Greet {
- return &defaultGreet{
- cli: cli,
- }
- }
- func (m *defaultGreet) SayHello(ctx context.Context, in *HelloReq, opts ...grpc.CallOption) (*HelloResp, error) {
- client := hello.NewGreetClient(m.cli.Conn())
- return client.SayHello(ctx, in, opts...)
- }
|