code: @SuppressWarnings("unchecked")
      private EventSetDescriptor[] introspectEvents() throws IntrospectionException {
          // Get descriptors for the public methods
          // FIXME: performance
          MethodDescriptor[] theMethods = introspectMethods();
  
          if (theMethods == null)
              return null;
  
          HashMap<String, HashMap> eventTable = new HashMap<String, HashMap>(
                  theMethods.length);
  
          // Search for methods that add an Event Listener
          for (int i = 0; i < theMethods.length; i++) {
              introspectListenerMethods(PREFIX_ADD, theMethods[i].getMethod(),
                      eventTable);
              introspectListenerMethods(PREFIX_REMOVE, theMethods[i].getMethod(),
                      eventTable);
              introspectGetListenerMethods(theMethods[i].getMethod(), eventTable);
          }
  
          ArrayList<EventSetDescriptor> eventList = new ArrayList<EventSetDescriptor>();
          for (Map.Entry<String, HashMap> entry : eventTable.entrySet()) {
              HashMap table = entry.getValue();
              Method add = (Method) table.get(PREFIX_ADD);
              Method remove = (Method) table.get(PREFIX_REMOVE);
  
              if ((add == null) || (remove == null)) {
                  continue;
              }
  
              Method get = (Method) table.get(PREFIX_GET);
              Class<?> listenerType = (Class) table.get("listenerType"); //$NON-NLS-1$
              Method[] listenerMethods = (Method[]) table.get("listenerMethods"); //$NON-NLS-1$
              EventSetDescriptor eventSetDescriptor = new EventSetDescriptor(
                      decapitalize(entry.getKey()), listenerType, listenerMethods, add,
                      remove, get);
  
              eventSetDescriptor.setUnicast(table.get("isUnicast") != null); //$NON-NLS-1$
              eventList.add(eventSetDescriptor);
          }
  
          EventSetDescriptor[] theEvents = new EventSetDescriptor[eventList
                  .size()];
          eventList.toArray(theEvents);
  
          return theEvents;
      }
docs: Introspects the supplied Bean class and returns a list of the Events of
  the class
  
  @return the events
  @throws IntrospectionException