Friday 27 September 2013

Undiscovered POCO class requirements

Undiscovered POCO class requirements

I have been developing an application for the last five months and just
ran into this problem.
We are using EF5 and, similar to this question, I designed the class
hierarchy to have all entity classes derived from an abstract base class
to force validation interfaces to be implemented. We are also using the
validation attributes in the entity classes.
Everything has worked fine until I started trying to use the entity
classes in WCF Services. I am getting a bunch of serialization exceptions,
and have been trying to figure out what "POCO" rule I broke in the design.
This article tells me the class (obviously...) cannot be abstract, but
since my classes are DERIVING from an abstract class, have I perhaps
broken a rule I don't know about?
Thanks, Peter

No comments:

Post a Comment