T4 Template Interception

Posted by JeffN825 on Stack Overflow See other posts from Stack Overflow or by JeffN825
Published on 2010-12-13T18:59:55Z Indexed on 2011/01/15 22:53 UTC
Read the original article Hit count: 213

I'm wondering if anyone out there knows of any T4 template based method interception systems?

We are beginning to write mobile applications (currently with MonoTouch for IOS). We have a very nice core set of DI/IoC functionality and I'd like to leverage this in development for the new platform. Since runtime code generation Reflection.Emit is not supported, I'm hoping to use T4 templates to implement the dynamic interception functionality (+ TinyIoC as a container for resolution).

We are currently using Castle Windsor (and intend to continue doing so for our SL and full .NET development), but all of the Windsor specific ties are completely encapsulated, so given a suitable T4 solution, it shouldn't be hard to implement an adapter that uses a T4 based implementation instead of Windsor.

© Stack Overflow or respective owner

Related posts about .NET

Related posts about dependency-injection