Documentation ¶
Index ¶
- func DecodeSayHelloRequest(ctx context.Context, v interface{}, md metadata.MD) (interface{}, error)
- func EncodeSayHelloResponse(ctx context.Context, v interface{}, hdr, trlr *metadata.MD) (interface{}, error)
- func NewProtoSayHelloResponse(result string) *hellopb.SayHelloResponse
- func NewSayHelloHandler(endpoint goa.Endpoint, h goagrpc.UnaryHandler) goagrpc.UnaryHandler
- func NewSayHelloPayload(message *hellopb.SayHelloRequest) *hello.SayHelloPayload
- type ErrorNamer
- type Server
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DecodeSayHelloRequest ¶
DecodeSayHelloRequest decodes requests sent to "hello" service "say-hello" endpoint.
func EncodeSayHelloResponse ¶
func EncodeSayHelloResponse(ctx context.Context, v interface{}, hdr, trlr *metadata.MD) (interface{}, error)
EncodeSayHelloResponse encodes responses from the "hello" service "say-hello" endpoint.
func NewProtoSayHelloResponse ¶
func NewProtoSayHelloResponse(result string) *hellopb.SayHelloResponse
NewProtoSayHelloResponse builds the gRPC response type from the result of the "say-hello" endpoint of the "hello" service.
func NewSayHelloHandler ¶
func NewSayHelloHandler(endpoint goa.Endpoint, h goagrpc.UnaryHandler) goagrpc.UnaryHandler
NewSayHelloHandler creates a gRPC handler which serves the "hello" service "say-hello" endpoint.
func NewSayHelloPayload ¶
func NewSayHelloPayload(message *hellopb.SayHelloRequest) *hello.SayHelloPayload
NewSayHelloPayload builds the payload of the "say-hello" endpoint of the "hello" service from the gRPC request type.
Types ¶
type ErrorNamer ¶
type ErrorNamer interface {
ErrorName() string
}
ErrorNamer is an interface implemented by generated error structs that exposes the name of the error as defined in the expr.
type Server ¶
type Server struct { SayHelloH goagrpc.UnaryHandler hellopb.UnimplementedHelloServer }
Server implements the hellopb.HelloServer interface.
func New ¶
func New(e *hello.Endpoints, uh goagrpc.UnaryHandler) *Server
New instantiates the server struct with the hello service endpoints.
func (*Server) SayHello ¶
func (s *Server) SayHello(ctx context.Context, message *hellopb.SayHelloRequest) (*hellopb.SayHelloResponse, error)
SayHello implements the "SayHello" method in hellopb.HelloServer interface.