func (mux *EventMux) Handle(path string, handler Handler) {
	if path == "" {
		panic("jqeventrouter: empty path")
	}
	if handler == nil {
		panic("jqeventrouter: nil handler")
	}
	if parsed, err := url.ParseRequestURI(path); err != nil {
		panic(fmt.Sprintf("jqeventrouter: Invalid path '%s': %s", path, err))
	} else if parsed.Path != path {
		panic(fmt.Sprintf("jqeventrouter: Invalid path '%s'. Did you mean '%s'?", path, parsed.Path))
	}
	if _, ok := mux.paths[path]; ok {
		panic("jqeventrouter: multiple registrations for " + path)
	}

	mux.paths[path] = &muxEntry{
		h:    handler,
		path: path,
	}
}
// Handle registers the handler for the given path. If a handler already
// exists for path, or the path is not valid in a URL, Handle panics.
Handle registers the handler for the given path. If a handler already
exists for path, or the path is not valid in a URL, Handle panics.
// Handle registers the handler for the given path . If a handler already // exists for path or the path is not valid in a URL Handle panics .
func (mux *EventMux) Handle(path string, handler Handler) {
	if path == "" {
		panic("jqeventrouter: empty path")
	}
	if handler == nil {
		panic("jqeventrouter: nil handler")
	}
	if parsed, err := url.ParseRequestURI(path); err != nil {
		panic(fmt.Sprintf("jqeventrouter: Invalid path '%s': %s", path, err))
	} else if parsed.Path != path {
		panic(fmt.Sprintf("jqeventrouter: Invalid path '%s'. Did you mean '%s'?", path, parsed.Path))
	}
	if _, ok := mux.paths[path]; ok {
		panic("jqeventrouter: multiple registrations for " + path)
	}
	mux.paths[path] = &muxEntry{
		h:    handler,
		path: path,
	}
}
func ( mux * EventMux ) Handle ( path string , handler Handler ) { if path == " " { panic ( " " ) } if handler == nil { panic ( " " ) } if parsed , err := url . ParseRequestURI ( path ) ; err != nil { panic ( fmt . Sprintf ( " " , path , err ) ) } else if parsed . Path != path { panic ( fmt . Sprintf ( " " , path , parsed . Path ) ) } if _ , ok := mux . paths [ path ] ; ok { panic ( " " + path ) } mux . paths [ path ] = & muxEntry { h : handler , path : path , } }
Handle registers the handler for the given path.
Handle registers the handler for the given path .