You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@arrow.apache.org by "Dominik Moritz (JIRA)" <ji...@apache.org> on 2018/06/30 00:26:00 UTC

[jira] [Commented] (ARROW-2767) [JS] Add generic to Table for column names

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

Dominik Moritz commented on ARROW-2767:
---------------------------------------

One thing I realized later is that the `getColumn(name)` function can then guarantee to return a column rather than returning `Column | null`. 

> [JS] Add generic to Table for column names
> ------------------------------------------
>
>                 Key: ARROW-2767
>                 URL: https://issues.apache.org/jira/browse/ARROW-2767
>             Project: Apache Arrow
>          Issue Type: Improvement
>          Components: JavaScript
>            Reporter: Brian Hulette
>            Priority: Major
>
> Requested by [~domoritz]
> Something like:
> {code:javascript}
> class Table<ColName extends string = string> {
>     ...
>     getColumn(name: ColName): Vector<any> {
>     }
>     ...
> }
> {code}
> It would be even better if we could find a way to map the column names to the actual vector data types, but one thing at a time.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)