Hi we are evaluating the new mapping by code features, and we does not
succeeding with creating a default access strategy for Id, we are
unfortunately using
VB.NET in this project so the example code will be
in
VB.NET.
AddHandler _mapper.BeforeMapClass, Sub(modelInspector As
IModelInspector, type As Type, classCustomizer As
IClassAttributesMapper)
classCustomizer.Lazy(False)
classCustomizer.Id(Sub(idMapper As IIdMapper)
idMapper.Access(Accessor.Field)
idMapper.Generator(Generators.GuidComb)
End Sub)
End Sub
It seems like the access strategy is ignored
(NHibernate.PropertyNotFoundException: Could not find a setter for
property 'Id' in class).
We are also trying to figure out how to choose camelcase-underscore
strategy
Any ideas that would help us solve our problems?