cosmos-sdk/codec/testdata/test_service.go

20 lines
481 B
Go
Raw Normal View History

package testdata
import (
"context"
"fmt"
)
type TestServiceImpl struct{}
func (e TestServiceImpl) Echo(_ context.Context, req *EchoRequest) (*EchoResponse, error) {
return &EchoResponse{Message: req.Message}, nil
}
func (e TestServiceImpl) SayHello(_ context.Context, request *SayHelloRequest) (*SayHelloResponse, error) {
greeting := fmt.Sprintf("Hello %s!", request.Name)
return &SayHelloResponse{Greeting: greeting}, nil
}
var _ TestServiceServer = TestServiceImpl{}