/// <summary> /// Constructor for servicefactory /// </summary> public ServiceFactory() { bookCopyRepo = repoFactory.GetBookCopyrepository(); bookRepo = repoFactory.GetBookRepository(); authorRepo = repoFactory.GetAuthorRepository(); loanRepo = repoFactory.GetLoanRepository(); memberRepo = repoFactory.GetMemberRepository(); }
/// <summary> /// Constructor for searchservice /// </summary> /// <param name="repo">loanrepo</param> public SearchService(LoanRepository repo) { loanRepo = repo; }
public LoanService(RepositoryFactory repoFactory) { _loanRepository = repoFactory.GetLoanRepository(); }