@Test public void testNameIdPackageAsDefaultIfNotEmpty() { when(definitionManager.definitionSets()).thenReturn(definitionSetRegistry); when(marshalling.unmarshall(any(), any())).thenReturn(graph); when(graph.nodes()).thenReturn(nodes); diagramSet.getName().setValue("somePreviousName"); diagramSet.getId().setValue("somePreviousId"); diagramSet.getPackageProperty().setValue("somePreviousPackage"); tested.transform(BPMNClientDiagramService.DEFAULT_DIAGRAM_ID, xml, new ServiceCallback<Diagram>() { @Override public void onSuccess(Diagram item) { } @Override public void onError(ClientRuntimeError error) { } }); assertEquals("somePreviousName", diagramSet.getName().getValue()); assertEquals("somePreviousId", diagramSet.getId().getValue()); assertEquals("somePreviousPackage", diagramSet.getPackageProperty().getValue()); }
@Override public void transform(final String xml, final ServiceCallback<Diagram> callback) { doTransform(DEFAULT_DIAGRAM_ID, xml, callback); }
BPMNClientDiagramService extends AbstractKogitoClientDiagramService { @Override public void transform(final String xml, final ServiceCallback<Diagram> callback) { doTransform(DEFAULT_DIAGRAM_ID, xml, callback); } }
BPMNClientDiagramService extends AbstractKogitoClientDiagramService { @Override public void transform(final String xml, final ServiceCallback<Diagram> callback) { doTransform(DEFAULT_DIAGRAM_ID, xml, callback); } protected  BPMNClientDiagramService(); @Inject  BPMNClientDiagramService(final DefinitionManager definitionManager,
                                    final BPMNClientMarshalling marshalling,
                                    final FactoryManager factoryManager,
                                    final BPMNDiagramFactory diagramFactory,
                                    final ShapeManager shapeManager,
                                    final Promises promises,
                                    final WorkItemDefinitionClientService widService); }
BPMNClientDiagramService extends AbstractKogitoClientDiagramService { @Override public void transform(final String xml, final ServiceCallback<Diagram> callback) { doTransform(DEFAULT_DIAGRAM_ID, xml, callback); } protected  BPMNClientDiagramService(); @Inject  BPMNClientDiagramService(final DefinitionManager definitionManager,
                                    final BPMNClientMarshalling marshalling,
                                    final FactoryManager factoryManager,
                                    final BPMNDiagramFactory diagramFactory,
                                    final ShapeManager shapeManager,
                                    final Promises promises,
                                    final WorkItemDefinitionClientService widService); @Override void transform(final String xml,
                          final ServiceCallback<Diagram> callback); @Override void transform(final String fileName,
                          final String xml,
                          final ServiceCallback<Diagram> callback); @Override Promise<String> transform(final KogitoDiagramResourceImpl resource); String transform(final Diagram diagram); }
BPMNClientDiagramService extends AbstractKogitoClientDiagramService { @Override public void transform(final String xml, final ServiceCallback<Diagram> callback) { doTransform(DEFAULT_DIAGRAM_ID, xml, callback); } protected  BPMNClientDiagramService(); @Inject  BPMNClientDiagramService(final DefinitionManager definitionManager,
                                    final BPMNClientMarshalling marshalling,
                                    final FactoryManager factoryManager,
                                    final BPMNDiagramFactory diagramFactory,
                                    final ShapeManager shapeManager,
                                    final Promises promises,
                                    final WorkItemDefinitionClientService widService); @Override void transform(final String xml,
                          final ServiceCallback<Diagram> callback); @Override void transform(final String fileName,
                          final String xml,
                          final ServiceCallback<Diagram> callback); @Override Promise<String> transform(final KogitoDiagramResourceImpl resource); String transform(final Diagram diagram);  }