@Test public void build() { tested.build(GRAPH_UUID, DEFINITION); verify(tested).build(GRAPH_UUID, DEFINITION, null); }
@Override public Graph<DefinitionSet, Node> build(String uuid, String definition, Metadata metadata) { final Optional<ProjectType> projectType = (Objects.nonNull(metadata) && metadata instanceof ProjectMetadata) ? Optional.ofNullable(((ProjectMetadata) metadata).getProjectType()).map(ProjectType::valueOf) : Optional.empty(); return graphFactoryDelegation.get(projectType).build(uuid, definition, metadata); }
BPMNDelegateGraphFactory implements BPMNGraphFactory { @Override public Graph<DefinitionSet, Node> build(String uuid, String definition, Metadata metadata) { final Optional<ProjectType> projectType = (Objects.nonNull(metadata) && metadata instanceof ProjectMetadata) ? Optional.ofNullable(((ProjectMetadata) metadata).getProjectType()).map(ProjectType::valueOf) : Optional.empty(); return graphFactoryDelegation.get(projectType).build(uuid, definition, metadata); } }
BPMNDelegateGraphFactory implements BPMNGraphFactory { @Override public Graph<DefinitionSet, Node> build(String uuid, String definition, Metadata metadata) { final Optional<ProjectType> projectType = (Objects.nonNull(metadata) && metadata instanceof ProjectMetadata) ? Optional.ofNullable(((ProjectMetadata) metadata).getProjectType()).map(ProjectType::valueOf) : Optional.empty(); return graphFactoryDelegation.get(projectType).build(uuid, definition, metadata); } @Inject  BPMNDelegateGraphFactory(final BPMNGraphFactoryImpl bpmnGraphFactory,
                                    final CaseGraphFactoryImpl caseGraphFactory); }
BPMNDelegateGraphFactory implements BPMNGraphFactory { @Override public Graph<DefinitionSet, Node> build(String uuid, String definition, Metadata metadata) { final Optional<ProjectType> projectType = (Objects.nonNull(metadata) && metadata instanceof ProjectMetadata) ? Optional.ofNullable(((ProjectMetadata) metadata).getProjectType()).map(ProjectType::valueOf) : Optional.empty(); return graphFactoryDelegation.get(projectType).build(uuid, definition, metadata); } @Inject  BPMNDelegateGraphFactory(final BPMNGraphFactoryImpl bpmnGraphFactory,
                                    final CaseGraphFactoryImpl caseGraphFactory); @Override boolean isDelegateFactory(); @Override void setDiagramType(Class<? extends BPMNDiagram> diagramType); @Override Class<? extends ElementFactory> getFactoryType(); @Override Graph<DefinitionSet, Node> build(String uuid, String definition, Metadata metadata); @Override Graph<DefinitionSet, Node> build(String uuid, String definition); @Override boolean accepts(String source); }
BPMNDelegateGraphFactory implements BPMNGraphFactory { @Override public Graph<DefinitionSet, Node> build(String uuid, String definition, Metadata metadata) { final Optional<ProjectType> projectType = (Objects.nonNull(metadata) && metadata instanceof ProjectMetadata) ? Optional.ofNullable(((ProjectMetadata) metadata).getProjectType()).map(ProjectType::valueOf) : Optional.empty(); return graphFactoryDelegation.get(projectType).build(uuid, definition, metadata); } @Inject  BPMNDelegateGraphFactory(final BPMNGraphFactoryImpl bpmnGraphFactory,
                                    final CaseGraphFactoryImpl caseGraphFactory); @Override boolean isDelegateFactory(); @Override void setDiagramType(Class<? extends BPMNDiagram> diagramType); @Override Class<? extends ElementFactory> getFactoryType(); @Override Graph<DefinitionSet, Node> build(String uuid, String definition, Metadata metadata); @Override Graph<DefinitionSet, Node> build(String uuid, String definition); @Override boolean accepts(String source);  }