@SuppressWarnings("AutoBoxing") @Test public void handleNeedChildrenTest() { final ParseTreeNode node = mock(ParseTreeNode.class); final int id = 42; when(node.getId()).thenReturn(id); @SuppressWarnings("unchecked") final List<ParseTreeNode> children = mock(List.class); when(model.getNodeChildren(anyInt())).thenReturn(children); presenter.handleNeedChildren(node); verify(view).waitForChildren(); verify(model).getNodeChildren(id); verify(view).setTreeChildren(same(children)); }
public void handleNeedChildren(final ParseTreeNode value) { taskRunner.compute( view::waitForChildren, () -> model.getNodeChildren(value.getId()), view::setTreeChildren ); }
TreeTabPresenter extends TabPresenter<TreeTabView> { public void handleNeedChildren(final ParseTreeNode value) { taskRunner.compute( view::waitForChildren, () -> model.getNodeChildren(value.getId()), view::setTreeChildren ); } }
TreeTabPresenter extends TabPresenter<TreeTabView> { public void handleNeedChildren(final ParseTreeNode value) { taskRunner.compute( view::waitForChildren, () -> model.getNodeChildren(value.getId()), view::setTreeChildren ); } TreeTabPresenter(final GuiTaskRunner taskRunner,
        final MainWindowView mainView, final TraceDb traceDb); }
TreeTabPresenter extends TabPresenter<TreeTabView> { public void handleNeedChildren(final ParseTreeNode value) { taskRunner.compute( view::waitForChildren, () -> model.getNodeChildren(value.getId()), view::setTreeChildren ); } TreeTabPresenter(final GuiTaskRunner taskRunner,
        final MainWindowView mainView, final TraceDb traceDb); @Override CountDownLatch refresh(); @Override void load(); void handleParseTreeNodeShow(final ParseTreeNode node); void handleNeedChildren(final ParseTreeNode value); }
TreeTabPresenter extends TabPresenter<TreeTabView> { public void handleNeedChildren(final ParseTreeNode value) { taskRunner.compute( view::waitForChildren, () -> model.getNodeChildren(value.getId()), view::setTreeChildren ); } TreeTabPresenter(final GuiTaskRunner taskRunner,
        final MainWindowView mainView, final TraceDb traceDb); @Override CountDownLatch refresh(); @Override void load(); void handleParseTreeNodeShow(final ParseTreeNode node); void handleNeedChildren(final ParseTreeNode value);  }