I've seen both formats in different examples, tutorials, blogs, etc, but for the life of me, I cannot find an explanation for the difference. What is the difference between
ICriteria crit = session.CreateCriteria(typeof(Cat));
and
ICriteria crit = session.CreateCriteria<Cat>();
When do I use one and when do I use the other?
An example of a tutorial using session.CreateCriteria(typeof(Cat)) can be found at http://nhibernate.info/doc/nh/en/index.html#quickstart
An example of a tutorial using session.CreateCriteria() can be found at http://ayende.com/blog/4023/nhibernate-queries-examples (table Blog instead of Cat)
Thanks so much!!