apache / apache/arrow-java

[Java] Add accessors to get type parameters from vector classes

未关闭
#427 9 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
Type: enhancement
主要语言
Java
星标
94
派生
152
平均合并
3 天 16 小时
30 天内合并 PR
11

描述

Vector classes contain private copies of each param in the `ArrowType`, but does not have any public api to access them. So if given a vector you would have to get the `Field` from the and cast to the correct type. For example, with a `TimeStampMicroTZVector` and trying to get the timezone:

```

if field.getType.isInstanceOf[ArrowType.Timestamp] &&
field.getType.asInstanceOf[ArrowType.Timestamp].getTimezone
```

It would be more convenient to have direct accessors for these type params for the vector types that have parameters:

- DecimalVector
- FixedSizeBinaryVector
- ListVector
- TimeStamps with timezones
- FixedSizedListVector
- Unions

**Reporter**: [Bryan Cutler](https://issues.apache.org/jira/browse/ARROW-1361) / @BryanCutler
#### PRs and other links:
- [GitHub Pull Request apache/arrow#972](https://github.com/apache/arrow/pull/972)

**Note**: *This issue was originally created as [ARROW-1361](https://issues.apache.org/jira/browse/ARROW-1361). Please see the [migration documentation](https://github.com/apache/arrow/issues/14542) for further details.*

贡献指南

打开贡献指南

调研方向

首先检查 issue 中提到的向量类以及链接的 pull request apache/arrow#972。检查它们的私有 ArrowType 参数是如何表示的,然后确认 DecimalVector、FixedSizeBinaryVector、ListVector、支持时区的 timestamp 向量、FixedSizeListVector 和 union 存在直接访问器。

由索引模型根据 Issue 内容生成。

评估

技术栈
java
领域
backend-api-design
Issue 类型
功能
难度
3/5
预计耗时
3-5 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
25/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。