code: public boolean canAcceptParent(Class<? extends ElementBase> clazz) {
          if (!canAcceptParent(getClass(), clazz)) {
              rejectReason = getDisplayName() + " does not accept " + clazz.getSimpleName() + " as a parent.";
          } else {
              rejectReason = null;
          }
          
          return rejectReason == null;
      }
docs: Returns true if this element may accept a parent of the specified class. Updates the reject
  reason with the result.
  
  @param clazz Parent class to test.
  @return True if this element may accept a parent of the specified class.