/** Creates the child bean. */
  @Override
  public Object create(Object parent, QName qName) throws ConfigException {
    Class<?> cl = TypeFactory.loadClass(qName);

    if (cl == null) {
      ConfigType<?> type = TypeFactory.getFactory().getEnvironmentType(qName);

      if (type != null) return type.create(parent, qName);

      throw new ConfigException(
          L.l(
              "'{0}.{1}' is an unknown class for element '{2}'",
              qName.getNamespaceURI(), qName.getLocalName(), qName));
    }

    if (Annotation.class.isAssignableFrom(cl)) {
      return new AnnotationConfig(cl);
    } else {
      XmlBeanConfig<?> config = new XmlBeanConfig(qName, cl, parent);
      config.setInlineBean(true);

      // config.setScope("singleton");

      return config;
    }
  }
 private AddAttribute(Class<T> cl) {
   this(null, (ConfigType<T>) TypeFactory.getType(cl));
 }