inputselect

package
v0.0.0-...-fb4a7ab Latest Latest
Warning

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

Go to latest
Published: Aug 2, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WithInputSelectApiClientFactory

func WithInputSelectApiClientFactory(f func(name string) (traits.InputSelectApiClient, error)) router.Option

WithInputSelectApiClientFactory instructs the router to create a new client the first time Get is called for that name.

func WithInputSelectInfoClientFactory

func WithInputSelectInfoClientFactory(f func(name string) (traits.InputSelectInfoClient, error)) router.Option

WithInputSelectInfoClientFactory instructs the router to create a new client the first time Get is called for that name.

func WrapApi

WrapApi adapts a traits.InputSelectApiServer and presents it as a traits.InputSelectApiClient

func WrapInfo

WrapInfo adapts a traits.InputSelectInfoServer and presents it as a traits.InputSelectInfoClient

Types

type ApiRouter

ApiRouter is a traits.InputSelectApiServer that allows routing named requests to specific traits.InputSelectApiClient

func NewApiRouter

func NewApiRouter(opts ...router.Option) *ApiRouter

func (*ApiRouter) Add

func (r *ApiRouter) Add(name string, client any) any

Add extends Router.Add to panic if client is not of type traits.InputSelectApiClient.

func (*ApiRouter) AddInputSelectApiClient

func (r *ApiRouter) AddInputSelectApiClient(name string, client traits.InputSelectApiClient) traits.InputSelectApiClient

func (*ApiRouter) GetInput

func (r *ApiRouter) GetInput(ctx context.Context, request *traits.GetInputRequest) (*traits.Input, error)

func (*ApiRouter) GetInputSelectApiClient

func (r *ApiRouter) GetInputSelectApiClient(name string) (traits.InputSelectApiClient, error)

func (*ApiRouter) HoldsType

func (r *ApiRouter) HoldsType(client any) bool

func (*ApiRouter) PullInput

func (*ApiRouter) Register

func (r *ApiRouter) Register(server *grpc.Server)

func (*ApiRouter) RemoveInputSelectApiClient

func (r *ApiRouter) RemoveInputSelectApiClient(name string) traits.InputSelectApiClient

func (*ApiRouter) UpdateInput

func (r *ApiRouter) UpdateInput(ctx context.Context, request *traits.UpdateInputRequest) (*traits.Input, error)

type InfoRouter

InfoRouter is a traits.InputSelectInfoServer that allows routing named requests to specific traits.InputSelectInfoClient

func NewInfoRouter

func NewInfoRouter(opts ...router.Option) *InfoRouter

func (*InfoRouter) Add

func (r *InfoRouter) Add(name string, client any) any

Add extends Router.Add to panic if client is not of type traits.InputSelectInfoClient.

func (*InfoRouter) AddInputSelectInfoClient

func (r *InfoRouter) AddInputSelectInfoClient(name string, client traits.InputSelectInfoClient) traits.InputSelectInfoClient

func (*InfoRouter) DescribeInput

func (r *InfoRouter) DescribeInput(ctx context.Context, request *traits.DescribeInputRequest) (*traits.InputSupport, error)

func (*InfoRouter) GetInputSelectInfoClient

func (r *InfoRouter) GetInputSelectInfoClient(name string) (traits.InputSelectInfoClient, error)

func (*InfoRouter) HoldsType

func (r *InfoRouter) HoldsType(client any) bool

func (*InfoRouter) Register

func (r *InfoRouter) Register(server *grpc.Server)

func (*InfoRouter) RemoveInputSelectInfoClient

func (r *InfoRouter) RemoveInputSelectInfoClient(name string) traits.InputSelectInfoClient

Jump to

Keyboard shortcuts

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