104 references to RuntimeModule
System.Private.CoreLib (104)
src\libraries\System.Private.CoreLib\src\System\Runtime\CompilerServices\QCallHandles.cs (1)
87internal QCallModule(ref Reflection.RuntimeModule module)
src\libraries\System.Private.CoreLib\src\System\Runtime\InteropServices\TypeMapLazyDictionary.cs (10)
144context->ExternalTypeMap.AddPreCachedModule((RuntimeModule)context->CurrentAssembly.ManifestModule); 163context->ProxyTypeMap.AddPreCachedModule((RuntimeModule)context->CurrentAssembly.ManifestModule); 305protected readonly List<RuntimeModule> _preCachedModules = []; 309protected abstract bool TryGetOrLoadTypeFromPreCachedDictionary(RuntimeModule module, TKey key, [NotNullWhen(true)] out Type? type); 315foreach (RuntimeModule module in _preCachedModules) 337public void AddPreCachedModule(RuntimeModule module) 344foreach (RuntimeModule module in _preCachedModules) 414protected override bool TryGetOrLoadTypeFromPreCachedDictionary(RuntimeModule module, string key, [NotNullWhen(true)] out Type? type) 447foreach (RuntimeModule module in _preCachedModules) 488protected override bool TryGetOrLoadTypeFromPreCachedDictionary(RuntimeModule module, Type key, [NotNullWhen(true)] out Type? type)
src\libraries\System.Private.CoreLib\src\System\RuntimeType.cs (1)
189internal RuntimeModule GetRuntimeModule() => RuntimeTypeHandle.GetModule(this);
src\System\Reflection\Emit\DynamicILGenerator.cs (2)
25internal void GetCallableMethod(RuntimeModule module, DynamicMethod dm) 886internal void GetCallableMethod(RuntimeModule module, DynamicMethod dm)
src\System\Reflection\Emit\DynamicMethod.CoreCLR.cs (2)
74_dynamicILInfo.GetCallableMethod((RuntimeModule)_module, this); 80_ilGenerator.GetCallableMethod((RuntimeModule)_module, this);
src\System\Reflection\Emit\RuntimeAssemblyBuilder.cs (1)
100_manifestModuleBuilder = new RuntimeModuleBuilder(this, (RuntimeModule)InternalAssembly.ManifestModule);
src\System\Reflection\Emit\RuntimeModuleBuilder.cs (7)
53internal readonly RuntimeModule _internalModule; 65internal RuntimeModuleBuilder(RuntimeAssemblyBuilder assemblyBuilder, RuntimeModule internalModule) 110RuntimeModule refedRuntimeModule = GetRuntimeModuleFromModule(refedModule); 220RuntimeModule refedRuntimeModule = GetRuntimeModuleFromModule(refedModule); 290internal RuntimeModule InternalModule => _internalModule; 294internal static RuntimeModule GetRuntimeModuleFromModule(Module? m) 301return (m as RuntimeModule)!;
src\System\Reflection\MdFieldInfo.cs (1)
45internal override RuntimeModule GetRuntimeModule() { return m_declaringType.GetRuntimeModule(); }
src\System\Reflection\MdImport.cs (3)
250internal static unsafe MarshalAsAttribute GetMarshalAs(ConstArray nativeType, RuntimeModule scope) 325private static extern IntPtr GetMetadataImport(RuntimeModule module); 327internal MetadataImport(RuntimeModule module)
src\System\Reflection\Metadata\RuntimeTypeMetadataUpdateHandler.cs (1)
20internal static bool IsMetadataUpdateDeleted(RuntimeModule module, int memberToken)
src\System\Reflection\RtFieldInfo.cs (1)
64internal override RuntimeModule GetRuntimeModule()
src\System\Reflection\RuntimeAssembly.cs (9)
434RuntimeModule? m = (RuntimeModule?)GetModule(name); 457fs[i] = new FileStream(((RuntimeModule)m[i]).GetFullyQualifiedName(), 682private RuntimeModule[] GetModulesInternal(bool loadIfNotFound, 685RuntimeModule[]? modules = null; 702private RuntimeModule GetManifestModule() 707static RuntimeModule GetManifestModuleWorker(RuntimeAssembly assembly) 709RuntimeModule? module = null; 716private static extern RuntimeModule? GetManifestModule(RuntimeAssembly assembly);
src\System\Reflection\RuntimeConstructorInfo.CoreCLR.cs (1)
174internal RuntimeModule GetRuntimeModule() { return RuntimeTypeHandle.GetModule(m_declaringType); }
src\System\Reflection\RuntimeCustomAttributeData.cs (30)
69internal static IList<CustomAttributeData> GetCustomAttributesInternal(RuntimeModule target) 85return GetCustomAttributes((RuntimeModule)target.ManifestModule, RuntimeAssembly.GetToken(target)); 183private static IList<CustomAttributeData> GetCustomAttributes(RuntimeModule module, int tkTarget) 200internal static CustomAttributeRecord[] GetCustomAttributeRecords(RuntimeModule module, int targetToken) 238private readonly RuntimeModule m_scope = null!; 251private RuntimeCustomAttributeData(RuntimeModule scope, MetadataToken caCtorToken, in ConstArray blob) 543private static RuntimeType ResolveType(RuntimeModule scope, string typeName) 551internal CustomAttributeTypedArgument(RuntimeModule scope, CustomAttributeEncodedArgument encodedArg) 667RuntimeModule customAttributeModule) 707RuntimeModule module) 721RuntimeModule module) 809RuntimeModule module) 877private static CustomAttributeType ParseCustomAttributeType(ref CustomAttributeDataParser parser, RuntimeModule module) 1230return IsCustomAttributeDefined((assembly.ManifestModule as RuntimeModule)!, RuntimeAssembly.GetToken(assembly), caType); 1233internal static bool IsDefined(RuntimeModule module, RuntimeType caType) 1392return GetCustomAttributes((assembly.ManifestModule as RuntimeModule)!, assemblyToken, 0, caType); 1395internal static object[] GetCustomAttributes(RuntimeModule module, RuntimeType caType) 1405internal static bool IsAttributeDefined(RuntimeModule decoratedModule, int decoratedMetadataToken, int attributeCtorToken) 1411RuntimeModule decoratedModule, int decoratedMetadataToken, RuntimeType? attributeFilterType) 1417RuntimeModule decoratedModule, int decoratedMetadataToken, RuntimeType? attributeFilterType, int attributeCtorToken, bool mustBeInheritable) 1470RuntimeModule decoratedModule, int decoratedMetadataToken, int pcaCount, RuntimeType attributeFilterType) 1490RuntimeModule decoratedModule, int decoratedMetadataToken, 1621RuntimeModule decoratedModule, 1767RuntimeModule decoratedModule = decoratedAttribute.GetRuntimeModule(); 1872private static object CreateCustomAttributeInstance(RuntimeModule module, RuntimeType type, IRuntimeMethodInfo ctor, ref IntPtr blob, IntPtr blobEnd, out int namedArgs) 1902RuntimeModule module, ref IntPtr blobStart, IntPtr blobEnd, out string name, out bool isProperty, out RuntimeType? type, out object? value) 2184RuntimeModule module = method.Module.ModuleHandle.GetRuntimeModule(); 2241private static MarshalAsAttribute? GetMarshalAsCustomAttribute(int token, RuntimeModule scope) 2255RuntimeModule module = field.GetRuntimeModule(); 2288RuntimeModule module = type.GetRuntimeModule();
src\System\Reflection\RuntimeEventInfo.cs (1)
131internal RuntimeModule GetRuntimeModule() { return m_declaringType.GetRuntimeModule(); }
src\System\Reflection\RuntimeFieldInfo.cs (1)
36internal abstract RuntimeModule GetRuntimeModule();
src\System\Reflection\RuntimeMethodInfo.CoreCLR.cs (1)
236internal RuntimeModule GetRuntimeModule() { return m_declaringType.GetRuntimeModule(); }
src\System\Reflection\RuntimeModule.cs (3)
410RuntimeModule thisAsLocal = this; 425RuntimeModule thisAsLocal = this; 492RuntimeModule thisAsLocal = this;
src\System\Reflection\RuntimeParameterInfo.cs (1)
417internal RuntimeModule? GetRuntimeModule()
src\System\Reflection\RuntimePropertyInfo.cs (2)
38RuntimeModule module = declaredType.GetRuntimeModule(); 182internal RuntimeModule GetRuntimeModule() { return m_declaringType.GetRuntimeModule(); }
src\System\Reflection\TypeNameResolver.CoreCLR.cs (1)
112internal static RuntimeType GetTypeReferencedByCustomAttribute(string typeName, RuntimeModule scope)
src\System\Runtime\CompilerServices\RuntimeHelpers.CoreCLR.cs (1)
191RuntimeModule rm = module.GetRuntimeModule() ??
src\System\RuntimeHandles.cs (17)
412internal static RuntimeModule GetModule(RuntimeType type) 417static RuntimeModule GetModuleWorker(RuntimeType type) 419RuntimeModule? module = null; 426private static extern RuntimeModule? GetModuleIfExists(RuntimeType type); 1784private readonly RuntimeModule m_ptr; 1788internal ModuleHandle(RuntimeModule module) 1794internal RuntimeModule GetRuntimeModule() 1832internal static IRuntimeMethodInfo GetDynamicMethod(RuntimeModule module, string name, byte[] sig, Resolver resolver) 1849internal static int GetToken(RuntimeModule module) 1852private static void ValidateModulePointer(RuntimeModule module) 1874RuntimeModule module = GetRuntimeModule(); 1930RuntimeModule module = GetRuntimeModule(); 1945internal static RuntimeMethodHandleInternal ResolveMethodHandleInternal(RuntimeModule module, int methodToken, ReadOnlySpan<IntPtr> typeInstantiationContext, ReadOnlySpan<IntPtr> methodInstantiationContext) 1982RuntimeModule module = GetRuntimeModule(); 2033internal static RuntimeType GetModuleType(RuntimeModule module) 2045internal static void GetPEKind(RuntimeModule module, out PortableExecutableKinds peKind, out ImageFileMachine machine) 2057internal static int GetMDStreamVersion(RuntimeModule module)
src\System\RuntimeType.CoreCLR.cs (6)
937RuntimeModule declaringModule = declaringType.GetRuntimeModule(); 1185RuntimeModule declaringModule = declaringType.GetRuntimeModule(); 1297RuntimeModule declaringModule = declaringType.GetRuntimeModule(); 1574RuntimeModule module = ((RuntimeType)type).GetRuntimeModule(); 1800internal static MethodBase? GetMethodBase(RuntimeModule scope, int typeMetadataToken) 3575RuntimeModule module = GetRuntimeModule();