12 overrides of TypeHandle
System.Private.CoreLib (9)
src\libraries\System.Private.CoreLib\src\System\Reflection\Emit\SymbolType.cs (1)
341
public override RuntimeTypeHandle
TypeHandle
=> throw new NotSupportedException(SR.NotSupported_NonReflectedType);
src\libraries\System.Private.CoreLib\src\System\Reflection\Emit\TypeBuilderInstantiation.cs (1)
106
public override RuntimeTypeHandle
TypeHandle
=> throw new NotSupportedException();
src\libraries\System.Private.CoreLib\src\System\Reflection\ModifiedType.cs (1)
91
public override RuntimeTypeHandle
TypeHandle
=> throw new NotSupportedException(SR.NotSupported_ModifiedType);
src\libraries\System.Private.CoreLib\src\System\Reflection\SignatureType.cs (1)
205
public sealed override RuntimeTypeHandle
TypeHandle
=> throw new NotSupportedException(SR.NotSupported_SignatureType);
src\libraries\System.Private.CoreLib\src\System\Reflection\TypeDelegator.cs (1)
53
public override RuntimeTypeHandle
TypeHandle
=> typeImpl.TypeHandle;
src\libraries\System.Private.CoreLib\src\System\RuntimeType.cs (1)
27
public override RuntimeTypeHandle
TypeHandle
src\System\Reflection\Emit\RuntimeEnumBuilder.cs (1)
79
public override RuntimeTypeHandle
TypeHandle
=> m_typeBuilder.TypeHandle;
src\System\Reflection\Emit\RuntimeGenericTypeParameterBuilder.cs (1)
92
public override RuntimeTypeHandle
TypeHandle
=> throw new NotSupportedException();
src\System\Reflection\Emit\RuntimeTypeBuilder.cs (1)
651
public override RuntimeTypeHandle
TypeHandle
=> throw new NotSupportedException(SR.NotSupported_DynamicModule);
System.Reflection.Context (1)
System\Reflection\Context\Delegation\DelegatingType.cs (1)
150
public override RuntimeTypeHandle
TypeHandle
System.Reflection.Emit (1)
src\libraries\System.Private.CoreLib\src\System\Reflection\Emit\SymbolType.cs (1)
341
public override RuntimeTypeHandle
TypeHandle
=> throw new NotSupportedException(SR.NotSupported_NonReflectedType);
System.Reflection.MetadataLoadContext (1)
System\Reflection\TypeLoading\Types\RoType.cs (1)
372
public sealed override RuntimeTypeHandle
TypeHandle
=> throw new InvalidOperationException(SR.Arg_InvalidOperation_Reflection);
120 references to TypeHandle
dotnet-svcutil-lib (27)
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\DataContract.cs (5)
111
return GetDataContract(type.
TypeHandle
, type);
617
int id = DataContract.GetId(classContract.TypeForInitialization.
TypeHandle
);
801
if (Globals.TypeOfDateTimeOffset.
TypeHandle
.Equals(typeHandle))
803
return Globals.TypeOfDateTimeOffsetAdapter.
TypeHandle
;
1091
s_typeHandleRef.Value = GetDataContractAdapterTypeHandle(type.
TypeHandle
);
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\DataContractSerializer.cs (3)
338
context.SerializeWithoutXsiType(contract, writer, graph, declaredType.
TypeHandle
);
360
context.SerializeWithXsiTypeAtTopLevel(contract, writer, graph, declaredType.
TypeHandle
, graphType);
377
return DataContract.GetDataContract(objectType.
TypeHandle
, objectType, SerializationMode.SharedContract);
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\DataContractSet.cs (2)
269
return DataContract.GetGetOnlyCollectionDataContract(DataContract.GetId(dataMemberType.
TypeHandle
), dataMemberType.
TypeHandle
, dataMemberType, SerializationMode.SharedContract);
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\DataMember.cs (2)
277
_memberTypeContract = DataContract.GetGetOnlyCollectionDataContract(DataContract.GetId(MemberType.
TypeHandle
), MemberType.
TypeHandle
, MemberType, SerializationMode.SharedContract);
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\ExceptionDataContract.cs (1)
380
context.SerializeWithoutXsiType(propDataContract, writer, prop.GetValue(value), prop.PropertyType.
TypeHandle
);
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\XmlFormatReaderGenerator.cs (1)
474
_ilg.Load(DataContract.GetId(declaredType.
TypeHandle
));
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\XmlFormatWriterGenerator.cs (1)
628
_ilg.Load(DataContract.GetId(memberType.
TypeHandle
));
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\XmlObjectSerializerContext.cs (1)
127
return GetDataContract(type.
TypeHandle
, type);
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\XmlObjectSerializerReadContextComplex.cs (2)
105
dataContract = (declaredTypeID < 0) ? GetDataContract(declaredType) : GetDataContract(declaredTypeID, declaredType.
TypeHandle
);
115
dataContract = (declaredTypeID < 0) ? GetDataContract(declaredType) : GetDataContract(declaredTypeID, declaredType.
TypeHandle
);
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\XmlObjectSerializerWriteContext.cs (5)
118
SerializeWithXsiType(xmlWriter, obj, obj.GetType().
TypeHandle
, null/*type*/, -1, declaredType.
TypeHandle
, declaredType);
127
RuntimeTypeHandle objTypeHandle = obj.GetType().
TypeHandle
;
501
return obj.GetType().
TypeHandle
.Equals(memberType.
TypeHandle
);
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\XmlObjectSerializerWriteContextComplex.cs (4)
253
RuntimeTypeHandle objTypeHandle = isDeclaredType ? declaredTypeHandle : obj.GetType().
TypeHandle
;
259
declaredTypeHandle = declaredType.
TypeHandle
;
262
objTypeHandle = objType.
TypeHandle
;
269
SerializeWithXsiType(xmlWriter, obj, objTypeHandle, objType, -1, declaredType.
TypeHandle
, declaredType);
illink (1)
src\tools\illink\src\ILLink.Shared\TrimAnalysis\IntrinsicId.cs (1)
22
/// <see cref="System.Type.
TypeHandle
"/>
ILLink.RoslynAnalyzer (1)
src\tools\illink\src\ILLink.Shared\TrimAnalysis\IntrinsicId.cs (1)
22
/// <see cref="System.Type.
TypeHandle
"/>
PresentationFramework (6)
System\Windows\Markup\Baml2006\Baml2006Reader.cs (1)
1383
RuntimeHelpers.RunClassConstructor(currentType.
TypeHandle
);
System\Windows\Markup\RoutedEventConverter.cs (1)
114
RuntimeHelpers.RunClassConstructor(currentType.
TypeHandle
);
System\Windows\Markup\RoutedEventValueSerializer.cs (1)
46
RuntimeHelpers.RunClassConstructor(currentType.
TypeHandle
);
System\Windows\Markup\XamlReader.cs (1)
941
RuntimeHelpers.RunClassConstructor(typeof(Application).
TypeHandle
);
System\Windows\Markup\XamlTypeMapper.cs (1)
1999
RuntimeHelpers.RunClassConstructor(currentType.
TypeHandle
);
System\Windows\SystemResources.cs (1)
809
RuntimeHelpers.RunClassConstructor(knownTypeHelper.
TypeHandle
);
System.ComponentModel.TypeConverter (1)
System\ComponentModel\ReflectTypeDescriptionProvider.cs (1)
429
System.Runtime.CompilerServices.RuntimeHelpers.RunClassConstructor(editorBaseType.
TypeHandle
);
System.Private.CoreLib (27)
src\libraries\System.Private.CoreLib\src\System\Reflection\FieldAccessor.cs (2)
81
_methodTable = (MethodTable*)typeof(IntPtr).
TypeHandle
.Value;
109
_methodTable = (MethodTable*)typeof(IntPtr).
TypeHandle
.Value;
src\libraries\System.Private.CoreLib\src\System\Reflection\TypeDelegator.cs (1)
53
public override RuntimeTypeHandle TypeHandle => typeImpl.
TypeHandle
;
src\libraries\System.Private.CoreLib\src\System\Runtime\CompilerServices\RuntimeHelpers.cs (1)
154
=> new ReadOnlySpan<T>(ref Unsafe.As<byte, T>(ref GetSpanDataFrom(fldHandle, typeof(T).
TypeHandle
, out int length)), length);
src\libraries\System.Private.CoreLib\src\System\SR.cs (4)
84
RuntimeHelpers.RunClassConstructor(typeof(ResourceManager).
TypeHandle
);
85
RuntimeHelpers.RunClassConstructor(typeof(ResourceReader).
TypeHandle
);
86
RuntimeHelpers.RunClassConstructor(typeof(RuntimeResourceSet).
TypeHandle
);
87
RuntimeHelpers.RunClassConstructor(typeof(BinaryReader).
TypeHandle
);
src\libraries\System.Private.CoreLib\src\System\Type.cs (1)
477
return o.GetType().
TypeHandle
;
src\libraries\System.Private.CoreLib\src\System\TypedReference.cs (1)
87
return __reftype(value).
TypeHandle
;
src\System\GC.CoreCLR.cs (2)
824
AllocateNewArray(RuntimeTypeHandle.ToIntPtr(typeof(T[]).
TypeHandle
), length, flags, ObjectHandleOnStack.Create(ref result));
845
AllocateNewArray(RuntimeTypeHandle.ToIntPtr(typeof(T[]).
TypeHandle
), length, flags, ObjectHandleOnStack.Create(ref result));
src\System\Reflection\Emit\RuntimeModuleBuilder.cs (2)
1216
mr = GetMemberRefOfFieldInfo(tr, field.DeclaringType.
TypeHandle
, rtField);
1221
mr = GetMemberRefOfFieldInfo(tr, field.DeclaringType!.
TypeHandle
, rtField);
src\System\Reflection\Emit\SignatureHelper.cs (1)
545
IntPtr handle = type.
TypeHandle
.Value;
src\System\Reflection\MdFieldInfo.cs (1)
94
object? value = MdConstant.GetValue(GetRuntimeModule().MetadataImport, m_tkField, FieldType.
TypeHandle
, raw);
src\System\Reflection\RuntimeConstructorInfo.CoreCLR.cs (1)
211
RuntimeHelpers.RunClassConstructor(declaringType.
TypeHandle
);
src\System\Reflection\RuntimeModule.cs (1)
41
typeHandleArgs[i] = typeArg.
TypeHandle
;
src\System\Reflection\RuntimeParameterInfo.cs (1)
347
defaultValue = MdConstant.GetValue(m_scope, m_tkParamDef, ParameterType.
TypeHandle
, raw);
src\System\Reflection\RuntimePropertyInfo.cs (1)
214
object? defaultValue = MdConstant.GetValue(GetRuntimeModule().MetadataImport, m_token, PropertyType.
TypeHandle
, raw);
src\System\Runtime\CompilerServices\RuntimeHelpers.CoreCLR.cs (1)
1124
return new TypeHandle((void*)RuntimeTypeHandle.ToIntPtr(typeof(T).
TypeHandle
));
src\System\RuntimeHandles.cs (1)
217
outHandles[i] = inHandles[i].
TypeHandle
.Value;
src\System\RuntimeType.CoreCLR.cs (5)
2017
if (!RuntimeTypeHandle.SatisfiesConstraints(genericParameter.
TypeHandle
.GetRuntimeTypeChecked(),
2018
typeContext, methodContext, genericArgument.
TypeHandle
.GetRuntimeTypeChecked()))
3561
return GetRootElementType().
TypeHandle
.GetInstantiationInternal();
3566
Type[] types = GetRootElementType().
TypeHandle
.GetInstantiationPublic();
3653
GetRootElementType().
TypeHandle
.ContainsGenericVariables();
System.Private.DataContractSerialization (48)
System\Runtime\Serialization\DataContract.cs (7)
57
return GetDataContract(type.
TypeHandle
);
370
int id = DataContract.GetId(classContract.TypeForInitialization.
TypeHandle
);
565
if (Globals.TypeOfDateTimeOffset.
TypeHandle
.Equals(typeHandle))
567
return Globals.TypeOfDateTimeOffsetAdapter.
TypeHandle
;
569
if (Globals.TypeOfMemoryStream.
TypeHandle
.Equals(typeHandle))
571
return Globals.TypeOfMemoryStreamAdapter.
TypeHandle
;
933
RuntimeTypeHandle runtimeTypeHandle = GetDataContractAdapterTypeHandle(type.
TypeHandle
);
System\Runtime\Serialization\DataContractSerializer.cs (2)
397
context.SerializeWithoutXsiType(contract, writer, graph, declaredType.
TypeHandle
);
417
context.SerializeWithXsiTypeAtTopLevel(contract, writer, graph, declaredType.
TypeHandle
, graphType);
System\Runtime\Serialization\DataContractSet.cs (2)
281
return DataContract.GetGetOnlyCollectionDataContract(DataContract.GetId(dataMemberType.
TypeHandle
), dataMemberType.
TypeHandle
, dataMemberType);
System\Runtime\Serialization\DataMember.cs (2)
195
_memberTypeContract = DataContract.GetGetOnlyCollectionDataContract(DataContract.GetId(MemberType.
TypeHandle
), MemberType.
TypeHandle
, MemberType);
System\Runtime\Serialization\Json\DataContractJsonSerializer.cs (4)
517
context.SerializeWithoutXsiType(contract, writer, graph, declaredType.
TypeHandle
);
521
DataContractJsonSerializer.WriteJsonValue(JsonDataContract.GetJsonDataContract(contract), writer, graph, null, declaredType.
TypeHandle
); // XmlObjectSerializerWriteContextComplexJson
531
context.SerializeWithXsiTypeAtTopLevel(contract, writer, graph, declaredType.
TypeHandle
, graphType);
535
context.SerializeWithoutXsiType(contract, writer, graph, declaredType.
TypeHandle
);
System\Runtime\Serialization\Json\JsonDataContract.cs (1)
179
int id = JsonDataContractCriticalHelper.GetId(traditionalDataContract.UnderlyingType.
TypeHandle
);
System\Runtime\Serialization\Json\JsonFormatReaderGenerator.cs (1)
563
_ilg.Load(DataContract.GetId(declaredType.
TypeHandle
));
System\Runtime\Serialization\Json\JsonFormatWriterGenerator.cs (1)
712
_ilg.Load(DataContract.GetId(memberType.
TypeHandle
));
System\Runtime\Serialization\Json\ReflectionJsonFormatWriter.cs (1)
119
jsonDataContract!.WriteJsonValue(jsonWriter, current, context, collectionContract.ItemType.
TypeHandle
);
System\Runtime\Serialization\Json\XmlObjectSerializerWriteContextComplexJson.cs (2)
201
SerializeAndVerifyType(dataContract, xmlWriter, obj, verifyKnownType, declaredType.
TypeHandle
, declaredType);
259
SerializeAndVerifyType(dataContract, xmlWriter, obj, verifyKnownType, declaredType.
TypeHandle
, declaredType);
System\Runtime\Serialization\ReflectionClassWriter.cs (8)
62
ReflectionInternalSerialize(xmlWriter, context, memberValue, memberValue.GetType().
TypeHandle
.Equals(memberType.
TypeHandle
), writeXsiType, memberType);
102
ReflectionInternalSerialize(xmlWriter, context, memberValue!, memberValue!.GetType().
TypeHandle
.Equals(memberType.
TypeHandle
), writeXsiType, memberType, originValueIsNullableOfT);
172
context.InternalSerialize(xmlWriter, obj, isDeclaredType, writeXsiType, DataContract.GetId(memberType.
TypeHandle
), memberType.
TypeHandle
);
176
context.InternalSerializeReference(xmlWriter, obj, isDeclaredType, writeXsiType, DataContract.GetId(memberType.
TypeHandle
), memberType.
TypeHandle
);
System\Runtime\Serialization\ReflectionReader.cs (2)
395
return context.InternalDeserialize(xmlReader, DataContract.GetId(type.
TypeHandle
), type.
TypeHandle
, name, ns);
System\Runtime\Serialization\XmlFormatReaderGenerator.cs (1)
600
_ilg.Load(DataContract.GetId(declaredType.
TypeHandle
));
System\Runtime\Serialization\XmlFormatWriterGenerator.cs (1)
724
_ilg.Load(DataContract.GetId(memberType.
TypeHandle
));
System\Runtime\Serialization\XmlObjectSerializerContext.cs (1)
102
return GetDataContract(type.
TypeHandle
, type);
System\Runtime\Serialization\XmlObjectSerializerWriteContext.cs (8)
100
SerializeWithXsiType(xmlWriter, obj, obj.GetType().
TypeHandle
, null/*type*/, -1, declaredType.
TypeHandle
, declaredType);
109
RuntimeTypeHandle objTypeHandle = obj.GetType().
TypeHandle
;
446
return obj.GetType().
TypeHandle
.Equals(memberType.
TypeHandle
);
568
InternalSerializeReference(xmlWriter, obj, false /*isDeclaredType*/, false /*writeXsiType*/, -1, Globals.TypeOfObject.
TypeHandle
);
731
InternalSerialize(xmlWriter, o, false /*isDeclaredType*/, false /*writeXsiType*/, -1, o.GetType().
TypeHandle
);
749
InternalSerialize(xmlWriter, o, false /*isDeclaredType*/, false /*writeXsiType*/, -1, declaredType.
TypeHandle
);
System\Runtime\Serialization\XmlObjectSerializerWriteContextComplex.cs (4)
223
RuntimeTypeHandle objTypeHandle = isDeclaredType ? declaredTypeHandle : obj.GetType().
TypeHandle
;
229
declaredTypeHandle = declaredType.
TypeHandle
;
232
objTypeHandle = objType.
TypeHandle
;
239
SerializeWithXsiType(xmlWriter, obj, objTypeHandle, objType, -1, declaredType.
TypeHandle
, declaredType);
System.Reflection.Context (1)
System\Reflection\Context\Delegation\DelegatingType.cs (1)
152
get { return _typeInfo.
TypeHandle
; }
System.Runtime.InteropServices (5)
System\Runtime\InteropServices\Marshalling\ComInterfaceMarshaller.cs (1)
24
private static readonly Guid? TargetInterfaceIID = StrategyBasedComWrappers.DefaultIUnknownInterfaceDetailsStrategy.GetIUnknownDerivedDetails(typeof(T).
TypeHandle
)?.Iid;
System\Runtime\InteropServices\Marshalling\ComObject.cs (1)
155
if (!LookUpVTableInfo(type.
TypeHandle
, out IIUnknownCacheStrategy.TableInfo result, out int qiHResult))
System\Runtime\InteropServices\Marshalling\ComVariantMarshaller.cs (1)
103
else if (managed is not null && StrategyBasedComWrappers.DefaultIUnknownInterfaceDetailsStrategy.GetComExposedTypeDetails(managed.GetType().
TypeHandle
) is not null)
System\Runtime\InteropServices\Marshalling\DefaultCaching.cs (1)
24
ManagedType = details.Implementation.
TypeHandle
System\Runtime\InteropServices\Marshalling\StrategyBasedComWrappers.cs (1)
79
if (GetOrCreateInterfaceDetailsStrategy().GetComExposedTypeDetails(obj.GetType().
TypeHandle
) is { } details)
System.Windows.Forms (3)
System\Windows\Forms\Accessibility\AccessibleObject.cs (3)
315
RuntimeTypeHandle type = GetType().
TypeHandle
;
316
return type.Equals(typeof(AccessibleObject).
TypeHandle
)
317
|| type.GetModuleHandle().Equals(typeof(AccessibleObject).
TypeHandle
.GetModuleHandle());