Пример #1
0
        //Use this constructor if a handler is created manually.
        //Otherwise, use DelegatingHandler.InnerHandler public property to set the next handler.
        public PhotinoHttpHandler(PhotinoBlazorApp app, HttpMessageHandler innerHandler)
        {
            this.app = app;

            //the last (inner) handler in the pipeline should be a "real" handler.
            //To make a HTTP request, create a HttpClientHandler instance.
            InnerHandler = innerHandler ?? new HttpClientHandler();
        }
Пример #2
0
 //use this constructor if a handler is registered in DI to inject dependencies
 public PhotinoHttpHandler(PhotinoBlazorApp app) : this(app, null)
 {
 }