What is the use case for Access.BackingField in Fluent NHibernate?

The documentation for Access.BackingField()indicates that this is:

Sets the access policy for using the auto property support field.

I understand that auto-properties are compiled using the support fields, but if the property is by definition a vanilla getter / setter, what advantage is gained by going to the support field directly or using setter (i.e. using the default values โ€‹โ€‹of FNH).

The only thing I can think of is that it would be possible to break the display if someone later added logic to the setter.

What am I missing?

+3
source share
1 answer

, , .

, - private.

+3

Source: https://habr.com/ru/post/1764052/


All Articles