RSS 2.0 Feed
RSS 2.0

Atom 1.0 Feed
Atom 1.0

  Implementing the Visitor Pattern using Reflection 

I just read an awesome article from Brad Wilson (posted to his DotNetDevs site) about implementing the Visitor pattern using Reflection. Man, that was some truly great stuff. A must read. I've been working on something similar in C# 2.0, but going the route of using generics instead. The Reflection route is very interesting but as Brad mentioned, you'd have to use some sort of caching scheme to offset the performance penalties.

Great stuff.


Leave a comment below.


  1. SteveC-A9 6/14/2006 8:04 AM
    I would love to see this updated (possibly using Generics) for 2.0 of the Framework....
  2. 11/22/2009 8:00 AM
    rsfwtwpl - Google Search
  3. Bruce Wallace 4/29/2010 9:36 AM
    The link you reference has gone away, but you can see this technique in an article I had published back in 2000. The example code is in Java but the technique is the same.
Comments have been closed on this topic.



Also see my CRM Developer blog