Beispiel #1
0
        public GraphBuilder(
            IEnumerable <ProjectGraphEntryPoint> entryPoints,
            ProjectCollection projectCollection,
            ProjectGraph.ProjectInstanceFactoryFunc projectInstanceFactory,
            ProjectInterpretation projectInterpretation,
            int degreeOfParallelism,
            CancellationToken cancellationToken)
        {
            var(actualEntryPoints, solutionDependencies) = ExpandSolutionIfPresent(entryPoints.ToImmutableArray());

            _solutionDependencies = solutionDependencies;

            _entryPointConfigurationMetadata = AddGraphBuildPropertyToEntryPoints(actualEntryPoints);

            IEqualityComparer <ConfigurationMetadata> configComparer = EqualityComparer <ConfigurationMetadata> .Default;

            _graphWorkSet = new ParallelWorkSet <ConfigurationMetadata, ParsedProject>(
                degreeOfParallelism - ImplicitWorkerCount,
                configComparer,
                cancellationToken);

            _projectCollection      = projectCollection;
            _projectInstanceFactory = projectInstanceFactory;
            _projectInterpretation  = projectInterpretation;
        }
Beispiel #2
0
        public GraphBuilder(
            IEnumerable <ProjectGraphEntryPoint> entryPoints,
            ProjectCollection projectCollection,
            ProjectGraph.ProjectInstanceFactoryFunc projectInstanceFactory,
            ProjectInterpretation projectInterpretation,
            int degreeOfParallelism,
            CancellationToken cancellationToken)
        {
            _entryPointConfigurationMetadata = AddGraphBuildPropertyToEntryPoints(entryPoints);
            IEqualityComparer <ConfigurationMetadata> configComparer = EqualityComparer <ConfigurationMetadata> .Default;

            _graphWorkSet = new ParallelWorkSet <ConfigurationMetadata, ProjectGraphNode>(
                degreeOfParallelism - ImplicitWorkerCount,
                configComparer,
                cancellationToken);
            _projectCollection      = projectCollection;
            _projectInstanceFactory = projectInstanceFactory;
            _projectInterpretation  = projectInterpretation;
        }