Fluent NHibernate and computed properties
问题 I'm using Fluent NHibernate, and auto-mapping the classes. I have a computed property in a class along the lines of public virtual DateTime? LastActionTimeStamp { get { return Actions.Count == 0 ? null : Actions.OrderByDescending( a => a.TimeStamp).ElementAt(0).TimeStamp; } } This wasn't mapped with the rest of the properties, so I couldn't use it in an ICriteria restriction. I added an empty setter (as I read somewhere that doing so would include it in the mapping, which it does), but now I