SimpleGraphModule

File:Microsoft Excel 2013 logo.svg

SimpleGraph Excel module

The SimpleGraph Excel module makes Microsoft Excel workbooks accessible via the Apache POI API see Apache POI XSSF/HSSF.

Sources

Mental Model

Mapping rules

  1. Each Vertex type (by label) is converted to an Excel sheet
  2. Each Edge type (by label) is converted to an Excel sheet
  3. Each vertex is converted to a row
  4. Each vertex property is converted to a cell
  5. Each edge is converted to a row
  6. Each edge property is converted to a cell
  7. The header row for Vertices has a column for each property key
  8. The header for for Edges has a column for each property key + an in and and out column
  9. The in and out header columns for edges have the label of the corresponding vertex in parentheses

UML diagram

Diagrams error (with plantuml command): cp: missing destination file operand after '/tmp/diagrams_ine9cf6fef01e6.png' Try 'cp --help' for more information.

Examples

Modern

Diagrams error (with plantuml command): cp: missing destination file operand after '/tmp/diagrams_inde9dc8366cff.png' Try 'cp --help' for more information. File:Modern.xlsx

AirRoutes

The UML diagram and excel table is not fully consistent with the graph. The graph can have contains edges between airport and country.

Diagrams error (with plantuml command): cp: missing destination file operand after '/tmp/diagrams_in1b41ed367bc0.png' Try 'cp --help' for more information. File:Air-routes.xlsx

@Test
  public void testCreateExcelAirRoutes() throws Exception {
    ExcelSystem es = new ExcelSystem();
    Graph graph = TestTinkerPop3.getAirRoutes();
    GraphTraversalSource g = graph.traversal();
    // es.setDebug(true);
    Workbook wb = es.createWorkBook(g);
    assertEquals(6, wb.getNumberOfSheets());
    es.save(wb, testAirRouteFileName);
}

Railway

Diagrams error (with plantuml command): cp: missing destination file operand after '/tmp/diagrams_inac8ab417cb70.png' Try 'cp --help' for more information.

Links