nbauernfeind commented on issue #399:
URL: https://github.com/apache/arrow-java/issues/399#issuecomment-2644418271
This issue still persists.
Notably:
```java
@Override
public void setPosition(int index) {
super.setPosition(index);
for (BaseWriter writer : writers) {
writer.setPosition(index);
}
}
```
But, writers is an array of length 128 and each writer is lazily initialized
- in that every writer is `null`.
The result is that it is impossible to write Lists of Unions using this
library. Noting that `UnionListWriter#startList` invokes `setPosition`:
```java
@Override
public void startList() {
vector.startNewValue(idx());
writer.setPosition(vector.getOffsetBuffer().getInt((idx() + 1L) *
OFFSET_WIDTH));
listStarted = true;
}
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]