@Test public void testBuild() { final Diagram<Graph, Metadata> diagram = tested.build(NAME, metadata, graph); assertNotNull(diagram); assertEquals(NAME, diagram.getName()); assertEquals(metadata, diagram.getMetadata()); assertEquals(graph, diagram.getGraph()); }
@Override public Diagram<Graph, Metadata> build(final String name, final Metadata metadata, final Graph<DefinitionSet, ?> graph) { final AbstractDiagram<Graph, Metadata> result = new DiagramImpl(name, metadata); result.setGraph(graph); return result; }
DiagramFactoryImpl implements DiagramFactory<Metadata, Diagram<Graph, Metadata>> { @Override public Diagram<Graph, Metadata> build(final String name, final Metadata metadata, final Graph<DefinitionSet, ?> graph) { final AbstractDiagram<Graph, Metadata> result = new DiagramImpl(name, metadata); result.setGraph(graph); return result; } }
DiagramFactoryImpl implements DiagramFactory<Metadata, Diagram<Graph, Metadata>> { @Override public Diagram<Graph, Metadata> build(final String name, final Metadata metadata, final Graph<DefinitionSet, ?> graph) { final AbstractDiagram<Graph, Metadata> result = new DiagramImpl(name, metadata); result.setGraph(graph); return result; }  }
DiagramFactoryImpl implements DiagramFactory<Metadata, Diagram<Graph, Metadata>> { @Override public Diagram<Graph, Metadata> build(final String name, final Metadata metadata, final Graph<DefinitionSet, ?> graph) { final AbstractDiagram<Graph, Metadata> result = new DiagramImpl(name, metadata); result.setGraph(graph); return result; }  @Override Class<? extends Metadata> getMetadataType(); @Override Diagram<Graph, Metadata> build(final String name,
                                          final Metadata metadata,
                                          final Graph<DefinitionSet, ?> graph); @Override boolean accepts(final String source); @Override boolean isDefault(); }
DiagramFactoryImpl implements DiagramFactory<Metadata, Diagram<Graph, Metadata>> { @Override public Diagram<Graph, Metadata> build(final String name, final Metadata metadata, final Graph<DefinitionSet, ?> graph) { final AbstractDiagram<Graph, Metadata> result = new DiagramImpl(name, metadata); result.setGraph(graph); return result; }  @Override Class<? extends Metadata> getMetadataType(); @Override Diagram<Graph, Metadata> build(final String name,
                                          final Metadata metadata,
                                          final Graph<DefinitionSet, ?> graph); @Override boolean accepts(final String source); @Override boolean isDefault();  }