Usually when a project is created in c # that can be the MVC, ASP.NET, etc , the right thing is to create different layers, are generally layer Data, Presentation , Entities,etc.
1) I Seen in some projects with entity framework that it´s only a single layer of Entities (obj. from data base), all operations on the database are performed on these objects
2) But in another projects I seen two layers, one Domain and other Entities.The domain layer contains the same objects as the layer Entities, then they are other layer called Mapper that is responsible for match obj from Entities and obj from Domain. Here all operations on the database are performed on Domain objects
My question is what are the advantages and disadvantages of these two ways of structuring a project?
Aucun commentaire:
Enregistrer un commentaire