code: public synchronized void unregister(Object subscriber) {
          List<Class<?>> subscribedTypes = typesBySubscriber.get(subscriber);
          if (subscribedTypes != null) {
              for (Class<?> eventType : subscribedTypes) {
                  unsubscribeByEventType(subscriber, eventType);
              }
              typesBySubscriber.remove(subscriber);
          } else {
              logger.log(Level.WARNING, "Subscriber to unregister was not registered before: " + subscriber.getClass());
          }
      }
docs: Unregisters the given subscriber from all event classes.