public void Setup() { _comics = new TestData().Comics(); _comicRepository = MockRepository.MockComicRepository(_comics); _unitOfWork = new Mock <IUnitOfWork>().Object; _comicService = new ComicService(_comicRepository, _unitOfWork); }
public IndexModel(IComicService comicService, IGalleryService galleryService, IOptions <ApplicationSettings> options) { _comicService = comicService; _galleryService = galleryService; _appOptions = options; }
public ReadController(IComicService comicService, IGalleryService galleryService, IOptions <ApplicationSettings> options) { _comicService = comicService; _galleryService = galleryService; _appOptions = options; }
public AdminController(IComicService comicService, IOrderService orderService) { Guard.WhenArgument(comicService, "comicService").IsNull().Throw(); Guard.WhenArgument(orderService, "orderService").IsNull().Throw(); this.comicService = comicService; this.orderService = orderService; }
public ComicViewModel(IComicService comicService) { this.comicService = comicService; FirstComicCommand = new Command(OnFirstComic); NextComicCommand = new Command(OnNextComic); PreviousComicCommand = new Command(OnPreviousComic); LastComicCommand = new Command(OnLastComic); RandomComicCommand = new Command(OnRandomComic); }
public ScanService( IOptions <ApplicationSettings> options, IHubContext <ScanHub> hubContext, IGalleryService galleryService, IComicService comicService ) { _options = options; _hubContext = hubContext; _galleryService = galleryService; _comicService = comicService; }
public AddComicViewModel(IInteractionService message, IComicService comicManager) { Interaction = message; ComicManager = comicManager; DownloadCommand = new AsyncRelayCommand(Download, (o) => !Downloading && ComicValid(ComicNumber)); PropertyChanged += (o, e) => { if (e.PropertyName == "Downloading" || e.PropertyName == "ComicNumber") DownloadCommand.RaiseCanExecuteChanged(); }; }
public MainWindowViewModel(IInteractionService message, IComicService comicManager, IPropertiesService properties) { Interaction = message; ComicManager = comicManager; Properties = properties; AddComicCommand = new RelayCommand(AddComic, (o) => !Downloading); AddRandomComicCommand = new AsyncRelayCommand(AddRandomComic); AddCurrentComicCommand = new AsyncRelayCommand(AddCurrentComic, (o) => !Downloading); RemoveComicCommand = new RelayCommand(RemoveComic, () => SelectedComic != null); ClearComicsCommand = new RelayCommand(() => Comics.Clear()); LoadedCommand = new AsyncRelayCommand(Loaded); ClosedCommand = new AsyncRelayCommand(Closed); AboutCommand = new RelayCommand(About); ConfigurationCommand = new RelayCommand(Configuration); CopyLinkCommand = new RelayCommand( (o) => Interaction.SetClipboardText(string.Format(o as string, SelectedComic.Number)), (o) => SelectedComic != null && o is string); DeleteCacheCommand = new RelayCommand( () => SelectedComic?.DeleteCache(), () => SelectedComic != null); OpenLinkCommand = new RelayCommand( (o) => Interaction.StartProcess(string.Format(o as string, SelectedComic.Number)), (o) => SelectedComic != null && o is string); PropertyChanged += (o, e) => { if (e.PropertyName == "SelectedComic") { RemoveComicCommand.RaiseCanExecuteChanged(); DeleteCacheCommand.RaiseCanExecuteChanged(); OpenLinkCommand.RaiseCanExecuteChanged(); CopyLinkCommand.RaiseCanExecuteChanged(); } if (e.PropertyName == "Downloading") { AddComicCommand.RaiseCanExecuteChanged(); AddCurrentComicCommand.RaiseCanExecuteChanged(); AddRandomComicCommand.RaiseCanExecuteChanged(); } }; }
public ConfigurationViewModel(IInteractionService message, IComicService comicManager, IPropertiesService properties) { Interaction = message; ComicManager = comicManager; Properties = properties; LoadFromProperties(); OkCommand = new RelayCommand(Ok, (o) => !Busy); CancelCommand = new RelayCommand(Cancel, (o) => !Busy); ResetCommand = new RelayCommand(Reset); ClearCacheCommand = new AsyncRelayCommand(ClearCache, (o) => !Busy); PropertyChanged += (o, e) => { if (e.PropertyName == "Busy") { OkCommand.RaiseCanExecuteChanged(); CancelCommand.RaiseCanExecuteChanged(); ClearCacheCommand.RaiseCanExecuteChanged(); } }; }
public HomeController(ILogger <HomeController> logger, IComicService comicService) { _logger = logger; _comicService = comicService; }
public UserComicController(IUserComicService userComicService, IComicService comicService, IUserSeriesService userSeries) { _userComicService = userComicService; _comicService = comicService; _userSeries = userSeries; }
public ComicController(IComicService service) : base(service) { _service = service; }
public ComicModel(IComicService comicService, IGalleryService galleryService) { _comicService = comicService; _galleryService = galleryService; }
public ComicController(ILogger <ComicController> logger, IMemoryCache cache, IComicService comicService) { _logger = logger; _cache = cache; _comicService = comicService; }
public ComicController(IComicService comicService) { _comicService = comicService; }
public ShoppingCartController(IComicService comicService) { Guard.WhenArgument(comicService, "comicService").IsNull().Throw(); this.comicService = comicService; }
public ContactRepository(ISessionWrapper session, IComicService comicService) { _session = session; _comicService = comicService; }
private void InjectionInitialize( ICharacterService characterService, IComicService comicService, ICreatorService creatorService, ISeriesService seriesService, IEventService eventService, ILoadingManager loadingManager, IScreenManager screenManager, IEventManager eventManager, IResultProcessor resultProcessor, IPlanetSystemSpawner planetSystemSpawner, SearchViewModel searchViewModel) { this.characterService = characterService; this.comicService = comicService; this.creatorService = creatorService; this.seriesService = seriesService; this.eventService = eventService; this.loadingManager = loadingManager; this.screenManager = screenManager; this.eventManager = eventManager; this.resultProcessor = resultProcessor; this.planetSystemSpawner = planetSystemSpawner; this.searchViewModel = searchViewModel; this.eventManager.GetEvent<LoadingEvent>().AddListener(this.OnLoading); }
private void InjectionInitialize( IComicService comicService) { this.comicService = comicService; }
public ComicsController(BookContext context, IComicService service) { _context = context; _service = service; }
public ComicController(IComicService comicService, IUserComicService userComicService) { _comicService = comicService; _userComicService = userComicService; }