I'm trying to complete some first step with fluent nhibernate with sql server express, to add this features in my project. But got some errors. As I'm newbie to nhibernate, couldn't solve a problem for some time. I have an entity with
Id { get; private set; }
accessors. And this entity is mapped to table with identity {1,1} column in sql server. But during creating Session factory, I get an error:
The following types may not be used as proxies:Entity: method set_Id should be 'public/protected virtual' or 'protected internal virtual'
I understand that private setter is used to encapsulate setting of this property, but why do I get this error then? PS: example on site of fluent for nhibernate is using sqllite db and everything is just fine.