7 overrides of CanWrite
PresentationFramework (1)
MS\Internal\Data\IndexerPropertyInfo.cs (1)
39public override bool CanWrite
System.Private.CoreLib (2)
src\System\Reflection\Emit\RuntimePropertyBuilder.cs (1)
170public override bool CanWrite
src\System\Reflection\RuntimePropertyInfo.cs (1)
320public override bool CanWrite => m_setterMethod != null;
System.Reflection.Context (2)
System\Reflection\Context\Delegation\DelegatingPropertyInfo.cs (1)
29public override bool CanWrite
System\Reflection\Context\Virtual\VirtualPropertyBase.cs (1)
62public sealed override bool CanWrite
System.Reflection.MetadataLoadContext (1)
System\Reflection\TypeLoading\Properties\RoProperty.cs (1)
107public sealed override bool CanWrite => SetMethod != null;
System.Xaml.Tests (1)
System\Xaml\XamlMemberTests.cs (1)
2375public override bool CanWrite => DelegatingProperty.CanWrite;
55 references to CanWrite
dotnet-svcutil-lib (3)
FrameworkFork\Microsoft.Xml\Xml\Serialization\Models.cs (3)
221if (!propertyInfo.CanWrite && typeDesc.Kind != TypeKind.Collection && typeDesc.Kind != TypeKind.Enumerable) 302_checkSpecified = specifiedProperty.CanWrite ? SpecifiedAccessor.ReadWrite : SpecifiedAccessor.ReadOnly; 313_readOnly = !((PropertyInfo)memberInfo).CanWrite;
Microsoft.AspNetCore.App.Analyzers.Test (1)
Http\HeaderDictionaryIndexerAnalyzerTests.cs (1)
165.Where(p => p.CanWrite && p.CanRead && p.PropertyType == typeof(StringValues) && p.GetIndexParameters().Length == 0)
Microsoft.AspNetCore.Http.Extensions (2)
RequestDelegateFactory.cs (1)
1608if (properties[i].CanWrite && properties[i].GetSetMethod(nonPublic: false) != null)
src\Shared\PropertyAsParameterInfo.cs (1)
124if (property.CanWrite)
Microsoft.AspNetCore.Mvc.ApiExplorer (1)
src\Shared\PropertyAsParameterInfo.cs (1)
124if (property.CanWrite)
Microsoft.AspNetCore.Mvc.Core (1)
ModelBinding\Metadata\DefaultModelMetadataProvider.cs (1)
373if (propertyHelper.Property.CanWrite &&
Microsoft.AspNetCore.OpenApi (1)
src\Shared\PropertyAsParameterInfo.cs (1)
124if (property.CanWrite)
Microsoft.AspNetCore.Server.IntegrationTesting (1)
Common\DeploymentParameters.cs (1)
79if (propertyInfo.CanWrite)
Microsoft.CodeAnalysis.ExpressionEvaluator.ResultProvider.Utilities (1)
Debugger\MemberInfo\PropertyInfoImpl.cs (1)
41return this.Property.CanWrite;
Microsoft.CodeAnalysis.Test.Utilities (2)
Platform\Custom\MetadataSignatureHelper.cs (2)
543if (property.CanRead && property.CanWrite) 551else if (property.CanWrite)
Microsoft.Maui.Controls (6)
BindingExpression.cs (4)
278 if (pi.CanWrite && pi.SetMethod.ReturnType == typeof(int)) 291 if (pi.CanWrite && pi.SetMethod.ReturnType == typeof(string)) 302 if (pi.CanWrite && pi.SetMethod.ReturnType == typeof(object)) 399 if (property is { CanWrite: true, SetMethod: { IsPublic: true, IsStatic: false } propertySetMethod })
Shell\ShellContent.cs (2)
391 if (prop != null && prop.CanWrite && prop.SetMethod.IsPublic) 411 if (prop != null && prop.CanWrite && prop.SetMethod.IsPublic)
Microsoft.Maui.Controls.Xaml (1)
ApplyPropertiesVisitor.cs (1)
662 if (propertyInfo == null || !propertyInfo.CanWrite || (setter = propertyInfo.SetMethod) == null)
Microsoft.ML.Data (2)
Data\SchemaDefinition.cs (2)
166.Where(x => x.CanRead && x.CanWrite && x.GetGetMethod() != null && x.GetSetMethod() != null && x.GetIndexParameters().Length == 0) 342((direction & Direction.Write) == Direction.Write && (x.CanWrite && x.GetSetMethod() != null))) &&
Microsoft.ML.SearchSpace (1)
Parameter.cs (1)
195.Where(p => p.CanRead && p.CanWrite);
Microsoft.ML.Tests (1)
CollectionsDataViewTest.cs (1)
74if (!property.CanRead || !property.CanWrite || property.GetGetMethod() == null || property.GetSetMethod() == null)
Microsoft.VisualBasic.Core (1)
Microsoft\VisualBasic\CompilerServices\LateBinding.vb (1)
403If pi Is Nothing OrElse (Not pi.CanWrite) Then
PresentationBuildTasks (4)
src\Microsoft.DotNet.Wpf\src\PresentationFramework\System\Windows\Markup\XamlReaderHelper.cs (3)
3193propertyCanWrite = propInfo.CanWrite; 3512return propertyInfo.CanWrite; 3905if (pi.CanWrite)
src\Microsoft.DotNet.Wpf\src\PresentationFramework\System\Windows\Markup\XamlTypeMapper.cs (1)
2050propertyCanWrite = propertyInfo.CanWrite;
PresentationFramework (5)
MS\Internal\Data\PropertyPathWorker.cs (1)
1610if (!pi.CanWrite)
System\Windows\Controls\DataGridColumn.cs (1)
1213if (!pi.CanWrite)
System\Windows\Markup\BamlCollectionHolder.cs (1)
206(PropertyDefinition.PropertyInfo == null || !PropertyDefinition.PropertyInfo.CanWrite) &&
System\Windows\Markup\BamlWriter.cs (1)
645propertyCanWrite = pi.CanWrite;
System\Windows\Markup\XamlTypeMapper.cs (1)
2050propertyCanWrite = propertyInfo.CanWrite;
ReachFramework (3)
Serialization\Manager\MetroSerializationManager.cs (1)
1029bool isReadOnly = !propertyCache.PropertyInfo.CanWrite;
Serialization\Manager\ReachSerializableProperties.cs (1)
652isReadOnly = !((PropertyInfo)_propertyInfo.PropertyInfo).CanWrite;
Serialization\Manager\ReachSerializationCacheItems.cs (1)
244(propertyInfo.CanWrite || visibility == DesignerSerializationVisibility.Content))
System.ComponentModel.Composition (1)
System\ComponentModel\Composition\MetadataViewGenerator.cs (1)
305if (propertyInfo.CanWrite)
System.ComponentModel.TypeConverter (1)
System\ComponentModel\ComponentResourceManager.cs (1)
199if (prop != null && prop.CanWrite && (kvp.Value == null || prop.PropertyType.IsInstanceOfType(kvp.Value)))
System.Composition.TypedParts (1)
System\Composition\TypedParts\ActivationFeatures\PropertyInjectionFeature.cs (1)
31.Where(pi => pi.CanWrite && pi.SetMethod.IsPublic && !(pi.SetMethod.IsStatic))
System.Linq.Expressions (7)
System\Linq\Expressions\Compiler\LambdaCompiler.Address.cs (2)
262if (property is null || !property.CanWrite) 311if (node.Indexer == null || !node.Indexer.CanWrite)
System\Linq\Expressions\Expression.cs (2)
256if (indexer == null || indexer.CanWrite) 265if (prop.CanWrite)
System\Linq\Expressions\Interpreter\LightCompiler.cs (1)
2327if (property.CanWrite)
System\Linq\Expressions\MemberAssignment.cs (1)
100if (!pi.CanWrite)
System\Linq\Expressions\MemberExpression.cs (1)
322if (pi.CanWrite && CheckMethod(mi, pi.GetSetMethod(nonPublic: true)!))
System.Private.CoreLib (1)
src\System\Reflection\Emit\CustomAttributeBuilder.cs (1)
146if (!property.CanWrite)
System.Private.DataContractSerialization (1)
System\Runtime\Serialization\AccessorBuilder.cs (1)
101if (propInfo.CanWrite)
System.Private.Xml (3)
System\Xml\Serialization\Models.cs (3)
238if (!propertyInfo.CanWrite && typeDesc.Kind != TypeKind.Collection && typeDesc.Kind != TypeKind.Enumerable) 320_checkSpecified = specifiedProperty.CanWrite ? SpecifiedAccessor.ReadWrite : SpecifiedAccessor.ReadOnly; 331_readOnly = !((PropertyInfo)memberInfo).CanWrite;
System.Reflection.Context (1)
System\Reflection\Context\Delegation\DelegatingPropertyInfo.cs (1)
31get { return UnderlyingProperty.CanWrite; }
System.Windows.Forms.Primitives (1)
Windows\Win32\System\Ole\ClassPropertyDispatchAdapter.cs (1)
324FDEX_PROP_FLAGS flags = IDispatch.GetPropertyFlags(info.CanRead, info.CanWrite);
System.Xaml.Tests (1)
System\Xaml\XamlMemberTests.cs (1)
2375public override bool CanWrite => DelegatingProperty.CanWrite;