Reputation: 983
I am developing one application in MVC4 with sybase as database. I am not using Enterprise library for database activity and not using any ORM tools like Entity Framework.
I want to implement Repository and Unit of work patern in this application for models. But on internet all application sample i found uses entity framework.
Please help me to achieve repository patern without entity framework.
Upvotes: 0
Views: 752
Reputation: 16348
Repository pattern is unrelated to ORM or the db you're using. You simply define an interface that works with your business objects (save/get) and implement it in DAL.
The Repository implementation will just use whatever you have to access the db (ado.net, a micro orm, full ORM), really it's just a class working with the db saving and restoring business objects. Nothing special, nothing magic.
Upvotes: 1