Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DispatcherWrapper ¶
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.
func NewDispatcherWrapper ¶
func NewDispatcherWrapper() *DispatcherWrapper
NewDispatcherWrapper creates a new DispatcherWrapper.
func (*DispatcherWrapper) Lookup ¶
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 ¶
func (w *DispatcherWrapper) SetDispatcher(d rpc.Dispatcher)
SetDispatcher sets the underlying dispatcher and allows Lookups to proceed.