Skip to main content

Posts

Showing posts with the label How to send data at Business Logic layer by repository pattern

How to send data at Business Logic layer by repository pattern

Core--> interfaces, entities, helpers, constants etc Data-->responsible for fetching data from DB. mostly returns Data Table Data Sets--> if m using LINQ, this would be the Data Context Service--> Converts Data Table etc into Entities . Application --> Knows how to deal with entities . show them manipulate them send them back and forth .  insert data using Service layer . If you  find this pattern more flexible .. you could write multiple Data layers that could fetch data from more than one kind of DB and use what you want. If you want to write Data layer that targets more than one kind of DB types (Oracle, Sql, MySql) with little code change then you can use the provider pattern.