I put together T4 Templates that generate sample Fluent NHibernate Mapping Classes based on metadata in a LINQ To SQL DBML File:
These aren’t production quality T4 Templates, but more of a proof of concept that I put together rather quickly to jumpstart the conversion to NHibernate from LINQ To SQL. I had to manually make some changes after running the templates to support many-to-many relationships that are not supported by LINQ To SQL, tweak lengths of certain database columns, etc. There are probably a number of limitations I am not aware of, but they worked well given the simple nature of the relational database model I was dealing with. Depending on your situation your mileage may vary
You can learn more about the T4 Templates here.
Recent Posts:
Very cool, nice work David.
I (being on the Fluent NHibernate team) am really flattered by efforts by people like yourself in making fluent nhib even better. Thanks!