if (RuntimeRebindRuleGenerator.RUNTIME_REBIND_RULE_SOURCES_BY_SHORT_NAME.isEmpty()) {
// Then there's no need to generate a registrator to attach them to the runtime registry.
return;
}
RuntimeRebindRegistratorGenerator runtimeRebindRegistratorGenerator =
new RuntimeRebindRegistratorGenerator();
StandardGeneratorContext generatorContext = getGeneratorContext();
// Name based on module canonical name, to avoid collisions resulting from multiple modules
// with the same rename.
String runtimeRebindRegistratorTypeName = runtimeRebindRegistratorGenerator.generate(logger,
generatorContext, module.getCanonicalName());
// Ensures that unification traverses and keeps the class.
allRootTypes.add(runtimeRebindRegistratorTypeName);
// Ensures that JProgram knows to index this class's methods so that later bootstrap
// construction code is able to locate the FooRuntimeRebindRegistrator.register() function.