[ https://issues.apache.org/jira/browse/FLINK-1520?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14590557#comment-14590557 ]
ASF GitHub Bot commented on FLINK-1520: --------------------------------------- Github user vasia commented on a diff in the pull request: https://github.com/apache/flink/pull/847#discussion_r32672827 --- Diff: flink-staging/flink-gelly/src/main/java/org/apache/flink/graph/Graph.java --- @@ -282,6 +282,58 @@ public void flatMap(Edge<K, EV> edge, Collector<Tuple1<K>> out) { } /** + * Creates a graph from CSV files. + * + * Vertices with value are created from a CSV file with 2 fields + * Edges with value are created from a CSV file with 3 fields + * from Tuple3. + * + * @param path1 path to a CSV file with the Vertices data. + * @param path2 path to a CSV file with the Edges data + * @param context the flink execution environment. + * @return An instance of {@link org.apache.flink.graph.GraphCsvReader} , which on calling types() method to specify types of the + * Vertex ID, Vertex Value and Edge value returns a Graph + */ + + public static GraphCsvReader fromCsvReader(String path1, String path2, ExecutionEnvironment context){ + return (new GraphCsvReader(path1,path2,context)); + } + /** Creates a graph from a CSV file for Edges., Vertices are + * induced from the edges. + * + * Edges with value are created from a CSV file with 3 fields. Vertices are created + * automatically and their values are set to NullValue. + * + * @param path a path to a CSV file with the Edges data + * @param context the flink execution environment. + * @return An instance of {@link org.apache.flink.graph.GraphCsvReader} , which on calling types() method to specify types of the + * Vertex ID, Vertex Value and Edge value returns a Graph + */ + --- End diff -- new line > Read edges and vertices from CSV files > -------------------------------------- > > Key: FLINK-1520 > URL: https://issues.apache.org/jira/browse/FLINK-1520 > Project: Flink > Issue Type: New Feature > Components: Gelly > Reporter: Vasia Kalavri > Assignee: Shivani Ghatge > Priority: Minor > Labels: easyfix, newbie > > Add methods to create Vertex and Edge Datasets directly from CSV file inputs. -- This message was sent by Atlassian JIRA (v6.3.4#6332)