linq to sql - DataContext, Repositories and Unit of Work -
i have 2 repositories 2 different entities , each 1 has own private linq-to-sql datacontext.
in addition, have service class must return result these 2 repositories.
question 1 - should have common datacontext both repositories? (i guess instantiating datacontext in service class , injecting 2 repositories.)
question 2 - unit of work for? many help.
this tutorial answered questions:
Comments
Post a Comment