How can I share an auto-generated object data model (generated object classes) among all layers of my C # web application, only providing access to the request in the data layer? It uses a typical three-layer approach: data, business, presentation.
My data layer returns IEnumerable<T>to my business layer, but I cannot return type T to the presentation layer, because I do not want the presentation layer to know about the existence of the data layer, where my entity classes are automatically located.
It is recommended that you have a separate layer with the data model only, but I'm not sure how to separate the data model from the query functionality provided by the entity infrastructure.
source
share