public SecurityController(IParkingBusiness securityParking, IDistributedCache cache)
 {
     this.securityParking = securityParking;
     this.cache           = cache;
     this.cacheKey        = "parkingLot";
     this.options         = new DistributedCacheEntryOptions().SetSlidingExpiration(TimeSpan.FromHours(3.0));
 }
Example #2
0
 public PolicemanController(IParkingBusiness policeParking, IDistributedCache cache)
 {
     this.policeParking = policeParking;
     this.cache         = cache;
     this.cacheKey      = "parkingLot";
     this.options       = new DistributedCacheEntryOptions().SetSlidingExpiration(TimeSpan.FromHours(3.0));
 }
        public ParkingLotTest()
        {
            var context = new ParkingContext(dbContextOptions);

            userRepository = new UserRepository(context);
            _userBusiness  = new UserBussiness(userRepository);

            parkingLotRepository = new ParkingRepository(context);
            _parkingLotBusiness  = new ParkingBusiness(parkingLotRepository);


            IConfigurationBuilder _configuration = new ConfigurationBuilder();

            _configuration.AddJsonFile("appsettings.json");
            configuration = _configuration.Build();

            parkingLotController   = new ParkingLotController(_parkingLotBusiness);
            registrationController = new RegistrationController(_userBusiness, configuration);
        }
 public ParkingController(ILogger <ParkingController> logger, IParkingBusiness parkingHandler)
 {
     _logger         = logger;
     _parkingHandler = parkingHandler;
 }
Example #5
0
 public OwnerController(IParkingBusiness parking)
 {
     this.parking = parking;
 }
Example #6
0
 public DriverController(IParkingBusiness driverParking)
 {
     this.driverParking = driverParking;
 }
Example #7
0
 public ParkingLotController(IParkingBusiness _parkingBussiness)
 {
     parkingBussiness = _parkingBussiness;
 }