@Test public void enqueu_event() { Event e = mock(Event.class); handlerExecutor.execute(e); ArgumentCaptor<Runnable> captor = ArgumentCaptor.forClass(Runnable.class); verify(executor).execute(captor.capture()); captor.getValue().run(); verify(e).visit(any(EventVisitor.class)); }
@Override public void execute(Event event) { executor.execute(new EventRunner(event)); }
UnorderHandlerExecutor implements IoHandlerExecutor { @Override public void execute(Event event) { executor.execute(new EventRunner(event)); } }
UnorderHandlerExecutor implements IoHandlerExecutor { @Override public void execute(Event event) { executor.execute(new EventRunner(event)); } UnorderHandlerExecutor(Executor executor); }
UnorderHandlerExecutor implements IoHandlerExecutor { @Override public void execute(Event event) { executor.execute(new EventRunner(event)); } UnorderHandlerExecutor(Executor executor); @Override void execute(Event event); }
UnorderHandlerExecutor implements IoHandlerExecutor { @Override public void execute(Event event) { executor.execute(new EventRunner(event)); } UnorderHandlerExecutor(Executor executor); @Override void execute(Event event);  }