code: public static ComponentDef createTooManyRegistration(Object key, ComponentDef currentComponentDef, ComponentDef newComponentDef) {
          if (currentComponentDef instanceof TooManyRegistrationComponentDef) {
              ((TooManyRegistrationComponentDef) currentComponentDef).addComponentDef(newComponentDef);
              return currentComponentDef;
          } else {
              TooManyRegistrationComponentDef tmrcf = new TooManyRegistrationComponentDefImpl(key);
              tmrcf.addComponentDef(currentComponentDef);
              tmrcf.addComponentDef(newComponentDef);
              return tmrcf;
          }
      }
docs: =============