I am currently in the evaluation of ReSharper 8.2.1 C# Edition. I have a project in my solution containing entity framework entities classes.
Since the properties mapped in the classes are virtual, I am getting the warning that class has virtual members with no inheritors on almost all my entities. Actually, the entity framework itself creates proxy classes inheriting from my entities and overrides my virtual members.
The other warning I get on almost all properties is that they can be made protected (or the setter can be made protected). However, entity framework ignores protected members by default unless I use fluid API.
Currently I workaround this by adding ReSharper disable once ClassWithVirtualMembersNeverInherited.Global comment in code for every class, and UsedImplicitly attribute on all properties. But this is an ugly solution in my opionion. Is there a better way to mark the class as a entity framework entity to silence these warnings?
Also if I have a class whose members are set using MVC model binder, and never directly in code, is there a way to tell reshaper to not warn me that setter should be protected?
Thanks a lot in advance.