v.io: v.io/x/ref/lib/dispatcher Index | Files

package dispatcher

import "v.io/x/ref/lib/dispatcher"


Package Files


type DispatcherWrapper Uses

type DispatcherWrapper struct {
    // contains filtered or unexported fields

DispatcherWrapper is used when a dispatcher can't be constructed at server creation time. The most common use for this is when the dispatcher needs to know some information about the server to be constructed. For example it is sometimes helpful to know the server's endpoints. In such cases you can construct a DispatcherWrapper which will simply block all lookups until the real dispatcher is set with SetDispatcher. nolint:golint // API change required.

func NewDispatcherWrapper Uses

func NewDispatcherWrapper() *DispatcherWrapper

NewDispatcherWrapper creates a new DispatcherWrapper.

func (*DispatcherWrapper) Lookup Uses

func (w *DispatcherWrapper) Lookup(ctx *context.T, suffix string) (interface{}, security.Authorizer, error)

Lookup will wait until SetDispatcher is called and then simply forward requests to the underlying dispatcher.

func (*DispatcherWrapper) SetDispatcher Uses

func (w *DispatcherWrapper) SetDispatcher(d rpc.Dispatcher)

SetDispatcher sets the underlying dispatcher and allows Lookups to proceed.

Package dispatcher imports 3 packages (graph) and is imported by 3 packages. Updated 2020-06-09. Refresh now. Tools for package owners.