protected static synchronized void registerAllowedParentClass ( Class < ? extends ElementBase > clazz , Class < ? extends ElementBase > parentClass ) { allowedParentClasses . addCardinality ( clazz , parentClass , 1 ) ; }
A ElementBase subclass should call this in its static initializer block to register any subclasses that may act as a parent .