Subsonic Vs NHibernate

后端 未结 15 2287
醉梦人生
醉梦人生 2020-11-29 17:44

What is the concensus on when to use one of these tools adversed to the other? I find Subsonic very useful in terms of getting things done quickly, but on large projects it

15条回答
  •  一生所求
    2020-11-29 18:24

    Again slightly off-topic, but I'll second Castle ActiveRecord - rather than using the database as your model (Subsonic approach) or spending hours in XML spaghetti (NHibernate approach) you simply place attributes on your model classes.

    You can even get ActiveRecord to generate the database schema for you.

    We've used this approach on quite a few projects now and the benefits are as follows:

    • Easy upgrade path to NHibernate if required in the future
    • Support for simple inheritance models - eg. Car -> Vehicle
    • The schema it generates is most likely how you would have created it anyway, so you can spend more time building the app rather than worrying about keeping your model/db in sync.

提交回复
热议问题