Thanks for your answer Jason!

I am almost newbie and I need more details. like how to configure the
configuration file (web.config) with castle ...

Hope somebody can help!

Regards
Sheri

On 21 Jan, 15:21, Jason Meckley <[email protected]> wrote:
> the 2 frameworks solve unique problems. they can be used together, but
> how that is done is really up to you. the common approach is to
> register the configuration and session factory as singletons in the
> container. then resolve the session from the factory by implementing
> ISubDependencyResolver. to resolve the same session for a given scope
> use the ISessionFactory.GetCurrentSession() method.
> defining the session and transaction boundaries is up to you. for web
> applications most use a Session per Request and implement a
> Transaction Filter.
>
> You can also use IoC with NH by implementing your own BytecodeProvider
> and ReflectionOptimizer. this isn't required, but can be helpful if
> dependency injection is required.
>
> I believe there is a Nhibernate Facility as part of the Castle source
> code which handles most/all of the first paragraph above. Because I
> use the trunk of both NH and Castle I have found it's easier to simply
> roll my own facility for each project rather than manage all the
> project dependencies each time I build from the trunk.
>
> On Jan 21, 7:34 am, Sheri <[email protected]> wrote:
>
>
>
> > Hello!
>
> > Does anyone know any god link/documentation to using Castle (Kernel/
> > Facilities/Windsor) in NHibernate 2.1.
>
> > Thanks in advance
> > /Sheri
-- 
You received this message because you are subscribed to the Google Groups 
"nhusers" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/nhusers?hl=en.


Reply via email to