Re: How to inject HttpBaseContext

2009-05-17 Thread Tiendq
Could you provide me a sample code? Thanks, On May 13, 11:55 am, Ayende Rahien aye...@ayende.com wrote: You write a ISubDependencyResolver On Wed, May 13, 2009 at 5:47 AM, Tiendq tie...@gmail.com wrote: You know in many case we will need access to HttpContext, HttpRequest... objects from

Re: How to inject HttpBaseContext

2009-05-17 Thread Ken Egozi
I'd say: first you fire up VS, create a project, reference MicroKernel and Windsor, then you write that: public class MySubDependencyResolver : ISubDependencyResolver { } Then you click on the Implement interface and see what you need to implement. It could be a good starting point. after

Re: How to inject HttpBaseContext

2009-05-17 Thread Mauricio Scheffer
I register it like this: var container = new WindsorContainer(); container.AddFacilityFactorySupportFacility(); container.Register(Component.ForHttpContextBase() .UsingFactoryMethod(() = new HttpContextWrapper (HttpContext.Current)) .LifeStyle.Transient); On May 13, 1:47 am, Tiendq

How to inject HttpBaseContext

2009-05-12 Thread Tiendq
You know in many case we will need access to HttpContext, HttpRequest... objects from other layers (other components), not just in web presentation layer. I don't want these code are coupled with these above object by using, for example, HttpContext.Current.Request.propertyname. How can I inject