packageserviceimport("context"v1"github.com/go-kratos/kratos-layout/api/helloworld/v1""github.com/go-kratos/kratos-layout/internal/biz")// GreeterService is a greeter service.typeGreeterServicestruct{v1.UnimplementedGreeterServeruc*biz.GreeterUsecase}// NewGreeterService new a greeter service.funcNewGreeterService(uc*biz.GreeterUsecase)*GreeterService{return&GreeterService{uc:uc}}// SayHello implements helloworld.GreeterServer.func(s*GreeterService)SayHello(ctxcontext.Context,in*v1.HelloRequest)(*v1.HelloReply,error){g,err:=s.uc.CreateGreeter(ctx,&biz.Greeter{Hello:in.Name})iferr!=nil{returnnil,err}return&v1.HelloReply{Message:"Hello "+g.Hello},nil}