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 that (or before that, whatever), you can google for
ISubDependencyResolver in order to see how to click the resolver in.
for instance, I found this:
http://kozmic.pl/archive/2009/04/09/convention-based-dependency-injection-with-castle-microkernelwindsor.aspx,
which could be of help.


good luck.




On Sun, May 17, 2009 at 9:37 AM, Tiendq <tie...@gmail.com> wrote:

>
> 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 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 a
> > > HttpBaseContext in this case? I'm using ASP.NET MVC so I prefer
> > > HttpBaseContext so I can mock it in unit test.
> >
> > > Thanks,
> >
>


-- 
Ken Egozi.
http://www.kenegozi.com/blog
http://www.delver.com
http://www.musicglue.com
http://www.castleproject.org
http://www.gotfriends.co.il

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Castle Project Users" group.
To post to this group, send email to castle-project-users@googlegroups.com
To unsubscribe from this group, send email to 
castle-project-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/castle-project-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to