@Test public void testFromDataSetsWithGraphHeads() throws Exception { final LogicalGraphLayout<TemporalGraphHead, TemporalVertex, TemporalEdge> layout = factory.fromDataSets(graphHeadDataSet, vertexDataSet, edgeDataSet); Collection<TemporalGraphHead> loadedGraphHeads = Lists.newArrayList(); Collection<TemporalVertex> loadedVertices = Lists.newArrayList(); Collection<TemporalEdge> loadedEdges = Lists.newArrayList(); layout.getGraphHead().output(new LocalCollectionOutputFormat<>(loadedGraphHeads)); layout.getVertices().output(new LocalCollectionOutputFormat<>(loadedVertices)); layout.getEdges().output(new LocalCollectionOutputFormat<>(loadedEdges)); getExecutionEnvironment().execute(); validateElementCollections(graphHeads, loadedGraphHeads); validateElementCollections(vertices, loadedVertices); validateElementCollections(edges, loadedEdges); validateGraphElementCollections(vertices, loadedVertices); validateGraphElementCollections(edges, loadedEdges); }
@Override public LogicalGraphLayout<TemporalGraphHead, TemporalVertex, TemporalEdge> fromDataSets( DataSet<TemporalVertex> vertices) { return fromDataSets(vertices, createEdgeDataSet(Collections.emptyList())); }
TemporalGraphLayoutFactory extends TemporalBaseLayoutFactory implements LogicalGraphLayoutFactory<TemporalGraphHead, TemporalVertex, TemporalEdge> { @Override public LogicalGraphLayout<TemporalGraphHead, TemporalVertex, TemporalEdge> fromDataSets( DataSet<TemporalVertex> vertices) { return fromDataSets(vertices, createEdgeDataSet(Collections.emptyList())); } }
TemporalGraphLayoutFactory extends TemporalBaseLayoutFactory implements LogicalGraphLayoutFactory<TemporalGraphHead, TemporalVertex, TemporalEdge> { @Override public LogicalGraphLayout<TemporalGraphHead, TemporalVertex, TemporalEdge> fromDataSets( DataSet<TemporalVertex> vertices) { return fromDataSets(vertices, createEdgeDataSet(Collections.emptyList())); }  }
TemporalGraphLayoutFactory extends TemporalBaseLayoutFactory implements LogicalGraphLayoutFactory<TemporalGraphHead, TemporalVertex, TemporalEdge> { @Override public LogicalGraphLayout<TemporalGraphHead, TemporalVertex, TemporalEdge> fromDataSets( DataSet<TemporalVertex> vertices) { return fromDataSets(vertices, createEdgeDataSet(Collections.emptyList())); }  @Override LogicalGraphLayout<TemporalGraphHead, TemporalVertex, TemporalEdge> fromDataSets(
    DataSet<TemporalVertex> vertices); @Override LogicalGraphLayout<TemporalGraphHead, TemporalVertex, TemporalEdge> fromDataSets(
    DataSet<TemporalVertex> vertices, DataSet<TemporalEdge> edges); @Override LogicalGraphLayout<TemporalGraphHead, TemporalVertex, TemporalEdge> fromDataSets(
    DataSet<TemporalGraphHead> graphHead,
    DataSet<TemporalVertex> vertices,
    DataSet<TemporalEdge> edges); @Override LogicalGraphLayout<TemporalGraphHead, TemporalVertex, TemporalEdge> fromIndexedDataSets(
    Map<String, DataSet<TemporalVertex>> vertices, Map<String, DataSet<TemporalEdge>> edges); @Override LogicalGraphLayout<TemporalGraphHead, TemporalVertex, TemporalEdge> fromIndexedDataSets(
    Map<String, DataSet<TemporalGraphHead>> graphHeads,
    Map<String, DataSet<TemporalVertex>> vertices, Map<String, DataSet<TemporalEdge>> edges); @Override LogicalGraphLayout<TemporalGraphHead, TemporalVertex, TemporalEdge> fromCollections(
    TemporalGraphHead graphHead, Collection<TemporalVertex> vertices,
    Collection<TemporalEdge> edges); @Override LogicalGraphLayout<TemporalGraphHead, TemporalVertex, TemporalEdge> fromCollections(
    Collection<TemporalVertex> vertices, Collection<TemporalEdge> edges); @Override LogicalGraphLayout<TemporalGraphHead, TemporalVertex, TemporalEdge> createEmptyGraph(); }
TemporalGraphLayoutFactory extends TemporalBaseLayoutFactory implements LogicalGraphLayoutFactory<TemporalGraphHead, TemporalVertex, TemporalEdge> { @Override public LogicalGraphLayout<TemporalGraphHead, TemporalVertex, TemporalEdge> fromDataSets( DataSet<TemporalVertex> vertices) { return fromDataSets(vertices, createEdgeDataSet(Collections.emptyList())); }  @Override LogicalGraphLayout<TemporalGraphHead, TemporalVertex, TemporalEdge> fromDataSets(
    DataSet<TemporalVertex> vertices); @Override LogicalGraphLayout<TemporalGraphHead, TemporalVertex, TemporalEdge> fromDataSets(
    DataSet<TemporalVertex> vertices, DataSet<TemporalEdge> edges); @Override LogicalGraphLayout<TemporalGraphHead, TemporalVertex, TemporalEdge> fromDataSets(
    DataSet<TemporalGraphHead> graphHead,
    DataSet<TemporalVertex> vertices,
    DataSet<TemporalEdge> edges); @Override LogicalGraphLayout<TemporalGraphHead, TemporalVertex, TemporalEdge> fromIndexedDataSets(
    Map<String, DataSet<TemporalVertex>> vertices, Map<String, DataSet<TemporalEdge>> edges); @Override LogicalGraphLayout<TemporalGraphHead, TemporalVertex, TemporalEdge> fromIndexedDataSets(
    Map<String, DataSet<TemporalGraphHead>> graphHeads,
    Map<String, DataSet<TemporalVertex>> vertices, Map<String, DataSet<TemporalEdge>> edges); @Override LogicalGraphLayout<TemporalGraphHead, TemporalVertex, TemporalEdge> fromCollections(
    TemporalGraphHead graphHead, Collection<TemporalVertex> vertices,
    Collection<TemporalEdge> edges); @Override LogicalGraphLayout<TemporalGraphHead, TemporalVertex, TemporalEdge> fromCollections(
    Collection<TemporalVertex> vertices, Collection<TemporalEdge> edges); @Override LogicalGraphLayout<TemporalGraphHead, TemporalVertex, TemporalEdge> createEmptyGraph();  }