/// <summary> /// Adds a handler for a specific virtual path /// </summary> /// <param name="hostName">The host name to use for request resolution (Virtual hosts are not currently supported)</param> /// <param name="virtualPath">The virtual path that will be routed to this handler ( e.g "/virdir1"</param> /// <param name="handler">The handler that will handle requests on this path</param> /// <param name="force">If set to true, the handler will replace any other handlers defined at the path, if false, an exception will /// be thrown if any handlers are already defined at the path</param> public void AddHandlerContext( string hostName, string virtualPath, IAdkHttpHandler handler, bool force ) { AdkHttpHandlerListeningContext contextHandler = new AdkHttpHandlerListeningContext( handler ); this.AddHandlerContext( hostName, virtualPath, contextHandler, force ); }
/// <summary> /// Adds a handler for a specific virtual path /// </summary> /// <param name="hostName">The host name to use for request resolution (Virtual hosts are not currently supported)</param> /// <param name="virtualPath">The virtual path that will be routed to this handler ( e.g "/virdir1"</param> /// <param name="handler">The handler that will handle requests on this path</param> /// <param name="force">If set to true, the handler will replace any other handlers defined at the path, if false, an exception will /// be thrown if any handlers are already defined at the path</param> public void AddHandlerContext(string hostName, string virtualPath, IAdkHttpHandler handler, bool force) { AdkHttpHandlerListeningContext contextHandler = new AdkHttpHandlerListeningContext(handler); this.AddHandlerContext(hostName, virtualPath, contextHandler, force); }