29 references to ReadOnlyCollection
Microsoft.Build (27)
BackEnd\BuildManager\BuildRequestData.cs (1)
195new ReadOnlyCollection<ProjectPropertyInstance>(GlobalPropertiesDictionary);
Collections\ItemDictionary.cs (1)
127return new ReadOnlyCollection<T>(list);
Construction\ProjectElementContainer.cs (2)
81: new Collections.ReadOnlyCollection<ProjectElement>(new ProjectElementSiblingEnumerable(FirstChild)); 105: new Collections.ReadOnlyCollection<ProjectElement>(new ProjectElementSiblingEnumerable(LastChild, forwards: false));
Construction\ProjectRootElement.cs (4)
300public ICollection<ProjectItemDefinitionElement> ItemDefinitions => new ReadOnlyCollection<ProjectItemDefinitionElement>(GetAllChildrenOfType<ProjectItemDefinitionElement>()); 312public ICollection<ProjectItemElement> Items => new ReadOnlyCollection<ProjectItemElement>(GetAllChildrenOfType<ProjectItemElement>()); 322public ICollection<ProjectImportElement> Imports => new ReadOnlyCollection<ProjectImportElement>(GetAllChildrenOfType<ProjectImportElement>()); 334public ICollection<ProjectPropertyElement> Properties => new ReadOnlyCollection<ProjectPropertyElement>(GetAllChildrenOfType<ProjectPropertyElement>());
Definition\Project.cs (7)
2176public override ICollection<ProjectProperty> Properties => new ReadOnlyCollection<ProjectProperty>(_data.Properties); 2218public override ICollection<ProjectItem> Items => new ReadOnlyCollection<ProjectItem>(_data.Items); 2238return new ReadOnlyCollection<ProjectItem>(_data.ItemsIgnoringCondition); 2330return new ReadOnlyCollection<ProjectProperty>(allEvaluatedProperties); 2352return new ReadOnlyCollection<ProjectMetadata>(allEvaluatedItemDefinitionMetadata); 2376return new ReadOnlyCollection<ProjectItem>(allEvaluatedItems); 4608ICollection<ProjectItem> items = new ReadOnlyCollection<ProjectItem>(ItemsByEvaluatedIncludeCache[evaluatedInclude]);
Instance\ProjectInstance.cs (6)
654this.CreatePropertiesSnapshot(new ReadOnlyCollection<ProjectProperty>(data.Properties), immutable); 659var projectItemToInstanceMap = this.CreateItemsSnapshot(new ReadOnlyCollection<ProjectItem>(data.Items), data.ItemTypes.Count, keepEvaluationCache); 661this.CreateEvaluatedIncludeSnapshotIfRequested(keepEvaluationCache, new ReadOnlyCollection<ProjectItem>(data.Items), projectItemToInstanceMap); 1126new ReadOnlyCollection<ProjectPropertyInstance>(_properties); 1141new ReadOnlyCollection<ProjectItemInstance>(_items); 1560internal ICollection<ProjectPropertyInstance> TestEnvironmentalProperties => new ReadOnlyCollection<ProjectPropertyInstance>(_environmentVariableProperties);
Instance\ProjectItemDefinitionInstance.cs (1)
110return new ReadOnlyCollection<ProjectMetadataInstance>(_metadata.Values);
Instance\ProjectItemGroupTaskInstance.cs (1)
98new ReadOnlyCollection<ProjectItemGroupTaskItemInstance>(_items);
Instance\ProjectItemGroupTaskItemInstance.cs (1)
329new ReadOnlyCollection<ProjectItemGroupTaskMetadataInstance>(_metadata);
Instance\ProjectItemInstance.cs (1)
285get { return new ReadOnlyCollection<string>(_taskItem.MetadataNames.Cast<string>()); }
Instance\ProjectPropertyGroupTaskInstance.cs (1)
98new ReadOnlyCollection<ProjectPropertyGroupTaskPropertyInstance>(_properties);
Instance\ProjectTargetInstance.cs (1)
335return new ReadOnlyCollection<ProjectTaskInstance>(Children.OfType<ProjectTaskInstance>());
Microsoft.Build.Engine.UnitTests (2)
Collections\OMcollections_tests.cs (2)
243new ReadOnlyCollection<string>(null); 297var collection = new ReadOnlyCollection<string>(backing);