private UnitOfWork() { context = new CarsCatalogContext(); Cars = new CarRepository(context); Brands = new BrandRepository(context); BodyTypes = new BodyTypeRepository(context); Gearboxes = new GearboxRepository(context); WheelDrives = new WheelDriveRepository(context); }
public BrandRepository(CarsCatalogContext db) { this.db = db; }
public GearboxRepository(CarsCatalogContext db) { this.db = db; }
public WheelDriveRepository(CarsCatalogContext db) { this.db = db; }
public BodyTypeRepository(CarsCatalogContext db) { this.db = db; }