echo

package
v0.0.0-...-92745da Latest Latest
Warning

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

Go to latest
Published: Jul 14, 2021 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var EchoArgs_Req_DEFAULT *pbapi.Request
View Source
var EchoResult_Success_DEFAULT *pbapi.Response

Functions

func NewInvoker

func NewInvoker(handler pbapi.Echo, opts ...server.Option) server.Invoker

NewInvoker creates a server.Invoker with the given handler and options.

func NewServer

func NewServer(handler pbapi.Echo, opts ...server.Option) server.Server

NewServer creates a server.Server with the given handler and options.

Types

type Client

type Client interface {
	Echo(ctx context.Context, Req *pbapi.Request, callOptions ...callopt.Option) (r *pbapi.Response, err error)
}

Client is designed to provide IDL-compatible methods with call-option parameter for kitex framework.

func MustNewClient

func MustNewClient(psm string, opts ...client.Option) Client

MustNewClient creates a client for the service defined in IDL. It panics if any error occurs.

func NewClient

func NewClient(psm string, opts ...client.Option) (Client, error)

NewClient creates a client for the service defined in IDL.

type EchoArgs

type EchoArgs struct {
	Req *pbapi.Request
}

func (*EchoArgs) GetReq

func (p *EchoArgs) GetReq() *pbapi.Request

func (*EchoArgs) IsSetReq

func (p *EchoArgs) IsSetReq() bool

func (*EchoArgs) Marshal

func (p *EchoArgs) Marshal(out []byte) ([]byte, error)

func (*EchoArgs) Unmarshal

func (p *EchoArgs) Unmarshal(in []byte) error

type EchoResult

type EchoResult struct {
	Success *pbapi.Response
}

func (*EchoResult) GetSuccess

func (p *EchoResult) GetSuccess() *pbapi.Response

func (*EchoResult) IsSetSuccess

func (p *EchoResult) IsSetSuccess() bool

func (*EchoResult) Marshal

func (p *EchoResult) Marshal(out []byte) ([]byte, error)

func (*EchoResult) SetSuccess

func (p *EchoResult) SetSuccess(x interface{})

func (*EchoResult) Unmarshal

func (p *EchoResult) Unmarshal(in []byte) error

Jump to

Keyboard shortcuts

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