I’ve been making a bit of time to explore CodeSmith 3.0, particularly in using shared codebehind classes. Codebehind existed in 2.x, but I didn’t discover it until I started investigating 3.0. In the sample CSLA templates, for instance, a single codebehind class serves the several CSLA templates, sharing methods, properties and logic.
I was feeling stuck the other morning when I decided to drop the day’s “work” objectives and play with CodeSmith 3.0. By the end of the workday I felt unstuck and moving forward again. While some the issues producing that stuck feeling were not yet resolved, I knew that in making a conscious effort to employ CodeSmith along the way that execution would take care of itself.