Return derived complex type

Topics: ASP.NET Web API
Jun 10, 2014 at 4:26 PM
Hi,

I use web api 2.2-rc to build odata v4 service.
I'm trying to model entity type with property of complex type. Complex types are hierarchy of base abstract class and several concrete classes with extra properties defined. On entity type I have property of base class type, but each entity instance has concrete complex type instance.
In the model metadata I see both base abstract class and concrete classes as unrelated complex types (all properties of base class are duplicated in derived classes and there is no BaseType attribute as described here: http://docs.oasis-open.org/odata/odata/v4.0/os/part3-csdl/odata-v4.0-os-part3-csdl.html#_Toc372793944).
As a result, service returns only those properties of my concrete complex type that are defined in base class.
Is complex type inheritance supported or going to be supported? Are there any way to workaround the problem without modelling complex type as entity type?

Thank you,
Anton