client

package
v0.0.0-...-5a969d9 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 7, 2023 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BuildDivideFunc

func BuildDivideFunc(grpccli calcpb.CalcClient, cliopts ...grpc.CallOption) goagrpc.RemoteFunc

BuildDivideFunc builds the remote method to invoke for "calc" service "divide" endpoint.

func BuildDividePayload

func BuildDividePayload(calcDivideMessage string) (*calc.DividePayload, error)

BuildDividePayload builds the payload for the calc divide endpoint from CLI flags.

func DecodeDivideResponse

func DecodeDivideResponse(ctx context.Context, v any, hdr, trlr metadata.MD) (any, error)

DecodeDivideResponse decodes responses from the calc divide endpoint.

func EncodeDivideRequest

func EncodeDivideRequest(ctx context.Context, v any, md *metadata.MD) (any, error)

EncodeDivideRequest encodes requests sent to calc divide endpoint.

func NewDivideDivByZeroError

func NewDivideDivByZeroError(message *calcpb.DivideDivByZeroError) *calc.DivByZero

NewDivideDivByZeroError builds the error type of the "divide" endpoint of the "calc" service from the gRPC error response type.

func NewDivideResult

func NewDivideResult(message *calcpb.DivideResponse) *calc.DivideResult

NewDivideResult builds the result type of the "divide" endpoint of the "calc" service from the gRPC response type.

func NewProtoDivideRequest

func NewProtoDivideRequest(payload *calc.DividePayload) *calcpb.DivideRequest

NewProtoDivideRequest builds the gRPC request type from the payload of the "divide" endpoint of the "calc" service.

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

Client lists the service endpoint gRPC clients.

func NewClient

func NewClient(cc *grpc.ClientConn, opts ...grpc.CallOption) *Client

NewClient instantiates gRPC client for all the calc service servers.

func (*Client) Divide

func (c *Client) Divide() goa.Endpoint

Divide calls the "Divide" function in calcpb.CalcClient interface.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL