public AddJourneyWithLiftsViewModel(ICommandDispatcher commandDispatcher, IQueryDispatcher queryDispatcher, IEventBus eventBus, IIdFactory idFactory) { _commandDispatcher = commandDispatcher; _eventBus = eventBus; _idFactory = idFactory; AddJourneyCommand = new DelegateCommand(AddJourney); LoadSettingCommand = new DelegateCommand <string>(LoadSetting); SaveSettingCommand = new DelegateCommand <string>(SaveSetting); RemoveSettingCommand = new DelegateCommand <string>(RemoveSetting); DateOfOccurrence = DateTime.Now.Date; Notification = new NotifierViewModel(); Lifts = new ObservableCollection <LiftViewModel>(); try { PassengerNames = queryDispatcher.Dispatch(new GetPeopleNamesQuery()).Select(personName => personName.Name).ToList(); } catch { PassengerNames = new List <string>(); } try { JourneyTemplates = new ObservableCollection <JourneyTemplate>(queryDispatcher.Dispatch(new GetJourneyTemplatesQuery())); } catch { JourneyTemplates = new ObservableCollection <JourneyTemplate>(); } }
public CustomerService( ICustomerRepository customerRepository, IIdFactory idFactory) { this.customerRepository = customerRepository; this.idFactory = idFactory; }
public CustomerService( ICustomerRepository customerRepository, IIdFactory idFactory) { _customerRepository = customerRepository; _idFactory = idFactory; }
private void Awake() { Log.Verbose("Game Awake", "Unity"); // TODO: Random Start _eventAggregator = new EventAggregator(); _first = PhotonNetwork.isMasterClient ? PlayerType.Player : PlayerType.Opponent; _idFactory = new CardIdFactory(); _players = new Dictionary <PlayerType, Player>(); foreach (var type in Extension.GetValues <PlayerType>()) { _players.Add(type, new Player(this, type)); } _battle = null; _deck = new List <string>(Deck.Get().GetList()); _deck.Shuffle(); Subscribe(this); GuiMediator.OnButtonClick += OnButtonClick; GuiMediator.SetButtonClickable(ButtonType.NextPhaseButton, PhotonNetwork.isMasterClient); GuiMediator.OnCardDragToZone += OnCardDragToZone; GuiMediator.OnCardDragToCard += OnCardDragToCard; QuitButton.onClick.AddListener(() => { PhotonNetwork.LeaveRoom(); }); End = false; }
/// <summary> /// Adds custom ID functionality to the given graph, /// supporting either custom vertex IDs, custom edge IDs, or both. /// </summary> /// <param name="baseGraph">the base graph which does not necessarily support custom IDs</param> /// <param name="supportVertexIds">whether to support custom vertex IDs</param> /// <param name="supportEdgeIds">whether to support custom edge IDs</param> public IdGraph(IKeyIndexableGraph baseGraph, bool supportVertexIds, bool supportEdgeIds) { if (baseGraph == null) { throw new ArgumentNullException(nameof(baseGraph)); } if (!(supportVertexIds || supportEdgeIds)) { throw new ArgumentException("Edge or Vertex Ids support must be on"); } _baseGraph = baseGraph; _features = _baseGraph.Features.CopyFeatures(); _features.IsWrapper = true; _features.IgnoresSuppliedIds = false; _supportVertexIds = supportVertexIds; _supportEdgeIds = supportEdgeIds; CreateIndices(); _vertexIdFactory = new DefaultIdFactory(); _edgeIdFactory = new DefaultIdFactory(); }
public Bootstrapper( IEventBus eventBus, ICommandDispatcher commandDispatcher, ICommandHandlerRegistry commandHandlerRegistry, IQueryDispatcher queryDispatcher, IQueryHandlerRegistry queryHandlerRegistry, IIdFactory idFactory) { _eventBus = eventBus; _commandDispatcher = commandDispatcher; _commandHandlerRegistry = commandHandlerRegistry; _queryDispatcher = queryDispatcher; _queryHandlerRegistry = queryHandlerRegistry; _idFactory = idFactory; }
public CustomerService(ICustomerRepository repository, IEmailBuilder emailBuilder, IIdFactory idFactory, IMailingAddressFactory mailingAddressFactory, INameBuilder nameBuilder, ICustomerStatusFactory statusFactory, IWorkstationSettings workstationSettings) { _repositry = repository; _emailBuilder = emailBuilder; _idFactory = idFactory; _mailingAddressFactory = mailingAddressFactory; _nameBuilder = nameBuilder; _statusFactory = statusFactory; _workstationSettings = workstationSettings; // установка обработчика события _repositry.Notify += (o, e) => _mailingAddressFactory.CreatenewMessage(e.CustomerName); }
public MainPanel( ICommandDispatcher commandDispatcher, IQueryDispatcher queryDispatcher, IEventBus eventBus, IIdFactory idFactory) { InitializeComponent(); AddJourney.DataContext = new AddJourneyWithLiftsViewModel(commandDispatcher, queryDispatcher, eventBus, idFactory); var journeyCalendarsViewModel = new JourneyCalendarsViewModel(queryDispatcher, eventBus); journeyCalendarsViewModel.Refresh(); JourneyCalendars.DataContext = journeyCalendarsViewModel; var calculatePassengerLiftsCostInPeriod = new CalculatePassengerLiftsCostInPeriodViewModel(queryDispatcher); calculatePassengerLiftsCostInPeriod.Refresh(); CalculatePassengerLiftsCostInPeriod.DataContext = calculatePassengerLiftsCostInPeriod; }
public CustomerService(ICustomerRepository repo, IIdFactory idFactory) { this.repo = repo; this.idFactory = idFactory; }
public CustomerService(ICustomerRepository repository, IIdFactory idFactory) { _repositry = repository; _idFactory = idFactory; }
protected RepositoryBase(ICollection <TEntity> collection, IIdFactory <TId> idFactory) { _collection = collection; _idFactory = idFactory; }
public ClienteService(IEmailBuilder emailBuilder, IClienteRepository clienteRepository, IIdFactory idFactory) { _emailBuilder = emailBuilder; _clienteRepository = clienteRepository; _idFactory = idFactory; }
protected SchoolMember(IIdFactory idFactory, DateTime dateStarted, DateTime dateOfBirth) : base(dateOfBirth, idFactory) { DateStarted = dateStarted; }
protected Person(DateTime dateOfBirth, IIdFactory idFactory) { Id = idFactory.CreateId(); DateOfBirth = dateOfBirth; }