9 references to IsUsableDuringInitialization
System.Xaml (3)
System\Xaml\Context\ObjectWriterContext.cs (1)
373
&& lowerFrame.XamlType is not null && !lowerFrame.XamlType.
IsUsableDuringInitialization
)
System\Xaml\InfosetObjects\XamlObjectWriter.cs (1)
1786
if (type.
IsUsableDuringInitialization
&& !inDictionary)
System\Xaml\XamlType.cs (1)
1354
return BaseType.
IsUsableDuringInitialization
;
System.Xaml.Tests (6)
System\Xaml\XamlTypeTests.cs (6)
4534
Assert.Equal(expected, type.
IsUsableDuringInitialization
);
4548
Assert.Throws<NullReferenceException>(() => type.
IsUsableDuringInitialization
);
4562
Assert.Throws<NullReferenceException>(() => type.
IsUsableDuringInitialization
);
4576
Assert.Throws<InvalidCastException>(() => type.
IsUsableDuringInitialization
);
4587
Assert.Throws<XamlSchemaException>(() => type.
IsUsableDuringInitialization
);
4612
Assert.Throws<XamlSchemaException>(() => type.
IsUsableDuringInitialization
);