code: protected static synchronized void registerAllowedParentClass(Class<? extends ElementBase> clazz,
                                                                    Class<? extends ElementBase> parentClass) {
          allowedParentClasses.addCardinality(clazz, parentClass, 1);
      }
docs: A ElementBase subclass should call this in its static initializer block to register any
  subclasses that may act as a parent.
  
  @param clazz Class whose valid parent classes are to be registered.
  @param parentClass Class that may act as a parent to clazz.