Esempio n. 1
0
 private void SetUpMocksAndServices()
 {
     _aircraftRepositoryMock = Substitute.For <IAircraftRepository <Airplane> >();
     _unitOfWorkMock         = Substitute.For <IUnitOfWork>();
     _airportRepositoryMock  = Substitute.For <IAirportRepository>();
     _aircraftService        = new AircraftService <Airplane>(_aircraftRepositoryMock, _unitOfWorkMock, _airportRepositoryMock);
 }
Esempio n. 2
0
 public AircraftsController(
     IUnitOfWork unitOfWork,
     ILotRepository lotRepository,
     IInventoryRepository inventoryRepository,
     IAircraftRepository aircraftRepository,
     IAircraftRegistrationRepository aircraftRegistrationRepository,
     IAircraftRegMarkRepository aircraftRegMarkRepository,
     ISModeCodeRepository sModeCodeRepository,
     IFileRepository fileRepository,
     IApplicationRepository applicationRepository,
     ICaseTypeRepository caseTypeRepository,
     ILotEventDispatcher lotEventDispatcher,
     UserContext userContext)
 {
     this.unitOfWork = unitOfWork;
     this.lotRepository = lotRepository;
     this.inventoryRepository = inventoryRepository;
     this.aircraftRepository = aircraftRepository;
     this.aircraftRegistrationRepository = aircraftRegistrationRepository;
     this.aircraftRegMarkRepository = aircraftRegMarkRepository;
     this.sModeCodeRepository = sModeCodeRepository;
     this.fileRepository = fileRepository;
     this.applicationRepository = applicationRepository;
     this.caseTypeRepository = caseTypeRepository;
     this.lotEventDispatcher = lotEventDispatcher;
     this.userContext = userContext;
 }
Esempio n. 3
0
 public GvaNomController(
     IUnitOfWork unitOfWork,
     ILotRepository lotRepository,
     IApplicationRepository applicationRepository,
     IPersonRepository personRepository,
     IAircraftRepository aircraftRepository,
     IAirportRepository airportRepository,
     IEquipmentRepository equipmentRepository,
     IOrganizationRepository organizationRepository,
     ICaseTypeRepository caseTypeRepository,
     INomRepository nomRepository,
     IStageRepository stageRepository,
     IExaminationSystemRepository examinationSystemRepository,
     IAircraftRegistrationRepository aircraftRegistrationRepository,
     IEnumerable<IDataGenerator> dataGenerators)
 {
     this.unitOfWork = unitOfWork;
     this.lotRepository = lotRepository;
     this.applicationRepository = applicationRepository;
     this.personRepository = personRepository;
     this.aircraftRepository = aircraftRepository;
     this.airportRepository = airportRepository;
     this.equipmentRepository = equipmentRepository;
     this.organizationRepository = organizationRepository;
     this.caseTypeRepository = caseTypeRepository;
     this.nomRepository = nomRepository;
     this.stageRepository = stageRepository;
     this.examinationSystemRepository = examinationSystemRepository;
     this.aircraftRegistrationRepository = aircraftRegistrationRepository;
     this.dataGenerators = dataGenerators;
 }
Esempio n. 4
0
 public ApplicationsController(
     IUnitOfWork unitOfWork,
     ILotRepository lotRepository,
     IPersonRepository personRepository,
     IOrganizationRepository organizationRepository,
     IAircraftRepository aircraftRepository,
     IAirportRepository airportRepository,
     IEquipmentRepository equipmentRepository,
     IDocRepository docRepository,
     IApplicationRepository applicationRepository,
     INomRepository nomRepository,
     IFileRepository fileRepository,
     IExaminationSystemRepository examinationSystemRepository,
     ILotEventDispatcher lotEventDispatcher,
     UserContext userContext)
 {
     this.unitOfWork = unitOfWork;
     this.lotRepository = lotRepository;
     this.personRepository = personRepository;
     this.organizationRepository = organizationRepository;
     this.aircraftRepository = aircraftRepository;
     this.airportRepository = airportRepository;
     this.equipmentRepository = equipmentRepository;
     this.docRepository = docRepository;
     this.applicationRepository = applicationRepository;
     this.nomRepository = nomRepository;
     this.examinationSystemRepository = examinationSystemRepository;
     this.fileRepository = fileRepository;
     this.lotEventDispatcher = lotEventDispatcher;
     this.userContext = userContext;
 }
Esempio n. 5
0
 public SnRegAppService(ISnRegQuery snRegQuery, ISnRegRepository snRegRepository,
     IAircraftRepository aircraftRepository, IPnRegRepository pnRegRepository)
 {
     _snRegQuery = snRegQuery;
     _snRegRepository = snRegRepository;
     _aircraftRepository = aircraftRepository;
     _pnRegRepository = pnRegRepository;
 }
        public AirCraftController(ILoggerFactory loggerFactory,
                                  IAircraftRepository aircraftRepository)
        {
            _logger = loggerFactory.CreateLogger(GetType());
            _logger.LogDebug("Construct AirCraftController");

            _aircraftRepository = aircraftRepository;
        }
Esempio n. 7
0
 /// <summary>
 ///
 /// </summary>
 /// <param name="flightRepository"></param>
 /// <param name="aircraftRepository"></param>
 /// <param name="airportRepository"></param>
 public FlightController(IFlightRepository flightRepository,
                         IAircraftRepository aircraftRepository,
                         IAirportRepository airportRepository)
 {
     _flightRepository   = flightRepository;
     _aircraftRepository = aircraftRepository;
     _airportRepository  = airportRepository;
 }
Esempio n. 8
0
 public SnRemInstRecordAppService(ISnRemInstRecordQuery snRemInstRecordQuery,
     ISnRemInstRecordRepository snRemInstRecordRepository,
     IAircraftRepository aircraftRepository)
 {
     _snRemInstRecordQuery = snRemInstRecordQuery;
     _snRemInstRecordRepository = snRemInstRecordRepository;
     _aircraftRepository = aircraftRepository;
 }
        public AircraftsControllerTests()
        {
            this.aircrafts = new List <Aircraft>();
            aircrafts.Add(new Aircraft("AAA", "Aircraft AAA", 1, 0));
            aircrafts.Add(new Aircraft("BBB", "Aircraft BBB", 10, 1));

            this.aircraftRepository = new global::Flight.Api.Tests.Repositories.AircraftRepository(aircrafts);
        }
Esempio n. 10
0
 public FlightRepositoryFacade(
     IFlightRepository flightRepository,
     IAirportRepository airportRespository,
     IAircraftRepository aircraftRepository)
 {
     _flightRepository   = flightRepository;
     _airportRespository = airportRespository;
     _aircraftRepository = aircraftRepository;
 }
 public AircraftRegistrationRepository(
     IUnitOfWork unitOfWork,
     ILotRepository lotRepository,
     IAircraftRepository aircraftRepository)
 {
     this.unitOfWork = unitOfWork;
     this.lotRepository = lotRepository;
     this.aircraftRepository = aircraftRepository;
 }
Esempio n. 12
0
 public PlanAircraftAppService(IPlanAircraftQuery planAircraftQuery,
     IAircraftRepository aircraftRepository,
     IAircraftTypeRepository aircraftTypeRepository,
     IAirlinesRepository airlinesRepository,
     IPlanAircraftRepository planAircraftRepository)
 {
     _planAircraftQuery = planAircraftQuery;
     _aircraftRepository = aircraftRepository;
     _aircraftTypeRepository = aircraftTypeRepository;
     _airlinesRepository = airlinesRepository;
     _planAircraftRepository = planAircraftRepository;
 }
Esempio n. 13
0
 public FlightController(IFlightRepository flightrepos, IAirportRepository airportRepo,
                         IAirlineCompanyRepository airlineRepo, IAircraftRepository aircraftRepo)
 {
     _flightrepos  = flightrepos;
     _airportRepo  = airportRepo;
     _airlineRepo  = airlineRepo;
     _aircraftRepo = aircraftRepo;
     airports      = _airportRepo.GetAllAirport();
     flights       = _flightrepos.GetAllFlight();
     airlines      = _airlineRepo.GetAllAirlines();
     aircrafts     = _aircraftRepo.GetAllAircraft();
 }
Esempio n. 14
0
        public OpenFlightsDataCache(HttpClient httpClient, IMemoryCache memoryCache)
        {
            _memoryCache = memoryCache;
            _httpClient  = httpClient;
            _disposeMode = DisposeModeEnum.DoNothing;

            IDataAccessFactory factory = new DataAccessFactory(_httpClient, _memoryCache);

            _airportRepository  = factory.CreateAirportRepository();
            _aircraftRepository = factory.CreateAircraftRepository();
            _routeRepository    = factory.CreateRouteRepository();
            _airlineRepository  = factory.CreateAirlineRepository();
        }
Esempio n. 15
0
 public AircraftAppService(IAircraftQuery aircraftQuery, IActionCategoryRepository actionCategoryRepository,
     IAircraftRepository aircraftRepository, IAircraftTypeRepository aircraftTypeRepository,
     IAirlinesRepository airlinesRepository, ISupplierRepository supplierRepository,
     IAircraftConfigurationRepository aircraftConfigurationRepository)
 {
     _aircraftQuery = aircraftQuery;
     _actionCategoryRepository = actionCategoryRepository;
     _aircraftRepository = aircraftRepository;
     _aircraftTypeRepository = aircraftTypeRepository;
     _airlinesRepository = airlinesRepository;
     _supplierRepository = supplierRepository;
     _aircraftConfigurationRepository = aircraftConfigurationRepository;
 }
Esempio n. 16
0
        public HomeController(
            ILoggerFactory loggerFactory,
            IAircraftRepository aircraftRepository,
            IAirportRepository airportRepository,
            IFlightRepository flightRepository)
        {
            _logger = loggerFactory.CreateLogger(GetType());
            _logger.LogDebug("Construct HomeController");

            _aircraftRepository = aircraftRepository;
            _airportRepository  = airportRepository;
            _flightRepository   = flightRepository;
        }
Esempio n. 17
0
 public AircraftType(IAircraftRepository aircraftRepository)
 {
     Field(x => x.Id);
     Field(x => x.Name, true);
     Field <StringGraphType>("lastServiceDate",
                             resolve: context => context.Source.LastServiceDate.ToShortDateString());
     Field <StringGraphType>("lastUsage", resolve: context => context.Source.LastUsage.ToShortDataString());
     Field <ListGraphType <FlightType> >("flights",
                                         arguments: new QueryArguments(new QueryArgument <IntGraphType> {
         Name = "id"
     }),
                                         resolve: context => aircraftRepository.Get(context.Source.Id), description: "This Aircrafts Flights");
 }
 public CustomerInformationModel()
 {
     _aircraftRepo = SimpleIoc.Default.GetInstance<IAircraftRepository>();
     _upgradeRepo = SimpleIoc.Default.GetInstance<IUpgradeRepository>();
     _customerRepo = SimpleIoc.Default.GetInstance<ICustomerRepository>();
     _configurationRepo= SimpleIoc.Default.GetInstance<ICustomerConfigurationRespository>();
     _configurationFileManager = new ConfigurationFileManager();
     if (! SimpleIoc.Default.IsRegistered<IConfiguration>())
     {
         var configuration = new Configuration("id", new List<IUpgradeItem>(), new List<IAircraft>(),
                                               System.DateTime.Now.ToString(), ConfigurationState.IN_PROGRESS, null, _customerRepo.GetCustomerById("emirates"));
         SimpleIoc.Default.Register<IConfiguration>(() => configuration);
     }
 }
Esempio n. 19
0
 public SnHistoryAppService(ISnHistoryQuery snHistoryQuery,
     ISnHistoryRepository snHistoryRepository,
     IAircraftRepository aircraftRepository,
     IPnRegRepository pnRegRepository,
     ISnRegRepository snRegRepository,
     ISnRemInstRecordRepository snRemInstRecordRepository)
 {
     _aircraftRepository = aircraftRepository;
     _pnRegRepository = pnRegRepository;
     _snHistoryQuery = snHistoryQuery;
     _snHistoryRepository = snHistoryRepository;
     _snRegRepository = snRegRepository;
     _snRemInstRecordRepository = snRemInstRecordRepository;
 }
Esempio n. 20
0
 public PlanHistoryAppService(IPlanHistoryQuery planHistoryQuery,
     IActionCategoryRepository actionCategoryRepository,
     IAircraftTypeRepository aircraftTypeRepository,
     IAircraftRepository aircraftRepository,
     IAirlinesRepository airlinesRepository,
     IAnnualRepository annualRepository,
     IPlanHistoryRepository planHistoryRepository)
 {
     _planHistoryQuery = planHistoryQuery;
     _actionCategoryRepository = actionCategoryRepository;
     _aircraftRepository = aircraftRepository;
     _aircraftTypeRepository = aircraftTypeRepository;
     _airlinesRepository = airlinesRepository;
     _annualRepository = annualRepository;
     _planHistoryRepository = planHistoryRepository;
 }
Esempio n. 21
0
        public GrapherMutation(IAircraftRepository aircraftRepository)
        {
            Name = "CreateAircraftMutation";

            Field <AircraftType>(
                "createAircraft",
                arguments: new QueryArguments(
                    new QueryArgument <NonNullGraphType <AircraftInputType> > {
                Name = "aircraft"
            }
                    ),
                resolve: context =>
            {
                var aircraft = context.GetArgument <Aircraft>("aircraft");
                return(aircraftRepository.Add(aircraft));
            });
        }
Esempio n. 22
0
 public AircraftQuery(IAircraftRepository aircraftRepository)
 {
     _aircraftRepository = aircraftRepository;
 }
Esempio n. 23
0
 public GetAllAircraftHandler(IAircraftRepository aircraftRepository)
 {
     _aircraftRepository = aircraftRepository;
 }
Esempio n. 24
0
 public Application(IPositionRepository positionRepository, IAircraftRepository aircraftRepository, IConflictRepository conflictRepository)
 {
     _positionRepository = positionRepository;
     _aircraftRepository = aircraftRepository;
     _conflictRepository = conflictRepository;
 }
Esempio n. 25
0
 public AirplaneCrudService(IAircraftRepository <Airplane> aircraftRepository,
                            IUnitOfWork unitOfWork,
                            IAirportRepository airportRepository)
     : base(aircraftRepository, unitOfWork, airportRepository)
 {
 }
 public AverageUtilizationRepository(IAircraftRepository aircraftRepository, IComponentRepository componentRepository)
 {
     _aircraftRepository  = aircraftRepository;
     _componentRepository = componentRepository;
 }
 public AircraftManagerService(IClubRepository clubRepository, IAircraftRepository aircraftRepository, IAsyncRepository <AircraftPrice> asyncRepositoryAircraftPrice)
 {
     this.clubRepository               = clubRepository;
     this.aircraftRepository           = aircraftRepository;
     this.asyncRepositoryAircraftPrice = asyncRepositoryAircraftPrice;
 }
Esempio n. 28
0
 public AircraftService(ILogger <AircraftService> logger, IAircraftRepository aircraftRepository)
 {
     _logger             = logger;
     _aircraftRepository = aircraftRepository;
 }
Esempio n. 29
0
 public HomeController(IAircraftRepository aircraftRepository, DatabaseContext db)
 {
     _aircraftRepository = aircraftRepository;
     _db = db;
 }
Esempio n. 30
0
 public FlightController(IFlightRepository flightRepository, IAircraftRepository aircraftRepository)
 {
     this.flightRepository   = flightRepository;
     this.aircraftRepository = aircraftRepository;
 }
Esempio n. 31
0
        //private readonly AppDbContext _context;


        public HomeController(IAircraftRepository ACRepository)
        {
            _ACRepository = ACRepository;
        }
Esempio n. 32
0
 //TODO: Figure out why not executing quickly
 public HandlePosition(IPositionRepository positionRepository, IAircraftRepository aircraftRepository, IConflictRepository conflictRepository)
 {
     _positionRepository = positionRepository;
     _aircraftRepository = aircraftRepository;
     _conflictRepository = conflictRepository;
 }
Esempio n. 33
0
 public AircraftService(IAircraftRepository repository, IMapper mapper)
 {
     _aircraftRepository = repository;
     _mapper             = mapper;
 }
Esempio n. 34
0
 public WorkPackageRepository(IAircraftRepository aircraftRepository, IComponentRepository componentRepository, DatabaseContext db)
 {
     _aircraftRepository  = aircraftRepository;
     _componentRepository = componentRepository;
     _db = db;
 }
Esempio n. 35
0
 public AircraftsController(IAircraftRepository aircraftRepository)
 {
     _aircraftRepository = aircraftRepository;
 }
Esempio n. 36
0
 public AircraftController(IAircraftRepository aircraftRepository)
 {
     this.aircraftRepository = aircraftRepository;
 }
 public ConfigurationModel()
 {
     _upgradeRepository = SimpleIoc.Default.GetInstance<IUpgradeRepository>();
     _aircraftRepository = SimpleIoc.Default.GetInstance<IAircraftRepository>();
 }
 public AircraftWorker(ILogger <AircraftWorker> logger, DatabaseContext db, IAircraftRepository aircraftRepository)
 {
     _logger             = logger;
     _db                 = db;
     _aircraftRepository = aircraftRepository;
 }
 public TransferableConverter()
 {
     _upgradeRepository = SimpleIoc.Default.GetInstance<IUpgradeRepository>();
     _aircraftRepository = SimpleIoc.Default.GetInstance<IAircraftRepository>();
 }
Esempio n. 40
0
 public FleetTransferService(IAirlinesRepository airlinesRepository,
     IAircraftRepository aircraftRepository,
     IApprovalDocRepository approvalDocRepository,
     IDocumentRepository documentRepository,
     IMailAddressRepository mailAddressRepository,
     IPlanRepository planRepository,
     IPlanAircraftRepository planAircraftRepository,
     IPlanHistoryRepository planHistoryRepository,
     IRequestRepository requestRepository)
 {
     _airlinesRepository = airlinesRepository;
     _aircraftRepository = aircraftRepository;
     _approvalDocRepository = approvalDocRepository;
     _documentRepository = documentRepository;
     _mailAddressRepository = mailAddressRepository;
     _planRepository = planRepository;
     _planAircraftRepository = planAircraftRepository;
     _planHistoryRepository = planHistoryRepository;
     _requestRepository = requestRepository;
 }
Esempio n. 41
0
 public GliderCrudService(IAircraftRepository <Glider> aircraftRepository,
                          IUnitOfWork unitOfWork,
                          IAirportRepository airportRepository)
     : base(aircraftRepository, unitOfWork, airportRepository)
 {
 }
Esempio n. 42
0
 public AircraftAppService(IAircraftQuery aircraftQuery, IAircraftRepository aircraftRepository)
 {
     _aircraftQuery = aircraftQuery;
     _aircraftRepository = aircraftRepository;
 }
Esempio n. 43
0
 public AircraftAddedToFleetHandler(IAircraftRepository aircraftRepository)
 {
     _aircraftRepository = aircraftRepository;
 }
Esempio n. 44
0
 public AircraftController(IAircraftRepository aircraftRepository, IComponentRepository componentRepository, DatabaseContext db)
 {
     _aircraftRepository  = aircraftRepository;
     _componentRepository = componentRepository;
     _db = db;
 }
Esempio n. 45
0
 public AircraftService(IAircraftRepository <T> aircraftRepository, IUnitOfWork unitOfWork, IAirportRepository airportRepository)
 {
     _aircraftRepository = aircraftRepository;
     _unitOfWork         = unitOfWork;
     _airportRepository  = airportRepository;
 }
 public FlightRepository(IAircraftRepository aircraftRepository, IAirportRepository airportRepository)
 {
     this.xmlHelper          = new XmlRepositoryHelper <PersistenceFlight>(@"SampleData\Flights.xml");
     this.aircraftRepository = aircraftRepository;
     this.airportRepository  = airportRepository;
 }
 public AircraftListViewComponent(IAircraftRepository aircraftRepository)
 {
     _aircraftRepository = aircraftRepository;
 }