Example #1
0
        static void Main(string[] args)
        {
            ProxySubject p = new ProxySubject();

            p.Request();
            Console.Read();
        }
Example #2
0
        static void Main(string[] args)
        {
            ISubject subject = new ProxySubject();

            subject.Request();

            Console.ReadKey();
        }
Example #3
0
        // This method gets called by the runtime. Use this method to configure the HTTP request pipeline.
        public void Configure(IApplicationBuilder app, IHostingEnvironment env)
        {
            if (env.IsDevelopment())
            {
                app.UseDeveloperExceptionPage();
            }

            app.Run(async(context) =>
            {
                ProxySubject proxySubject = new ProxySubject();
                string msg = proxySubject.Request();
                await context.Response.WriteAsync(msg);
            });
        }