private ApplicationSettings(ApplicationSettings other)
 {
     _fileName      = other._fileName;
     _fileFolder    = other._fileFolder;
     _autoUpdate    = other._autoUpdate.Clone();
     _mainWindow    = other._mainWindow.Clone();
     _dataSources   = other._dataSources.Clone();
     _quickFilters  = other._quickFilters.Clone();
     _export        = other._export.Clone();
     _logViewer     = other._logViewer.Clone();
     _logFile       = other._logFile.Clone();
     _customFormats = other._customFormats.Clone();
     _allowSave     = true;
 }
        public void Setup()
        {
            _serviceContainer = new ServiceContainer();

            _registry = new Mock <ILogFileFormatRegistry>();
            _serviceContainer.RegisterInstance(_registry.Object);

            _settings = new Mock <IApplicationSettings>();
            _customFormatsSettings = new CustomFormatsSettings();
            _settings.SetupGet(x => x.CustomFormats).Returns(_customFormatsSettings);

            _pluginId  = new PluginId("221dwdwaddwa");
            _plugin    = new Mock <ICustomLogFileFormatCreatorPlugin>();
            _encodings = new[] { new EncodingViewModel(Encoding.Default) };
        }
        public ApplicationSettings(string fileName)
        {
            _fileName   = Path.GetFullPath(fileName);
            _fileFolder = Path.GetDirectoryName(_fileName);

            _autoUpdate    = new AutoUpdateSettings();
            _mainWindow    = new MainWindowSettings();
            _dataSources   = new DataSourceSettings();
            _quickFilters  = new QuickFiltersSettings();
            _logViewer     = new LogViewerSettings();
            _logFile       = new LogFileSettings();
            _export        = new ExportSettings();
            _customFormats = new CustomFormatsSettings();
            _allowSave     = true;
        }