code: public boolean add(Object targetChild)
      {
          //
          // The context can contain ControlBeans and other types of objects, such as a control
          // factory.
          //
          String beanID = null;
          if (targetChild instanceof ControlBean)
          {
              ControlBean bean = (ControlBean)targetChild;
              beanID = bean.getLocalID();
  
              //
              // The bean is anonymous, so we must generate a new unique name within this context.
              //
              if (beanID == null)
              {
                  beanID = generateUniqueID(bean.getClass());
                  bean.setLocalID(beanID);
              }
  
              ControlBean existingBean = (ControlBean)_childMap.get(beanID);
              if (existingBean != null && existingBean != targetChild)
              {
                  throw new IllegalArgumentException("Attempting to add control with duplicate ID: " +
                                                     beanID);
              }
          }
  
          boolean added = _beanContextServicesDelegate.add(targetChild);
          if (added && beanID != null)
              _childMap.put(beanID, targetChild);
  
          return added;
      }
docs: Overrides the BeanContextSupport.add() method to perform additional validation
  that is unique for ControlBeans containers.