internal PythonToolsService(IServiceContainer container) { _container = container; _analyzers = new ConcurrentDictionary <string, VsProjectAnalyzer>(); _langPrefs = new Lazy <LanguagePreferences>(() => new LanguagePreferences(this, typeof(PythonLanguageInfo).GUID)); _interpreterOptionsService = new Lazy <IInterpreterOptionsService>(Site.GetComponentModel().GetService <IInterpreterOptionsService>); _interpreterRegistryService = new Lazy <IInterpreterRegistryService>(Site.GetComponentModel().GetService <IInterpreterRegistryService>); _optionsService = (IPythonToolsOptionsService)container.GetService(typeof(IPythonToolsOptionsService)); _idleManager = new IdleManager(container); _advancedOptions = new Lazy <AdvancedEditorOptions>(CreateAdvancedEditorOptions); _debuggerOptions = new Lazy <DebuggerOptions>(CreateDebuggerOptions); _experimentalOptions = new Lazy <Options.ExperimentalOptions>(CreateExperimentalOptions); _diagnosticsOptions = new Lazy <DiagnosticsOptions>(CreateDiagnosticsOptions); _generalOptions = new Lazy <GeneralOptions>(CreateGeneralOptions); _suppressDialogOptions = new Lazy <SuppressDialogOptions>(() => new SuppressDialogOptions(this)); _interactiveOptions = new Lazy <PythonInteractiveOptions>(() => CreateInteractiveOptions("Interactive")); _debugInteractiveOptions = new Lazy <PythonInteractiveOptions>(() => CreateInteractiveOptions("Debug Interactive Window")); _logger = (IPythonToolsLogger)container.GetService(typeof(IPythonToolsLogger)); _diagnosticsProvider = new DiagnosticsProvider(container); _idleManager.OnIdle += OnIdleInitialization; EditorServices = ComponentModel.GetService <PythonEditorServices>(); EditorServices.SetPythonToolsService(this); }
internal PythonToolsService(IServiceContainer container) { _container = container; _langPrefs = new Lazy <LanguagePreferences>(() => new LanguagePreferences(this, typeof(PythonLanguageInfo).GUID)); _interpreterOptionsService = new Lazy <IInterpreterOptionsService>(CreateInterpreterOptionsService); _optionsService = (IPythonToolsOptionsService)container.GetService(typeof(IPythonToolsOptionsService)); _idleManager = new IdleManager(container); _advancedOptions = new Lazy <AdvancedEditorOptions>(CreateAdvancedEditorOptions); _debuggerOptions = new Lazy <DebuggerOptions>(CreateDebuggerOptions); _experimentalOptions = new Lazy <Options.ExperimentalOptions>(CreateExperimentalOptions); _diagnosticsOptions = new Lazy <DiagnosticsOptions>(CreateDiagnosticsOptions); _generalOptions = new Lazy <GeneralOptions>(CreateGeneralOptions); _suppressDialogOptions = new Lazy <SuppressDialogOptions>(() => new SuppressDialogOptions(this)); _interactiveOptions = new Lazy <PythonInteractiveOptions>(() => CreateInteractiveOptions("Interactive")); _debugInteractiveOptions = new Lazy <PythonInteractiveOptions>(() => CreateInteractiveOptions("Debug Interactive Window")); _logger = new PythonToolsLogger(ComponentModel.GetExtensions <IPythonToolsLogger>().ToArray()); _entryService = (AnalysisEntryService)ComponentModel.GetService <IAnalysisEntryService>(); _diagnosticsProvider = new DiagnosticsProvider(container); _idleManager.OnIdle += OnIdleInitialization; EditorServices.SetPythonToolsService(this); }