protected sealed override void IterateTypeForwards(TypeForwardHandler handler) { MetadataReader reader = Reader; foreach (ExportedTypeHandle exportedTypeHandle in reader.ExportedTypes) { ExportedType exportedType = reader.GetExportedType(exportedTypeHandle); if (!exportedType.IsForwarder) { continue; } EntityHandle implementation = exportedType.Implementation; if (implementation.Kind != HandleKind.AssemblyReference) // This check also weeds out nested types. This is intentional. { continue; } RoAssembly redirectedAssembly = ((AssemblyReferenceHandle)implementation).ResolveToAssemblyOrExceptionAssembly(GetEcmaManifestModule()); ReadOnlySpan <byte> ns = exportedType.Namespace.AsReadOnlySpan(reader); ReadOnlySpan <byte> name = exportedType.Name.AsReadOnlySpan(reader); handler(redirectedAssembly, ns, name); } }
protected abstract void IterateTypeForwards(TypeForwardHandler handler);
protected sealed override void IterateTypeForwards(TypeForwardHandler handler) => throw null !;