private void SetUpGenericRepositoryStub() { _genericRepository = Substitute.For<IGenericRepository>(); _summer2010 = new Web.Data.Entities.Session { SessionName = "Summer 2010", BeginDate = new DateTime(2010, 6, 1), EndDate = new DateTime(2010, 8, 30) }; _fall2010 = new Web.Data.Entities.Session { SessionName = "Fall 2010", BeginDate = new DateTime(2010, 10, 1), EndDate = new DateTime(2011, 1, 3) }; _spring2010 = new Web.Data.Entities.Session { SessionName = "Spring 2010", BeginDate = new DateTime(2010, 01, 1), EndDate = new DateTime(2010, 5, 01) }; IEnumerable<Web.Data.Entities.Session> sessionList = new List<Web.Data.Entities.Session> { _summer2010, _fall2010, _spring2010 }; _genericRepository.GetAll<Web.Data.Entities.Session>().Returns(sessionList); }
public MembershipService(IUnitOfWork unitOfWork, IGenericRepository<UserProfile> userRepository, IGenericRepository<Role> roleRepository) { this.unitOfWork = unitOfWork; this.userRepository = userRepository; this.roleRepository = roleRepository; //this.userRepository = new GenericRepository<UserProfile>(unitOfWork); }
public TaskController(IGenericRepository<Task> taskRepository, IGenericRepository<Project> projectRepository, IGenericRepository<User> userRepository, IFileStorage fileStorage) { _taskRepository = taskRepository; _projectRepository = projectRepository; _userRepository = userRepository; _fileStorage = fileStorage; }
public PhotoSaveService(IUnitOfWork uof) { photosDb = uof.Repository<Photo>(); usersDb = uof.Repository<User>(); accountsDb = uof.Repository<Account>(); }
public SecurityApplicationProcessingRule(ISecurityAuthorizationProvider securityAuthorizationProvider, IGenericRepository genericRepository, ISecurityContext securityContext, IObjectFactory objectFactory) { _securityAuthorizationProvider = securityAuthorizationProvider; _genericRepository = genericRepository; _securityContext = securityContext; _objectFactory = objectFactory; }
public ComponentController(IGenericRepository<ComponentModel> componentRepository, IGenericRepository<ComponentCategoryModel> componentCategoryRepository ) { _componentRepo = componentRepository; _componentCategoryRepo = componentCategoryRepository; }
public UsersController() { CourseDBContext context = new CourseDBContext(); users = new GenericRepository<User>(new StorageContext<User>(context)); roles = new RolesImpl(); webSecurity = new WebSecurityImpl(); }
public LoanController(IEmailService mailService, IGenericRepository<Component> componentRepo, IGenericRepository<LoanInformation> loanInformationRepo, IGenericRepository<Loaner> loanerRepo) { _componentRepo = componentRepo; _loanInformationRepo = loanInformationRepo; _loanerRepo = loanerRepo; _mailService = mailService; }
public CustomMembershipProvider() { var uof = DependencyResolver.Current.GetService<IUnitOfWork>(); usersDb = uof.Repository<User>(); accountsDb = uof.Repository<Account>(); rolesDb = uof.Repository<Role>(); }
/// <summary> /// Constructor used by the web application itself /// </summary> public ElectiveListsController() { CourseDBContext context = new CourseDBContext(); electiveLists = new GenericRepository<ElectiveList>(new StorageContext<ElectiveList>(context)); courses = new GenericRepository<Course>(new StorageContext<Course>(context)); electiveListCourses = new GenericRepository<ElectiveListCourse>(new StorageContext<ElectiveListCourse>(context)); }
public VerifyAccountTypeController() { _nhSessionFactory = NhDatabaseConfiguration.CreateSessionFactory(); _repository = new AccountTypeRepository(_nhSessionFactory); _repositoryAsset = new AssetRepository(_nhSessionFactory); _identityService = new PimsIdentityService(); }
public UnitOfWork(IGenericRepository<Recipe> recipeRepository, IGenericRepository<Region> regionRepository, IGenericRepository<Category> categoryRepository) { this.recipeRepository = recipeRepository; this.regionRepository = regionRepository; this.categoryRepository = categoryRepository; }
public StudentController(IGenericRepository repository, IMapper<Student, ProfileModel> studentToProfileModelMapper, IMapper<Student, IndexModel> studentToStudentIndexModelMapper, IMapper<NameModel, Student> studentNameToStudentMapper, IMapper<HomeAddressModel, StudentAddress> studentHomeAddressToStudentMapper, AzureStorageUploader fileUploader, IStudentRepository studentRepository, IMapper<EditableStudentBiographicalInfoModel, Student> studentBiographicalInfoToStudentMapper, IParentRepository parentRepository, IMapper<EditProfileParentModel, Parent> editProfileParentModelToParentMapper, ProgramStatusModelToProgramStatusForEditMapper programStatusModelToProgramStatusForEditMapper, EditAcademicDetailModelToStudentAcademicDetailMapper editAcademicDetailModelToStudentAcademicDetailMapper) { _repository = repository; _studentToProfileModelMapper = studentToProfileModelMapper; _studentToStudentIndexModelMapper = studentToStudentIndexModelMapper; _fileUploader = fileUploader; _studentRepository = studentRepository; _studentBiographicalInfoToStudentMapper = studentBiographicalInfoToStudentMapper; _studentNameToStudentMapper = studentNameToStudentMapper; _studentHomeAddressToStudentMapper = studentHomeAddressToStudentMapper; _parentRepository = parentRepository; _editProfileParentModelToParentMapper = editProfileParentModelToParentMapper; _programStatusModelToProgramStatusForEditMapper = programStatusModelToProgramStatusForEditMapper; _editAcademicDetailModelToStudentAcademicDetailMapper = editAcademicDetailModelToStudentAcademicDetailMapper; }
public SyncWithTokenController(IUnitOfWork uow, IGenericRepository<Rate> rateRepo, IGenericRepository<Core.DomainModel.Profile> profileRepo, IGenericRepository<Token> tokenRepo) { _uow = uow; _profileRepo = profileRepo; _tokenRepo = tokenRepo; _rateRepo = rateRepo; }
public TransactionsHandler(DbContext dbContext, ICardAccountRepository cardAcountRepo, IGenericRepository<TransactionHistory> transactionLogRepo) { this.dbContext = dbContext; this.cardAcountRepo = cardAcountRepo; this.transactionLogRepo = transactionLogRepo; this.errors = new List<string>(); }
public ProductService( IUnitOfWork unitOfWork, IGenericRepository<Product> productRepository) { UnitOfWork = unitOfWork; _productRepository = productRepository; }
public PlansController(IGenericRepository<Plan> fakePlan, IGenericRepository<PlanCourse> fakePlanCourse, IGenericRepository<Semester> fakeSem, IGenericRepository<User> fakeUser, IGenericRepository<DegreeProgram> fakeDegree, IRoles fakeRoles, IWebSecurity fakeWebSecurity) { roles = fakeRoles; webSecurity = fakeWebSecurity; messagequeue = new ObjectMessageQueue(); }
public SubmitDriveController(IUnitOfWork uow, IGenericRepository<Rate> rateRepo, IGenericRepository<DriveReport> driveReportRepo, IGenericRepository<Token> tokenRepo) { _uow = uow; _driveReportRepo = driveReportRepo; _tokenRepo = tokenRepo; _rateRepo = rateRepo; }
public Klasservice(IUOW uow, IGenericRepository<Klas> KlasRepository, IGenericRepository<LeerkrachtSchoolKlas> lskRepos, IKlasRepository repository) { this.uow = uow; this.KlasRepository = KlasRepository; this.klasrepository = repository; this.lskRepos = lskRepos; }
public LeaguesController() { //If default constructor is called, means it is "real" request //IDatabaseFactory factory = new MongoDBDatabaseFactory(); IDatabaseFactory factory = new TestDatabaseFactory(); databasePlaceholder = factory.GetLeagueRepository(); }
public DataManager( IGenericRepository<Coutry> coutries, IGenericRepository<Stone> stones, IGenericRepository<JewelPHoto> jewelPHotos, IGenericRepository<Material> materials, IGenericRepository<Cover> covers, IGenericRepository<Markup> markups, IGenericRepository<Product> products, IGenericRepository<Discount> discounts, IGenericRepository<Category> categories, IGenericRepository<Cart> carts, IGenericRepository<Order> orders, IGenericRepository<OrderDetail> orderDetails, IGenericRepository<MethodOfDelivery> methodOfDeliveries, IGenericRepository<MethodOfPayment> methodOfPayments ) { Coutries = coutries; Stones = stones; JewelPHotos = jewelPHotos; Materials = materials; Covers = covers; Markups = markups; Products = products; Discounts = discounts; Categories = categories; Carts = carts; Orders = orders; OrderDetails = orderDetails; MethodOfDeliveries = methodOfDeliveries; MethodOfPayments = methodOfPayments; }
public SupplierService( IUnitOfWork unitOfWork, IGenericRepository<Supplier> supplierRepository) { UnitOfWork = unitOfWork; _supplierRepository = supplierRepository; }
public AccountsController() { var uof = DependencyResolver.Current.GetService<IUnitOfWork>(); accountsDb = uof.Repository<Account>(); accountsSerialsDb = uof.Repository<AccountSerial>(); usersDb = uof.Repository<User>(); }
public BrowseBySupplierController(IGenericRepository<Meal> inMeal, IGenericRepository<Supplier> inSupplier, IGenericRepository<Category> inCat) { mealRepo = inMeal; supplierRepo = inSupplier; categoryRepo = inCat; }
public UnitOfWork() { context = new MainContext(); userRepo = new GenericRepository<User>(context); roleRepo = new GenericRepository<Role>(context); }
public VideoGalleryService(IUnitOfWork unitOfWork, IGenericRepository<VideoGallery> videoGalleryRepository, IGenericRepository<Project> projectRepository, IGenericRepository<Video> videoRepository) { this.unitOfWork = unitOfWork; this.videoGalleryRepository = videoGalleryRepository; this.projectRepository = projectRepository; this.videoRepository = videoRepository; }
/// <summary> /// ctor /// </summary> public GenericRepositoryTest() { _documentSessionMock = new Mock<IDocumentSession>(); _documentStoreMock = new Mock<IDocumentStore>(); _genericRepository = new GenericRepository<TestObject>(_documentStoreMock.Object); _testObjectService = new TestObjectService(); }
public UserService(IUnitOfWork unitOfWork, IGenericRepository<User> userRepository) { if (unitOfWork == null) throw new ArgumentNullException("unitOfWork"); if (userRepository == null) throw new ArgumentNullException("userRepository"); this.unitOfWork = unitOfWork; this.userRepository = userRepository; }
public AccountTypeController(IGenericRepository<AccountType> repository, IGenericRepository<Asset> repositoryAssets, IPimsIdentityService identityService, IGenericRepository<Investor> repositoryInvestor) { _repository = repository; _repositoryAssets = repositoryAssets; _identityService = identityService; _repositoryInvestor = repositoryInvestor; }
public EveOnlineService( IUnitOfWork unitOfWork, IEveOnlineConstellationRepository eveOnlineConstellationRepository, IEveOnlineTypeRepository eveOnlineTypeRepository, IEveOnlineRegionRepository eveOnlineRegionRepository, IEveOnlineSolarSystemRepository eveOnlineSolarSystemRepository, IGenericRepository<EveOnlineSkill> eveOnlineSkillRepository, IGenericRepository<EveOnlineSkillGroup> eveOnlineSkillGroupRepository, IGenericRepository<EveOnlineSkillTree> eveOnlineSkillTreeRepository, IEveOnlineRequiredSkillRepository eveOnlineRequiredSkillRepository, IGenericRepository<EveOnlineAttribute> eveOnlineAttributeRepository, IGenericRepository<UserLog> userLogRepository, IRoleRepository roleRepository) { UnitOfWork = unitOfWork; _eveOnlineConstellationRepository = eveOnlineConstellationRepository; _eveOnlineTypeRepository = eveOnlineTypeRepository; _eveOnlineRegionRepository = eveOnlineRegionRepository; _eveOnlineSolarSystemRepository = eveOnlineSolarSystemRepository; _eveOnlineSkillRepository = eveOnlineSkillRepository; _eveOnlineSkillGroupRepository = eveOnlineSkillGroupRepository; _eveOnlineSkillTreeRepository = eveOnlineSkillTreeRepository; _eveOnlineRequiredSkillRepository = eveOnlineRequiredSkillRepository; _eveOnlineAttributeRepository = eveOnlineAttributeRepository; _userLogRepository = userLogRepository; _roleRepository = roleRepository; }
public ContactRequestController(IGenericRepository <ContactRequest> contactRequestRepository) { this.contactRequestRepository = contactRequestRepository; }
public SellerService(IUnitOfWork db) { _database = db; _repos = _database.GetRepository <Seller>(); }
public TrainingsController(IGenericRepository <Trainings> genericRepository) { _genericRepository = genericRepository; }
public ShipmentRegistrationMapper(IGenericRepository <ShipmentRegistration> repo) { this.repo = repo; }
public EtiketService(IUnitOfWork uow) : base(uow) { _etiket = uow.GetRepository <Etiket>(); _haber = uow.GetRepository <Haber>(); _kategori = uow.GetRepository <Kategori>(); }
/// <summary> /// Initializes a new instance of the <see cref="RoleRepository"/> class. /// </summary> /// <param name="genericRepository">The generic repository.</param> /// <param name="mapper">The mapper.</param> public RoleRepository(IGenericRepository <Role, IRolePoco> genericRepository, IMapper mapper) { this.genericRepository = genericRepository; this.mapper = mapper; }
public CategoryService(IGenericRepository <Category> repository, IMapper mapper) : base(repository) { _mapper = mapper; }
public LocalBusinessTypesController(IGenericRepository <LocalBusinessType> repository, IGenericRepository <BusinessType> optionsRepository) : base(repository, optionsRepository) { }
public GenericService(DbContext context) { repository = new GenericRepository <T>(context); _context = context; }
public AidatGunService(UnitofWork uow) { _uow = uow; _aidatGunRepository = _uow.GetRepository <aidat_gun>(); }
public GlobalConfigsController(IGenericRepository <Core.DomainModel.GlobalConfig> repository) : base(repository) { }
public AccountController(IGenericRepository <Customer> inCutomerRepo) { customerRepo = inCutomerRepo; }
public GenericExample(IUserRepositoryGeneric userRepository, IGenericRepository <UserModel> genericRepository) { UserRepository = userRepository; GenericRepository = genericRepository; }
public TurnoService(IGenericRepository repository, ITurnoQuery query, ICalendarioTurnosQuery calendarioTurnosQuery) { _repository = repository; _query = query; _calendarioTurnosQuery = calendarioTurnosQuery; }
public ReportManager(IGenericRepository db) { _db = db; }
public FileRepository(IUnitOfWork uow) : base(uow) { this._fileGRepo = this._unitOfWork.GetDataRepository <Kpi_File>(); }
public BuyTwoGetOneHalfPriceDiscounts(IGenericRepository <SpecialOffer> specialOfferRepository) { _specialOfferRepository = specialOfferRepository; }
public MySQLDataProvider(Func <IUnitOfWork> unitOfWork, IGenericRepository <JsonReport> jsonReport) { this.JsonReports = jsonReport; this.UnitOfWork = unitOfWork; }
public GenericSyncService(IGenericRepository <TContext, TEntity> genericRepo) { _genericRepo = genericRepo; }
public ProductService(IUnitOfWork uow, IMapper mapper) { _uow = uow; _mapper = mapper; _productRepository = _uow.GetRepository <Product>(); }
public ChildDataService(IGenericRepository genericRepository, IBlobCache cache = null) : base(cache) { this._genericRepository = genericRepository; }
public MovimientoManager(IGenericRepository <Movimiento> repositorio) : base(repositorio) { }
public StatusService(IGenericRepository repo) { _repo = repo; }
public HomeController(ILogger <HomeController> logger, IGenericRepository genericRepository) { _logger = logger; _genericRepository = genericRepository; }
public AddressService(IGenericRepository <Address> addressRepoParam, IGenericRepository <User> userRepoParam) { addressRepo = addressRepoParam; userRepo = userRepoParam; }
public ConcursosController(IGenericRepository <Concurso> repository, IGenericRepository <Link> linkRepository) { _repository = repository; _linkRepository = linkRepository; }
public LanguesController(IGenericRepository <Langue> langueRepository) { _langueRepository = langueRepository; }
public LogementService(IGenericRepository <Logement> genericRepo, ILogementRepo logementRepo) { GenericRepo = genericRepo; LogementRepo = logementRepo; }
public ProductsController(IGenericRepository <Product> productRepo, IGenericRepository <ProductBrand> productBrandRepo, IGenericRepository <ProductType> proudctTypeRepo, IMapper mapper) { _mapper = mapper; _proudctTypeRepo = proudctTypeRepo; _productBrandRepo = productBrandRepo; _productRepo = productRepo; }
public ServiceRecipientController() { this.recipientRepo = new EFRecipientRepository(_db); this.addressRepo = new EFAddressRepository(_db); }