code: static void addInterfaces(List<Class<?>> eventTypes, Class<?>[] interfaces) {
          for (Class<?> interfaceClass : interfaces) {
              if (!eventTypes.contains(interfaceClass)) {
                  eventTypes.add(interfaceClass);
                  addInterfaces(eventTypes, interfaceClass.getInterfaces());
              }
          }
      }
docs: Recurses through super interfaces.