constructor(entry) {
    /**
     * List of pre-compiled renamings.
     * @private @const {
     *     !Array<{old: string, new: ?string, get: ?string, set: ?string}>}
     */
    this.renamings_ = [];
    // See the sample entry in renamings.json5 for explanation of the
    // meaning of the different properties on database entries.
    for (const module of entry) {
      // TODO: switch all of the || to ?? if/when we drop Node12.
      const oldModulePath = module.oldPath || module.oldName;
      const newExport = module.newExport ? `.${module.newExport}` : '';
      const newModulePath =
        module.newPath || `${module.newName || oldModulePath}${newExport}`;

      if (module.exports) {
        for (const [oldExportName, info] of Object.entries(module.exports)) {
          const oldExportPath =
            info.oldPath || `${oldModulePath}.${oldExportName}`;
          const newBase = `${info.newModule || newModulePath}.`;
          const renaming = {old: oldExportPath};
          if (info.newPath) {
            // If newPath provided just use that.
            renaming.new = info.newPath;
          } else if (info.getMethod || info.setMethod) {
            renaming.get = info.getMethod
              ? `${newBase}${info.getMethod}`
              : null;
            renaming.set = info.setMethod
              ? `${newBase}${info.setMethod}`
              : null;
          } else {
            renaming.new = `${newBase}${info.newExport || oldExportName}`;
          }
          this.renamings_.push(renaming);
        }
      }

      // Module renamings have to be added at the end so all export renamings
      // can be detected.
      // Eg if we have renamings:
      //   moduleA -> moduleB
      //   moduleA.exportA -> moduleC.exportB
      // And we performed the module rename first, we wouldn't be able to detect
      // the export rename.
      if (newModulePath !== oldModulePath) {
        this.renamings_.push({old: oldModulePath, new: newModulePath});
      }
    }
  }
Constructor for the version renamer.
@param {!Object} entry The database entry for a single version.