3 writes to _reflector
System.Xaml (3)
System\Xaml\XamlType.cs (3)
57
_reflector
= TypeReflector.UnknownReflector;
74
_reflector
= reflector ?? new TypeReflector(underlyingType);
1397
Interlocked.CompareExchange(ref
_reflector
, reflector, null);
125 references to _reflector
System.Xaml (125)
System\Xaml\XamlType.cs (125)
79
_reflector
.Invoker = invoker;
87
if (!
_reflector
.BaseTypeIsSet)
89
_reflector
.BaseType = LookupBaseType();
91
return
_reflector
.BaseType;
100
if (
_reflector
.Invoker == null)
102
_reflector
.Invoker = LookupInvoker() ?? XamlTypeInvoker.UnknownInvoker;
104
return
_reflector
.Invoker;
125
return
_reflector
.IsUnknown;
199
Debug.Assert(
_reflector
!= null, "_reflector should have been initialized by IsDictionary");
200
if (
_reflector
.KeyType == null)
202
_reflector
.KeyType = LookupKeyType() ?? XamlLanguage.Object;
204
return
_reflector
.KeyType;
216
Debug.Assert(
_reflector
!= null, "_reflector should have been initialized by GetCollectionKind");
217
if (
_reflector
.ItemType == null)
219
_reflector
.ItemType = LookupItemType() ?? XamlLanguage.Object;
221
return
_reflector
.ItemType;
235
Debug.Assert(
_reflector
!= null, "_reflector should have been initialized by GetCollectionKind");
236
if (
_reflector
.AllowedContentTypes == null)
238
_reflector
.AllowedContentTypes = LookupAllowedContentTypes() ??
241
return
_reflector
.AllowedContentTypes;
253
Debug.Assert(
_reflector
!= null, "_reflector should have been initialized by IsCollection");
254
if (
_reflector
.ContentWrappers == null)
256
_reflector
.ContentWrappers = LookupContentWrappers() ??
259
return
_reflector
.ContentWrappers;
268
if (!
_reflector
.TypeConverterIsSet)
270
_reflector
.TypeConverter = LookupTypeConverter();
272
return
_reflector
.TypeConverter;
281
if (!
_reflector
.ValueSerializerIsSet)
283
_reflector
.ValueSerializer = LookupValueSerializer();
285
return
_reflector
.ValueSerializer;
294
if (!
_reflector
.ContentPropertyIsSet)
296
_reflector
.ContentProperty = LookupContentProperty();
298
return
_reflector
.ContentProperty;
307
if (!
_reflector
.DeferringLoaderIsSet)
309
_reflector
.DeferringLoader = LookupDeferringLoader();
311
return
_reflector
.DeferringLoader;
323
Debug.Assert(
_reflector
!= null, "_reflector should have been initialized by IsMarkupExtension");
324
if (
_reflector
.MarkupExtensionReturnType == null)
326
_reflector
.MarkupExtensionReturnType = LookupMarkupExtensionReturnType() ?? XamlLanguage.Object;
328
return
_reflector
.MarkupExtensionReturnType;
338
if (!
_reflector
.Members.TryGetValue(name, out result) && !
_reflector
.Members.IsComplete)
341
result =
_reflector
.Members.TryAdd(name, result);
349
if (!
_reflector
.Members.IsComplete)
356
_reflector
.Members.TryAdd(member.Name, member);
359
_reflector
.Members.IsComplete = true;
363
return
_reflector
.Members.Values;
372
if (!
_reflector
.TryGetAliasedProperty(directive, out result))
375
_reflector
.TryAddAliasedProperty(directive, result);
384
if (!
_reflector
.AttachableMembers.TryGetValue(name, out result) &&
385
!
_reflector
.AttachableMembers.IsComplete)
388
result =
_reflector
.AttachableMembers.TryAdd(name, result);
396
if (!
_reflector
.AttachableMembers.IsComplete)
403
_reflector
.AttachableMembers.TryAdd(member.Name, member);
406
_reflector
.AttachableMembers.IsComplete = true;
408
return
_reflector
.AttachableMembers.Values;
449
if (!
_reflector
.TryGetPositionalParameters(parameterCount, out result))
452
result =
_reflector
.TryAddPositionalParameters(parameterCount, result);
498
Debug.Assert(
_reflector
!= null, "_reflector should have been initialized by ItemType");
499
if (!
_reflector
.IsReadOnlyMethodIsSet)
503
_reflector
.IsReadOnlyMethod = CollectionReflector.
508
_reflector
.IsReadOnlyMethod = null;
511
return
_reflector
.IsReadOnlyMethod;
519
if (!
_reflector
.XamlSetMarkupExtensionHandlerIsSet)
521
_reflector
.XamlSetMarkupExtensionHandler = LookupSetMarkupExtensionHandler();
523
return
_reflector
.XamlSetMarkupExtensionHandler;
532
if (!
_reflector
.XamlSetTypeConverterHandlerIsSet)
534
_reflector
.XamlSetTypeConverterHandler = LookupSetTypeConverterHandler();
536
return
_reflector
.XamlSetTypeConverterHandler;
549
if (!
_reflector
.AddMethodIsSet)
552
_reflector
.AddMethod = CollectionReflector.LookupAddMethod(UnderlyingType, collectionKind);
554
return
_reflector
.AddMethod;
566
Debug.Assert(
_reflector
!= null, "_reflector should have been initialized by GetCollectionKind");
567
if (!
_reflector
.GetEnumeratorMethodIsSet)
569
_reflector
.GetEnumeratorMethod = CollectionReflector.GetEnumeratorMethod(UnderlyingType);
571
return
_reflector
.GetEnumeratorMethod;
602
if (
_reflector
.ExcludedReadOnlyMembers == null)
604
_reflector
.ExcludedReadOnlyMembers = LookupAllExcludedReadOnlyMembers() ?? EmptyList<XamlMember>.Value;
606
return
_reflector
.ExcludedReadOnlyMembers;
731
_reflector
.AddMethod = addMethod;
775
Debug.Assert(
_reflector
!= null, "_reflector should have been initialized by AreAttributesAvailable");
776
List<Type> wrapperTypes =
_reflector
.GetAllAttributeContents<Type>(typeof(ContentWrapperAttribute));
812
Debug.Assert(
_reflector
!= null, "_reflector should have been initialized by AreAttributesAvailable");
813
Type[] loaderTypes =
_reflector
.GetAttributeTypes(typeof(XamlDeferLoadAttribute), 2);
886
if (
_reflector
!= null)
888
return
_reflector
.IsUnknown;
897
Debug.Assert(
_reflector
!= null, "_reflector should have been initialized by AreAttributesAvailable");
898
if (
_reflector
.IsAttributePresent(typeof(WhitespaceSignificantCollectionAttribute)))
909
Debug.Assert(
_reflector
!= null, "_reflector should have been initialized by AreAttributesAvailable");
910
return
_reflector
.GetFlag(BoolTypeBits.WhitespaceSignificantCollection).Value;
967
Debug.Assert(
_reflector
!= null, "_reflector should have been initialized by AreAttributesAvailable");
968
Type returnType =
_reflector
.GetAttributeType(typeof(MarkupExtensionReturnTypeAttribute));
989
return
_reflector
.LookupAllAttachableMembers(SchemaContext);
1003
_reflector
.LookupAllMembers(out properties, out events, out result);
1041
PropertyInfo pi =
_reflector
.LookupProperty(name);
1052
EventInfo ei =
_reflector
.LookupEvent(name);
1069
if (
_reflector
.LookupAttachableProperty(name, out getter, out setter))
1078
setter =
_reflector
.LookupAttachableEvent(name);
1098
if (
_reflector
.ReflectedPositionalParameters == null)
1100
_reflector
.ReflectedPositionalParameters = LookupAllPositionalParameters();
1103
_reflector
.ReflectedPositionalParameters.TryGetValue(parameterCount, out result);
1131
Debug.Assert(
_reflector
!= null, "_reflector should have been initialized by AreAttributesAvailable");
1132
if (
_reflector
.IsAttributePresent(typeof(AmbientAttribute)))
1143
Debug.Assert(
_reflector
!= null, "_reflector should have been initialized by AreAttributesAvailable");
1144
return
_reflector
.GetFlag(BoolTypeBits.Ambient).Value;
1153
Debug.Assert(
_reflector
!= null, "_reflector should have been initialized by AreAttributesAvailable");
1154
Type converterType =
_reflector
.GetAttributeType(typeof(TypeConverterAttribute));
1197
Debug.Assert(
_reflector
!= null, "_reflector should have been initialized by AreAttributesAvailable");
1198
Type converterType =
_reflector
.GetAttributeType(typeof(ValueSerializerAttribute));
1239
Debug.Assert(
_reflector
!= null, "_reflector should have been initialized by AreAttributesAvailable");
1240
if (
_reflector
.IsAttributePresent(typeof(TrimSurroundingWhitespaceAttribute)))
1256
Debug.Assert(
_reflector
!= null, "_reflector should have been initialized by AreAttributesAvailable");
1257
bool? usable =
_reflector
.GetAttributeValue<bool>(typeof(UsableDuringInitializationAttribute));
1325
if (!
_reflector
.CustomAttributeProviderIsSet)
1327
_reflector
.CustomAttributeProvider = LookupCustomAttributeProvider();
1330
return
_reflector
.CustomAttributeProvider != null || UnderlyingTypeInternal.Value != null;
1403
if (
_reflector
== null)
1412
if (!
_reflector
.CollectionKindIsSet)
1414
_reflector
.CollectionKind = LookupCollectionKind();
1416
return
_reflector
.CollectionKind;
1422
bool? result =
_reflector
.GetFlag(flagBit);
1426
_reflector
.SetFlag(flagBit, result.Value);
1545
IList<PropertyInfo> excludedMembers =
_reflector
.LookupRemainingProperties();
1691
Debug.Assert(
_reflector
!= null, "_reflector should have been initialized by AreAttributesAvailable");
1695
result =
_reflector
.GetAttributeString(attributeType, out checkedInherited);