api

package
v1.0.8 Latest Latest
Warning

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

Go to latest
Published: Feb 2, 2022 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InputToPBInput

func InputToPBInput(in *stub.Input) *mockpb.Input

func OutputToPBOutput

func OutputToPBOutput(out *stub.Output) *mockpb.Output

func PBInputToInput

func PBInputToInput(pbin *mockpb.Input) *stub.Input

func PBOutputToOutput

func PBOutputToOutput(pbout *mockpb.Output) *stub.Output

func PBStubToStub

func PBStubToStub(pbstub *mockpb.Stub) *stub.Stub

func PBStubsToStubs

func PBStubsToStubs(pbstubs []*mockpb.Stub) ([]*stub.Stub, error)

func StubToPBStub

func StubToPBStub(stub *stub.Stub) *mockpb.Stub

func StubsToPBStubs

func StubsToPBStubs(stubs []*stub.Stub) []*mockpb.Stub

Types

type Server

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

func NewServer

func NewServer(mgr StubManager) *Server

func (*Server) AddStubs

func (*Server) DeleteStubs

func (*Server) FindStubs

type StubManager

type StubManager interface {
	FindStubs(service, method string, in map[string]interface{}) []*stub.Stub
	AddStub(stub *stub.Stub) error
	DeleteStub(service, method string) error
}

Jump to

Keyboard shortcuts

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