public FilesController(IFileSystemService fileSystemService, IUnitOfWorkFactory unitOfWorkFactory, ILogService logService, ICacheWrapper cacheWrapper) { _fileSystemService = fileSystemService; _unitOfWorkFactory = unitOfWorkFactory; _logService = logService; _cacheWrapper = cacheWrapper; }
public static void Initialize(ILogService logger) { if (logger == null) throw new ArgumentNullException(); _logger = logger; }
public AudioRenderingService(IAudioStationSession audioStationSession) { // todo : inject ? _logService = IoC.Container.Get<ILogService>(); _logService.Trace("AudioRenderingService .ctor"); if (audioStationSession == null) { throw new ArgumentNullException("audioStationSession"); } _audioStationSession = audioStationSession; //_mediaElement = (MediaElement)Application.Current.Resources["MediaElement"]; BufferPlayableHeuristicPredicate = (track, bytesLoaded) => bytesLoaded >= track.Bitrate|| bytesLoaded == track.Size; //_mediaElement.MediaFailed += MediaFailed; // TODO : Add error handling // TODO : Add position handling BackgroundAudioPlayer.Instance.Position // _mediaElement.SetBinding(MediaElement.PositionProperty, new Binding { Source = this, Mode = BindingMode.TwoWay, Path = new PropertyPath(PositionPropertyName) }); // todo : handle state changes // _mediaElement.CurrentStateChanged += OnCurrentStateChanged; //_mediaElement.MediaOpened += MediaOpened; // todo : handle end of track //_mediaElement.MediaEnded += PlayingMediaEnded; }
/// <summary> /// Appends the specified log service to a root log service (the current instance). /// </summary> /// <param name="logService">The log service.</param> /// <param name="additionalData">The optional additional data.</param> /// <returns> /// An implementation of <see cref="ILogLevelThresholdSelector"/> allowing to set a maximum log level to trace. /// </returns> public ILogLevelThresholdSelector AppendLogService(ILogService logService, IDictionary<string, object> additionalData = null) { if (logService == null) throw new ArgumentNullException("logService"); if (RootLog4NetService == null) return null; return RootLog4NetService.AppendLogService(logService, additionalData); }
public WorkerService(ITradingDao tradingDao, ITradeDao tradeDao, ILogService logService, IQuoteService quoteService) { _tradingDao = tradingDao; _tradeDao = tradeDao; _logService = logService; _quoteService = quoteService; }
public void SetUp() { _loggingService = A.Fake<ILogService>(); _tagService = A.Fake<ITagService>(); _facebookService = A.Fake<IFacebookService>(); _controller = new ChartController(_facebookService, _loggingService, _tagService); }
public WizardPlugin(ILogService logger) : base(logger) { //we must have the highest merit to force display above all else DefaultMerit = (int)MeritLevel.Max; DefaultAssetGroup = WizardAssetGroup; }
public BlogMLPlugin(ILogService logger) : base(logger) { DefaultMerit = (int)MeritLevel.Default; CanUninstall = true; DefaultAssetGroup = "admin"; }
public BasicReportModule(IRegionManager regionManager, BasicReportView basicReportView, IWorkPeriodService workPeriodService, IPrinterService printerService, ICacheService cacheService, IInventoryService inventoryService, IUserService userService, IAutomationService automationService, IApplicationState applicationState, ILogService logService, ISettingService settingService) : base(regionManager, AppScreens.ReportView) { ReportContext.PrinterService = printerService; ReportContext.WorkPeriodService = workPeriodService; ReportContext.InventoryService = inventoryService; ReportContext.UserService = userService; ReportContext.ApplicationState = applicationState; ReportContext.CacheService = cacheService; ReportContext.LogService = logService; ReportContext.SettingService = settingService; _userService = userService; _regionManager = regionManager; _basicReportView = basicReportView; SetNavigationCommand(Resources.Reports, Resources.Common, "Images/Ppt.png", 60); PermissionRegistry.RegisterPermission(PermissionNames.OpenReports, PermissionCategories.Navigation, Resources.CanDisplayReports); PermissionRegistry.RegisterPermission(PermissionNames.ChangeReportDate, PermissionCategories.Report, Resources.CanChangeReportFilter); //todo refactor automationService.RegisterParameterSource("ReportName", () => ReportContext.Reports.Select(x => x.Header)); }
public RouteService(IAppServiceRepository svcRepo, RequestContext context, RouteCollection routes, ILogService logger) { AppService = svcRepo.GetService(); Routes = routes; Context = context; LogService = logger; }
public OAuthClientHandlerService () :base() { appContext = Application.Context; tcs = new TaskCompletionSource<OAuthResult> (); logger = ServiceFinder.Resolve<ILogService> (); }
/// <summary> /// Initializes a new instance of the <see cref="AccountController"/> class. /// </summary> /// <param name="userManager">The user manager to use.</param> /// <param name="signInManager">The sign in manager to use.</param> /// <param name="urlHelper">The URL helper to use.</param> /// <param name="authManager">The authentication manager to use.</param> /// <param name="logService">The logging service to use.</param> /// <remarks> /// This overload is used to allow dependency injection for testing. /// </remarks> public AccountController(IUserManager userManager, ISignInManager signInManager, UrlHelper urlHelper, IAuthenticationManager authManager = null, ILogService logService = null) : base(userManager, signInManager) { Url = urlHelper ?? Url; _authManager = authManager; _logService = logService; }
public WorkPeriodService(IWorkPeriodDao workPeriodDao, IApplicationState applicationState, IApplicationStateSetter applicationStateSetter, ILogService logService) { _workPeriodDao = workPeriodDao; _applicationState = applicationState; _applicationStateSetter = applicationStateSetter; _logService = logService; }
//---------------------------------------------------------------------------------------- public HomeController(ILogService logService) { if (logService == null) throw new ArgumentNullException("logService"); this.logService = logService; }
private LogController CreateLogController(ILogService logService) { var userService = new Mock<IUserService>(); var mapper = new Mock<IMapperService>(); var controller = new LogController(userService.Object, logService, mapper.Object); return controller; }
public NoteController(INoteService noteService, IUserService userService , ILogService logService ) : base(userService, logService) { this.serviceNote = noteService; }
/// <summary> /// Initializes a new instance of the <see cref="ImportService"/> class. /// </summary> /// <param name="settingsService"> /// Провайдер настроек /// </param> /// <param name="fileSystemService"> /// Сервис файловой системы /// </param> /// <param name="logService"> /// Сервис логирования /// </param> /// <param name="dateTimeService"> /// Сервис даты/времени /// </param> public ImportService(IAlbumeSettingsService settingsService, IFileSystemService fileSystemService, ILogService logService, IDateTimeService dateTimeService) { this.settingsService = settingsService; this.fileSystemService = fileSystemService; this.logService = logService; this.dateTimeService = dateTimeService; }
/// <summary> /// Public constructor to initialize product service instance /// </summary> public DataController( ILogUnitOfWorkAsync unitOfWorkAsync, ILogService LogService) { _unitOfWorkAsync = unitOfWorkAsync; _LogService = LogService; }
public NavigatorService(IEventAggregator eventAggregator, IUrlParameterToObjectsPlateHeater urlParameterToObjectsPlateHeater, ILogService logService, INotificationService notificationService) { _eventAggregator = eventAggregator; this._notificationService = notificationService; this._logService = logService; _urlParameterToObjectsPlateHeater = urlParameterToObjectsPlateHeater; }
public BasicReportModule(IRegionManager regionManager, BasicReportView basicReportView, IWorkPeriodService workPeriodService, IPrinterService printerService, IInventoryService inventoryService, IUserService userService, IApplicationState applicationState, IAutomationService automationService, ILogService logService) : base(regionManager, AppScreens.ReportView) { ReportContext.PrinterService = printerService; ReportContext.WorkPeriodService = workPeriodService; ReportContext.InventoryService = inventoryService; ReportContext.UserService = userService; ReportContext.ApplicationState = applicationState; ReportContext.LogService = logService; _userService = userService; _regionManager = regionManager; _basicReportView = basicReportView; SetNavigationCommand(Resources.Reports, Resources.Common, "Images/Ppt.png", 60); PermissionRegistry.RegisterPermission(PermissionNames.OpenReports, PermissionCategories.Navigation, Resources.CanDisplayReports); PermissionRegistry.RegisterPermission(PermissionNames.ChangeReportDate, PermissionCategories.Report, Resources.CanChangeReportFilter); automationService.RegisterActionType("SaveReportToFile", Resources.SaveReportToFile, new { ReportName = "", FileName = "" }); automationService.RegisterActionType(ActionNames.PrintReport, Resources.PrintReport, new { ReportName = "" }); automationService.RegisterParameterSoruce("ReportName", () => ReportContext.Reports.Select(x => x.Header)); EventServiceFactory.EventService.GetEvent<GenericEvent<IActionData>>().Subscribe(x => { if (x.Value.Action.ActionType == "SaveReportToFile") { var reportName = x.Value.GetAsString("ReportName"); var fileName = x.Value.GetAsString("FileName"); if (!string.IsNullOrEmpty(reportName)) { var report = ReportContext.Reports.FirstOrDefault(y => y.Header == reportName); if (report != null) { ReportContext.CurrentWorkPeriod = ReportContext.ApplicationState.CurrentWorkPeriod; var document = report.GetReportDocument(); ReportViewModelBase.SaveAsXps(fileName, document); } } } if (x.Value.Action.ActionType == ActionNames.PrintReport) { var reportName = x.Value.GetAsString("ReportName"); if (!string.IsNullOrEmpty(reportName)) { var report = ReportContext.Reports.FirstOrDefault(y => y.Header == reportName); if (report != null) { ReportContext.CurrentWorkPeriod = ReportContext.ApplicationState.CurrentWorkPeriod; var document = report.GetReportDocument(); ReportContext.PrinterService.PrintReport(document, ReportContext.ApplicationState.CurrentTerminal.ReportPrinter); } } } }); }
public InventoryModule(IRegionManager regionManager, ICacheService cacheService, IUserService userService, IInventoryService inventoryService, WarehouseInventoryView resourceInventoryView, WarehouseInventoryViewModel resourceInventoryViewModel, ILogService logService) : base(regionManager, AppScreens.InventoryView) { _regionManager = regionManager; _cacheService = cacheService; _userService = userService; _inventoryService = inventoryService; _warehouseInventoryView = resourceInventoryView; _warehouseInventoryViewModel = resourceInventoryViewModel; _logService = logService; AddDashboardCommand<EntityCollectionViewModelBase<WarehouseTypeViewModel, WarehouseType>>(Resources.WarehouseType.ToPlural(), Resources.Inventory, 35); AddDashboardCommand<EntityCollectionViewModelBase<WarehouseViewModel, Warehouse>>(Resources.Warehouse.ToPlural(), Resources.Inventory, 35); AddDashboardCommand<EntityCollectionViewModelBase<TransactionTypeViewModel, InventoryTransactionType>>(Resources.TransactionType.ToPlural(), Resources.Inventory, 35); AddDashboardCommand<EntityCollectionViewModelBase<TransactionDocumentTypeViewModel, InventoryTransactionDocumentType>>(Resources.DocumentType.ToPlural(), Resources.Inventory, 35); AddDashboardCommand<TransactionDocumentListViewModel>(Resources.Transaction.ToPlural(), Resources.Inventory, 35); AddDashboardCommand<EntityCollectionViewModelBase<InventoryItemViewModel, InventoryItem>>(Resources.InventoryItems, Resources.Inventory, 35); AddDashboardCommand<RecipeListViewModel>(Resources.Recipes, Resources.Inventory, 35); AddDashboardCommand<PeriodicConsumptionListViewModel>(Resources.EndOfDayRecords, Resources.Inventory, 36); SetNavigationCommand(Resources.Warehouses, Resources.Common, "Images/box.png", 40); EventServiceFactory.EventService.GetEvent<GenericEvent<Entity>>().Subscribe(OnResourceEvent); EventServiceFactory.EventService.GetEvent<GenericEvent<Warehouse>>().Subscribe(OnWarehouseEvent); PermissionRegistry.RegisterPermission(PermissionNames.OpenInventory, PermissionCategories.Navigation, string.Format(Resources.CanNavigate_f, Resources.Inventory)); }
/// <summary> /// Initializes a new instance of the <see cref="C:RetainedLogger"/> class. /// </summary> /// <param name="logService">The log service.</param> /// <param name="maxEntries">The maximum number of entries to keep.</param> public RetainedLogService(ILogService logService, int maxEntries) { if (logService == null) realLogger = This.Logger; else realLogger = logService; if (maxEntries > 0) maxEntriesToKeep = maxEntries; }
public ThemeService(IAppServiceRepository svcRepo, string appPath, ILogService logger) { AppServiceRepository = svcRepo; LogService = logger; AppPath = appPath; ThemePath = Path.Combine(appPath, "themes"); }
public FollowController(IFollowService followService, IUserService userService , ILogService logService ) : base(userService, logService) { this.serviceFollow = followService; }
public LogController(IUserService userService, ILogService logService, IMapperService mapper) : base(userService, logService) { _mapper = mapper; }
public SiteCollectionController(ISiteTemplateService siteTemplateService, ICreateRequestService createRequestService, ILogService logService) { _siteTemplateService = siteTemplateService; _createRequestService = createRequestService; _logService = logService; }
public ProgramSettingsManager(ISystemEnvironment systemEnvironment, ILogService logService, IStorageService storageService) { _systemEnvironment = systemEnvironment; _storageService = storageService; _logService = logService; }
public AssetService(IAppServiceRepository svcRepo, IThemeService themeSvc, ILogService logSvc) { AppServiceRepository = svcRepo; ThemeService = themeSvc; LogService = logSvc; Assets = new Collection<Asset>(); }
/// <summary> /// Constructor for the Application object. /// </summary> public App() { // Global handler for uncaught exceptions. UnhandledException += Application_UnhandledException; // Show graphics profiling information while debugging. if (System.Diagnostics.Debugger.IsAttached) { // Display the current frame rate counters. Application.Current.Host.Settings.EnableFrameRateCounter = true; // Show the areas of the app that are being redrawn in each frame. //Application.Current.Host.Settings.EnableRedrawRegions = true; // Enable non-production analysis visualization mode, // which shows areas of a page that are being GPU accelerated with a colored overlay. //Application.Current.Host.Settings.EnableCacheVisualization = true; } // Standard Silverlight initialization InitializeComponent(); // App specific settings initialization InitializeSettings(); // Phone-specific initialization InitializePhoneApplication(); this._logService = IoC.Container.Get<ILogService>(); }
/// <summary> /// For testing purposes only. /// </summary> internal SymbolSearchService( Workspace workspace, IPackageInstallerService installerService, IRemoteControlService remoteControlService, ILogService logService, IDelayService delayService, IIOService ioService, IPatchService patchService, IDatabaseFactoryService databaseFactoryService, string localSettingsDirectory, Func<Exception, bool> reportAndSwallowException, CancellationTokenSource cancellationTokenSource) { if (remoteControlService == null) { // If we can't access the file update service, then there's nothing we can do. return; } _workspace = workspace; _installerService = installerService; _delayService = delayService; _ioService = ioService; _logService = logService; _remoteControlService = remoteControlService; _patchService = patchService; _databaseFactoryService = databaseFactoryService; _localSettingsDirectory = localSettingsDirectory; _reportAndSwallowException = reportAndSwallowException; _cancellationTokenSource = cancellationTokenSource; _cancellationToken = _cancellationTokenSource.Token; }
public IISClient(ILogService log) { _log = log; Version = GetIISVersion(); }
/// <summary> /// Creates a license validator using the client information /// and a service endpoint address to validate the license. /// </summary> protected AbstractLicenseValidator(ILogService log, string publicKey, string licenseServerUrl, Guid clientId) : this(log, publicKey) { this.licenseServerUrl = licenseServerUrl; this.clientId = clientId; }
public IISSitesFactory(ILogService log, IISClient iisClient) : base(log, nameof(IISSites), "SAN certificate for all bindings of multiple IIS sites") { _iisClient = iisClient; }
public UsStatesViewModel(ILogService service) : base(service) { MessageSink.MessageBus.GetEvent <LogChangedNotification>().Subscribe(details => onLogChangedNotification(details)); updateUsStateList(); }
public KeyVault(KeyVaultOptions options, IProxyService proxyService, ILogService log) { _options = options; _proxyService = proxyService; _log = log; }
static public LogEntry LogInformation(this ILogService service, string message) { return(service.Create(new LogEntry { UtcTs = DateTime.UtcNow, Type = LogEntryType.Information, Message = message })); }
static public LogEntry LogError(this ILogService service, string message, Exception ex) { return(service.Create(new LogEntry { UtcTs = DateTime.UtcNow, Type = LogEntryType.Error, Message = string.Format("{0}\r\n{1}\r\n{2}", message, ex, ex.StackTrace) })); }
public OLogController(ILogService logService, IUserService userService) { this._logService = logService; this._userService = userService; }
public IISSites(ILogService log, IISClient iisClient) : base(log, iisClient) { }
public MethodUseController(IMethodUseService methodUseService, IMapper mapper, ILogService log) { _methodUseService = methodUseService; _mapper = mapper; _log = log; }
public HobliCollection(IHobliService hobliService, ILogService logService) : base(logService) { HobliService = hobliService; }
public TrangThaiCongViecRepository(ILogService logService) : base(logService) { }
public LogController(ILogger <LogController> logger, ILogService service) { _logger = logger; _service = service; }
public VstsHelper(IOptions <Secrets> secrets, IOptions <Settings> settings, ILogService logService) { _secrets = secrets; _settings = settings; _logService = logService; }
public PemFilesOptionsFactory(ILogService log) : base(log) { }
/// <summary> /// 构造函数 /// </summary> /// <param name="logService">日志记录器</param> /// <param name="exceptionFormatter">信息收集格式化接口</param> protected internal ExceptionHandler(ILogService logService, IExceptionFormatter exceptionFormatter) { this.LogService = logService; this.exceptionFormatter = exceptionFormatter; }
public TestAuth(ISettingService setting, ILogService logger) : base(setting, logger) { }
/// <summary> /// Inject buisiness layer dependency /// </summary> /// <param name="placeOrderActions">Instance of this interface is injected in startup</param> public OrderFoodController(IPlaceOrderActions placeOrderActions, ILogService logService, IMessagePublisher messagePublisher) { _placeOrderActions = placeOrderActions; _logService = logService; _messagePublisher = messagePublisher; }
public CommonServices(IContextService contextService, INavigationService navigationService, IMessageService messageService, IDialogService dialogService, ILogService logService) { ContextService = contextService; NavigationService = navigationService; MessageService = messageService; DialogService = dialogService; LogService = logService; }
public NotificationService(ILogService log, EmailClient email, ICertificateService certificateService) { _log = log; _certificateService = certificateService; _email = email; }
public LogController() { logService = (ILogService)Activator.GetObject( typeof(ILogService), ApiConfig.LogServiceIP); }
public SocialController(IGlassMapperService glassMapperService, ILogService logService) { _glassMapperService = glassMapperService; _logService = logService; }
public PersonalInfoController(IPersonalInfo personalInfoService, ILogService log) { _personalInfoService = personalInfoService; _logger = log; }
public ExpenseHeadCollection(IExpenseHeadService expenseHeadService, ILogService logService) : base(logService) { ExpenseHeadService = expenseHeadService; }
public ApplicationController(IApplicationMediator applicationMediator, IConfigurationService configurationService, ILogService logService) : base(configurationService, logService) { _applicationMediator = applicationMediator; }
/// <summary> /// /// </summary> /// <param name="repository"></param> /// <param name="_userRepository"></param> /// <param name="_roleAuthorizeRepository"></param> /// <param name="_systemTypeRepository"></param> /// <param name="logService"></param> public MenuService(IMenuRepository repository, IUserRepository _userRepository, IRoleAuthorizeRepository _roleAuthorizeRepository, ISystemTypeRepository _systemTypeRepository, ILogService logService) : base(repository) { _MenuRepository = repository; userRepository = _userRepository; roleAuthorizeRepository = _roleAuthorizeRepository; systemTypeRepository = _systemTypeRepository; _logService = logService; }
public LogsController(ILogService logService) { this.logService = logService; }
public PurchasingController(IPermissionService permissionService, IPurchasingService purchasingService, IWareHouseService wareHouseService, ICommonService commonService, IProductService productService, ILogService logService, IUserService userService, IScheduleTaskFuncService scheduleTaskFuncService, IDbAccessor omsAccessor , IHostingEnvironment hostingEnvironment) { _permissionService = permissionService; _purchasingService = purchasingService; _wareHouseService = wareHouseService; _commonService = commonService; _productService = productService; _logService = logService; _userService = userService; _scheduleTaskFuncService = scheduleTaskFuncService; _omsAccessor = omsAccessor; _hostingEnvironment = hostingEnvironment; }
/// <summary> /// Initializes a new instance of the <see cref="SYSRolesRepository"/> class. /// </summary> /// <param name="logService">The log service.</param> public RolesRepository(ILogService logService) { this._logService = logService; }
public FlightEntryViewModel(IMvxNavigationService navigationService) { _logger = Mvx.Resolve <ILogService>(); _navigationService = navigationService; }