target stringlengths 20 113k | src_fm stringlengths 11 86.3k | src_fm_fc stringlengths 21 86.4k | src_fm_fc_co stringlengths 30 86.4k | src_fm_fc_ms stringlengths 42 86.8k | src_fm_fc_ms_ff stringlengths 43 86.8k |
|---|---|---|---|---|---|
@Test public void testInit() { tested.init(); verify(view, times(1)).init(eq(tested)); } | @PostConstruct public void init() { view.init(this); } | ZoomLevelSelector implements IsWidget { @PostConstruct public void init() { view.init(this); } } | ZoomLevelSelector implements IsWidget { @PostConstruct public void init() { view.init(this); } @Inject ZoomLevelSelector(final View view); } | ZoomLevelSelector implements IsWidget { @PostConstruct public void init() { view.init(this); } @Inject ZoomLevelSelector(final View view); @PostConstruct void init(); ZoomLevelSelector onDecreaseLevel(final Command onDecreaseLevel); ZoomLevelSelector onIncreaseLevel(final Command onIncreaseLevel); ZoomLevelSelector on... | ZoomLevelSelector implements IsWidget { @PostConstruct public void init() { view.init(this); } @Inject ZoomLevelSelector(final View view); @PostConstruct void init(); ZoomLevelSelector onDecreaseLevel(final Command onDecreaseLevel); ZoomLevelSelector onIncreaseLevel(final Command onIncreaseLevel); ZoomLevelSelector on... |
@Test public void testSetText() { tested.setText("hiya"); verify(view, times(1)).setText(eq("hiya")); } | public ZoomLevelSelector setText(final String text) { view.setText(text); return this; } | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector setText(final String text) { view.setText(text); return this; } } | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector setText(final String text) { view.setText(text); return this; } @Inject ZoomLevelSelector(final View view); } | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector setText(final String text) { view.setText(text); return this; } @Inject ZoomLevelSelector(final View view); @PostConstruct void init(); ZoomLevelSelector onDecreaseLevel(final Command onDecreaseLevel); ZoomLevelSelector onIncreaseLevel(final Command onIn... | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector setText(final String text) { view.setText(text); return this; } @Inject ZoomLevelSelector(final View view); @PostConstruct void init(); ZoomLevelSelector onDecreaseLevel(final Command onDecreaseLevel); ZoomLevelSelector onIncreaseLevel(final Command onIn... |
@Test public void testAdd() { Command callback = mock(Command.class); tested.add("item1", callback); verify(view, times(1)).add(eq("item1"), eq(callback)); } | public ZoomLevelSelector add(final String text, final Command onClick) { view.add(text, onClick); return this; } | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector add(final String text, final Command onClick) { view.add(text, onClick); return this; } } | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector add(final String text, final Command onClick) { view.add(text, onClick); return this; } @Inject ZoomLevelSelector(final View view); } | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector add(final String text, final Command onClick) { view.add(text, onClick); return this; } @Inject ZoomLevelSelector(final View view); @PostConstruct void init(); ZoomLevelSelector onDecreaseLevel(final Command onDecreaseLevel); ZoomLevelSelector onIncrease... | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector add(final String text, final Command onClick) { view.add(text, onClick); return this; } @Inject ZoomLevelSelector(final View view); @PostConstruct void init(); ZoomLevelSelector onDecreaseLevel(final Command onDecreaseLevel); ZoomLevelSelector onIncrease... |
@Test public void testClear() { tested.clear(); verify(view, times(1)).clear(); } | public ZoomLevelSelector clear() { view.clear(); return this; } | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector clear() { view.clear(); return this; } } | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector clear() { view.clear(); return this; } @Inject ZoomLevelSelector(final View view); } | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector clear() { view.clear(); return this; } @Inject ZoomLevelSelector(final View view); @PostConstruct void init(); ZoomLevelSelector onDecreaseLevel(final Command onDecreaseLevel); ZoomLevelSelector onIncreaseLevel(final Command onIncreaseLevel); ZoomLevelSe... | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector clear() { view.clear(); return this; } @Inject ZoomLevelSelector(final View view); @PostConstruct void init(); ZoomLevelSelector onDecreaseLevel(final Command onDecreaseLevel); ZoomLevelSelector onIncreaseLevel(final Command onIncreaseLevel); ZoomLevelSe... |
@Test public void testSetEnabled() { tested.setEnabled(true); verify(view, times(1)).setEnabled(eq(true)); tested.setEnabled(false); verify(view, times(1)).setEnabled(eq(false)); } | public ZoomLevelSelector setEnabled(boolean enabled) { view.setEnabled(enabled); return this; } | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector setEnabled(boolean enabled) { view.setEnabled(enabled); return this; } } | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector setEnabled(boolean enabled) { view.setEnabled(enabled); return this; } @Inject ZoomLevelSelector(final View view); } | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector setEnabled(boolean enabled) { view.setEnabled(enabled); return this; } @Inject ZoomLevelSelector(final View view); @PostConstruct void init(); ZoomLevelSelector onDecreaseLevel(final Command onDecreaseLevel); ZoomLevelSelector onIncreaseLevel(final Comma... | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector setEnabled(boolean enabled) { view.setEnabled(enabled); return this; } @Inject ZoomLevelSelector(final View view); @PostConstruct void init(); ZoomLevelSelector onDecreaseLevel(final Command onDecreaseLevel); ZoomLevelSelector onIncreaseLevel(final Comma... |
@Test public void testOnReset() { tested.onReset(); verify(onReset, times(1)).execute(); } | public ZoomLevelSelector onReset(final Command onReset) { checkNotNull("onReset", onReset); this.onReset = onReset; return this; } | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector onReset(final Command onReset) { checkNotNull("onReset", onReset); this.onReset = onReset; return this; } } | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector onReset(final Command onReset) { checkNotNull("onReset", onReset); this.onReset = onReset; return this; } @Inject ZoomLevelSelector(final View view); } | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector onReset(final Command onReset) { checkNotNull("onReset", onReset); this.onReset = onReset; return this; } @Inject ZoomLevelSelector(final View view); @PostConstruct void init(); ZoomLevelSelector onDecreaseLevel(final Command onDecreaseLevel); ZoomLevelS... | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector onReset(final Command onReset) { checkNotNull("onReset", onReset); this.onReset = onReset; return this; } @Inject ZoomLevelSelector(final View view); @PostConstruct void init(); ZoomLevelSelector onDecreaseLevel(final Command onDecreaseLevel); ZoomLevelS... |
@Test public void testOnIncreaseLevel() { tested.onIncreaseLevel(); verify(onIncreaseLevel, times(1)).execute(); } | public ZoomLevelSelector onIncreaseLevel(final Command onIncreaseLevel) { checkNotNull("onIncreaseLevel", onIncreaseLevel); this.onIncreaseLevel = onIncreaseLevel; return this; } | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector onIncreaseLevel(final Command onIncreaseLevel) { checkNotNull("onIncreaseLevel", onIncreaseLevel); this.onIncreaseLevel = onIncreaseLevel; return this; } } | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector onIncreaseLevel(final Command onIncreaseLevel) { checkNotNull("onIncreaseLevel", onIncreaseLevel); this.onIncreaseLevel = onIncreaseLevel; return this; } @Inject ZoomLevelSelector(final View view); } | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector onIncreaseLevel(final Command onIncreaseLevel) { checkNotNull("onIncreaseLevel", onIncreaseLevel); this.onIncreaseLevel = onIncreaseLevel; return this; } @Inject ZoomLevelSelector(final View view); @PostConstruct void init(); ZoomLevelSelector onDecrease... | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector onIncreaseLevel(final Command onIncreaseLevel) { checkNotNull("onIncreaseLevel", onIncreaseLevel); this.onIncreaseLevel = onIncreaseLevel; return this; } @Inject ZoomLevelSelector(final View view); @PostConstruct void init(); ZoomLevelSelector onDecrease... |
@Test public void testOnDecreaseLevel() { tested.onDecreaseLevel(); verify(onDecreaseLevel, times(1)).execute(); } | public ZoomLevelSelector onDecreaseLevel(final Command onDecreaseLevel) { checkNotNull("onDecreaseLevel", onDecreaseLevel); this.onDecreaseLevel = onDecreaseLevel; return this; } | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector onDecreaseLevel(final Command onDecreaseLevel) { checkNotNull("onDecreaseLevel", onDecreaseLevel); this.onDecreaseLevel = onDecreaseLevel; return this; } } | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector onDecreaseLevel(final Command onDecreaseLevel) { checkNotNull("onDecreaseLevel", onDecreaseLevel); this.onDecreaseLevel = onDecreaseLevel; return this; } @Inject ZoomLevelSelector(final View view); } | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector onDecreaseLevel(final Command onDecreaseLevel) { checkNotNull("onDecreaseLevel", onDecreaseLevel); this.onDecreaseLevel = onDecreaseLevel; return this; } @Inject ZoomLevelSelector(final View view); @PostConstruct void init(); ZoomLevelSelector onDecrease... | ZoomLevelSelector implements IsWidget { public ZoomLevelSelector onDecreaseLevel(final Command onDecreaseLevel) { checkNotNull("onDecreaseLevel", onDecreaseLevel); this.onDecreaseLevel = onDecreaseLevel; return this; } @Inject ZoomLevelSelector(final View view); @PostConstruct void init(); ZoomLevelSelector onDecrease... |
@Test public void testAsWidget() { Widget w = mock(Widget.class); when(view.asWidget()).thenReturn(w); assertEquals(w, tested.asWidget()); } | @Override public Widget asWidget() { return view.asWidget(); } | ZoomLevelSelector implements IsWidget { @Override public Widget asWidget() { return view.asWidget(); } } | ZoomLevelSelector implements IsWidget { @Override public Widget asWidget() { return view.asWidget(); } @Inject ZoomLevelSelector(final View view); } | ZoomLevelSelector implements IsWidget { @Override public Widget asWidget() { return view.asWidget(); } @Inject ZoomLevelSelector(final View view); @PostConstruct void init(); ZoomLevelSelector onDecreaseLevel(final Command onDecreaseLevel); ZoomLevelSelector onIncreaseLevel(final Command onIncreaseLevel); ZoomLevelSel... | ZoomLevelSelector implements IsWidget { @Override public Widget asWidget() { return view.asWidget(); } @Inject ZoomLevelSelector(final View view); @PostConstruct void init(); ZoomLevelSelector onDecreaseLevel(final Command onDecreaseLevel); ZoomLevelSelector onIncreaseLevel(final Command onIncreaseLevel); ZoomLevelSel... |
@Test public void testMakeRootWhenDMNDiagramElementIsDRG() { final Diagram stunnerDiagram = mock(Diagram.class); final Graph graph = mock(Graph.class); final Node node = mock(Node.class); final Definition definition = mock(Definition.class); final String dmnDiagramId = "0000"; final String dmnModelName = "diagram-name"... | public DecisionNavigatorItem makeRoot(final DMNDiagramTuple diagramTuple) { final DMNDiagramElement dmnDiagramElement = diagramTuple.getDMNDiagram(); final String uuid = dmnDiagramElement.getId().getValue(); final String diagramName = dmnDiagramElement.getName().getValue(); final String label; final boolean isDRG = isD... | DecisionNavigatorItemFactory { public DecisionNavigatorItem makeRoot(final DMNDiagramTuple diagramTuple) { final DMNDiagramElement dmnDiagramElement = diagramTuple.getDMNDiagram(); final String uuid = dmnDiagramElement.getId().getValue(); final String diagramName = dmnDiagramElement.getName().getValue(); final String l... | DecisionNavigatorItemFactory { public DecisionNavigatorItem makeRoot(final DMNDiagramTuple diagramTuple) { final DMNDiagramElement dmnDiagramElement = diagramTuple.getDMNDiagram(); final String uuid = dmnDiagramElement.getId().getValue(); final String diagramName = dmnDiagramElement.getName().getValue(); final String l... | DecisionNavigatorItemFactory { public DecisionNavigatorItem makeRoot(final DMNDiagramTuple diagramTuple) { final DMNDiagramElement dmnDiagramElement = diagramTuple.getDMNDiagram(); final String uuid = dmnDiagramElement.getId().getValue(); final String diagramName = dmnDiagramElement.getName().getValue(); final String l... | DecisionNavigatorItemFactory { public DecisionNavigatorItem makeRoot(final DMNDiagramTuple diagramTuple) { final DMNDiagramElement dmnDiagramElement = diagramTuple.getDMNDiagram(); final String uuid = dmnDiagramElement.getId().getValue(); final String diagramName = dmnDiagramElement.getName().getValue(); final String l... |
@Test @SuppressWarnings("unchecked") public void testInit() { assertEquals(mediators, tested.getMediators()); ArgumentCaptor<Supplier> panelCaptor = ArgumentCaptor.forClass(Supplier.class); verify(notification, times(1)).init(panelCaptor.capture()); assertEquals(panel, panelCaptor.getValue().get()); verify(zoomMediator... | public void init(final Supplier<LienzoCanvas> canvas) { keyEventHandler.addKeyShortcutCallback(new KogitoKeyShortcutKeyDownThenUp(new Key[]{Key.ALT}, "Navigate | Hold and drag to Pan", this::enablePan, this::clear)); keyEventHandler.addKeyShortcutCallback(new KogitoKeyShortcutKeyDownThenUp(new Key[]{Key.CONTROL}, "Navi... | LienzoCanvasMediators { public void init(final Supplier<LienzoCanvas> canvas) { keyEventHandler.addKeyShortcutCallback(new KogitoKeyShortcutKeyDownThenUp(new Key[]{Key.ALT}, "Navigate | Hold and drag to Pan", this::enablePan, this::clear)); keyEventHandler.addKeyShortcutCallback(new KogitoKeyShortcutKeyDownThenUp(new K... | LienzoCanvasMediators { public void init(final Supplier<LienzoCanvas> canvas) { keyEventHandler.addKeyShortcutCallback(new KogitoKeyShortcutKeyDownThenUp(new Key[]{Key.ALT}, "Navigate | Hold and drag to Pan", this::enablePan, this::clear)); keyEventHandler.addKeyShortcutCallback(new KogitoKeyShortcutKeyDownThenUp(new K... | LienzoCanvasMediators { public void init(final Supplier<LienzoCanvas> canvas) { keyEventHandler.addKeyShortcutCallback(new KogitoKeyShortcutKeyDownThenUp(new Key[]{Key.ALT}, "Navigate | Hold and drag to Pan", this::enablePan, this::clear)); keyEventHandler.addKeyShortcutCallback(new KogitoKeyShortcutKeyDownThenUp(new K... | LienzoCanvasMediators { public void init(final Supplier<LienzoCanvas> canvas) { keyEventHandler.addKeyShortcutCallback(new KogitoKeyShortcutKeyDownThenUp(new Key[]{Key.ALT}, "Navigate | Hold and drag to Pan", this::enablePan, this::clear)); keyEventHandler.addKeyShortcutCallback(new KogitoKeyShortcutKeyDownThenUp(new K... |
@Test @SuppressWarnings("unchecked") public void testKeyBindings() { ArgumentCaptor<KeyboardControl.KeyShortcutCallback> callbackArgumentCaptor = ArgumentCaptor.forClass(KeyboardControl.KeyShortcutCallback.class); verify(keyEventHandler, times(4)).addKeyShortcutCallback(callbackArgumentCaptor.capture()); KeyboardContro... | private void enablePreview() { if (null != mediators && mediators.enablePreview()) { cursor.accept(CURSOR_PREVIEW); notification.show(translationService.getNotNullValue(CoreTranslationMessages.MEDIATOR_PREVIEW)); } } | LienzoCanvasMediators { private void enablePreview() { if (null != mediators && mediators.enablePreview()) { cursor.accept(CURSOR_PREVIEW); notification.show(translationService.getNotNullValue(CoreTranslationMessages.MEDIATOR_PREVIEW)); } } } | LienzoCanvasMediators { private void enablePreview() { if (null != mediators && mediators.enablePreview()) { cursor.accept(CURSOR_PREVIEW); notification.show(translationService.getNotNullValue(CoreTranslationMessages.MEDIATOR_PREVIEW)); } } @Inject LienzoCanvasMediators(final KeyEventHandler keyEventHandler,
... | LienzoCanvasMediators { private void enablePreview() { if (null != mediators && mediators.enablePreview()) { cursor.accept(CURSOR_PREVIEW); notification.show(translationService.getNotNullValue(CoreTranslationMessages.MEDIATOR_PREVIEW)); } } @Inject LienzoCanvasMediators(final KeyEventHandler keyEventHandler,
... | LienzoCanvasMediators { private void enablePreview() { if (null != mediators && mediators.enablePreview()) { cursor.accept(CURSOR_PREVIEW); notification.show(translationService.getNotNullValue(CoreTranslationMessages.MEDIATOR_PREVIEW)); } } @Inject LienzoCanvasMediators(final KeyEventHandler keyEventHandler,
... |
@Test public void testSetMinScale() { tested.setMinScale(0.3d); verify(zoomMediator, times(1)).setMinScale(eq(0.3d)); } | public void setMinScale(final double minScale) { mediators.getZoomMediator().setMinScale(minScale); } | LienzoCanvasMediators { public void setMinScale(final double minScale) { mediators.getZoomMediator().setMinScale(minScale); } } | LienzoCanvasMediators { public void setMinScale(final double minScale) { mediators.getZoomMediator().setMinScale(minScale); } @Inject LienzoCanvasMediators(final KeyEventHandler keyEventHandler,
final ClientTranslationService translationService,
final L... | LienzoCanvasMediators { public void setMinScale(final double minScale) { mediators.getZoomMediator().setMinScale(minScale); } @Inject LienzoCanvasMediators(final KeyEventHandler keyEventHandler,
final ClientTranslationService translationService,
final L... | LienzoCanvasMediators { public void setMinScale(final double minScale) { mediators.getZoomMediator().setMinScale(minScale); } @Inject LienzoCanvasMediators(final KeyEventHandler keyEventHandler,
final ClientTranslationService translationService,
final L... |
@Test public void testSetMaxScale() { tested.setMaxScale(3d); verify(zoomMediator, times(1)).setMaxScale(eq(3d)); verify(previewMediator, times(1)).setMaxScale(eq(3d)); } | public void setMaxScale(final double maxScale) { mediators.getZoomMediator().setMaxScale(maxScale); mediators.getPreviewMediator().setMaxScale(maxScale); } | LienzoCanvasMediators { public void setMaxScale(final double maxScale) { mediators.getZoomMediator().setMaxScale(maxScale); mediators.getPreviewMediator().setMaxScale(maxScale); } } | LienzoCanvasMediators { public void setMaxScale(final double maxScale) { mediators.getZoomMediator().setMaxScale(maxScale); mediators.getPreviewMediator().setMaxScale(maxScale); } @Inject LienzoCanvasMediators(final KeyEventHandler keyEventHandler,
final ClientTranslationService transl... | LienzoCanvasMediators { public void setMaxScale(final double maxScale) { mediators.getZoomMediator().setMaxScale(maxScale); mediators.getPreviewMediator().setMaxScale(maxScale); } @Inject LienzoCanvasMediators(final KeyEventHandler keyEventHandler,
final ClientTranslationService transl... | LienzoCanvasMediators { public void setMaxScale(final double maxScale) { mediators.getZoomMediator().setMaxScale(maxScale); mediators.getPreviewMediator().setMaxScale(maxScale); } @Inject LienzoCanvasMediators(final KeyEventHandler keyEventHandler,
final ClientTranslationService transl... |
@Test public void testSetZoomFactor() { tested.setZoomFactor(0.5d); verify(zoomMediator, times(1)).setZoomFactor(eq(0.5d)); } | public void setZoomFactor(final double factor) { mediators.getZoomMediator().setZoomFactor(factor); } | LienzoCanvasMediators { public void setZoomFactor(final double factor) { mediators.getZoomMediator().setZoomFactor(factor); } } | LienzoCanvasMediators { public void setZoomFactor(final double factor) { mediators.getZoomMediator().setZoomFactor(factor); } @Inject LienzoCanvasMediators(final KeyEventHandler keyEventHandler,
final ClientTranslationService translationService,
final L... | LienzoCanvasMediators { public void setZoomFactor(final double factor) { mediators.getZoomMediator().setZoomFactor(factor); } @Inject LienzoCanvasMediators(final KeyEventHandler keyEventHandler,
final ClientTranslationService translationService,
final L... | LienzoCanvasMediators { public void setZoomFactor(final double factor) { mediators.getZoomMediator().setZoomFactor(factor); } @Inject LienzoCanvasMediators(final KeyEventHandler keyEventHandler,
final ClientTranslationService translationService,
final L... |
@Test public void testSetScaleAboutPoint() { tested.setScaleAboutPoint(true); verify(zoomMediator, atLeastOnce()).setScaleAboutPoint(eq(true)); tested.setScaleAboutPoint(false); verify(zoomMediator, atLeastOnce()).setScaleAboutPoint(eq(false)); } | public void setScaleAboutPoint(final boolean scaleAboutPoint) { mediators.getZoomMediator().setScaleAboutPoint(scaleAboutPoint); } | LienzoCanvasMediators { public void setScaleAboutPoint(final boolean scaleAboutPoint) { mediators.getZoomMediator().setScaleAboutPoint(scaleAboutPoint); } } | LienzoCanvasMediators { public void setScaleAboutPoint(final boolean scaleAboutPoint) { mediators.getZoomMediator().setScaleAboutPoint(scaleAboutPoint); } @Inject LienzoCanvasMediators(final KeyEventHandler keyEventHandler,
final ClientTranslationService translationService,
... | LienzoCanvasMediators { public void setScaleAboutPoint(final boolean scaleAboutPoint) { mediators.getZoomMediator().setScaleAboutPoint(scaleAboutPoint); } @Inject LienzoCanvasMediators(final KeyEventHandler keyEventHandler,
final ClientTranslationService translationService,
... | LienzoCanvasMediators { public void setScaleAboutPoint(final boolean scaleAboutPoint) { mediators.getZoomMediator().setScaleAboutPoint(scaleAboutPoint); } @Inject LienzoCanvasMediators(final KeyEventHandler keyEventHandler,
final ClientTranslationService translationService,
... |
@Test public void testDisable() { tested.disable(); verify(mediators, times(1)).disablePreview(); verify(cursor, times(1)).accept(eq(LienzoCanvasMediators.CURSOR_DEFAULT)); verify(notification, times(1)).hide(); } | public void disable() { keyEventHandler.setEnabled(false); clear(); } | LienzoCanvasMediators { public void disable() { keyEventHandler.setEnabled(false); clear(); } } | LienzoCanvasMediators { public void disable() { keyEventHandler.setEnabled(false); clear(); } @Inject LienzoCanvasMediators(final KeyEventHandler keyEventHandler,
final ClientTranslationService translationService,
final LienzoCanvasNotification notifica... | LienzoCanvasMediators { public void disable() { keyEventHandler.setEnabled(false); clear(); } @Inject LienzoCanvasMediators(final KeyEventHandler keyEventHandler,
final ClientTranslationService translationService,
final LienzoCanvasNotification notifica... | LienzoCanvasMediators { public void disable() { keyEventHandler.setEnabled(false); clear(); } @Inject LienzoCanvasMediators(final KeyEventHandler keyEventHandler,
final ClientTranslationService translationService,
final LienzoCanvasNotification notifica... |
@Test public void testDestroy() { tested.destroy(); verify(mediators, times(1)).destroy(); assertNull(tested.getMediators()); } | @PreDestroy public void destroy() { if (null != mediators) { mediators.destroy(); mediators = null; } } | LienzoCanvasMediators { @PreDestroy public void destroy() { if (null != mediators) { mediators.destroy(); mediators = null; } } } | LienzoCanvasMediators { @PreDestroy public void destroy() { if (null != mediators) { mediators.destroy(); mediators = null; } } @Inject LienzoCanvasMediators(final KeyEventHandler keyEventHandler,
final ClientTranslationService translationService,
final... | LienzoCanvasMediators { @PreDestroy public void destroy() { if (null != mediators) { mediators.destroy(); mediators = null; } } @Inject LienzoCanvasMediators(final KeyEventHandler keyEventHandler,
final ClientTranslationService translationService,
final... | LienzoCanvasMediators { @PreDestroy public void destroy() { if (null != mediators) { mediators.destroy(); mediators = null; } } @Inject LienzoCanvasMediators(final KeyEventHandler keyEventHandler,
final ClientTranslationService translationService,
final... |
@Test @SuppressWarnings("unchecked") public void getUUID_AtWhenOverShape() { final double x = 0.0; final double y = 0.0; final String expectedUUID = "uuid"; whenThereIsAShapeAt(registerShape(expectedUUID).getPath(), x, y); final String actualUUID = LienzoLayerUtils.getUUID_At(lienzoLayer, x, y); assertEquals(expectedUU... | public static String getUUID_At(final LienzoLayer lienzoLayer, final double x, final double y) { int sx = (int) x; int sy = (int) y; final Shape<?> shape = lienzoLayer.getLienzoLayer().getLayer().findShapeAtPoint(sx, sy); final String viewUUID = getShapeUUID(shape); return viewUUID; } | LienzoLayerUtils { public static String getUUID_At(final LienzoLayer lienzoLayer, final double x, final double y) { int sx = (int) x; int sy = (int) y; final Shape<?> shape = lienzoLayer.getLienzoLayer().getLayer().findShapeAtPoint(sx, sy); final String viewUUID = getShapeUUID(shape); return viewUUID; } } | LienzoLayerUtils { public static String getUUID_At(final LienzoLayer lienzoLayer, final double x, final double y) { int sx = (int) x; int sy = (int) y; final Shape<?> shape = lienzoLayer.getLienzoLayer().getLayer().findShapeAtPoint(sx, sy); final String viewUUID = getShapeUUID(shape); return viewUUID; } } | LienzoLayerUtils { public static String getUUID_At(final LienzoLayer lienzoLayer, final double x, final double y) { int sx = (int) x; int sy = (int) y; final Shape<?> shape = lienzoLayer.getLienzoLayer().getLayer().findShapeAtPoint(sx, sy); final String viewUUID = getShapeUUID(shape); return viewUUID; } static String ... | LienzoLayerUtils { public static String getUUID_At(final LienzoLayer lienzoLayer, final double x, final double y) { int sx = (int) x; int sy = (int) y; final Shape<?> shape = lienzoLayer.getLienzoLayer().getLayer().findShapeAtPoint(sx, sy); final String viewUUID = getShapeUUID(shape); return viewUUID; } static String ... |
@Test @SuppressWarnings("unchecked") public void getUUID_AtWhenNotOverShape() { final double x = 0.0; final double y = 0.0; final String expectedUUID = "uuid"; registerShape(expectedUUID); final String actualUUID = LienzoLayerUtils.getUUID_At(lienzoLayer, x, y); assertNull(actualUUID); } | public static String getUUID_At(final LienzoLayer lienzoLayer, final double x, final double y) { int sx = (int) x; int sy = (int) y; final Shape<?> shape = lienzoLayer.getLienzoLayer().getLayer().findShapeAtPoint(sx, sy); final String viewUUID = getShapeUUID(shape); return viewUUID; } | LienzoLayerUtils { public static String getUUID_At(final LienzoLayer lienzoLayer, final double x, final double y) { int sx = (int) x; int sy = (int) y; final Shape<?> shape = lienzoLayer.getLienzoLayer().getLayer().findShapeAtPoint(sx, sy); final String viewUUID = getShapeUUID(shape); return viewUUID; } } | LienzoLayerUtils { public static String getUUID_At(final LienzoLayer lienzoLayer, final double x, final double y) { int sx = (int) x; int sy = (int) y; final Shape<?> shape = lienzoLayer.getLienzoLayer().getLayer().findShapeAtPoint(sx, sy); final String viewUUID = getShapeUUID(shape); return viewUUID; } } | LienzoLayerUtils { public static String getUUID_At(final LienzoLayer lienzoLayer, final double x, final double y) { int sx = (int) x; int sy = (int) y; final Shape<?> shape = lienzoLayer.getLienzoLayer().getLayer().findShapeAtPoint(sx, sy); final String viewUUID = getShapeUUID(shape); return viewUUID; } static String ... | LienzoLayerUtils { public static String getUUID_At(final LienzoLayer lienzoLayer, final double x, final double y) { int sx = (int) x; int sy = (int) y; final Shape<?> shape = lienzoLayer.getLienzoLayer().getLayer().findShapeAtPoint(sx, sy); final String viewUUID = getShapeUUID(shape); return viewUUID; } static String ... |
@Test public void testMakeRootWhenDMNDiagramElementIsNotDRG() { final Diagram stunnerDiagram = mock(Diagram.class); final Graph graph = mock(Graph.class); final Node node = mock(Node.class); final Definition definition = mock(Definition.class); final String drdName = "DRD 1"; final String dmnDiagramId = "0000"; final D... | public DecisionNavigatorItem makeRoot(final DMNDiagramTuple diagramTuple) { final DMNDiagramElement dmnDiagramElement = diagramTuple.getDMNDiagram(); final String uuid = dmnDiagramElement.getId().getValue(); final String diagramName = dmnDiagramElement.getName().getValue(); final String label; final boolean isDRG = isD... | DecisionNavigatorItemFactory { public DecisionNavigatorItem makeRoot(final DMNDiagramTuple diagramTuple) { final DMNDiagramElement dmnDiagramElement = diagramTuple.getDMNDiagram(); final String uuid = dmnDiagramElement.getId().getValue(); final String diagramName = dmnDiagramElement.getName().getValue(); final String l... | DecisionNavigatorItemFactory { public DecisionNavigatorItem makeRoot(final DMNDiagramTuple diagramTuple) { final DMNDiagramElement dmnDiagramElement = diagramTuple.getDMNDiagram(); final String uuid = dmnDiagramElement.getId().getValue(); final String diagramName = dmnDiagramElement.getName().getValue(); final String l... | DecisionNavigatorItemFactory { public DecisionNavigatorItem makeRoot(final DMNDiagramTuple diagramTuple) { final DMNDiagramElement dmnDiagramElement = diagramTuple.getDMNDiagram(); final String uuid = dmnDiagramElement.getId().getValue(); final String diagramName = dmnDiagramElement.getName().getValue(); final String l... | DecisionNavigatorItemFactory { public DecisionNavigatorItem makeRoot(final DMNDiagramTuple diagramTuple) { final DMNDiagramElement dmnDiagramElement = diagramTuple.getDMNDiagram(); final String uuid = dmnDiagramElement.getId().getValue(); final String diagramName = dmnDiagramElement.getName().getValue(); final String l... |
@Test public void testLayerToDataURL() { ScratchPad scratchPad = mock(ScratchPad.class); Context2D context2D = mock(Context2D.class); when(layer.getScratchPad()).thenReturn(scratchPad); when(scratchPad.getContext()).thenReturn(context2D); when(scratchPad.toDataURL(eq(DataURLType.JPG), eq(1d))).thenReturn("theResultData... | public static String layerToDataURL(final LienzoLayer lienzoLayer, final DataURLType dataURLType, final int x, final int y, final int width, final int height, final String bgColor) { final com.ait.lienzo.client.core.shape.Layer layer = lienzoLayer.getLienzoLayer(); final ScratchPad scratchPad = layer.getScratchPad(); s... | LienzoLayerUtils { public static String layerToDataURL(final LienzoLayer lienzoLayer, final DataURLType dataURLType, final int x, final int y, final int width, final int height, final String bgColor) { final com.ait.lienzo.client.core.shape.Layer layer = lienzoLayer.getLienzoLayer(); final ScratchPad scratchPad = layer... | LienzoLayerUtils { public static String layerToDataURL(final LienzoLayer lienzoLayer, final DataURLType dataURLType, final int x, final int y, final int width, final int height, final String bgColor) { final com.ait.lienzo.client.core.shape.Layer layer = lienzoLayer.getLienzoLayer(); final ScratchPad scratchPad = layer... | LienzoLayerUtils { public static String layerToDataURL(final LienzoLayer lienzoLayer, final DataURLType dataURLType, final int x, final int y, final int width, final int height, final String bgColor) { final com.ait.lienzo.client.core.shape.Layer layer = lienzoLayer.getLienzoLayer(); final ScratchPad scratchPad = layer... | LienzoLayerUtils { public static String layerToDataURL(final LienzoLayer lienzoLayer, final DataURLType dataURLType, final int x, final int y, final int width, final int height, final String bgColor) { final com.ait.lienzo.client.core.shape.Layer layer = lienzoLayer.getLienzoLayer(); final ScratchPad scratchPad = layer... |
@Test public void testTranslateBounds() { Bounds bounds = Bounds.create(1.1d, 2.2d, 3.3d, 4.4d); OptionalBounds lienzoBounds = LienzoShapeUtils.translateBounds(bounds); assertTrue(lienzoBounds.hasMinX()); assertEquals(1.1d, lienzoBounds.getMinX(), 0d); assertTrue(lienzoBounds.hasMinY()); assertEquals(2.2d, lienzoBounds... | public static OptionalBounds translateBounds(final Bounds bounds) { final OptionalBounds result = OptionalBounds.createEmptyBounds(); if (bounds.hasUpperLeft()) { final Bound upperLeft = bounds.getUpperLeft(); if (upperLeft.hasX()) { result.setMinX(upperLeft.getX()); } if (upperLeft.hasY()) { result.setMinY(upperLeft.g... | LienzoShapeUtils { public static OptionalBounds translateBounds(final Bounds bounds) { final OptionalBounds result = OptionalBounds.createEmptyBounds(); if (bounds.hasUpperLeft()) { final Bound upperLeft = bounds.getUpperLeft(); if (upperLeft.hasX()) { result.setMinX(upperLeft.getX()); } if (upperLeft.hasY()) { result.... | LienzoShapeUtils { public static OptionalBounds translateBounds(final Bounds bounds) { final OptionalBounds result = OptionalBounds.createEmptyBounds(); if (bounds.hasUpperLeft()) { final Bound upperLeft = bounds.getUpperLeft(); if (upperLeft.hasX()) { result.setMinX(upperLeft.getX()); } if (upperLeft.hasY()) { result.... | LienzoShapeUtils { public static OptionalBounds translateBounds(final Bounds bounds) { final OptionalBounds result = OptionalBounds.createEmptyBounds(); if (bounds.hasUpperLeft()) { final Bound upperLeft = bounds.getUpperLeft(); if (upperLeft.hasX()) { result.setMinX(upperLeft.getX()); } if (upperLeft.hasY()) { result.... | LienzoShapeUtils { public static OptionalBounds translateBounds(final Bounds bounds) { final OptionalBounds result = OptionalBounds.createEmptyBounds(); if (bounds.hasUpperLeft()) { final Bound upperLeft = bounds.getUpperLeft(); if (upperLeft.hasX()) { result.setMinX(upperLeft.getX()); } if (upperLeft.hasY()) { result.... |
@Test public void checkDestructionRemovesResourcesFromDOMWhenPictureIsLoaded() { when(picture.isLoaded()).thenReturn(true); LienzoPictureUtils.tryDestroy(picture, LienzoPictureUtils::retryDestroy); verify(picture).removeFromParent(); verify(imageElement).removeFromParent(); } | public static void tryDestroy(final Picture picture, final Consumer<Picture> retryCallback) { if (!retryDestroy(picture)) { retryCallback.accept(picture); } } | LienzoPictureUtils { public static void tryDestroy(final Picture picture, final Consumer<Picture> retryCallback) { if (!retryDestroy(picture)) { retryCallback.accept(picture); } } } | LienzoPictureUtils { public static void tryDestroy(final Picture picture, final Consumer<Picture> retryCallback) { if (!retryDestroy(picture)) { retryCallback.accept(picture); } } } | LienzoPictureUtils { public static void tryDestroy(final Picture picture, final Consumer<Picture> retryCallback) { if (!retryDestroy(picture)) { retryCallback.accept(picture); } } static void forceLoad(final Picture picture,
final String data,
final Com... | LienzoPictureUtils { public static void tryDestroy(final Picture picture, final Consumer<Picture> retryCallback) { if (!retryDestroy(picture)) { retryCallback.accept(picture); } } static void forceLoad(final Picture picture,
final String data,
final Com... |
@Test public void testAnimate() { tested.run(); final ArgumentCaptor<AnimationProperties> propertiesArgumentCaptor = ArgumentCaptor.forClass(AnimationProperties.class); verify(decorator, times(1)).animate(any(AnimationTweener.class), propertiesArgumentCaptor.capture(), anyDouble(), any(AnimationCallback.class)); assert... | private IAnimationHandle animate(final com.ait.lienzo.client.core.shape.Shape<?> shape) { final AnimationProperties properties = isStrokeNotFill ? AnimationProperties.toPropertyList(STROKE_COLOR(color), STROKE_ALPHA(alpha), STROKE_WIDTH(strokeWidth)) : AnimationProperties.toPropertyList(FILL_COLOR(color), FILL_ALPHA(al... | ShapeViewDecoratorAnimation extends AbstractAnimation<LienzoShapeView<?>> { private IAnimationHandle animate(final com.ait.lienzo.client.core.shape.Shape<?> shape) { final AnimationProperties properties = isStrokeNotFill ? AnimationProperties.toPropertyList(STROKE_COLOR(color), STROKE_ALPHA(alpha), STROKE_WIDTH(strokeW... | ShapeViewDecoratorAnimation extends AbstractAnimation<LienzoShapeView<?>> { private IAnimationHandle animate(final com.ait.lienzo.client.core.shape.Shape<?> shape) { final AnimationProperties properties = isStrokeNotFill ? AnimationProperties.toPropertyList(STROKE_COLOR(color), STROKE_ALPHA(alpha), STROKE_WIDTH(strokeW... | ShapeViewDecoratorAnimation extends AbstractAnimation<LienzoShapeView<?>> { private IAnimationHandle animate(final com.ait.lienzo.client.core.shape.Shape<?> shape) { final AnimationProperties properties = isStrokeNotFill ? AnimationProperties.toPropertyList(STROKE_COLOR(color), STROKE_ALPHA(alpha), STROKE_WIDTH(strokeW... | ShapeViewDecoratorAnimation extends AbstractAnimation<LienzoShapeView<?>> { private IAnimationHandle animate(final com.ait.lienzo.client.core.shape.Shape<?> shape) { final AnimationProperties properties = isStrokeNotFill ? AnimationProperties.toPropertyList(STROKE_COLOR(color), STROKE_ALPHA(alpha), STROKE_WIDTH(strokeW... |
@Test public void testAnimationHandler() { final AnimationHandle handle = tested.run(); handle.run(); verify(decoratorAnimationHandle, times(1)).run(); handle.stop(); verify(decoratorAnimationHandle, times(1)).stop(); handle.isRunning(); verify(decoratorAnimationHandle, times(1)).isRunning(); } | @Override public AnimationHandle run() { final List<IAnimationHandle> handles = new LinkedList<>(); getDecorators().forEach(dec -> handles.add(animate(dec))); return new AnimationHandle() { @Override public AnimationHandle run() { handles.forEach(IAnimationHandle::run); return this; } @Override public AnimationHandle s... | ShapeViewDecoratorAnimation extends AbstractAnimation<LienzoShapeView<?>> { @Override public AnimationHandle run() { final List<IAnimationHandle> handles = new LinkedList<>(); getDecorators().forEach(dec -> handles.add(animate(dec))); return new AnimationHandle() { @Override public AnimationHandle run() { handles.forEa... | ShapeViewDecoratorAnimation extends AbstractAnimation<LienzoShapeView<?>> { @Override public AnimationHandle run() { final List<IAnimationHandle> handles = new LinkedList<>(); getDecorators().forEach(dec -> handles.add(animate(dec))); return new AnimationHandle() { @Override public AnimationHandle run() { handles.forEa... | ShapeViewDecoratorAnimation extends AbstractAnimation<LienzoShapeView<?>> { @Override public AnimationHandle run() { final List<IAnimationHandle> handles = new LinkedList<>(); getDecorators().forEach(dec -> handles.add(animate(dec))); return new AnimationHandle() { @Override public AnimationHandle run() { handles.forEa... | ShapeViewDecoratorAnimation extends AbstractAnimation<LienzoShapeView<?>> { @Override public AnimationHandle run() { final List<IAnimationHandle> handles = new LinkedList<>(); getDecorators().forEach(dec -> handles.add(animate(dec))); return new AnimationHandle() { @Override public AnimationHandle run() { handles.forEa... |
@Test public void testRun() { tested.run(); verify(handle1, times(1)).run(); verify(handle2, times(1)).run(); verify(handle1, never()).stop(); verify(handle2, never()).stop(); } | @Override public IAnimationHandle run() { handles.forEach(IAnimationHandle::run); return this; } | MultipleAnimationHandle implements IAnimationHandle { @Override public IAnimationHandle run() { handles.forEach(IAnimationHandle::run); return this; } } | MultipleAnimationHandle implements IAnimationHandle { @Override public IAnimationHandle run() { handles.forEach(IAnimationHandle::run); return this; } MultipleAnimationHandle(final List<IAnimationHandle> handles); } | MultipleAnimationHandle implements IAnimationHandle { @Override public IAnimationHandle run() { handles.forEach(IAnimationHandle::run); return this; } MultipleAnimationHandle(final List<IAnimationHandle> handles); @Override IAnimationHandle run(); @Override IAnimationHandle stop(); @Override Node<?> getNode(); @Overrid... | MultipleAnimationHandle implements IAnimationHandle { @Override public IAnimationHandle run() { handles.forEach(IAnimationHandle::run); return this; } MultipleAnimationHandle(final List<IAnimationHandle> handles); @Override IAnimationHandle run(); @Override IAnimationHandle stop(); @Override Node<?> getNode(); @Overrid... |
@Test public void testStop() { tested.stop(); verify(handle1, times(1)).stop(); verify(handle2, times(1)).stop(); verify(handle1, never()).run(); verify(handle2, never()).run(); } | @Override public IAnimationHandle stop() { handles.forEach(IAnimationHandle::stop); return this; } | MultipleAnimationHandle implements IAnimationHandle { @Override public IAnimationHandle stop() { handles.forEach(IAnimationHandle::stop); return this; } } | MultipleAnimationHandle implements IAnimationHandle { @Override public IAnimationHandle stop() { handles.forEach(IAnimationHandle::stop); return this; } MultipleAnimationHandle(final List<IAnimationHandle> handles); } | MultipleAnimationHandle implements IAnimationHandle { @Override public IAnimationHandle stop() { handles.forEach(IAnimationHandle::stop); return this; } MultipleAnimationHandle(final List<IAnimationHandle> handles); @Override IAnimationHandle run(); @Override IAnimationHandle stop(); @Override Node<?> getNode(); @Overr... | MultipleAnimationHandle implements IAnimationHandle { @Override public IAnimationHandle stop() { handles.forEach(IAnimationHandle::stop); return this; } MultipleAnimationHandle(final List<IAnimationHandle> handles); @Override IAnimationHandle run(); @Override IAnimationHandle stop(); @Override Node<?> getNode(); @Overr... |
@Test public void testIsRunning() { when(handle1.isRunning()).thenReturn(false); when(handle2.isRunning()).thenReturn(false); assertFalse(tested.isRunning()); when(handle1.isRunning()).thenReturn(true); when(handle2.isRunning()).thenReturn(false); assertTrue(tested.isRunning()); when(handle1.isRunning()).thenReturn(fal... | @Override public boolean isRunning() { return handles.stream() .filter(IAnimationHandle::isRunning) .findAny() .isPresent(); } | MultipleAnimationHandle implements IAnimationHandle { @Override public boolean isRunning() { return handles.stream() .filter(IAnimationHandle::isRunning) .findAny() .isPresent(); } } | MultipleAnimationHandle implements IAnimationHandle { @Override public boolean isRunning() { return handles.stream() .filter(IAnimationHandle::isRunning) .findAny() .isPresent(); } MultipleAnimationHandle(final List<IAnimationHandle> handles); } | MultipleAnimationHandle implements IAnimationHandle { @Override public boolean isRunning() { return handles.stream() .filter(IAnimationHandle::isRunning) .findAny() .isPresent(); } MultipleAnimationHandle(final List<IAnimationHandle> handles); @Override IAnimationHandle run(); @Override IAnimationHandle stop(); @Overri... | MultipleAnimationHandle implements IAnimationHandle { @Override public boolean isRunning() { return handles.stream() .filter(IAnimationHandle::isRunning) .findAny() .isPresent(); } MultipleAnimationHandle(final List<IAnimationHandle> handles); @Override IAnimationHandle run(); @Override IAnimationHandle stop(); @Overri... |
@Test public void testBoundsAndLineBreaks() { final ITextWrapper wrapper = TextWrapperProvider.get(TextWrapperStrategy.BOUNDS_AND_LINE_BREAKS, text); assertTrue(wrapper instanceof TextBoundsAndLineBreaksWrap); } | public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return new TextLineBreakTrun... | TextWrapperProvider { public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return... | TextWrapperProvider { public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return... | TextWrapperProvider { public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return... | TextWrapperProvider { public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return... |
@Test public void testLineBreak() { final ITextWrapper wrapper = TextWrapperProvider.get(TextWrapperStrategy.LINE_BREAK, text); assertTrue(wrapper instanceof TextLineBreakWrap); } | public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return new TextLineBreakTrun... | TextWrapperProvider { public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return... | TextWrapperProvider { public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return... | TextWrapperProvider { public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return... | TextWrapperProvider { public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return... |
@Test public void testMakeSeparator() { final String drds = "DRDs"; final DecisionNavigatorItem drdSeparator = factory.makeSeparator(drds); assertEquals(drds, drdSeparator.getLabel()); assertEquals(SEPARATOR, drdSeparator.getType()); assertNotNull(drdSeparator.getUUID()); assertNull(drdSeparator.getParentUUID()); } | public DecisionNavigatorItem makeSeparator(final String label) { return navigatorItemBuilder() .withUUID(UUID.uuid()) .withLabel(label) .withType(SEPARATOR) .build(); } | DecisionNavigatorItemFactory { public DecisionNavigatorItem makeSeparator(final String label) { return navigatorItemBuilder() .withUUID(UUID.uuid()) .withLabel(label) .withType(SEPARATOR) .build(); } } | DecisionNavigatorItemFactory { public DecisionNavigatorItem makeSeparator(final String label) { return navigatorItemBuilder() .withUUID(UUID.uuid()) .withLabel(label) .withType(SEPARATOR) .build(); } @Inject DecisionNavigatorItemFactory(final DecisionNavigatorBaseItemFactory baseItemFactory,
... | DecisionNavigatorItemFactory { public DecisionNavigatorItem makeSeparator(final String label) { return navigatorItemBuilder() .withUUID(UUID.uuid()) .withLabel(label) .withType(SEPARATOR) .build(); } @Inject DecisionNavigatorItemFactory(final DecisionNavigatorBaseItemFactory baseItemFactory,
... | DecisionNavigatorItemFactory { public DecisionNavigatorItem makeSeparator(final String label) { return navigatorItemBuilder() .withUUID(UUID.uuid()) .withLabel(label) .withType(SEPARATOR) .build(); } @Inject DecisionNavigatorItemFactory(final DecisionNavigatorBaseItemFactory baseItemFactory,
... |
@Test public void testNoWrap() { final ITextWrapper wrapper = TextWrapperProvider.get(TextWrapperStrategy.NO_WRAP, text); assertTrue(wrapper instanceof TextNoWrap); } | public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return new TextLineBreakTrun... | TextWrapperProvider { public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return... | TextWrapperProvider { public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return... | TextWrapperProvider { public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return... | TextWrapperProvider { public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return... |
@Test public void testTruncate() { final ITextWrapper wrapper = TextWrapperProvider.get(TextWrapperStrategy.TRUNCATE, text); assertTrue(wrapper instanceof TextTruncateWrapper); } | public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return new TextLineBreakTrun... | TextWrapperProvider { public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return... | TextWrapperProvider { public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return... | TextWrapperProvider { public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return... | TextWrapperProvider { public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return... |
@Test public void testBounds() { final ITextWrapper wrapper = TextWrapperProvider.get(TextWrapperStrategy.BOUNDS, text); assertTrue(wrapper instanceof TextBoundsWrap); } | public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return new TextLineBreakTrun... | TextWrapperProvider { public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return... | TextWrapperProvider { public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return... | TextWrapperProvider { public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return... | TextWrapperProvider { public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return... |
@Test public void testTruncateWithLineBreak() { final ITextWrapper wrapper = TextWrapperProvider.get(TextWrapperStrategy.TRUNCATE_WITH_LINE_BREAK, text); assertTrue(wrapper instanceof TextLineBreakTruncateWrapper); } | public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return new TextLineBreakTrun... | TextWrapperProvider { public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return... | TextWrapperProvider { public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return... | TextWrapperProvider { public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return... | TextWrapperProvider { public static ITextWrapper get(final TextWrapperStrategy strategy, final Text text) { switch (strategy) { case BOUNDS_AND_LINE_BREAKS: return new TextBoundsAndLineBreaksWrap(text); case LINE_BREAK: return new TextLineBreakWrap(text); case NO_WRAP: return new TextNoWrap(text); case TRUNCATE: return... |
@Test public void testTextWrapBoundariesUpdates() { tested.refresh(); verify(textDecorator).update(); } | @Override public void refresh() { getTextViewDecorator().update(); super.refresh(); } | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public void refresh() { getTextViewDecorator().update(); super.refresh(); } } | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public void refresh() { getTextViewDecorator().update(); super.refresh(); } WiresShapeViewExt(final ViewEventTyp... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public void refresh() { getTextViewDecorator().update(); super.refresh(); } WiresShapeViewExt(final ViewEventTyp... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public void refresh() { getTextViewDecorator().update(); super.refresh(); } WiresShapeViewExt(final ViewEventTyp... |
@Test public void testSetTitleXOffsetPosition() { tested.setTitleXOffsetPosition(10.0); verify(textDecorator).setTitleXOffsetPosition(10.0); } | @Override public T setTitleXOffsetPosition(final Double xOffset) { textViewDecorator.setTitleXOffsetPosition(xOffset); return cast(); } | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public T setTitleXOffsetPosition(final Double xOffset) { textViewDecorator.setTitleXOffsetPosition(xOffset); ret... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public T setTitleXOffsetPosition(final Double xOffset) { textViewDecorator.setTitleXOffsetPosition(xOffset); ret... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public T setTitleXOffsetPosition(final Double xOffset) { textViewDecorator.setTitleXOffsetPosition(xOffset); ret... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public T setTitleXOffsetPosition(final Double xOffset) { textViewDecorator.setTitleXOffsetPosition(xOffset); ret... |
@Test public void testSetTitleYOffsetPosition() { tested.setTitleYOffsetPosition(10.0); verify(textDecorator).setTitleYOffsetPosition(10.0); } | @Override public T setTitleYOffsetPosition(final Double yOffset) { textViewDecorator.setTitleYOffsetPosition(yOffset); return cast(); } | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public T setTitleYOffsetPosition(final Double yOffset) { textViewDecorator.setTitleYOffsetPosition(yOffset); ret... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public T setTitleYOffsetPosition(final Double yOffset) { textViewDecorator.setTitleYOffsetPosition(yOffset); ret... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public T setTitleYOffsetPosition(final Double yOffset) { textViewDecorator.setTitleYOffsetPosition(yOffset); ret... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public T setTitleYOffsetPosition(final Double yOffset) { textViewDecorator.setTitleYOffsetPosition(yOffset); ret... |
@Test public void testTextNotIncludedInBoundBox() { tested.addChild(new Circle(43)); final BoundingBox startingBB = tested.getBoundingBox(); tested.setTitle("Some Title"); final BoundingBox endingBB = tested.getBoundingBox(); assertTrue(startingBB.getMinX() == endingBB.getMinX()); assertTrue(startingBB.getMinY() == end... | @Override @SuppressWarnings("unchecked") public T setTitle(final String title) { textViewDecorator.setTitle(title); addTextAsChild(); return cast(); } | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override @SuppressWarnings("unchecked") public T setTitle(final String title) { textViewDecorator.setTitle(title); addTex... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override @SuppressWarnings("unchecked") public T setTitle(final String title) { textViewDecorator.setTitle(title); addTex... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override @SuppressWarnings("unchecked") public T setTitle(final String title) { textViewDecorator.setTitle(title); addTex... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override @SuppressWarnings("unchecked") public T setTitle(final String title) { textViewDecorator.setTitle(title); addTex... |
@Test public void testGetTitleFontFamily() { assertEquals(null, tested.getTitleFontFamily()); } | @Override public String getTitleFontFamily() { return textViewDecorator.getTitleFontFamily(); } | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public String getTitleFontFamily() { return textViewDecorator.getTitleFontFamily(); } } | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public String getTitleFontFamily() { return textViewDecorator.getTitleFontFamily(); } WiresShapeViewExt(final Vi... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public String getTitleFontFamily() { return textViewDecorator.getTitleFontFamily(); } WiresShapeViewExt(final Vi... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public String getTitleFontFamily() { return textViewDecorator.getTitleFontFamily(); } WiresShapeViewExt(final Vi... |
@Test public void testGetTitleFontSize() { assertEquals(0.0, tested.getTitleFontSize(), 0.001); } | @Override public double getTitleFontSize() { return textViewDecorator.getTitleFontSize(); } | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public double getTitleFontSize() { return textViewDecorator.getTitleFontSize(); } } | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public double getTitleFontSize() { return textViewDecorator.getTitleFontSize(); } WiresShapeViewExt(final ViewEv... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public double getTitleFontSize() { return textViewDecorator.getTitleFontSize(); } WiresShapeViewExt(final ViewEv... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public double getTitleFontSize() { return textViewDecorator.getTitleFontSize(); } WiresShapeViewExt(final ViewEv... |
@Test public void testGetOnClickAction() { final DMNDiagramElement dmnDiagramElement = mock(DMNDiagramElement.class); factory.getOnClickAction(dmnDiagramElement).execute(); verify(selectedEvent).fire(diagramSelectedArgumentCaptor.capture()); assertEquals(dmnDiagramElement, diagramSelectedArgumentCaptor.getValue().getDi... | Command getOnClickAction(final DMNDiagramElement dmnDiagramElement) { return () -> { selectedEvent.fire(new DMNDiagramSelected(dmnDiagramElement)); }; } | DecisionNavigatorItemFactory { Command getOnClickAction(final DMNDiagramElement dmnDiagramElement) { return () -> { selectedEvent.fire(new DMNDiagramSelected(dmnDiagramElement)); }; } } | DecisionNavigatorItemFactory { Command getOnClickAction(final DMNDiagramElement dmnDiagramElement) { return () -> { selectedEvent.fire(new DMNDiagramSelected(dmnDiagramElement)); }; } @Inject DecisionNavigatorItemFactory(final DecisionNavigatorBaseItemFactory baseItemFactory,
fi... | DecisionNavigatorItemFactory { Command getOnClickAction(final DMNDiagramElement dmnDiagramElement) { return () -> { selectedEvent.fire(new DMNDiagramSelected(dmnDiagramElement)); }; } @Inject DecisionNavigatorItemFactory(final DecisionNavigatorBaseItemFactory baseItemFactory,
fi... | DecisionNavigatorItemFactory { Command getOnClickAction(final DMNDiagramElement dmnDiagramElement) { return () -> { selectedEvent.fire(new DMNDiagramSelected(dmnDiagramElement)); }; } @Inject DecisionNavigatorItemFactory(final DecisionNavigatorBaseItemFactory baseItemFactory,
fi... |
@Test public void testGetTitlePosition() { assertEquals("INSIDE", tested.getTitlePosition()); } | @Override public String getTitlePosition() { return textViewDecorator.getLabelLayout() .getDirectionLayout() .getReferencePosition() .toString(); } | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public String getTitlePosition() { return textViewDecorator.getLabelLayout() .getDirectionLayout() .getReference... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public String getTitlePosition() { return textViewDecorator.getLabelLayout() .getDirectionLayout() .getReference... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public String getTitlePosition() { return textViewDecorator.getLabelLayout() .getDirectionLayout() .getReference... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public String getTitlePosition() { return textViewDecorator.getLabelLayout() .getDirectionLayout() .getReference... |
@Test public void testGetOrientation() { assertEquals("HORIZONTAL", tested.getOrientation()); } | @Override public String getOrientation() { return textViewDecorator.getLabelLayout() .getDirectionLayout() .getOrientation() .name(); } | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public String getOrientation() { return textViewDecorator.getLabelLayout() .getDirectionLayout() .getOrientation... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public String getOrientation() { return textViewDecorator.getLabelLayout() .getDirectionLayout() .getOrientation... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public String getOrientation() { return textViewDecorator.getLabelLayout() .getDirectionLayout() .getOrientation... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public String getOrientation() { return textViewDecorator.getLabelLayout() .getDirectionLayout() .getOrientation... |
@Test public void testGetMarginX() { assertEquals(0.0, tested.getMarginX(), 0.001); } | @Override public double getMarginX() { return textViewDecorator.getLabelLayout().getSizeConstraints().getMarginX(); } | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public double getMarginX() { return textViewDecorator.getLabelLayout().getSizeConstraints().getMarginX(); } } | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public double getMarginX() { return textViewDecorator.getLabelLayout().getSizeConstraints().getMarginX(); } Wire... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public double getMarginX() { return textViewDecorator.getLabelLayout().getSizeConstraints().getMarginX(); } Wire... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public double getMarginX() { return textViewDecorator.getLabelLayout().getSizeConstraints().getMarginX(); } Wire... |
@Test public void testGetFontPosition() { assertEquals("INSIDE", tested.getFontPosition()); } | @Override public String getFontPosition() { return textViewDecorator.getLabelLayout() .getDirectionLayout() .getReferencePosition() .name(); } | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public String getFontPosition() { return textViewDecorator.getLabelLayout() .getDirectionLayout() .getReferenceP... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public String getFontPosition() { return textViewDecorator.getLabelLayout() .getDirectionLayout() .getReferenceP... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public String getFontPosition() { return textViewDecorator.getLabelLayout() .getDirectionLayout() .getReferenceP... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public String getFontPosition() { return textViewDecorator.getLabelLayout() .getDirectionLayout() .getReferenceP... |
@Test public void testGetFontAlignment() { assertEquals("MIDDLE", tested.getFontAlignment()); } | @Override public String getFontAlignment() { return textViewDecorator.getLabelLayout() .getDirectionLayout() .getVerticalAlignment() .name(); } | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public String getFontAlignment() { return textViewDecorator.getLabelLayout() .getDirectionLayout() .getVerticalA... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public String getFontAlignment() { return textViewDecorator.getLabelLayout() .getDirectionLayout() .getVerticalA... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public String getFontAlignment() { return textViewDecorator.getLabelLayout() .getDirectionLayout() .getVerticalA... | WiresShapeViewExt extends WiresShapeView<T> implements HasTitle<T>,
HasControlPoints<T>,
HasEventHandlers<T, Shape<?>>,
HasFillGradient<T> { @Override public String getFontAlignment() { return textViewDecorator.getLabelLayout() .getDirectionLayout() .getVerticalA... |
@Test public void ensureResizeUpdatesTheNode() { when(layout.getMaxSize(any())).thenReturn(NEW_SIZE); decorator.update(); verify(layout, atLeastOnce()).execute(); assertBoundaries(NEW_SIZE.getWidth(), NEW_SIZE.getHeight()); } | public void update() { setTextBoundaries(shape.getPath().getBoundingBox()); } | WiresTextDecorator implements HasTitle<WiresTextDecorator> { public void update() { setTextBoundaries(shape.getPath().getBoundingBox()); } } | WiresTextDecorator implements HasTitle<WiresTextDecorator> { public void update() { setTextBoundaries(shape.getPath().getBoundingBox()); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresShapeViewExt shape); } | WiresTextDecorator implements HasTitle<WiresTextDecorator> { public void update() { setTextBoundaries(shape.getPath().getBoundingBox()); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresShapeViewExt shape); void setTextClickHandler(final ViewHand... | WiresTextDecorator implements HasTitle<WiresTextDecorator> { public void update() { setTextBoundaries(shape.getPath().getBoundingBox()); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresShapeViewExt shape); void setTextClickHandler(final ViewHand... |
@Test public void assertWidthHeightWhenMaxSizeIsNull() { when(layout.getMaxSize(any())).thenReturn(null); decorator.setTextBoundaries(30, 30); verify(layout, atLeastOnce()).execute(); assertBoundaries(30, 30); } | @Override public void setTextBoundaries(final double width, final double height) { setTextBoundaries(new BoundingBox(0, 0, width, height)); } | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public void setTextBoundaries(final double width, final double height) { setTextBoundaries(new BoundingBox(0, 0, width, height)); } } | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public void setTextBoundaries(final double width, final double height) { setTextBoundaries(new BoundingBox(0, 0, width, height)); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final W... | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public void setTextBoundaries(final double width, final double height) { setTextBoundaries(new BoundingBox(0, 0, width, height)); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final W... | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public void setTextBoundaries(final double width, final double height) { setTextBoundaries(new BoundingBox(0, 0, width, height)); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final W... |
@Test public void testMoveTitleToFront() { Text text = spy(new Text("")); Whitebox.setInternalState(decorator, "text", text); decorator.moveTitleToTop(); InOrder order = inOrder(text, child1.getGroup(), child2.getGroup()); order.verify(text).moveToTop(); order.verify(child1.getGroup()).moveToTop(); order.verify(child2.... | @SuppressWarnings("unchecked") public WiresTextDecorator moveTitleToTop() { text.moveToTop(); moveShapeChildrenToFront(); return this; } | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @SuppressWarnings("unchecked") public WiresTextDecorator moveTitleToTop() { text.moveToTop(); moveShapeChildrenToFront(); return this; } } | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @SuppressWarnings("unchecked") public WiresTextDecorator moveTitleToTop() { text.moveToTop(); moveShapeChildrenToFront(); return this; } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresS... | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @SuppressWarnings("unchecked") public WiresTextDecorator moveTitleToTop() { text.moveToTop(); moveShapeChildrenToFront(); return this; } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresS... | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @SuppressWarnings("unchecked") public WiresTextDecorator moveTitleToTop() { text.moveToTop(); moveShapeChildrenToFront(); return this; } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresS... |
@Test public void testGetTitleFontFamily() { assertEquals("Verdana", decorator.getTitleFontFamily()); } | @Override public String getTitleFontFamily() { return text.getFontFamily(); } | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public String getTitleFontFamily() { return text.getFontFamily(); } } | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public String getTitleFontFamily() { return text.getFontFamily(); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresShapeViewExt shape); } | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public String getTitleFontFamily() { return text.getFontFamily(); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresShapeViewExt shape); void setTextClickHandler(final ViewHand... | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public String getTitleFontFamily() { return text.getFontFamily(); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresShapeViewExt shape); void setTextClickHandler(final ViewHand... |
@Test public void testGetTitleFontSize() { assertEquals(10.0, decorator.getTitleFontSize(), 0.001); } | @Override public double getTitleFontSize() { return text.getFontSize(); } | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public double getTitleFontSize() { return text.getFontSize(); } } | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public double getTitleFontSize() { return text.getFontSize(); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresShapeViewExt shape); } | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public double getTitleFontSize() { return text.getFontSize(); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresShapeViewExt shape); void setTextClickHandler(final ViewHandler<... | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public double getTitleFontSize() { return text.getFontSize(); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresShapeViewExt shape); void setTextClickHandler(final ViewHandler<... |
@Test public void testGetOnUpdate() { final DMNDiagramElement dmnDiagramElement = mock(DMNDiagramElement.class); final DecisionNavigatorItem item = mock(DecisionNavigatorItem.class); final Name dmnDiagramElementName = new Name(); final String newDiagramName = "New diagram name"; when(item.getLabel()).thenReturn(newDiag... | Consumer<DecisionNavigatorItem> getOnUpdate(final DMNDiagramElement dmnDiagramElement) { return (item) -> { dmnDiagramElement.getName().setValue(item.getLabel()); selectedEvent.fire(new DMNDiagramSelected(dmnDiagramElement)); }; } | DecisionNavigatorItemFactory { Consumer<DecisionNavigatorItem> getOnUpdate(final DMNDiagramElement dmnDiagramElement) { return (item) -> { dmnDiagramElement.getName().setValue(item.getLabel()); selectedEvent.fire(new DMNDiagramSelected(dmnDiagramElement)); }; } } | DecisionNavigatorItemFactory { Consumer<DecisionNavigatorItem> getOnUpdate(final DMNDiagramElement dmnDiagramElement) { return (item) -> { dmnDiagramElement.getName().setValue(item.getLabel()); selectedEvent.fire(new DMNDiagramSelected(dmnDiagramElement)); }; } @Inject DecisionNavigatorItemFactory(final DecisionNaviga... | DecisionNavigatorItemFactory { Consumer<DecisionNavigatorItem> getOnUpdate(final DMNDiagramElement dmnDiagramElement) { return (item) -> { dmnDiagramElement.getName().setValue(item.getLabel()); selectedEvent.fire(new DMNDiagramSelected(dmnDiagramElement)); }; } @Inject DecisionNavigatorItemFactory(final DecisionNaviga... | DecisionNavigatorItemFactory { Consumer<DecisionNavigatorItem> getOnUpdate(final DMNDiagramElement dmnDiagramElement) { return (item) -> { dmnDiagramElement.getName().setValue(item.getLabel()); selectedEvent.fire(new DMNDiagramSelected(dmnDiagramElement)); }; } @Inject DecisionNavigatorItemFactory(final DecisionNaviga... |
@Test public void testGetTitlePosition() { assertEquals("INSIDE", decorator.getTitlePosition()); } | @Override public String getTitlePosition() { return getLabelLayout() .getDirectionLayout() .getReferencePosition() .toString(); } | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public String getTitlePosition() { return getLabelLayout() .getDirectionLayout() .getReferencePosition() .toString(); } } | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public String getTitlePosition() { return getLabelLayout() .getDirectionLayout() .getReferencePosition() .toString(); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresShapeVie... | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public String getTitlePosition() { return getLabelLayout() .getDirectionLayout() .getReferencePosition() .toString(); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresShapeVie... | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public String getTitlePosition() { return getLabelLayout() .getDirectionLayout() .getReferencePosition() .toString(); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresShapeVie... |
@Test public void testGetOrientation() { assertEquals("HORIZONTAL", decorator.getOrientation()); } | @Override public String getOrientation() { return getLabelLayout() .getDirectionLayout() .getOrientation().name(); } | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public String getOrientation() { return getLabelLayout() .getDirectionLayout() .getOrientation().name(); } } | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public String getOrientation() { return getLabelLayout() .getDirectionLayout() .getOrientation().name(); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresShapeViewExt shape); ... | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public String getOrientation() { return getLabelLayout() .getDirectionLayout() .getOrientation().name(); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresShapeViewExt shape); ... | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public String getOrientation() { return getLabelLayout() .getDirectionLayout() .getOrientation().name(); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresShapeViewExt shape); ... |
@Test public void testGetMarginX() { assertEquals(0.0, decorator.getMarginX(), 0.001); } | @Override public double getMarginX() { return getLabelLayout().getSizeConstraints().getMarginX(); } | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public double getMarginX() { return getLabelLayout().getSizeConstraints().getMarginX(); } } | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public double getMarginX() { return getLabelLayout().getSizeConstraints().getMarginX(); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresShapeViewExt shape); } | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public double getMarginX() { return getLabelLayout().getSizeConstraints().getMarginX(); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresShapeViewExt shape); void setTextClick... | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public double getMarginX() { return getLabelLayout().getSizeConstraints().getMarginX(); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresShapeViewExt shape); void setTextClick... |
@Test public void testGetFontPosition() { assertEquals("INSIDE", decorator.getFontPosition()); } | @Override public String getFontPosition() { return getLabelLayout() .getDirectionLayout() .getReferencePosition() .name(); } | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public String getFontPosition() { return getLabelLayout() .getDirectionLayout() .getReferencePosition() .name(); } } | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public String getFontPosition() { return getLabelLayout() .getDirectionLayout() .getReferencePosition() .name(); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresShapeViewExt ... | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public String getFontPosition() { return getLabelLayout() .getDirectionLayout() .getReferencePosition() .name(); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresShapeViewExt ... | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public String getFontPosition() { return getLabelLayout() .getDirectionLayout() .getReferencePosition() .name(); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresShapeViewExt ... |
@Test public void testGetFontAlignment() { assertEquals("MIDDLE", decorator.getFontAlignment()); } | @Override public String getFontAlignment() { return getLabelLayout() .getDirectionLayout() .getVerticalAlignment() .name(); } | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public String getFontAlignment() { return getLabelLayout() .getDirectionLayout() .getVerticalAlignment() .name(); } } | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public String getFontAlignment() { return getLabelLayout() .getDirectionLayout() .getVerticalAlignment() .name(); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresShapeViewExt... | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public String getFontAlignment() { return getLabelLayout() .getDirectionLayout() .getVerticalAlignment() .name(); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresShapeViewExt... | WiresTextDecorator implements HasTitle<WiresTextDecorator> { @Override public String getFontAlignment() { return getLabelLayout() .getDirectionLayout() .getVerticalAlignment() .name(); } WiresTextDecorator(final Supplier<ViewEventHandlerManager> eventHandlerManager,
final WiresShapeViewExt... |
@Test public void testSetDragBounds() { tested.setDragBounds(Bounds.create(1.5d, 6.4d, 564.78d, 543.84d)); ArgumentCaptor<OptionalBounds> bbCaptor = ArgumentCaptor.forClass(OptionalBounds.class); verify(control, times(1)).setLocationBounds(bbCaptor.capture()); final OptionalBounds bb = bbCaptor.getValue(); assertEquals... | @Override public T setDragBounds(final Bounds bounds) { ifLocationBoundsConstraintsSupported(() -> LienzoShapeUtils.translateBounds(bounds)); return cast(); } | WiresShapeView extends WiresShape implements LienzoShapeView<T>,
HasDragBounds<T> { @Override public T setDragBounds(final Bounds bounds) { ifLocationBoundsConstraintsSupported(() -> LienzoShapeUtils.translateBounds(bounds)); return cast(); } } | WiresShapeView extends WiresShape implements LienzoShapeView<T>,
HasDragBounds<T> { @Override public T setDragBounds(final Bounds bounds) { ifLocationBoundsConstraintsSupported(() -> LienzoShapeUtils.translateBounds(bounds)); return cast(); } WiresShapeView(final MultiPath path); WiresShapeView(fina... | WiresShapeView extends WiresShape implements LienzoShapeView<T>,
HasDragBounds<T> { @Override public T setDragBounds(final Bounds bounds) { ifLocationBoundsConstraintsSupported(() -> LienzoShapeUtils.translateBounds(bounds)); return cast(); } WiresShapeView(final MultiPath path); WiresShapeView(fina... | WiresShapeView extends WiresShape implements LienzoShapeView<T>,
HasDragBounds<T> { @Override public T setDragBounds(final Bounds bounds) { ifLocationBoundsConstraintsSupported(() -> LienzoShapeUtils.translateBounds(bounds)); return cast(); } WiresShapeView(final MultiPath path); WiresShapeView(fina... |
@Test public void testListening() { tested.setListening(true); assertTrue(tested.getPath().isListening()); assertTrue(tested.getPath().isFillBoundsForSelection()); tested.setListening(false); assertFalse(tested.getPath().isListening()); assertFalse(tested.getPath().isFillBoundsForSelection()); } | public T setListening(final boolean listening) { getPath().setFillBoundsForSelection(listening); listen(listening); return cast(); } | WiresShapeView extends WiresShape implements LienzoShapeView<T>,
HasDragBounds<T> { public T setListening(final boolean listening) { getPath().setFillBoundsForSelection(listening); listen(listening); return cast(); } } | WiresShapeView extends WiresShape implements LienzoShapeView<T>,
HasDragBounds<T> { public T setListening(final boolean listening) { getPath().setFillBoundsForSelection(listening); listen(listening); return cast(); } WiresShapeView(final MultiPath path); WiresShapeView(final MultiPath path,
... | WiresShapeView extends WiresShape implements LienzoShapeView<T>,
HasDragBounds<T> { public T setListening(final boolean listening) { getPath().setFillBoundsForSelection(listening); listen(listening); return cast(); } WiresShapeView(final MultiPath path); WiresShapeView(final MultiPath path,
... | WiresShapeView extends WiresShape implements LienzoShapeView<T>,
HasDragBounds<T> { public T setListening(final boolean listening) { getPath().setFillBoundsForSelection(listening); listen(listening); return cast(); } WiresShapeView(final MultiPath path); WiresShapeView(final MultiPath path,
... |
@Test @SuppressWarnings("unchecked") public void testConsumeChildrenAndConnectors() { final Consumer<IDrawable> consumer = mock(Consumer.class); final WiresShapeView child1 = newShape(); final WiresShapeView child2 = newShape(); tested.add(child1); tested.add(child2); final WiresConnectorView connector1 = newConnector(... | void consumeChildrenAndConnectors(final Consumer<IDrawable> primConsumer) { primConsumer.accept(getContainer()); final NFastArrayList<WiresShape> childShapes = getChildShapes(); if (null != childShapes) { for (int i = 0; i < childShapes.size(); i++) { final WiresShape shape = childShapes.get(i); if (shape instanceof Wi... | WiresShapeView extends WiresShape implements LienzoShapeView<T>,
HasDragBounds<T> { void consumeChildrenAndConnectors(final Consumer<IDrawable> primConsumer) { primConsumer.accept(getContainer()); final NFastArrayList<WiresShape> childShapes = getChildShapes(); if (null != childShapes) { for (int i =... | WiresShapeView extends WiresShape implements LienzoShapeView<T>,
HasDragBounds<T> { void consumeChildrenAndConnectors(final Consumer<IDrawable> primConsumer) { primConsumer.accept(getContainer()); final NFastArrayList<WiresShape> childShapes = getChildShapes(); if (null != childShapes) { for (int i =... | WiresShapeView extends WiresShape implements LienzoShapeView<T>,
HasDragBounds<T> { void consumeChildrenAndConnectors(final Consumer<IDrawable> primConsumer) { primConsumer.accept(getContainer()); final NFastArrayList<WiresShape> childShapes = getChildShapes(); if (null != childShapes) { for (int i =... | WiresShapeView extends WiresShape implements LienzoShapeView<T>,
HasDragBounds<T> { void consumeChildrenAndConnectors(final Consumer<IDrawable> primConsumer) { primConsumer.accept(getContainer()); final NFastArrayList<WiresShape> childShapes = getChildShapes(); if (null != childShapes) { for (int i =... |
@Test public void testDecorators() { final List decorators = tested.getDecorators(); assertNotNull(decorators); assertEquals(1, decorators.size()); assertEquals(PATH, decorators.get(0)); } | @Override public List<Shape<?>> getDecorators() { return Collections.singletonList(getShape()); } | WiresShapeView extends WiresShape implements LienzoShapeView<T>,
HasDragBounds<T> { @Override public List<Shape<?>> getDecorators() { return Collections.singletonList(getShape()); } } | WiresShapeView extends WiresShape implements LienzoShapeView<T>,
HasDragBounds<T> { @Override public List<Shape<?>> getDecorators() { return Collections.singletonList(getShape()); } WiresShapeView(final MultiPath path); WiresShapeView(final MultiPath path,
final LayoutConta... | WiresShapeView extends WiresShape implements LienzoShapeView<T>,
HasDragBounds<T> { @Override public List<Shape<?>> getDecorators() { return Collections.singletonList(getShape()); } WiresShapeView(final MultiPath path); WiresShapeView(final MultiPath path,
final LayoutConta... | WiresShapeView extends WiresShape implements LienzoShapeView<T>,
HasDragBounds<T> { @Override public List<Shape<?>> getDecorators() { return Collections.singletonList(getShape()); } WiresShapeView(final MultiPath path); WiresShapeView(final MultiPath path,
final LayoutConta... |
@Test public void testDestroy() { tested.destroy(); assertNull(tested.getParent()); } | @Override public void destroy() { super.destroy(); unsetDragBounds(); } | WiresShapeView extends WiresShape implements LienzoShapeView<T>,
HasDragBounds<T> { @Override public void destroy() { super.destroy(); unsetDragBounds(); } } | WiresShapeView extends WiresShape implements LienzoShapeView<T>,
HasDragBounds<T> { @Override public void destroy() { super.destroy(); unsetDragBounds(); } WiresShapeView(final MultiPath path); WiresShapeView(final MultiPath path,
final LayoutContainer layoutContainer); } | WiresShapeView extends WiresShape implements LienzoShapeView<T>,
HasDragBounds<T> { @Override public void destroy() { super.destroy(); unsetDragBounds(); } WiresShapeView(final MultiPath path); WiresShapeView(final MultiPath path,
final LayoutContainer layoutContainer); Sha... | WiresShapeView extends WiresShape implements LienzoShapeView<T>,
HasDragBounds<T> { @Override public void destroy() { super.destroy(); unsetDragBounds(); } WiresShapeView(final MultiPath path); WiresShapeView(final MultiPath path,
final LayoutContainer layoutContainer); Sha... |
@Test public void testGetOnRemove() { final DMNDiagramElement drgDiagramElement = new DMNDiagramElement(); final DMNDiagramElement drd1DiagramElement = new DMNDiagramElement(); final DMNDiagramElement drd2DiagramElement = new DMNDiagramElement(); final DMNDiagramElement drgElement = mock(DMNDiagramElement.class); final... | Consumer<DecisionNavigatorItem> getOnRemove(final DMNDiagramElement dmnDiagramElement) { return (item) -> { removeFromModel(dmnDiagramElement); removeFromSession(dmnDiagramElement); selectedEvent.fire(new DMNDiagramSelected(dmnDiagramsSession.getDRGDiagramElement())); }; } | DecisionNavigatorItemFactory { Consumer<DecisionNavigatorItem> getOnRemove(final DMNDiagramElement dmnDiagramElement) { return (item) -> { removeFromModel(dmnDiagramElement); removeFromSession(dmnDiagramElement); selectedEvent.fire(new DMNDiagramSelected(dmnDiagramsSession.getDRGDiagramElement())); }; } } | DecisionNavigatorItemFactory { Consumer<DecisionNavigatorItem> getOnRemove(final DMNDiagramElement dmnDiagramElement) { return (item) -> { removeFromModel(dmnDiagramElement); removeFromSession(dmnDiagramElement); selectedEvent.fire(new DMNDiagramSelected(dmnDiagramsSession.getDRGDiagramElement())); }; } @Inject Decisi... | DecisionNavigatorItemFactory { Consumer<DecisionNavigatorItem> getOnRemove(final DMNDiagramElement dmnDiagramElement) { return (item) -> { removeFromModel(dmnDiagramElement); removeFromSession(dmnDiagramElement); selectedEvent.fire(new DMNDiagramSelected(dmnDiagramsSession.getDRGDiagramElement())); }; } @Inject Decisi... | DecisionNavigatorItemFactory { Consumer<DecisionNavigatorItem> getOnRemove(final DMNDiagramElement dmnDiagramElement) { return (item) -> { removeFromModel(dmnDiagramElement); removeFromSession(dmnDiagramElement); selectedEvent.fire(new DMNDiagramSelected(dmnDiagramsSession.getDRGDiagramElement())); }; } @Inject Decisi... |
@Test public void testShowControlPoints() { final WiresConnectorControl connectorControl = mock(WiresConnectorControl.class); tested.setControl(connectorControl); final Object wcv = tested.showControlPoints(HasControlPoints.ControlPointType.POINTS); assertEquals(wcv, tested); verify(connectorControl, times(1)).showCont... | @Override @SuppressWarnings("unchecked") public T showControlPoints(final ControlPointType type) { if (null != getControl()) { if (ControlPointType.POINTS.equals(type)) { getControl().showControlPoints(); } else { throw new UnsupportedOperationException("Control point type [" + type + "] not supported yet"); } } return... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override @SuppressWarnings("unchecked") public T showControlPoints(final ControlPointType type) { if (null != getControl()) { if (ControlPointType.POINTS.equals(type)) { getC... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override @SuppressWarnings("unchecked") public T showControlPoints(final ControlPointType type) { if (null != getControl()) { if (ControlPointType.POINTS.equals(type)) { getC... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override @SuppressWarnings("unchecked") public T showControlPoints(final ControlPointType type) { if (null != getControl()) { if (ControlPointType.POINTS.equals(type)) { getC... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override @SuppressWarnings("unchecked") public T showControlPoints(final ControlPointType type) { if (null != getControl()) { if (ControlPointType.POINTS.equals(type)) { getC... |
@Test(expected = UnsupportedOperationException.class) public void testShowControlPointsNotSupported() { final WiresConnectorControl connectorControl = mock(WiresConnectorControl.class); tested.setControl(connectorControl); tested.showControlPoints(HasControlPoints.ControlPointType.RESIZE); } | @Override @SuppressWarnings("unchecked") public T showControlPoints(final ControlPointType type) { if (null != getControl()) { if (ControlPointType.POINTS.equals(type)) { getControl().showControlPoints(); } else { throw new UnsupportedOperationException("Control point type [" + type + "] not supported yet"); } } return... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override @SuppressWarnings("unchecked") public T showControlPoints(final ControlPointType type) { if (null != getControl()) { if (ControlPointType.POINTS.equals(type)) { getC... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override @SuppressWarnings("unchecked") public T showControlPoints(final ControlPointType type) { if (null != getControl()) { if (ControlPointType.POINTS.equals(type)) { getC... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override @SuppressWarnings("unchecked") public T showControlPoints(final ControlPointType type) { if (null != getControl()) { if (ControlPointType.POINTS.equals(type)) { getC... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override @SuppressWarnings("unchecked") public T showControlPoints(final ControlPointType type) { if (null != getControl()) { if (ControlPointType.POINTS.equals(type)) { getC... |
@Test public void testHideControlPoints() { final WiresConnectorControl connectorControl = mock(WiresConnectorControl.class); tested.setControl(connectorControl); final Object wcv = tested.hideControlPoints(); assertEquals(wcv, tested); verify(connectorControl, times(1)).hideControlPoints(); verify(connectorControl, ne... | @Override @SuppressWarnings("unchecked") public T hideControlPoints() { if (null != getControl()) { getControl().hideControlPoints(); } return cast(); } | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override @SuppressWarnings("unchecked") public T hideControlPoints() { if (null != getControl()) { getControl().hideControlPoints(); } return cast(); } } | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override @SuppressWarnings("unchecked") public T hideControlPoints() { if (null != getControl()) { getControl().hideControlPoints(); } return cast(); } WiresConnectorView(fin... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override @SuppressWarnings("unchecked") public T hideControlPoints() { if (null != getControl()) { getControl().hideControlPoints(); } return cast(); } WiresConnectorView(fin... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override @SuppressWarnings("unchecked") public T hideControlPoints() { if (null != getControl()) { getControl().hideControlPoints(); } return cast(); } WiresConnectorView(fin... |
@Test public void testConnectMagnets() { MagnetManager.Magnets headMagnets = mock(MagnetManager.Magnets.class); WiresMagnet headMagnet = mock(WiresMagnet.class); when(headMagnets.getMagnet(eq(3))).thenReturn(headMagnet); when(headMagnet.getIndex()).thenReturn(3); Point2D headPoint = new Point2D(10, 20); MagnetConnectio... | @SuppressWarnings("unchecked") public T connect(final ShapeView headShapeView, final Connection headConnection, final ShapeView tailShapeView, final Connection tailConnection) { final Optional<WiresShape> headWiresShape = Optional.ofNullable((WiresShape) headShapeView); final Optional<WiresShape> tailWiresShape = Optio... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @SuppressWarnings("unchecked") public T connect(final ShapeView headShapeView, final Connection headConnection, final ShapeView tailShapeView, final Connection tailConnection)... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @SuppressWarnings("unchecked") public T connect(final ShapeView headShapeView, final Connection headConnection, final ShapeView tailShapeView, final Connection tailConnection)... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @SuppressWarnings("unchecked") public T connect(final ShapeView headShapeView, final Connection headConnection, final ShapeView tailShapeView, final Connection tailConnection)... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @SuppressWarnings("unchecked") public T connect(final ShapeView headShapeView, final Connection headConnection, final ShapeView tailShapeView, final Connection tailConnection)... |
@Test public void testConnectMagnetsByLocation() { IControlHandleList headControlHandleList = new ControlHandleList(mock(Shape.class)); WiresMagnet headMagnet1 = mock(WiresMagnet.class); when(headMagnet1.getX()).thenReturn(10d); when(headMagnet1.getY()).thenReturn(20d); when(headMagnet1.getIndex()).thenReturn(0); IPrim... | @SuppressWarnings("unchecked") public T connect(final ShapeView headShapeView, final Connection headConnection, final ShapeView tailShapeView, final Connection tailConnection) { final Optional<WiresShape> headWiresShape = Optional.ofNullable((WiresShape) headShapeView); final Optional<WiresShape> tailWiresShape = Optio... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @SuppressWarnings("unchecked") public T connect(final ShapeView headShapeView, final Connection headConnection, final ShapeView tailShapeView, final Connection tailConnection)... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @SuppressWarnings("unchecked") public T connect(final ShapeView headShapeView, final Connection headConnection, final ShapeView tailShapeView, final Connection tailConnection)... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @SuppressWarnings("unchecked") public T connect(final ShapeView headShapeView, final Connection headConnection, final ShapeView tailShapeView, final Connection tailConnection)... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @SuppressWarnings("unchecked") public T connect(final ShapeView headShapeView, final Connection headConnection, final ShapeView tailShapeView, final Connection tailConnection)... |
@Test public void testConnectByPoints() { final Point2DConnection headConnection = Point2DConnection.at(org.kie.workbench.common.stunner.core.graph.content.view.Point2D.create(13d, 56.6d)); final Point2DConnection tailConnection = Point2DConnection.at(org.kie.workbench.common.stunner.core.graph.content.view.Point2D.cre... | @SuppressWarnings("unchecked") public T connect(final ShapeView headShapeView, final Connection headConnection, final ShapeView tailShapeView, final Connection tailConnection) { final Optional<WiresShape> headWiresShape = Optional.ofNullable((WiresShape) headShapeView); final Optional<WiresShape> tailWiresShape = Optio... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @SuppressWarnings("unchecked") public T connect(final ShapeView headShapeView, final Connection headConnection, final ShapeView tailShapeView, final Connection tailConnection)... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @SuppressWarnings("unchecked") public T connect(final ShapeView headShapeView, final Connection headConnection, final ShapeView tailShapeView, final Connection tailConnection)... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @SuppressWarnings("unchecked") public T connect(final ShapeView headShapeView, final Connection headConnection, final ShapeView tailShapeView, final Connection tailConnection)... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @SuppressWarnings("unchecked") public T connect(final ShapeView headShapeView, final Connection headConnection, final ShapeView tailShapeView, final Connection tailConnection)... |
@Test @SuppressWarnings("unchecked") public void testGetEmptyControlPoints() { Point2DArray linePoints = new Point2DArray(new Point2D(0, 0), new Point2D(1, 2)); when(line.getPoint2DArray()).thenReturn(linePoints); ControlPoint[] controlPoints = tested.getManageableControlPoints(); assertNotNull(controlPoints); assertEq... | @Override public ControlPoint[] getManageableControlPoints() { final Point2DArray controlPoints = getControlPoints(); if (null != controlPoints && controlPoints.size() > 2) { return StreamSupport.stream(controlPoints.spliterator(), false) .limit(controlPoints.size() - 1) .skip(1) .map(controlPoint -> ControlPoint.build... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public ControlPoint[] getManageableControlPoints() { final Point2DArray controlPoints = getControlPoints(); if (null != controlPoints && controlPoints.size() > 2) { ... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public ControlPoint[] getManageableControlPoints() { final Point2DArray controlPoints = getControlPoints(); if (null != controlPoints && controlPoints.size() > 2) { ... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public ControlPoint[] getManageableControlPoints() { final Point2DArray controlPoints = getControlPoints(); if (null != controlPoints && controlPoints.size() > 2) { ... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public ControlPoint[] getManageableControlPoints() { final Point2DArray controlPoints = getControlPoints(); if (null != controlPoints && controlPoints.size() > 2) { ... |
@Test @SuppressWarnings("unchecked") public void testGetEmptyControlPoints2() { Point2DArray linePoints = new Point2DArray(new Point2D(0, 0)); when(line.getPoint2DArray()).thenReturn(linePoints); ControlPoint[] controlPoints = tested.getManageableControlPoints(); assertNotNull(controlPoints); assertEquals(0, controlPoi... | @Override public ControlPoint[] getManageableControlPoints() { final Point2DArray controlPoints = getControlPoints(); if (null != controlPoints && controlPoints.size() > 2) { return StreamSupport.stream(controlPoints.spliterator(), false) .limit(controlPoints.size() - 1) .skip(1) .map(controlPoint -> ControlPoint.build... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public ControlPoint[] getManageableControlPoints() { final Point2DArray controlPoints = getControlPoints(); if (null != controlPoints && controlPoints.size() > 2) { ... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public ControlPoint[] getManageableControlPoints() { final Point2DArray controlPoints = getControlPoints(); if (null != controlPoints && controlPoints.size() > 2) { ... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public ControlPoint[] getManageableControlPoints() { final Point2DArray controlPoints = getControlPoints(); if (null != controlPoints && controlPoints.size() > 2) { ... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public ControlPoint[] getManageableControlPoints() { final Point2DArray controlPoints = getControlPoints(); if (null != controlPoints && controlPoints.size() > 2) { ... |
@Test @SuppressWarnings("unchecked") public void testGetControlPoints() { Point2DArray linePoints = new Point2DArray(new Point2D(0, 0), new Point2D(0.1, 0.2), new Point2D(0.3, 0.4), new Point2D(0.5, 0.6), new Point2D(1, 2)); when(line.getPoint2DArray()).thenReturn(linePoints); ControlPoint[] controlPoints = tested.getM... | @Override public ControlPoint[] getManageableControlPoints() { final Point2DArray controlPoints = getControlPoints(); if (null != controlPoints && controlPoints.size() > 2) { return StreamSupport.stream(controlPoints.spliterator(), false) .limit(controlPoints.size() - 1) .skip(1) .map(controlPoint -> ControlPoint.build... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public ControlPoint[] getManageableControlPoints() { final Point2DArray controlPoints = getControlPoints(); if (null != controlPoints && controlPoints.size() > 2) { ... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public ControlPoint[] getManageableControlPoints() { final Point2DArray controlPoints = getControlPoints(); if (null != controlPoints && controlPoints.size() > 2) { ... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public ControlPoint[] getManageableControlPoints() { final Point2DArray controlPoints = getControlPoints(); if (null != controlPoints && controlPoints.size() > 2) { ... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public ControlPoint[] getManageableControlPoints() { final Point2DArray controlPoints = getControlPoints(); if (null != controlPoints && controlPoints.size() > 2) { ... |
@Test @SuppressWarnings("unchecked") public void testAddControlPoint() { Point2DArray cps = new Point2DArray(new Point2D(0, 0), new Point2D(0.1, 0.2), new Point2D(1, 2)); when(line.getPoint2DArray()).thenReturn(cps); ControlPoint newCP = ControlPoint.build(0.5, 0.5); tested.addControlPoint(newCP, 1); ArgumentCaptor<Poi... | @Override public T addControlPoint(final ControlPoint controlPoint, final int index) { addControlPoint(controlPoint.getLocation().getX(), controlPoint.getLocation().getY() , index + 1); refreshControlPoints(); return cast(); } | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public T addControlPoint(final ControlPoint controlPoint, final int index) { addControlPoint(controlPoint.getLocation().getX(), controlPoint.getLocation().getY() , i... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public T addControlPoint(final ControlPoint controlPoint, final int index) { addControlPoint(controlPoint.getLocation().getX(), controlPoint.getLocation().getY() , i... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public T addControlPoint(final ControlPoint controlPoint, final int index) { addControlPoint(controlPoint.getLocation().getX(), controlPoint.getLocation().getY() , i... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public T addControlPoint(final ControlPoint controlPoint, final int index) { addControlPoint(controlPoint.getLocation().getX(), controlPoint.getLocation().getY() , i... |
@Test public void testMakeItem() { when(baseItemFactory.makeItem(node, ITEM)).thenReturn(item); assertEquals(item, factory.makeItem(node)); } | public DecisionNavigatorItem makeItem(final Node<View, Edge> node) { final String nodeClassName = Optional.ofNullable(DefinitionUtils.getElementDefinition(node)) .map(elementDefinition -> elementDefinition.getClass().getSimpleName()) .orElse(Node.class.getSimpleName()); return baseItemFactory.makeItem(node, Type.ofExpr... | DecisionNavigatorItemFactory { public DecisionNavigatorItem makeItem(final Node<View, Edge> node) { final String nodeClassName = Optional.ofNullable(DefinitionUtils.getElementDefinition(node)) .map(elementDefinition -> elementDefinition.getClass().getSimpleName()) .orElse(Node.class.getSimpleName()); return baseItemFac... | DecisionNavigatorItemFactory { public DecisionNavigatorItem makeItem(final Node<View, Edge> node) { final String nodeClassName = Optional.ofNullable(DefinitionUtils.getElementDefinition(node)) .map(elementDefinition -> elementDefinition.getClass().getSimpleName()) .orElse(Node.class.getSimpleName()); return baseItemFac... | DecisionNavigatorItemFactory { public DecisionNavigatorItem makeItem(final Node<View, Edge> node) { final String nodeClassName = Optional.ofNullable(DefinitionUtils.getElementDefinition(node)) .map(elementDefinition -> elementDefinition.getClass().getSimpleName()) .orElse(Node.class.getSimpleName()); return baseItemFac... | DecisionNavigatorItemFactory { public DecisionNavigatorItem makeItem(final Node<View, Edge> node) { final String nodeClassName = Optional.ofNullable(DefinitionUtils.getElementDefinition(node)) .map(elementDefinition -> elementDefinition.getClass().getSimpleName()) .orElse(Node.class.getSimpleName()); return baseItemFac... |
@Test @SuppressWarnings("unchecked") public void testDeleteControlPoint() { Point2DArray cps = new Point2DArray(new Point2D(0, 0), new Point2D(0.1, 0.2), new Point2D(1, 2)); when(line.getPoint2DArray()).thenReturn(cps); tested.deleteControlPoint(0); ArgumentCaptor<Point2DArray> linePointsCaptor = ArgumentCaptor.forClas... | @Override public T deleteControlPoint(final int index) { destroyControlPoints(new int[]{index + 1}); return cast(); } | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public T deleteControlPoint(final int index) { destroyControlPoints(new int[]{index + 1}); return cast(); } } | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public T deleteControlPoint(final int index) { destroyControlPoints(new int[]{index + 1}); return cast(); } WiresConnectorView(final AbstractDirectionalMultiPointSha... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public T deleteControlPoint(final int index) { destroyControlPoints(new int[]{index + 1}); return cast(); } WiresConnectorView(final AbstractDirectionalMultiPointSha... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public T deleteControlPoint(final int index) { destroyControlPoints(new int[]{index + 1}); return cast(); } WiresConnectorView(final AbstractDirectionalMultiPointSha... |
@Test @SuppressWarnings("unchecked") public void testUpdateControlPoint() { Point2D p = new Point2D(0.1, 0.2); Point2DArray cps = new Point2DArray(new Point2D(0, 0), p, new Point2D(1, 2)); when(line.getPoint2DArray()).thenReturn(cps); IControlHandleList pointHandles = mock(IControlHandleList.class); when(pointHandles.i... | @Override public T updateControlPoints(final ControlPoint[] controlPoints) { for (int i = 0; i < controlPoints.length; i++) { final Point2D location = controlPoints[i].getLocation(); final com.ait.lienzo.client.core.types.Point2D lienzoPoint = new com.ait.lienzo.client.core.types.Point2D(location.getX(), location.getY(... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public T updateControlPoints(final ControlPoint[] controlPoints) { for (int i = 0; i < controlPoints.length; i++) { final Point2D location = controlPoints[i].getLoca... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public T updateControlPoints(final ControlPoint[] controlPoints) { for (int i = 0; i < controlPoints.length; i++) { final Point2D location = controlPoints[i].getLoca... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public T updateControlPoints(final ControlPoint[] controlPoints) { for (int i = 0; i < controlPoints.length; i++) { final Point2D location = controlPoints[i].getLoca... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public T updateControlPoints(final ControlPoint[] controlPoints) { for (int i = 0; i < controlPoints.length; i++) { final Point2D location = controlPoints[i].getLoca... |
@Test public void testSetShadow() { tested.setShadow("red", 1, 2d, 3d); ArgumentCaptor<Shadow> shadowArgumentCaptor = ArgumentCaptor.forClass(Shadow.class); verify(line, times(1)).setShadow(shadowArgumentCaptor.capture()); final Shadow shadow = shadowArgumentCaptor.getValue(); assertEquals("red", shadow.getColor()); as... | @Override public T setShadow(final String color, final int blur, final double offx, final double offy) { getDirectionalLine().setShadow(new Shadow(color, blur, offx, offy)); return cast(); } | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public T setShadow(final String color, final int blur, final double offx, final double offy) { getDirectionalLine().setShadow(new Shadow(color, blur, offx, offy)); r... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public T setShadow(final String color, final int blur, final double offx, final double offy) { getDirectionalLine().setShadow(new Shadow(color, blur, offx, offy)); r... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public T setShadow(final String color, final int blur, final double offx, final double offy) { getDirectionalLine().setShadow(new Shadow(color, blur, offx, offy)); r... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public T setShadow(final String color, final int blur, final double offx, final double offy) { getDirectionalLine().setShadow(new Shadow(color, blur, offx, offy)); r... |
@Test public void testRemoveShadow() { tested.removeShadow(); verify(line, times(1)).setShadow((Shadow) isNull()); } | @Override public T removeShadow() { getDirectionalLine().setShadow(null); return cast(); } | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public T removeShadow() { getDirectionalLine().setShadow(null); return cast(); } } | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public T removeShadow() { getDirectionalLine().setShadow(null); return cast(); } WiresConnectorView(final AbstractDirectionalMultiPointShape<?> line,
... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public T removeShadow() { getDirectionalLine().setShadow(null); return cast(); } WiresConnectorView(final AbstractDirectionalMultiPointShape<?> line,
... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { @Override public T removeShadow() { getDirectionalLine().setShadow(null); return cast(); } WiresConnectorView(final AbstractDirectionalMultiPointShape<?> line,
... |
@Test public void testSetDashArray() { double dash = 1234; double[] dashes = {1, 2, 3, 4}; DashArray dashArray = DashArray.create(dash, dashes); tested.setDashArray(dashArray); verify(line).setDashArray(dash, dashes); } | public T setDashArray(DashArray dashArray) { if (dashArray != null) { getDirectionalLine().setDashArray(dashArray.getDash(), dashArray.getDashes()); } return cast(); } | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { public T setDashArray(DashArray dashArray) { if (dashArray != null) { getDirectionalLine().setDashArray(dashArray.getDash(), dashArray.getDashes()); } return cast(); } } | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { public T setDashArray(DashArray dashArray) { if (dashArray != null) { getDirectionalLine().setDashArray(dashArray.getDash(), dashArray.getDashes()); } return cast(); } WiresCo... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { public T setDashArray(DashArray dashArray) { if (dashArray != null) { getDirectionalLine().setDashArray(dashArray.getDash(), dashArray.getDashes()); } return cast(); } WiresCo... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { public T setDashArray(DashArray dashArray) { if (dashArray != null) { getDirectionalLine().setDashArray(dashArray.getDash(), dashArray.getDashes()); } return cast(); } WiresCo... |
@Test public void testListening() { tested.setListening(true); assertTrue(tested.getGroup().isListening()); tested.setListening(false); assertFalse(tested.getGroup().isListening()); } | public T setListening(final boolean listening) { listen(listening); return cast(); } | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { public T setListening(final boolean listening) { listen(listening); return cast(); } } | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { public T setListening(final boolean listening) { listen(listening); return cast(); } WiresConnectorView(final AbstractDirectionalMultiPointShape<?> line,
... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { public T setListening(final boolean listening) { listen(listening); return cast(); } WiresConnectorView(final AbstractDirectionalMultiPointShape<?> line,
... | WiresConnectorView extends WiresConnector implements
LienzoShapeView<T>,
IsConnector<T>,
HasManageableControlPoints<T> { public T setListening(final boolean listening) { listen(listening); return cast(); } WiresConnectorView(final AbstractDirectionalMultiPointShape<?> line,
... |
@Test public void testEnable() { tested.enable(); verify(shape, times(2)).setListening(eq(true)); } | public void enable() { listen(true); this.enabled = true; } | ViewEventHandlerManager { public void enable() { listen(true); this.enabled = true; } } | ViewEventHandlerManager { public void enable() { listen(true); this.enabled = true; } ViewEventHandlerManager(final Node<?> node,
final ViewEventType... supportedTypes); ViewEventHandlerManager(final Node<?> node,
final Shape<?> shape,
... | ViewEventHandlerManager { public void enable() { listen(true); this.enabled = true; } ViewEventHandlerManager(final Node<?> node,
final ViewEventType... supportedTypes); ViewEventHandlerManager(final Node<?> node,
final Shape<?> shape,
... | ViewEventHandlerManager { public void enable() { listen(true); this.enabled = true; } ViewEventHandlerManager(final Node<?> node,
final ViewEventType... supportedTypes); ViewEventHandlerManager(final Node<?> node,
final Shape<?> shape,
... |
@Test public void testDisable() { tested.disable(); verify(shape, times(1)).setListening(eq(false)); } | public void disable() { listen(false); this.enabled = false; } | ViewEventHandlerManager { public void disable() { listen(false); this.enabled = false; } } | ViewEventHandlerManager { public void disable() { listen(false); this.enabled = false; } ViewEventHandlerManager(final Node<?> node,
final ViewEventType... supportedTypes); ViewEventHandlerManager(final Node<?> node,
final Shape<?> shape,
... | ViewEventHandlerManager { public void disable() { listen(false); this.enabled = false; } ViewEventHandlerManager(final Node<?> node,
final ViewEventType... supportedTypes); ViewEventHandlerManager(final Node<?> node,
final Shape<?> shape,
... | ViewEventHandlerManager { public void disable() { listen(false); this.enabled = false; } ViewEventHandlerManager(final Node<?> node,
final ViewEventType... supportedTypes); ViewEventHandlerManager(final Node<?> node,
final Shape<?> shape,
... |
@Test public void testSupportedEventTypes() { this.tested = new ViewEventHandlerManager(node, shape, ViewEventType.MOUSE_CLICK, ViewEventType.MOUSE_DBL_CLICK, ViewEventType.TEXT_DBL_CLICK); assertTrue(tested.supports(ViewEventType.MOUSE_CLICK)); assertTrue(tested.supports(ViewEventType.MOUSE_DBL_CLICK)); assertTrue(tes... | public boolean supports(final ViewEventType type) { if (null != supportedTypes) { for (final ViewEventType type1 : supportedTypes) { if (type.equals(type1)) { return true; } } } return false; } | ViewEventHandlerManager { public boolean supports(final ViewEventType type) { if (null != supportedTypes) { for (final ViewEventType type1 : supportedTypes) { if (type.equals(type1)) { return true; } } } return false; } } | ViewEventHandlerManager { public boolean supports(final ViewEventType type) { if (null != supportedTypes) { for (final ViewEventType type1 : supportedTypes) { if (type.equals(type1)) { return true; } } } return false; } ViewEventHandlerManager(final Node<?> node,
final ViewEventType..... | ViewEventHandlerManager { public boolean supports(final ViewEventType type) { if (null != supportedTypes) { for (final ViewEventType type1 : supportedTypes) { if (type.equals(type1)) { return true; } } } return false; } ViewEventHandlerManager(final Node<?> node,
final ViewEventType..... | ViewEventHandlerManager { public boolean supports(final ViewEventType type) { if (null != supportedTypes) { for (final ViewEventType type1 : supportedTypes) { if (type.equals(type1)) { return true; } } } return false; } ViewEventHandlerManager(final Node<?> node,
final ViewEventType..... |
@Test @SuppressWarnings("unchecked") public void testReset() { tested.setBackgroundShape(() -> backgroundShape); tested.reset(); verify(backgroundShape, times(1)).removeShadow(); verify(backgroundShape, never()).setShadow(anyString(), anyInt(), anyDouble(), anyDouble()); } | @Override public ShapeState reset() { getShadowShape().ifPresent(this::removeShadow); return handler.reset(); } | ShapeStateDefaultHandler implements ShapeStateHandler { @Override public ShapeState reset() { getShadowShape().ifPresent(this::removeShadow); return handler.reset(); } } | ShapeStateDefaultHandler implements ShapeStateHandler { @Override public ShapeState reset() { getShadowShape().ifPresent(this::removeShadow); return handler.reset(); } ShapeStateDefaultHandler(); ShapeStateDefaultHandler(final ShapeStateAttributeAnimationHandler<LienzoShapeView<?>> handler); } | ShapeStateDefaultHandler implements ShapeStateHandler { @Override public ShapeState reset() { getShadowShape().ifPresent(this::removeShadow); return handler.reset(); } ShapeStateDefaultHandler(); ShapeStateDefaultHandler(final ShapeStateAttributeAnimationHandler<LienzoShapeView<?>> handler); ShapeStateDefaultHandler ... | ShapeStateDefaultHandler implements ShapeStateHandler { @Override public ShapeState reset() { getShadowShape().ifPresent(this::removeShadow); return handler.reset(); } ShapeStateDefaultHandler(); ShapeStateDefaultHandler(final ShapeStateAttributeAnimationHandler<LienzoShapeView<?>> handler); ShapeStateDefaultHandler ... |
@Test public void testMakeItemWhenTypeIsDecisionService() { when(baseItemFactory.makeItem(node, DECISION_SERVICE)).thenReturn(item); when(node.getContent()).thenReturn(content); when(content.getDefinition()).thenReturn(new DecisionService()); assertEquals(item, factory.makeItem(node)); } | public DecisionNavigatorItem makeItem(final Node<View, Edge> node) { final String nodeClassName = Optional.ofNullable(DefinitionUtils.getElementDefinition(node)) .map(elementDefinition -> elementDefinition.getClass().getSimpleName()) .orElse(Node.class.getSimpleName()); return baseItemFactory.makeItem(node, Type.ofExpr... | DecisionNavigatorItemFactory { public DecisionNavigatorItem makeItem(final Node<View, Edge> node) { final String nodeClassName = Optional.ofNullable(DefinitionUtils.getElementDefinition(node)) .map(elementDefinition -> elementDefinition.getClass().getSimpleName()) .orElse(Node.class.getSimpleName()); return baseItemFac... | DecisionNavigatorItemFactory { public DecisionNavigatorItem makeItem(final Node<View, Edge> node) { final String nodeClassName = Optional.ofNullable(DefinitionUtils.getElementDefinition(node)) .map(elementDefinition -> elementDefinition.getClass().getSimpleName()) .orElse(Node.class.getSimpleName()); return baseItemFac... | DecisionNavigatorItemFactory { public DecisionNavigatorItem makeItem(final Node<View, Edge> node) { final String nodeClassName = Optional.ofNullable(DefinitionUtils.getElementDefinition(node)) .map(elementDefinition -> elementDefinition.getClass().getSimpleName()) .orElse(Node.class.getSimpleName()); return baseItemFac... | DecisionNavigatorItemFactory { public DecisionNavigatorItem makeItem(final Node<View, Edge> node) { final String nodeClassName = Optional.ofNullable(DefinitionUtils.getElementDefinition(node)) .map(elementDefinition -> elementDefinition.getClass().getSimpleName()) .orElse(Node.class.getSimpleName()); return baseItemFac... |
@Test public void testSetBorderShape() { tested.setBorderShape(() -> borderShape); ArgumentCaptor<Supplier> viewCaptor = ArgumentCaptor.forClass(Supplier.class); verify(delegateHandler, times(1)).setView(viewCaptor.capture()); Supplier<LienzoShapeView<?>> viewSupplier = viewCaptor.getValue(); assertEquals(borderShape, ... | public ShapeStateDefaultHandler setBorderShape(final Supplier<LienzoShapeView<?>> shapeSupplier) { handler.getAttributesHandler().setView(shapeSupplier); borderShapeSupplier = shapeSupplier; shapeViewDataEncoder.applyShapeViewType(shapeSupplier, ShapeType.BORDER); return this; } | ShapeStateDefaultHandler implements ShapeStateHandler { public ShapeStateDefaultHandler setBorderShape(final Supplier<LienzoShapeView<?>> shapeSupplier) { handler.getAttributesHandler().setView(shapeSupplier); borderShapeSupplier = shapeSupplier; shapeViewDataEncoder.applyShapeViewType(shapeSupplier, ShapeType.BORDER);... | ShapeStateDefaultHandler implements ShapeStateHandler { public ShapeStateDefaultHandler setBorderShape(final Supplier<LienzoShapeView<?>> shapeSupplier) { handler.getAttributesHandler().setView(shapeSupplier); borderShapeSupplier = shapeSupplier; shapeViewDataEncoder.applyShapeViewType(shapeSupplier, ShapeType.BORDER);... | ShapeStateDefaultHandler implements ShapeStateHandler { public ShapeStateDefaultHandler setBorderShape(final Supplier<LienzoShapeView<?>> shapeSupplier) { handler.getAttributesHandler().setView(shapeSupplier); borderShapeSupplier = shapeSupplier; shapeViewDataEncoder.applyShapeViewType(shapeSupplier, ShapeType.BORDER);... | ShapeStateDefaultHandler implements ShapeStateHandler { public ShapeStateDefaultHandler setBorderShape(final Supplier<LienzoShapeView<?>> shapeSupplier) { handler.getAttributesHandler().setView(shapeSupplier); borderShapeSupplier = shapeSupplier; shapeViewDataEncoder.applyShapeViewType(shapeSupplier, ShapeType.BORDER);... |
@Test public void testSetBackgroundShape() { tested.setBackgroundShape(() -> backgroundShape); verifyShapeTypeAttributeWasSet(backgroundShape, "shapeType=BACKGROUND"); } | public ShapeStateDefaultHandler setBackgroundShape(final Supplier<LienzoShapeView<?>> shapeSupplier) { backgroundShapeSupplier = shapeSupplier; shapeViewDataEncoder.applyShapeViewType(shapeSupplier, ShapeType.BACKGROUND); return this; } | ShapeStateDefaultHandler implements ShapeStateHandler { public ShapeStateDefaultHandler setBackgroundShape(final Supplier<LienzoShapeView<?>> shapeSupplier) { backgroundShapeSupplier = shapeSupplier; shapeViewDataEncoder.applyShapeViewType(shapeSupplier, ShapeType.BACKGROUND); return this; } } | ShapeStateDefaultHandler implements ShapeStateHandler { public ShapeStateDefaultHandler setBackgroundShape(final Supplier<LienzoShapeView<?>> shapeSupplier) { backgroundShapeSupplier = shapeSupplier; shapeViewDataEncoder.applyShapeViewType(shapeSupplier, ShapeType.BACKGROUND); return this; } ShapeStateDefaultHandler();... | ShapeStateDefaultHandler implements ShapeStateHandler { public ShapeStateDefaultHandler setBackgroundShape(final Supplier<LienzoShapeView<?>> shapeSupplier) { backgroundShapeSupplier = shapeSupplier; shapeViewDataEncoder.applyShapeViewType(shapeSupplier, ShapeType.BACKGROUND); return this; } ShapeStateDefaultHandler();... | ShapeStateDefaultHandler implements ShapeStateHandler { public ShapeStateDefaultHandler setBackgroundShape(final Supplier<LienzoShapeView<?>> shapeSupplier) { backgroundShapeSupplier = shapeSupplier; shapeViewDataEncoder.applyShapeViewType(shapeSupplier, ShapeType.BACKGROUND); return this; } ShapeStateDefaultHandler();... |
@Test public void testReset() { tested.setAnimationHandle(animationHandle); tested.reset(); verify(shape, never()).animate(any(AnimationTweener.class), any(AnimationProperties.class), anyDouble(), any(AnimationCallback.class)); verify(animationHandle, times(1)).stop(); assertEquals(ShapeState.NONE, tested.getShapeState... | @Override public ShapeState reset() { if (null != animationHandle) { animationHandle.stop(); setAnimationHandle(null); } return handler.reset(); } | ShapeStateAttributeAnimationHandler implements ShapeStateHandler { @Override public ShapeState reset() { if (null != animationHandle) { animationHandle.stop(); setAnimationHandle(null); } return handler.reset(); } } | ShapeStateAttributeAnimationHandler implements ShapeStateHandler { @Override public ShapeState reset() { if (null != animationHandle) { animationHandle.stop(); setAnimationHandle(null); } return handler.reset(); } ShapeStateAttributeAnimationHandler(); } | ShapeStateAttributeAnimationHandler implements ShapeStateHandler { @Override public ShapeState reset() { if (null != animationHandle) { animationHandle.stop(); setAnimationHandle(null); } return handler.reset(); } ShapeStateAttributeAnimationHandler(); ShapeStateAttributeHandler<V> getAttributesHandler(); ShapeStateAtt... | ShapeStateAttributeAnimationHandler implements ShapeStateHandler { @Override public ShapeState reset() { if (null != animationHandle) { animationHandle.stop(); setAnimationHandle(null); } return handler.reset(); } ShapeStateAttributeAnimationHandler(); ShapeStateAttributeHandler<V> getAttributesHandler(); ShapeStateAtt... |
@Test public void testInit() { ImageSelectionMode before = LienzoCore.get().getDefaultImageSelectionMode(); new StunnerLienzoCore().init(); ImageSelectionMode after = LienzoCore.get().getDefaultImageSelectionMode(); assertEquals(ImageSelectionMode.SELECT_NON_TRANSPARENT, before); assertEquals(ImageSelectionMode.SELECT_... | @PostConstruct public void init() { LienzoCore.get().setDefaultImageSelectionMode(ImageSelectionMode.SELECT_BOUNDS); } | StunnerLienzoCore { @PostConstruct public void init() { LienzoCore.get().setDefaultImageSelectionMode(ImageSelectionMode.SELECT_BOUNDS); } } | StunnerLienzoCore { @PostConstruct public void init() { LienzoCore.get().setDefaultImageSelectionMode(ImageSelectionMode.SELECT_BOUNDS); } } | StunnerLienzoCore { @PostConstruct public void init() { LienzoCore.get().setDefaultImageSelectionMode(ImageSelectionMode.SELECT_BOUNDS); } @PostConstruct void init(); } | StunnerLienzoCore { @PostConstruct public void init() { LienzoCore.get().setDefaultImageSelectionMode(ImageSelectionMode.SELECT_BOUNDS); } @PostConstruct void init(); } |
@Test public void newWiresManager() { WiresManager wiresManager = wiresManagerFactory.newWiresManager(layer); assertEquals(wiresManager.getControlFactory(), wiresControlFactory); assertEquals(wiresManager.getWiresHandlerFactory(), wiresHandlerFactory); MagnetDecorator magnetDecorator = (MagnetDecorator) Whitebox.getInt... | @Override public WiresManager newWiresManager(final Layer layer) { WiresManager wiresManager = WiresManager.get(layer); wiresManager.setWiresHandlerFactory(wiresHandlerFactory); wiresManager.setWiresControlFactory(wiresControlFactory); wiresManager.getMagnetManager().setMagnetDecorator(new StunnerMagnetDecorator()); re... | WiresManagerFactoryImpl implements WiresManagerFactory { @Override public WiresManager newWiresManager(final Layer layer) { WiresManager wiresManager = WiresManager.get(layer); wiresManager.setWiresHandlerFactory(wiresHandlerFactory); wiresManager.setWiresControlFactory(wiresControlFactory); wiresManager.getMagnetManag... | WiresManagerFactoryImpl implements WiresManagerFactory { @Override public WiresManager newWiresManager(final Layer layer) { WiresManager wiresManager = WiresManager.get(layer); wiresManager.setWiresHandlerFactory(wiresHandlerFactory); wiresManager.setWiresControlFactory(wiresControlFactory); wiresManager.getMagnetManag... | WiresManagerFactoryImpl implements WiresManagerFactory { @Override public WiresManager newWiresManager(final Layer layer) { WiresManager wiresManager = WiresManager.get(layer); wiresManager.setWiresHandlerFactory(wiresHandlerFactory); wiresManager.setWiresControlFactory(wiresControlFactory); wiresManager.getMagnetManag... | WiresManagerFactoryImpl implements WiresManagerFactory { @Override public WiresManager newWiresManager(final Layer layer) { WiresManager wiresManager = WiresManager.get(layer); wiresManager.setWiresHandlerFactory(wiresHandlerFactory); wiresManager.setWiresControlFactory(wiresControlFactory); wiresManager.getMagnetManag... |
@Test public void testDestroy() { tested.destroy(); verify(delegate, times(1)).destroy(); } | @Override public void destroy() { getDelegate().destroy(); } | DelegateWiresCompositeControl implements WiresCompositeControl { @Override public void destroy() { getDelegate().destroy(); } } | DelegateWiresCompositeControl implements WiresCompositeControl { @Override public void destroy() { getDelegate().destroy(); } } | DelegateWiresCompositeControl implements WiresCompositeControl { @Override public void destroy() { getDelegate().destroy(); } @Override void useIndex(Supplier<WiresLayerIndex> index); @Override Context getContext(); @Override boolean isAllowed(); @Override WiresContainer getSharedParent(); @Override void execute(); @O... | DelegateWiresCompositeControl implements WiresCompositeControl { @Override public void destroy() { getDelegate().destroy(); } @Override void useIndex(Supplier<WiresLayerIndex> index); @Override Context getContext(); @Override boolean isAllowed(); @Override WiresContainer getSharedParent(); @Override void execute(); @O... |
@Test public void newConnectorHandler() { WiresConnectorHandler wiresConnectorHandler = tested.newConnectorHandler(connector, wiresManager); verify(delegate).newConnectorHandler(connector, wiresManager); } | @Override public WiresConnectorHandler newConnectorHandler(final WiresConnector wiresConnector, final WiresManager wiresManager) { return delegate.newConnectorHandler(wiresConnector, wiresManager); } | StunnerWiresHandlerFactory implements WiresHandlerFactory { @Override public WiresConnectorHandler newConnectorHandler(final WiresConnector wiresConnector, final WiresManager wiresManager) { return delegate.newConnectorHandler(wiresConnector, wiresManager); } } | StunnerWiresHandlerFactory implements WiresHandlerFactory { @Override public WiresConnectorHandler newConnectorHandler(final WiresConnector wiresConnector, final WiresManager wiresManager) { return delegate.newConnectorHandler(wiresConnector, wiresManager); } StunnerWiresHandlerFactory(); StunnerWiresHandlerFactory(W... | StunnerWiresHandlerFactory implements WiresHandlerFactory { @Override public WiresConnectorHandler newConnectorHandler(final WiresConnector wiresConnector, final WiresManager wiresManager) { return delegate.newConnectorHandler(wiresConnector, wiresManager); } StunnerWiresHandlerFactory(); StunnerWiresHandlerFactory(W... | StunnerWiresHandlerFactory implements WiresHandlerFactory { @Override public WiresConnectorHandler newConnectorHandler(final WiresConnector wiresConnector, final WiresManager wiresManager) { return delegate.newConnectorHandler(wiresConnector, wiresManager); } StunnerWiresHandlerFactory(); StunnerWiresHandlerFactory(W... |
@Test public void newControlPointHandler() { tested.newControlPointHandler(connector, wiresManager); verify(delegate).newControlPointHandler(connector, wiresManager); } | @Override public WiresControlPointHandler newControlPointHandler(final WiresConnector wiresConnector, final WiresManager wiresManager) { return delegate.newControlPointHandler(wiresConnector, wiresManager); } | StunnerWiresHandlerFactory implements WiresHandlerFactory { @Override public WiresControlPointHandler newControlPointHandler(final WiresConnector wiresConnector, final WiresManager wiresManager) { return delegate.newControlPointHandler(wiresConnector, wiresManager); } } | StunnerWiresHandlerFactory implements WiresHandlerFactory { @Override public WiresControlPointHandler newControlPointHandler(final WiresConnector wiresConnector, final WiresManager wiresManager) { return delegate.newControlPointHandler(wiresConnector, wiresManager); } StunnerWiresHandlerFactory(); StunnerWiresHandler... | StunnerWiresHandlerFactory implements WiresHandlerFactory { @Override public WiresControlPointHandler newControlPointHandler(final WiresConnector wiresConnector, final WiresManager wiresManager) { return delegate.newControlPointHandler(wiresConnector, wiresManager); } StunnerWiresHandlerFactory(); StunnerWiresHandler... | StunnerWiresHandlerFactory implements WiresHandlerFactory { @Override public WiresControlPointHandler newControlPointHandler(final WiresConnector wiresConnector, final WiresManager wiresManager) { return delegate.newControlPointHandler(wiresConnector, wiresManager); } StunnerWiresHandlerFactory(); StunnerWiresHandler... |
@Test public void newShapeHandler() { tested.newShapeHandler(shape, highlight, wiresManager); verify(delegate).newShapeHandler(shape, highlight, wiresManager); } | @Override public WiresShapeHandler newShapeHandler(final WiresShape shape, final WiresShapeHighlight<PickerPart.ShapePart> highlight, final WiresManager wiresManager) { return delegate.newShapeHandler(shape, highlight, wiresManager); } | StunnerWiresHandlerFactory implements WiresHandlerFactory { @Override public WiresShapeHandler newShapeHandler(final WiresShape shape, final WiresShapeHighlight<PickerPart.ShapePart> highlight, final WiresManager wiresManager) { return delegate.newShapeHandler(shape, highlight, wiresManager); } } | StunnerWiresHandlerFactory implements WiresHandlerFactory { @Override public WiresShapeHandler newShapeHandler(final WiresShape shape, final WiresShapeHighlight<PickerPart.ShapePart> highlight, final WiresManager wiresManager) { return delegate.newShapeHandler(shape, highlight, wiresManager); } StunnerWiresHandlerFacto... | StunnerWiresHandlerFactory implements WiresHandlerFactory { @Override public WiresShapeHandler newShapeHandler(final WiresShape shape, final WiresShapeHighlight<PickerPart.ShapePart> highlight, final WiresManager wiresManager) { return delegate.newShapeHandler(shape, highlight, wiresManager); } StunnerWiresHandlerFacto... | StunnerWiresHandlerFactory implements WiresHandlerFactory { @Override public WiresShapeHandler newShapeHandler(final WiresShape shape, final WiresShapeHighlight<PickerPart.ShapePart> highlight, final WiresManager wiresManager) { return delegate.newShapeHandler(shape, highlight, wiresManager); } StunnerWiresHandlerFacto... |
@Test public void testHighlightBodyForWiresShape() { tested.highlight(lienzoShape, PickerPart.ShapePart.BODY); verify(delegate, times(1)).highlight(eq(lienzoShape), eq(PickerPart.ShapePart.BODY)); } | @Override public void highlight(final WiresShape shape, final PickerPart.ShapePart part) { highlight(shape, part, HIGHLIGHT_COLOR); } | StunnerWiresShapeHighlight implements WiresShapeHighlight<PickerPart.ShapePart> { @Override public void highlight(final WiresShape shape, final PickerPart.ShapePart part) { highlight(shape, part, HIGHLIGHT_COLOR); } } | StunnerWiresShapeHighlight implements WiresShapeHighlight<PickerPart.ShapePart> { @Override public void highlight(final WiresShape shape, final PickerPart.ShapePart part) { highlight(shape, part, HIGHLIGHT_COLOR); } StunnerWiresShapeHighlight(final WiresManager wiresManager,
final ... | StunnerWiresShapeHighlight implements WiresShapeHighlight<PickerPart.ShapePart> { @Override public void highlight(final WiresShape shape, final PickerPart.ShapePart part) { highlight(shape, part, HIGHLIGHT_COLOR); } StunnerWiresShapeHighlight(final WiresManager wiresManager,
final ... | StunnerWiresShapeHighlight implements WiresShapeHighlight<PickerPart.ShapePart> { @Override public void highlight(final WiresShape shape, final PickerPart.ShapePart part) { highlight(shape, part, HIGHLIGHT_COLOR); } StunnerWiresShapeHighlight(final WiresManager wiresManager,
final ... |
@Test public void testMakeItemWhenTypeIsNotMapped() { when(baseItemFactory.makeItem(node, ITEM)).thenReturn(item); when(node.getContent()).thenReturn(content); when(content.getDefinition()).thenReturn(new Object()); assertEquals(item, factory.makeItem(node)); } | public DecisionNavigatorItem makeItem(final Node<View, Edge> node) { final String nodeClassName = Optional.ofNullable(DefinitionUtils.getElementDefinition(node)) .map(elementDefinition -> elementDefinition.getClass().getSimpleName()) .orElse(Node.class.getSimpleName()); return baseItemFactory.makeItem(node, Type.ofExpr... | DecisionNavigatorItemFactory { public DecisionNavigatorItem makeItem(final Node<View, Edge> node) { final String nodeClassName = Optional.ofNullable(DefinitionUtils.getElementDefinition(node)) .map(elementDefinition -> elementDefinition.getClass().getSimpleName()) .orElse(Node.class.getSimpleName()); return baseItemFac... | DecisionNavigatorItemFactory { public DecisionNavigatorItem makeItem(final Node<View, Edge> node) { final String nodeClassName = Optional.ofNullable(DefinitionUtils.getElementDefinition(node)) .map(elementDefinition -> elementDefinition.getClass().getSimpleName()) .orElse(Node.class.getSimpleName()); return baseItemFac... | DecisionNavigatorItemFactory { public DecisionNavigatorItem makeItem(final Node<View, Edge> node) { final String nodeClassName = Optional.ofNullable(DefinitionUtils.getElementDefinition(node)) .map(elementDefinition -> elementDefinition.getClass().getSimpleName()) .orElse(Node.class.getSimpleName()); return baseItemFac... | DecisionNavigatorItemFactory { public DecisionNavigatorItem makeItem(final Node<View, Edge> node) { final String nodeClassName = Optional.ofNullable(DefinitionUtils.getElementDefinition(node)) .map(elementDefinition -> elementDefinition.getClass().getSimpleName()) .orElse(Node.class.getSimpleName()); return baseItemFac... |
@Test public void testHighlightBorder() { tested.highlight(lienzoShape, PickerPart.ShapePart.BORDER); verify(delegate, times(1)).highlight(eq(lienzoShape), eq(PickerPart.ShapePart.BORDER)); } | private void highlightBorder(final WiresShape shape) { delegate.highlight(shape, PickerPart.ShapePart.BORDER); } | StunnerWiresShapeHighlight implements WiresShapeHighlight<PickerPart.ShapePart> { private void highlightBorder(final WiresShape shape) { delegate.highlight(shape, PickerPart.ShapePart.BORDER); } } | StunnerWiresShapeHighlight implements WiresShapeHighlight<PickerPart.ShapePart> { private void highlightBorder(final WiresShape shape) { delegate.highlight(shape, PickerPart.ShapePart.BORDER); } StunnerWiresShapeHighlight(final WiresManager wiresManager,
final Event<CanvasUnhighlig... | StunnerWiresShapeHighlight implements WiresShapeHighlight<PickerPart.ShapePart> { private void highlightBorder(final WiresShape shape) { delegate.highlight(shape, PickerPart.ShapePart.BORDER); } StunnerWiresShapeHighlight(final WiresManager wiresManager,
final Event<CanvasUnhighlig... | StunnerWiresShapeHighlight implements WiresShapeHighlight<PickerPart.ShapePart> { private void highlightBorder(final WiresShape shape) { delegate.highlight(shape, PickerPart.ShapePart.BORDER); } StunnerWiresShapeHighlight(final WiresManager wiresManager,
final Event<CanvasUnhighlig... |
@Test public void testRestore() { tested.highlightBody(stunnerShape, "color"); tested.restore(); verify(unhighlightEvent, times(1)).fire(any(CanvasUnhighlightEvent.class)); verify(delegate, times(1)).restore(); verify(decorator, times(2)).animate(any(AnimationTweener.class), any(AnimationProperties.class), anyDouble(),... | @Override public void restore() { restoreAnimation(() -> { }); delegate.restore(); unhighlightEvent.fire(new CanvasUnhighlightEvent()); } | StunnerWiresShapeHighlight implements WiresShapeHighlight<PickerPart.ShapePart> { @Override public void restore() { restoreAnimation(() -> { }); delegate.restore(); unhighlightEvent.fire(new CanvasUnhighlightEvent()); } } | StunnerWiresShapeHighlight implements WiresShapeHighlight<PickerPart.ShapePart> { @Override public void restore() { restoreAnimation(() -> { }); delegate.restore(); unhighlightEvent.fire(new CanvasUnhighlightEvent()); } StunnerWiresShapeHighlight(final WiresManager wiresManager,
fi... | StunnerWiresShapeHighlight implements WiresShapeHighlight<PickerPart.ShapePart> { @Override public void restore() { restoreAnimation(() -> { }); delegate.restore(); unhighlightEvent.fire(new CanvasUnhighlightEvent()); } StunnerWiresShapeHighlight(final WiresManager wiresManager,
fi... | StunnerWiresShapeHighlight implements WiresShapeHighlight<PickerPart.ShapePart> { @Override public void restore() { restoreAnimation(() -> { }); delegate.restore(); unhighlightEvent.fire(new CanvasUnhighlightEvent()); } StunnerWiresShapeHighlight(final WiresManager wiresManager,
fi... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.