140 references to new
dotnet-svcutil-lib (2)
FrameworkFork\Microsoft.Xml\Xml\schema\XmlSchemaObjectTable.cs (2)
332return new DictionaryEntry(currentKey, currentValue); 382return new DictionaryEntry(currentKey, currentValue);
Microsoft.Build (14)
BackEnd\Components\Logging\ProjectLoggingContext.cs (4)
214properties = projectProperties.GetCopyOnReadEnumerable(property => new DictionaryEntry(property.Name, property.EvaluatedValue)); 218properties = projectProperties.Filter(p => p is not EnvironmentDerivedProjectPropertyInstance || EnvironmentUtilities.IsWellKnownEnvironmentDerivedProperty(p.Name), p => new DictionaryEntry(p.Name, p.EvaluatedValue)); 221items = projectItems?.GetCopyOnReadEnumerable(item => new DictionaryEntry(item.ItemType, new TaskItem(item))) ?? []; 241properties = projectPropertiesToSerialize.Select((ProjectPropertyInstance property) => new DictionaryEntry(property.Name, property.EvaluatedValue));
Collections\ArrayDictionary.cs (1)
241private DictionaryEntry CurrentDictionaryEntry => new DictionaryEntry(_dictionary.keys[_position], _dictionary.values[_position]);
CopyOnWriteDictionary.cs (1)
363array.SetValue(new DictionaryEntry(entry.Key, entry.Value), index + i);
Logging\BaseConsoleLogger.cs (1)
500Internal.Utilities.EnumerateProperties(properties, list, static (list, kvp) => list.Add(new DictionaryEntry(kvp.Key, kvp.Value)));
Logging\BinaryLogger\BuildEventArgsReader.cs (4)
1448list[i] = new DictionaryEntry(property.Key, property.Value); 1549list[i] = new DictionaryEntry(itemName, item); 1569list.Add(new DictionaryEntry(itemType, item)); 1596list.Add(new DictionaryEntry(itemType, item));
LogMessagePacketBase.cs (2)
1435var entry = new DictionaryEntry(key, value); 1459var entry = new DictionaryEntry(itemType, taskItemData);
Utilities\Utilities.cs (1)
803callback(new DictionaryEntry(tuple.Type, tuple.Value));
Microsoft.Build.Engine.UnitTests (17)
BackEnd\NodePackets_Tests.cs (5)
152new DictionaryEntry("Compile", new TaskItemData("a", null)), 153new DictionaryEntry("Compile", new TaskItemData("b", CreateStringDictionary())), 154new DictionaryEntry("Reference", new TaskItemData("c", CreateStringDictionary())), 166new DictionaryEntry("a", "b"), 167new DictionaryEntry("c", "d")
BackEnd\TaskThatReturnsDictionaryTaskItem.cs (1)
200public DictionaryEntry Entry => new DictionaryEntry(Key, Value);
BuildEventArgsDataEnumeration.cs (7)
32new DictionaryEntry("Key", "Value"), 60new DictionaryEntry("Key", new MyTaskItem() { ItemSpec = "TestItemSpec" }), 61new DictionaryEntry("Key2", 98new DictionaryEntry("Key", new MyTaskItem() { ItemSpec = "TestItemSpec" }), 99new DictionaryEntry("Key2", 102new DictionaryEntry("Key2", new MyTaskItem() { ItemSpec = "TestItemSpec3" }), 103new DictionaryEntry("Key",
BuildEventArgsSerialization_Tests.cs (4)
160properties: new List<DictionaryEntry>() { new DictionaryEntry("Key", "Value") }, 161items: new List<DictionaryEntry>() { new DictionaryEntry("Key", new MyTaskItem() { ItemSpec = "TestItemSpec" }) }, 770Properties = new List<DictionaryEntry>() { new DictionaryEntry("Key", "Value") }, 771Items = new List<DictionaryEntry>() { new DictionaryEntry("Key", new MyTaskItem() { ItemSpec = "TestItemSpec" }) }
Microsoft.Build.Framework (5)
ImmutableSegmentedDictionary`2+Enumerator.cs (1)
47DictionaryEntry IDictionaryEnumerator.Entry => new(Current.Key, Current.Value);
ProjectStartedEventArgs.cs (1)
466DictionaryEntry entry = new DictionaryEntry(key, value);
SegmentedDictionary`2.cs (3)
883dictEntryArray[index++] = new DictionaryEntry(entries[i]._key, entries[i]._value); 1198return new DictionaryEntry(_current.Key, _current.Value); 1225return new DictionaryEntry(_current.Key, _current.Value);
Microsoft.Build.Framework.UnitTests (7)
CustomEventArgSerialization_Tests.cs (7)
581propertyList.Add(new DictionaryEntry("TeamBuildOutDir", "c:\\outdir")); 582propertyList.Add(new DictionaryEntry("Configuration", "BuildConfiguration")); 583propertyList.Add(new DictionaryEntry("Platform", "System Platform")); 584propertyList.Add(new DictionaryEntry("OutDir", "myOutDir")); 585propertyList.Add(new DictionaryEntry("WorkSpaceName", " MyWorkspace")); 586propertyList.Add(new DictionaryEntry("WorkSpaceOwner", "The workspace owner")); 587propertyList.Add(new DictionaryEntry("IAmBlank", string.Empty));
Microsoft.Build.Tasks.Core (5)
CopyOnWriteDictionary.cs (1)
363array.SetValue(new DictionaryEntry(entry.Key, entry.Value), index + i);
ManifestUtil\ManifestReader.cs (1)
187DictionaryEntry arg = new DictionaryEntry("manifest-type", manifestType);
ManifestUtil\ManifestWriter.cs (2)
150var arg = new DictionaryEntry("trust-file", temp); 175var arg = new DictionaryEntry("base-file", temp);
ManifestUtil\TrustInfo.cs (1)
631Stream s = tempPrivilegeDocument != null ? XmlUtil.XslTransform(trustInfoResource2, m, new DictionaryEntry("defaultRequestedPrivileges", tempPrivilegeDocument)) : XmlUtil.XslTransform(trustInfoResource2, m);
Microsoft.Build.Utilities.Core (1)
CopyOnWriteDictionary.cs (1)
363array.SetValue(new DictionaryEntry(entry.Key, entry.Value), index + i);
Microsoft.CodeAnalysis (4)
src\Dependencies\Collections\ImmutableSegmentedDictionary`2+Enumerator.cs (1)
47readonly DictionaryEntry IDictionaryEnumerator.Entry => new(Current.Key, Current.Value);
src\Dependencies\Collections\SegmentedDictionary`2.cs (3)
911dictEntryArray[index++] = new DictionaryEntry(entries[i]._key, entries[i]._value); 1232return new DictionaryEntry(_current.Key, _current.Value); 1259return new DictionaryEntry(_current.Key, _current.Value);
Microsoft.CodeAnalysis.CodeStyle (4)
src\Dependencies\Collections\ImmutableSegmentedDictionary`2+Enumerator.cs (1)
47readonly DictionaryEntry IDictionaryEnumerator.Entry => new(Current.Key, Current.Value);
src\Dependencies\Collections\SegmentedDictionary`2.cs (3)
911dictEntryArray[index++] = new DictionaryEntry(entries[i]._key, entries[i]._value); 1232return new DictionaryEntry(_current.Key, _current.Value); 1259return new DictionaryEntry(_current.Key, _current.Value);
Microsoft.CodeAnalysis.Collections.Package (4)
ImmutableSegmentedDictionary`2+Enumerator.cs (1)
47readonly DictionaryEntry IDictionaryEnumerator.Entry => new(Current.Key, Current.Value);
SegmentedDictionary`2.cs (3)
911dictEntryArray[index++] = new DictionaryEntry(entries[i]._key, entries[i]._value); 1232return new DictionaryEntry(_current.Key, _current.Value); 1259return new DictionaryEntry(_current.Key, _current.Value);
Microsoft.CodeAnalysis.Scripting.TestUtilities (1)
ObjectFormatterFixtures\Custom.cs (1)
456get { return new DictionaryEntry(_i, _i); }
Microsoft.CodeAnalysis.UnitTests (18)
Collections\ImmutableDictionaryBuilderTestBase.cs (9)
199Assert.Equal(new DictionaryEntry(null!, 0), enumerator.Current); 202Assert.Equal(new DictionaryEntry(null!, 0), enumerator.Entry); 210Assert.Equal(new DictionaryEntry(null!, 0), enumerator.Current); 213Assert.Equal(new DictionaryEntry(null!, 0), enumerator.Entry); 217Assert.Equal(new DictionaryEntry(null!, 0), enumerator.Current); 220Assert.Equal(new DictionaryEntry(null!, 0), enumerator.Entry); 227Assert.Equal(new DictionaryEntry(null!, 0), enumerator.Current); 230Assert.Equal(new DictionaryEntry(null!, 0), enumerator.Entry); 253Assert.Equal(new DictionaryEntry[] { default, new DictionaryEntry("b", 2) }, entryArray);
Collections\ImmutableDictionaryTestBase.cs (9)
150Assert.Equal(new DictionaryEntry("a", 1), (DictionaryEntry)array[1]); 187Assert.Equal(new DictionaryEntry(null!, 0), enumerator.Current); 190Assert.Equal(new DictionaryEntry(null!, 0), enumerator.Entry); 198Assert.Equal(new DictionaryEntry(null!, 0), enumerator.Current); 201Assert.Equal(new DictionaryEntry(null!, 0), enumerator.Entry); 205Assert.Equal(new DictionaryEntry(null!, 0), enumerator.Current); 208Assert.Equal(new DictionaryEntry(null!, 0), enumerator.Entry); 215Assert.Equal(new DictionaryEntry(null!, 0), enumerator.Current); 218Assert.Equal(new DictionaryEntry(null!, 0), enumerator.Entry);
Microsoft.CodeAnalysis.Workspaces (4)
src\Dependencies\Collections\ImmutableSegmentedDictionary`2+Enumerator.cs (1)
47readonly DictionaryEntry IDictionaryEnumerator.Entry => new(Current.Key, Current.Value);
src\Dependencies\Collections\SegmentedDictionary`2.cs (3)
911dictEntryArray[index++] = new DictionaryEntry(entries[i]._key, entries[i]._value); 1232return new DictionaryEntry(_current.Key, _current.Value); 1259return new DictionaryEntry(_current.Key, _current.Value);
Microsoft.CodeAnalysis.Workspaces.MSBuild.BuildHost (4)
src\Dependencies\Collections\ImmutableSegmentedDictionary`2+Enumerator.cs (1)
47readonly DictionaryEntry IDictionaryEnumerator.Entry => new(Current.Key, Current.Value);
src\Dependencies\Collections\SegmentedDictionary`2.cs (3)
911dictEntryArray[index++] = new DictionaryEntry(entries[i]._key, entries[i]._value); 1232return new DictionaryEntry(_current.Key, _current.Value); 1259return new DictionaryEntry(_current.Key, _current.Value);
MSBuild (1)
CopyOnWriteDictionary.cs (1)
363array.SetValue(new DictionaryEntry(entry.Key, entry.Value), index + i);
MSBuildTaskHost (2)
CopyOnWriteDictionary.cs (1)
363array.SetValue(new DictionaryEntry(entry.Key, entry.Value), index + i);
Immutable\ImmutableDictionary.cs (1)
106array.SetValue(new DictionaryEntry(item.Key, item.Value), arrayIndex++);
PresentationCore (7)
System\Windows\Media\CharacterMetricsDictionary.cs (4)
190typedArray[index++] = new SC.DictionaryEntry(item.Key, item.Value); 206array.SetValue(new SC.DictionaryEntry(item.Key, item.Value), index++); 559return new SC.DictionaryEntry(entry.Key, entry.Value); 585return new SC.DictionaryEntry(entry.Key, entry.Value);
System\Windows\Media\CultureSpecificStringDictionary.cs (3)
159typedArray[index++] = new SC.DictionaryEntry(item.Key, item.Value); 175array.SetValue(new SC.DictionaryEntry(item.Key, item.Value), index++); 404return new SC.DictionaryEntry(entry.Key, entry.Value);
PresentationFramework (2)
System\Windows\Markup\Localizer\BamlLocalizationDictionary.cs (1)
311DictionaryEntry entry = new(pair.Key, pair.Value);
System\Windows\ResourceDictionary.cs (1)
2156return new DictionaryEntry(key, value);
System.Collections (6)
System\Collections\Generic\OrderedDictionary.cs (2)
1410new DictionaryEntry(Current.Key, Current.Value) : 1414readonly DictionaryEntry IDictionaryEnumerator.Entry => new(Current.Key, Current.Value);
System\Collections\Generic\SortedDictionary.cs (2)
466return new DictionaryEntry(Current.Key, Current.Value); 510return new DictionaryEntry(Current.Key, Current.Value);
System\Collections\Generic\SortedList.cs (2)
819return new DictionaryEntry(_key!, _value); 836return new DictionaryEntry(_key!, _value);
System.Collections.Immutable (5)
System\Collections\Frozen\FrozenDictionary.cs (1)
390dictEntryArray[index++] = new DictionaryEntry(item.Key, item.Value);
System\Collections\Immutable\DictionaryEnumerator.cs (1)
21get { return new DictionaryEntry(_inner.Current.Key, _inner.Current.Value); }
System\Collections\Immutable\ImmutableDictionary_2.Builder.cs (1)
351array.SetValue(new DictionaryEntry(item.Key, item.Value), arrayIndex++);
System\Collections\Immutable\ImmutableDictionary_2.cs (1)
757array.SetValue(new DictionaryEntry(item.Key, item.Value), arrayIndex++);
System\Collections\Immutable\ImmutableSortedDictionary_2.Node.cs (1)
222array.SetValue(new DictionaryEntry(item.Key, item.Value), arrayIndex++);
System.Collections.NonGeneric (3)
System\Collections\SortedList.cs (3)
346DictionaryEntry entry = new DictionaryEntry(keys[i], values[i]); 847return new DictionaryEntry(_key, _value); 862return new DictionaryEntry(_key, _value);
System.Collections.Specialized (7)
System\Collections\Specialized\ListDictionary.cs (2)
215array.SetValue(new DictionaryEntry(node.key, node.value), index); 294return new DictionaryEntry(_current.key, _current.value);
System\Collections\Specialized\OrderedDictionary.cs (5)
171objectsArray[index] = new DictionaryEntry(key, value); 200objectsArray[IndexOfKey(key)] = new DictionaryEntry(key, value); 233objectsArray.Add(new DictionaryEntry(key, value)); 321objectsArray.Insert(index, new DictionaryEntry(key, value)); 486return new DictionaryEntry(((DictionaryEntry)_arrayEnumerator.Current).Key, ((DictionaryEntry)_arrayEnumerator.Current).Value);
System.ComponentModel.TypeConverter (1)
System\ComponentModel\PropertyDescriptorCollection.cs (1)
606return new DictionaryEntry(curProp.Name, curProp);
System.Diagnostics.Process (1)
System\Collections\Specialized\StringDictionaryWrapper.cs (1)
57yield return new DictionaryEntry(keyValuePair.Key, keyValuePair.Value);
System.Private.CoreLib (8)
src\libraries\System.Private.CoreLib\src\System\Collections\Hashtable.cs (3)
564DictionaryEntry entry = new DictionaryEntry(keyv, lbuckets[i].val); 1455return new DictionaryEntry(_currentKey!, _currentValue); 1471return new DictionaryEntry(_currentKey!, _currentValue);
src\libraries\System.Private.CoreLib\src\System\Collections\ListDictionaryInternal.cs (2)
162array.SetValue(new DictionaryEntry(node.key, node.value), index); 232return new DictionaryEntry(current.key, current.value);
src\libraries\System.Private.CoreLib\src\System\Collections\ObjectModel\ReadOnlyDictionary.cs (2)
189dictEntryArray[index++] = new DictionaryEntry(item.Key, item.Value); 227get => new DictionaryEntry(_enumerator.Current.Key, _enumerator.Current.Value);
src\libraries\System.Private.CoreLib\src\System\Resources\ResourceReader.cs (1)
1138return new DictionaryEntry(key, value);
System.Private.Xml (2)
System\Xml\Schema\XmlSchemaObjectTable.cs (2)
302return new DictionaryEntry(currentKey!, currentValue); 352return new DictionaryEntry(currentKey!, currentValue);
System.Resources.Extensions (1)
src\libraries\System.Private.CoreLib\src\System\Resources\ResourceReader.cs (1)
1138return new DictionaryEntry(key, value);
System.Windows.Forms (2)
misc\CollectionHelper.cs (2)
40dictionaryTarget[index++] = new DictionaryEntry(kvp.Key, kvp.Value); 57objects[index++] = new DictionaryEntry(kvp.Key, kvp.Value);
System.Windows.Forms.Design (1)
System\ComponentModel\Design\Serialization\StatementContext.cs (1)
228return new DictionaryEntry(entry.Owner, entry.Statements);
System.Xaml (1)
System\Xaml\Runtime\ClrObjectRuntime.cs (1)
765yield return new DictionaryEntry(enumerator.Current.Key, enumerator.Current.Value);