internal VSSolutionManager(
            [Import(typeof(SVsServiceProvider))]
            IServiceProvider serviceProvider,
            IProjectSystemCache projectSystemCache,
            NuGetProjectFactory projectSystemFactory,
            ICredentialServiceProvider credentialServiceProvider,
            IVsProjectAdapterProvider vsProjectAdapterProvider,
            [Import("VisualStudioActivityLogger")]
            Common.ILogger logger,
            Lazy <ISettings> settings)
        {
            Assumes.Present(serviceProvider);
            Assumes.Present(projectSystemCache);
            Assumes.Present(projectSystemFactory);
            Assumes.Present(credentialServiceProvider);
            Assumes.Present(vsProjectAdapterProvider);
            Assumes.Present(logger);
            Assumes.Present(settings);

            _serviceProvider           = serviceProvider;
            _projectSystemCache        = projectSystemCache;
            _projectSystemFactory      = projectSystemFactory;
            _credentialServiceProvider = credentialServiceProvider;
            _vsProjectAdapterProvider  = vsProjectAdapterProvider;
            _logger   = logger;
            _settings = settings;
        }
Exemple #2
0
        internal VSSolutionManager(
            IAsyncServiceProvider asyncServiceProvider,
            IProjectSystemCache projectSystemCache,
            NuGetProjectFactory projectSystemFactory,
            ICredentialServiceProvider credentialServiceProvider,
            IVsProjectAdapterProvider vsProjectAdapterProvider,
            ILogger logger,
            Lazy <ISettings> settings,
            JoinableTaskContext joinableTaskContext)
        {
            Assumes.Present(asyncServiceProvider);
            Assumes.Present(projectSystemCache);
            Assumes.Present(projectSystemFactory);
            Assumes.Present(credentialServiceProvider);
            Assumes.Present(vsProjectAdapterProvider);
            Assumes.Present(logger);
            Assumes.Present(settings);
            Assumes.Present(joinableTaskContext);

            _asyncServiceProvider      = asyncServiceProvider;
            _projectSystemCache        = projectSystemCache;
            _projectSystemFactory      = projectSystemFactory;
            _credentialServiceProvider = credentialServiceProvider;
            _vsProjectAdapterProvider  = vsProjectAdapterProvider;
            _logger   = logger;
            _settings = settings;
            _initLock = new NuGetLockService(joinableTaskContext);
        }
        internal VSSolutionManager(
            IAsyncServiceProvider asyncServiceProvider,
            IProjectSystemCache projectSystemCache,
            NuGetProjectFactory projectSystemFactory,
            ICredentialServiceProvider credentialServiceProvider,
            IVsProjectAdapterProvider vsProjectAdapterProvider,
            ILogger logger,
            Lazy <ISettings> settings,
            INuGetFeatureFlagService featureFlagService,
            JoinableTaskContext joinableTaskContext)
        {
            Assumes.Present(asyncServiceProvider);
            Assumes.Present(projectSystemCache);
            Assumes.Present(projectSystemFactory);
            Assumes.Present(credentialServiceProvider);
            Assumes.Present(vsProjectAdapterProvider);
            Assumes.Present(logger);
            Assumes.Present(settings);
            Assumes.Present(featureFlagService);
            Assumes.Present(joinableTaskContext);

            _asyncServiceProvider      = asyncServiceProvider;
            _projectSystemCache        = projectSystemCache;
            _projectSystemFactory      = projectSystemFactory;
            _credentialServiceProvider = credentialServiceProvider;
            _vsProjectAdapterProvider  = vsProjectAdapterProvider;
            _logger             = logger;
            _settings           = settings;
            _featureFlagService = featureFlagService;
            _initLock           = new NuGetLockService(joinableTaskContext);
            _dte             = new(() => asyncServiceProvider.GetDTEAsync(), NuGetUIThreadHelper.JoinableTaskFactory);
            _asyncVSSolution = new(() => asyncServiceProvider.GetServiceAsync <SVsSolution, IVsSolution>(), NuGetUIThreadHelper.JoinableTaskFactory);
        }
Exemple #4
0
 internal VSSolutionManager(
     IProjectSystemCache projectSystemCache,
     NuGetProjectFactory projectSystemFactory,
     ICredentialServiceProvider credentialServiceProvider,
     IVsProjectAdapterProvider vsProjectAdapterProvider,
     [Import("VisualStudioActivityLogger")]
     Common.ILogger logger,
     Lazy <ISettings> settings,
     JoinableTaskContext joinableTaskContext)
     : this(AsyncServiceProvider.GlobalProvider,
            projectSystemCache,
            projectSystemFactory,
            credentialServiceProvider,
            vsProjectAdapterProvider,
            logger,
            settings,
            joinableTaskContext)
 {
 }
Exemple #5
0
        internal VSSolutionManager(
            [Import(typeof(SVsServiceProvider))]
            IServiceProvider serviceProvider,
            IProjectSystemCache projectSystemCache,
            NuGetProjectFactory projectSystemFactory,
            ICredentialServiceProvider credentialServiceProvider,
            [Import(typeof(VisualStudioActivityLogger))]
            Common.ILogger logger)
        {
            if (serviceProvider == null)
            {
                throw new ArgumentNullException(nameof(serviceProvider));
            }

            if (projectSystemCache == null)
            {
                throw new ArgumentNullException(nameof(projectSystemCache));
            }

            if (projectSystemFactory == null)
            {
                throw new ArgumentNullException(nameof(projectSystemFactory));
            }
            if (credentialServiceProvider == null)
            {
                throw new ArgumentNullException(nameof(credentialServiceProvider));
            }
            if (logger == null)
            {
                throw new ArgumentNullException(nameof(logger));
            }

            _serviceProvider           = serviceProvider;
            _projectSystemCache        = projectSystemCache;
            _projectSystemFactory      = projectSystemFactory;
            _credentialServiceProvider = credentialServiceProvider;
            _logger = logger;
        }