github.com/RobustRoundRobin/quorum@v20.10.0+incompatible/plugin/helloworld/gateway.go (about) 1 package helloworld 2 3 import ( 4 "context" 5 6 "github.com/jpmorganchase/quorum-hello-world-plugin-sdk-go/proto" 7 ) 8 9 type PluginGateway struct { 10 client proto.PluginGreetingClient 11 } 12 13 func (p *PluginGateway) Greeting(ctx context.Context, msg string) (string, error) { 14 resp, err := p.client.Greeting(ctx, &proto.PluginHelloWorld_Request{ 15 Msg: msg, 16 }) 17 if err != nil { 18 return "", err 19 } 20 return resp.Msg, nil 21 }