100 references to SetValue
Microsoft.AspNetCore.Components (1)
Reflection\PropertySetter.cs (1)
43_setterDelegate = property.SetValue;
Microsoft.AspNetCore.Components.Endpoints (1)
src\Shared\PropertyHelper\PropertyHelper.cs (1)
306return propertyInfo.SetValue;
Microsoft.AspNetCore.Http.Abstractions (1)
src\Shared\PropertyHelper\PropertyHelper.cs (1)
306return propertyInfo.SetValue;
Microsoft.AspNetCore.Mvc.Core (1)
src\Shared\PropertyHelper\PropertyHelper.cs (1)
306return propertyInfo.SetValue;
Microsoft.AspNetCore.Mvc.TagHelpers.Test (6)
AnchorTagHelperTest.cs (2)
508typeof(AnchorTagHelper).GetProperty(propertyName).SetValue(anchorTagHelper, "Home"); 544typeof(AnchorTagHelper).GetProperty(propertyName).SetValue(anchorTagHelper, "Home");
FormActionTagHelperTest.cs (2)
532typeof(FormActionTagHelper).GetProperty(propertyName).SetValue(tagHelper, "Home"); 567typeof(FormActionTagHelper).GetProperty(propertyName).SetValue(tagHelper, "Home");
FormTagHelperTest.cs (2)
1029typeof(FormTagHelper).GetProperty(propertyName).SetValue(formTagHelper, "Home"); 1060typeof(FormTagHelper).GetProperty(propertyName).SetValue(formTagHelper, "Home");
Microsoft.AspNetCore.Routing (1)
src\Shared\PropertyHelper\PropertyHelper.cs (1)
306return propertyInfo.SetValue;
Microsoft.AspNetCore.Routing.Abstractions (1)
src\Shared\PropertyHelper\PropertyHelper.cs (1)
306return propertyInfo.SetValue;
Microsoft.AspNetCore.Server.IntegrationTesting (1)
Common\DeploymentParameters.cs (1)
81propertyInfo.SetValue(this, propertyInfo.GetValue(parameters));
Microsoft.AspNetCore.Shared.Tests (1)
src\Shared\PropertyHelper\PropertyHelper.cs (1)
306return propertyInfo.SetValue;
Microsoft.AspNetCore.SignalR.Client.Tests (1)
HttpConnectionFactoryTests.cs (1)
112property.SetValue(options, testValues[property.Name]);
Microsoft.Build (2)
PrintLineDebugger.cs (2)
87CommonWriterProperty.Value.SetValue(null, (CommonWriterType)LockWrappedWriter); 108CommonWriterProperty.Value.SetValue(null, null);
Microsoft.Build.Engine.OM.UnitTests (2)
PrintLineDebugger.cs (2)
87CommonWriterProperty.Value.SetValue(null, (CommonWriterType)LockWrappedWriter); 108CommonWriterProperty.Value.SetValue(null, null);
Microsoft.Build.Engine.UnitTests (3)
BackEnd\FailingTask.cs (1)
17BuildEngine.GetType().GetProperty("AllowFailureWithoutError").SetValue(BuildEngine, AllowFailureWithoutError.Equals("True"));
Telemetry\OpenTelemetryManager_Tests.cs (1)
139defaultSourceProp?.SetValue(instance, null);
Telemetry\Telemetry_Tests.cs (1)
194?.SetValue(instance, null);
Microsoft.Build.Tasks.CodeAnalysis.UnitTests (1)
VbcTests.cs (1)
483typeof(Vbc).GetProperty("UsedCommandLineTool", System.Reflection.BindingFlags.Instance | System.Reflection.BindingFlags.NonPublic)?.SetValue(vbc, true);
Microsoft.Build.Tasks.Core (2)
PrintLineDebugger.cs (2)
87CommonWriterProperty.Value.SetValue(null, (CommonWriterType)LockWrappedWriter); 108CommonWriterProperty.Value.SetValue(null, null);
Microsoft.Build.Utilities.Core (2)
PrintLineDebugger.cs (2)
87CommonWriterProperty.Value.SetValue(null, (CommonWriterType)LockWrappedWriter); 108CommonWriterProperty.Value.SetValue(null, null);
Microsoft.Extensions.AI.Abstractions.Tests (8)
Utilities\AIJsonUtilitiesTests.cs (8)
96property.SetValue(options1, !booleanFlag); 97property.SetValue(options2, !booleanFlag); 102property.SetValue(options1, transformer); 103property.SetValue(options2, transformer); 108property.SetValue(options1, includeParameter); 109property.SetValue(options2, includeParameter); 114property.SetValue(options1, transformOptions); 115property.SetValue(options2, transformOptions);
Microsoft.Extensions.Configuration.Binder (2)
ConfigurationBinder.cs (2)
285property.SetValue(instance, property.GetValue(instance)); 317property.SetValue(instance, propertyBindingPoint.Value);
Microsoft.Extensions.Validation.GeneratorTests (35)
ValidationsGenerator.ValidatableType.cs (35)
101type.GetProperty("IntegerWithRange")?.SetValue(instance, 5); 120type.GetProperty("IntegerWithRangeAndDisplayName")?.SetValue(instance, 5); 139type.GetProperty("PropertyWithMemberAttributes")?.SetValue(instance, null); 159subType.GetType().GetProperty("RequiredProperty")?.SetValue(subType, ""); 160subType.GetType().GetProperty("StringWithLength")?.SetValue(subType, "way-too-long"); 161type.GetProperty("PropertyWithMemberAttributes")?.SetValue(instance, subType); 187inheritanceType.GetType().GetProperty("RequiredProperty")?.SetValue(inheritanceType, ""); 188inheritanceType.GetType().GetProperty("StringWithLength")?.SetValue(inheritanceType, "way-too-long"); 189inheritanceType.GetType().GetProperty("EmailString")?.SetValue(inheritanceType, "not-an-email"); 190type.GetProperty("PropertyWithInheritance")?.SetValue(instance, inheritanceType); 224subType1.GetType().GetProperty("RequiredProperty")?.SetValue(subType1, ""); 225subType1.GetType().GetProperty("StringWithLength")?.SetValue(subType1, "way-too-long"); 229subType2.GetType().GetProperty("RequiredProperty")?.SetValue(subType2, "valid"); 230subType2.GetType().GetProperty("StringWithLength")?.SetValue(subType2, "way-too-long"); 234subType3.GetType().GetProperty("RequiredProperty")?.SetValue(subType3, "valid"); 235subType3.GetType().GetProperty("StringWithLength")?.SetValue(subType3, "valid"); 242type.GetProperty("ListOfSubTypes")?.SetValue(instance, subTypeList); 272type.GetProperty("IntegerWithCustomValidationAttribute")?.SetValue(instance, 5); // Odd number, should fail 291type.GetProperty("PropertyWithMultipleAttributes")?.SetValue(instance, 5); 318type.GetProperty("IntegerWithCustomValidationAttribute")?.SetValue(instance, 3); // Odd number should fail 339type.GetProperty("IntegerWithRange")?.SetValue(instance, 50); 340type.GetProperty("IntegerWithRangeAndDisplayName")?.SetValue(instance, 50); 344subType1.GetType().GetProperty("RequiredProperty")?.SetValue(subType1, "valid"); 345subType1.GetType().GetProperty("StringWithLength")?.SetValue(subType1, "valid"); 346type.GetProperty("PropertyWithMemberAttributes")?.SetValue(instance, subType1); 350subType2.GetType().GetProperty("RequiredProperty")?.SetValue(subType2, "valid"); 351subType2.GetType().GetProperty("StringWithLength")?.SetValue(subType2, "valid"); 352type.GetProperty("PropertyWithoutMemberAttributes")?.SetValue(instance, subType2); 356inheritanceType.GetType().GetProperty("RequiredProperty")?.SetValue(inheritanceType, "valid"); 357inheritanceType.GetType().GetProperty("StringWithLength")?.SetValue(inheritanceType, "valid"); 358inheritanceType.GetType().GetProperty("EmailString")?.SetValue(inheritanceType, "test@example.com"); 359type.GetProperty("PropertyWithInheritance")?.SetValue(instance, inheritanceType); 363type.GetProperty("ListOfSubTypes")?.SetValue(instance, emptyList); 366type.GetProperty("IntegerWithCustomValidationAttribute")?.SetValue(instance, 2); // Even number should pass 367type.GetProperty("PropertyWithMultipleAttributes")?.SetValue(instance, 12);
Microsoft.Maui.Controls (3)
Shell\ShellContent.cs (3)
398 prop.SetValue(content, value); 403 prop.SetValue(content, castValue); 412 prop.SetValue(content, null);
Microsoft.ML.Data (1)
Data\SchemaDefinition.cs (1)
191cursorChannelAttrPropertyInfo.SetValue(obj, channel);
Microsoft.ML.Tokenizers.Tests (2)
LlamaTests.cs (2)
72propertyInfo.SetValue(tokenizer, true); 78propertyInfo.SetValue(tokenizer.Normalizer, true);
MSBuild (2)
PrintLineDebugger.cs (2)
87CommonWriterProperty.Value.SetValue(null, (CommonWriterType)LockWrappedWriter); 108CommonWriterProperty.Value.SetValue(null, null);
PresentationFramework (1)
MS\Internal\WindowsRuntime\Generated\WinRT\ExceptionHelpers.cs (1)
355ex.GetType().GetProperty("HResult").SetValue(ex, value);
System.Composition.TypedParts (1)
System\Composition\CompositionContextExtensions.cs (1)
62pi.SetValue(objectWithLooseImports, value);
System.Linq.Expressions (1)
System\Linq\Expressions\Interpreter\LightCompiler.cs (1)
3228_property.SetValue(obj, value);
System.Private.DataContractSerialization (1)
System\Runtime\Serialization\AccessorBuilder.cs (1)
137propInfo.SetValue(obj, val);
System.Private.Windows.Core.TestUtilities (1)
TestAccessor.cs (1)
206propertyInfo.SetValue(_instance, value);
System.Private.Xml (2)
System\Xml\Serialization\ReflectionXmlSerializationReader.cs (2)
619result = new ReflectionXmlSerializationReaderHelper.SetMemberValueDelegate(propInfo.SetValue); 2121return propInfo.SetValue;
System.Windows.Forms.Design.Tests (1)
System\Windows\Forms\Design\ToolStripEditorManagerTests.cs (1)
201boundsProperty.SetValue(_toolStripEditorControl, newBounds);
System.Windows.Forms.Tests (12)
MaskedTextBoxTests.cs (2)
717property.SetValue(maskedTextBox, value); 721property.SetValue(maskedTextBox, !value);
System\Windows\Forms\AccessibleObjects\Control.ControlAccessibleObjectTests.cs (4)
1688control.GetType().GetProperty(nameof(Label.UseMnemonic)).SetValue(control, false); 1709control.GetType().GetProperty(nameof(Label.UseMnemonic)).SetValue(control, true); 1731control.GetType().GetProperty(nameof(Label.UseMnemonic)).SetValue(control, false); 1739control.GetType().GetProperty(nameof(Label.UseMnemonic)).SetValue(control, true);
System\Windows\Forms\DataGridViewButtonColumnTests.cs (2)
59_column.GetType().GetProperty("CellTemplate")!.SetValue(_column, null); 102_column.GetType().GetProperty("CellTemplate")!.SetValue(_column, null);
System\Windows\Forms\ToolStripLabelTests.cs (1)
234property!.SetValue(_toolStripLabel, color);
ToolStripContainerTests.cs (3)
49propertyInfo.SetValue(_toolStripContainer, value); 225propertyInfo.SetValue(_toolStripContainer, true); 229propertyInfo.SetValue(_toolStripContainer, false);