You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "Chiwan Park (JIRA)" <ji...@apache.org> on 2015/02/12 06:48:12 UTC

[jira] [Commented] (FLINK-1512) Add CsvReader for reading into POJOs.

    [ https://issues.apache.org/jira/browse/FLINK-1512?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14317644#comment-14317644 ] 

Chiwan Park commented on FLINK-1512:
------------------------------------

I'm trying to implement this feature. I can't understand that what is difference between {{tupleType}} method and {{types}} method in {{CsvReader}} class. I think that two methods are doing same. Why are two methods in class?

I propose a method {{targetType(Class<T> typeClass)}} (The name of method can be changed.). Users can use this method like following code.

{code:java}
DataSource<Item> items = env.readCsvFile("file-path")
    .fieldDelimiter(" ")
    .lineDelimiter("\n")
    .targetType(Item.class);
{code}

> Add CsvReader for reading into POJOs.
> -------------------------------------
>
>                 Key: FLINK-1512
>                 URL: https://issues.apache.org/jira/browse/FLINK-1512
>             Project: Flink
>          Issue Type: New Feature
>          Components: Java API, Scala API
>            Reporter: Robert Metzger
>            Assignee: Chiwan Park
>            Priority: Minor
>              Labels: starter
>
> Currently, the {{CsvReader}} supports only TupleXX types. 
> It would be nice if users were also able to read into POJOs.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)