1 write to Attribute
Microsoft.AspNetCore.Components (1)
CascadingParameterInfo.cs (1)
28Attribute = attribute;
16 references to Attribute
Microsoft.AspNetCore.Components (7)
CascadingParameterState.cs (2)
60if (info.Attribute.SingleDelivery) 68throw new InvalidOperationException($"'{info.Attribute.GetType()}' is flagged with SingleDelivery, but the selected supplier '{supplier.GetType()}' is not flagged with {nameof(ICascadingValueSupplier.IsFixed)}");
CascadingValue.cs (1)
131if (parameterInfo.Attribute is not CascadingParameterAttribute cascadingParameterAttribute || !parameterInfo.PropertyType.IsAssignableFrom(typeof(TValue)))
CascadingValueSource.cs (1)
141if (parameterInfo.Attribute is not CascadingParameterAttribute cascadingParameterAttribute || !parameterInfo.PropertyType.IsAssignableFrom(typeof(TValue)))
Rendering\ComponentState.cs (1)
196if (!param.ParameterInfo.Attribute.SingleDelivery)
Routing\SupplyParameterFromQueryValueProvider.cs (2)
24=> parameterInfo.Attribute is SupplyParameterFromQueryAttribute; 30var attribute = (SupplyParameterFromQueryAttribute)parameterInfo.Attribute; // Must be a valid cast because we check in CanSupplyValue
Microsoft.AspNetCore.Components.Tests (3)
CascadingParameterStateTest.cs (1)
487=> parameterInfo.Attribute is SupplyParameterWithSingleDeliveryAttribute;
CascadingParameterTest.cs (2)
886=> parameterInfo.Attribute is SingleDeliveryCascadingParameterAttribute; 1046if (parameterInfo.Attribute is not TAttribute ||
Microsoft.AspNetCore.Components.Web (6)
Forms\Mapping\SupplyParameterFromFormValueProvider.cs (6)
35if (parameterInfo.Attribute is CascadingParameterAttribute && parameterInfo.PropertyType == typeof(FormMappingContext)) 41if (_formValueMapper is not null && parameterInfo.Attribute is SupplyParameterFromFormAttribute supplyParameterFromFormAttribute) 52if (parameterInfo.Attribute is CascadingParameterAttribute && parameterInfo.PropertyType == typeof(FormMappingContext)) 58if (_formValueMapper is { } valueMapper && parameterInfo.Attribute is SupplyParameterFromFormAttribute) 63throw new InvalidOperationException($"Received an unexpected attribute type {parameterInfo.Attribute.GetType()}"); 76var attribute = (SupplyParameterFromFormAttribute)parameterInfo.Attribute; // Must be a valid cast because we check in CanSupplyValue