test_class.declarator: eventDispatcher
test_class.modifier: private
test_class.original_string: private EventDispatcher eventDispatcher;
test_class.type: EventDispatcher
test_class.var_name: eventDispatcher
test_class.declarator: listener
test_class.modifier: private
test_class.original_string: private MyGenericEventListener listener;
test_class.type: MyGenericEventListener
test_class.var_name: listener
test_class.file: dubbo-common/src/test/java/org/apache/dubbo/event/GenericEventListenerTest.java
test_class.identifier: GenericEventListenerTest
test_case.body: @Test
      public void testOnEvent() {
          String value = "Hello,World";
          EchoEvent echoEvent = new EchoEvent(value);
          eventDispatcher.dispatch(echoEvent);
          assertEquals(echoEvent, listener.getEchoEvent());
          assertEquals(value, listener.getEchoEvent().getSource());
      }
test_case.class_method_signature: GenericEventListenerTest.testOnEvent()
test_case.full_signature: @Test public void testOnEvent()
test_case.identifier: testOnEvent
test_case.invocations: dispatch assertEquals getEchoEvent assertEquals getSource getEchoEvent
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testOnEvent()
focal_class.declarator: onEventMethod
focal_class.modifier: private final
focal_class.original_string: private final Method onEventMethod;
focal_class.type: Method
focal_class.var_name: onEventMethod
focal_class.declarator: handleEventMethods
focal_class.modifier: private final
focal_class.original_string: private final Map<Class<?>, Set<Method>> handleEventMethods;
focal_class.type: Map<Class<?>, Set<Method>>
focal_class.var_name: handleEventMethods
focal_class.file: dubbo-common/src/main/java/org/apache/dubbo/event/GenericEventListener.java
focal_class.identifier: GenericEventListener
focal_class.interfaces: implements EventListener<Event>
focal_class.class_method_signature: GenericEventListener.GenericEventListener()
focal_class.full_signature: protected  GenericEventListener()
focal_class.identifier: GenericEventListener
focal_class.modifiers: protected
focal_class.parameters: ()
focal_class.signature:  GenericEventListener()
focal_class.class_method_signature: GenericEventListener.findOnEventMethod()
focal_class.full_signature: private Method findOnEventMethod()
focal_class.identifier: findOnEventMethod
focal_class.modifiers: private
focal_class.parameters: ()
focal_class.return: Method
focal_class.signature: Method findOnEventMethod()
focal_class.class_method_signature: GenericEventListener.findHandleEventMethods()
focal_class.full_signature: private Map<Class<?>, Set<Method>> findHandleEventMethods()
focal_class.identifier: findHandleEventMethods
focal_class.modifiers: private
focal_class.parameters: ()
focal_class.return: Map<Class<?>, Set<Method>>
focal_class.signature: Map<Class<?>, Set<Method>> findHandleEventMethods()
focal_class.class_method_signature: GenericEventListener.onEvent(Event event)
focal_class.full_signature: public final void onEvent(Event event)
focal_class.identifier: onEvent
focal_class.modifiers: public final
focal_class.parameters: (Event event)
focal_class.return: void
focal_class.signature: void onEvent(Event event)
focal_class.class_method_signature: GenericEventListener.isHandleEventMethod(Method method)
focal_class.full_signature: private boolean isHandleEventMethod(Method method)
focal_class.identifier: isHandleEventMethod
focal_class.modifiers: private
focal_class.parameters: (Method method)
focal_class.return: boolean
focal_class.signature: boolean isHandleEventMethod(Method method)
focal_method.body: public final void onEvent(Event event) {
          Class<?> eventClass = event.getClass();
          handleEventMethods.getOrDefault(eventClass, emptySet()).forEach(method -> {
              ThrowableConsumer.execute(method, m -> {
                  m.invoke(this, event);
              });
          });
      }
focal_method.class_method_signature: GenericEventListener.onEvent(Event event)
focal_method.full_signature: public final void onEvent(Event event)
focal_method.identifier: onEvent
focal_method.invocations: getClass forEach getOrDefault emptySet execute invoke
focal_method.modifiers: public final
focal_method.parameters: (Event event)
focal_method.return: void
focal_method.signature: void onEvent(Event event)