7 /// Summary description for AsyncModule.
9 public class AsyncModule : IHttpModule
13 public void Init(HttpApplication app) {
14 app.AddOnPreRequestHandlerExecuteAsync(
15 new BeginEventHandler(this.BeginPreHandlerExecute),
16 new EndEventHandler(this.EndPreHandlerExecute));
21 IAsyncResult BeginPreHandlerExecute(Object source, EventArgs e, AsyncCallback cb, Object extraData) {
22 ((HttpApplication) source).Context.Response.Write("AsyncModule.BeginPreHandlerExecute()<br>\n");
24 AsynchOperation asynch = new AsynchOperation(cb, _app.Context, extraData);
25 asynch.StartAsyncWork();
29 void EndPreHandlerExecute(IAsyncResult ar) {
30 ((AsynchOperation) ar).Context.Response.Write("AsyncModule.EndPreHandlerExecute()<br>\n");
33 public void Dispose() {