I have two objects, one is in our enterprise level and another in in our service level. The service object is inheriting from the enterprise. Here is a quick example:
[DataContract]
public class EnterpriseObject{
[DataMember]
int ID{get; set;}
string InternalUse{get; set;}
}
[DataContract]
public class ServiceObject: EnterpriseBaseObject{
[DataMember]
string Address{get; set;}
}
Is it possible to only expose the ServiceObject (with inherited properties from EnterpriseObject) in the serialization? I do not want the client to see the enterprise object listed as an option? As you can see in the example the DataMember attribute is not set for the InternalUser property. Is that the only way to do it? Thanks