public OmniSharpProjectWorkspaceStateGenerator(OmniSharpProjectSnapshotManagerDispatcher projectSnapshotManagerDispatcher)
        {
            if (projectSnapshotManagerDispatcher is null)
            {
                throw new ArgumentNullException(nameof(projectSnapshotManagerDispatcher));
            }

            InternalWorkspaceStateGenerator = new DefaultProjectWorkspaceStateGenerator(projectSnapshotManagerDispatcher.InternalDispatcher);
        }
        public DocumentChangedSynchronizationService(OmniSharpProjectSnapshotManagerDispatcher projectSnapshotManagerDispatcher)
        {
            if (projectSnapshotManagerDispatcher is null)
            {
                throw new ArgumentNullException(nameof(projectSnapshotManagerDispatcher));
            }

            _projectSnapshotManagerDispatcher = projectSnapshotManagerDispatcher;
        }
Ejemplo n.º 3
0
        public OmniSharpWorkspaceProjectStateChangeDetector(
            OmniSharpProjectSnapshotManagerDispatcher projectSnapshotManagerDispatcher,
            OmniSharpProjectWorkspaceStateGenerator workspaceStateGenerator)
        {
            if (projectSnapshotManagerDispatcher is null)
            {
                throw new ArgumentNullException(nameof(projectSnapshotManagerDispatcher));
            }

            if (workspaceStateGenerator is null)
            {
                throw new ArgumentNullException(nameof(workspaceStateGenerator));
            }

            InternalWorkspaceProjectStateChangeDetector = new ProjectSnapshotManagerWorkspaceProjectStateChangeDetector(
                projectSnapshotManagerDispatcher.InternalDispatcher,
                workspaceStateGenerator.InternalWorkspaceStateGenerator);
        }
        public MSBuildProjectManager(
            [ImportMany] IEnumerable <ProjectConfigurationProvider> projectConfigurationProviders,
            ProjectInstanceEvaluator projectInstanceEvaluator,
            ProjectChangePublisher projectConfigurationPublisher,
            OmniSharpProjectSnapshotManagerDispatcher projectSnapshotManagerDispatcher,
            ILoggerFactory loggerFactory)
        {
            if (projectConfigurationProviders is null)
            {
                throw new ArgumentNullException(nameof(projectConfigurationProviders));
            }

            if (projectInstanceEvaluator is null)
            {
                throw new ArgumentNullException(nameof(projectInstanceEvaluator));
            }

            if (projectConfigurationPublisher is null)
            {
                throw new ArgumentNullException(nameof(projectConfigurationPublisher));
            }

            if (projectSnapshotManagerDispatcher is null)
            {
                throw new ArgumentNullException(nameof(projectSnapshotManagerDispatcher));
            }

            if (loggerFactory is null)
            {
                throw new ArgumentNullException(nameof(loggerFactory));
            }

            _logger = loggerFactory.CreateLogger <MSBuildProjectManager>();
            _projectConfigurationProviders    = projectConfigurationProviders;
            _projectInstanceEvaluator         = projectInstanceEvaluator;
            _projectConfigurationPublisher    = projectConfigurationPublisher;
            _projectSnapshotManagerDispatcher = projectSnapshotManagerDispatcher;
        }
        public OmniSharpBackgroundDocumentGenerator(
            OmniSharpProjectSnapshotManagerDispatcher projectSnapshotManagerDispatcher,
            RemoteTextLoaderFactory remoteTextLoaderFactory,
            IEnumerable <OmniSharpDocumentProcessedListener> documentProcessedListeners)
        {
            if (projectSnapshotManagerDispatcher is null)
            {
                throw new ArgumentNullException(nameof(projectSnapshotManagerDispatcher));
            }

            if (remoteTextLoaderFactory is null)
            {
                throw new ArgumentNullException(nameof(remoteTextLoaderFactory));
            }

            if (documentProcessedListeners is null)
            {
                throw new ArgumentNullException(nameof(documentProcessedListeners));
            }

            var wrappedListeners = documentProcessedListeners.Select(listener => new WrappedDocumentProcessedListener(remoteTextLoaderFactory, listener));

            _backgroundDocumentGenerator = new BackgroundDocumentGenerator(projectSnapshotManagerDispatcher.InternalDispatcher, wrappedListeners);
        }