33 references to Count
Microsoft.Build (29)
BackEnd\Components\Communications\TranslatorExtensions.cs (1)
52int count = value.Count;
BackEnd\Components\ProjectCache\ProjectCacheService.cs (2)
330Dictionary<string, string> globalProperties = new(configuration.GlobalProperties.Count, StringComparer.OrdinalIgnoreCase); 626var globalProperties = new Dictionary<string, string>(configuration.GlobalProperties.Count, StringComparer.OrdinalIgnoreCase);
BackEnd\Components\RequestBuilder\Lookup.cs (1)
404SecondaryProperties ??= new PropertyDictionary<ProjectPropertyInstance>(PrimaryPropertySets.Count);
BackEnd\Shared\ConfigurationMetadata.cs (1)
177$"{truncatedProjectFile}, #GlobalProps={GlobalProperties.Count}";
Collections\PropertyDictionary.cs (3)
139int ICollection<KeyValuePair<string, T>>.Count => Count; 279if (Count != other.Count)
Definition\Project.cs (3)
2117return _data.GlobalPropertiesDictionary.Count; 2147if (_data.GlobalPropertiesDictionary.Count == 0) 2152var dictionary = new Dictionary<string, string>(_data.GlobalPropertiesDictionary.Count, MSBuildNameIgnoreCaseComparer.Default);
Definition\ProjectCollection.cs (2)
564if (_globalProperties.Count == 0) 569dictionary = new Dictionary<string, string>(_globalProperties.Count, MSBuildNameIgnoreCaseComparer.Default);
Definition\ProjectItem.cs (3)
277{ return Link != null ? Link.DirectMetadata.Count : _directMetadata != null ? _directMetadata.Count : 0; } 837List<ProjectMetadata> temporary = new List<ProjectMetadata>(_directMetadata.Count); 844_directMetadata = new PropertyDictionary<ProjectMetadata>(_directMetadata.Count);
Definition\ProjectItemDefinition.cs (1)
104get { return Link != null ? Link.Metadata.Count : (_metadata == null) ? 0 : _metadata.Count; }
Definition\Toolset.cs (2)
922int count = _environmentProperties.Count + reservedProperties.Count + Properties.Values.Count + _globalProperties.Count + 1;
Evaluation\Evaluator.cs (2)
826List<P> list = new(dictionary.Count); 1257return _data.GlobalPropertiesDictionary.Count;
Instance\ProjectInstance.cs (8)
711_properties = new PropertyDictionary<ProjectPropertyInstance>(that._properties.Count); 725_globalProperties = new PropertyDictionary<ProjectPropertyInstance>(that._globalProperties.Count); 733new PropertyDictionary<ProjectPropertyInstance>(that._environmentVariableProperties.Count); 1075if (_globalProperties == null /* cached */ || _globalProperties.Count == 0) 1080Dictionary<string, string> dictionary = new Dictionary<string, string>(_globalProperties.Count, MSBuildNameIgnoreCaseComparer.Default); 2548Dictionary<string, string> globalProperties = new Dictionary<string, string>(globalPropertiesInstances.Count, StringComparer.OrdinalIgnoreCase); 3265_environmentVariableProperties = new PropertyDictionary<ProjectPropertyInstance>(environmentVariableProperties.Count); 3278_globalProperties = new PropertyDictionary<ProjectPropertyInstance>(globalPropertiesDictionary.Count);
Microsoft.Build.Engine.UnitTests (4)
BackEnd\IntrinsicTask_Tests.cs (3)
44Assert.Equal(2, properties.Count); 977Assert.Equal(2, properties.Count); 1152Assert.Equal(2, properties.Count);
Collections\OMcollections_tests.cs (1)
47Assert.Equal(2, properties.Count);