Skip to content

Commit 8a348c7

Browse files
committed
Revert "throw exception rather 'return null'"
This reverts commit 4ef7160.
1 parent 4ef7160 commit 8a348c7

File tree

6 files changed

+6
-6
lines changed

6 files changed

+6
-6
lines changed

vector/src/main/java/org/apache/arrow/vector/LargeVarBinaryVector.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ public MinorType getMinorType() {
9898
public byte[] get(int index) {
9999
assert index >= 0;
100100
if (NULL_CHECKING_ENABLED && isSet(index) == 0) {
101-
throw new IllegalStateException("Value at index is null");
101+
return null;
102102
}
103103
final long startOffset = getStartOffset(index);
104104
final long dataLength = getEndOffset(index) - startOffset;

vector/src/main/java/org/apache/arrow/vector/LargeVarCharVector.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ public Types.MinorType getMinorType() {
102102
public byte[] get(int index) {
103103
assert index >= 0;
104104
if (NULL_CHECKING_ENABLED && isSet(index) == 0) {
105-
throw new IllegalStateException("Value at index is null");
105+
return null;
106106
}
107107
final long startOffset = getStartOffset(index);
108108
final long dataLength = getEndOffset(index) - startOffset;

vector/src/main/java/org/apache/arrow/vector/VarBinaryVector.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ public MinorType getMinorType() {
9797
public byte[] get(int index) {
9898
assert index >= 0;
9999
if (NULL_CHECKING_ENABLED && isSet(index) == 0) {
100-
throw new IllegalStateException("Value at index is null");
100+
return null;
101101
}
102102
final int startOffset = getStartOffset(index);
103103
final int dataLength = getEndOffset(index) - startOffset;

vector/src/main/java/org/apache/arrow/vector/VarCharVector.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ public MinorType getMinorType() {
9999
public byte[] get(int index) {
100100
assert index >= 0;
101101
if (NULL_CHECKING_ENABLED && isSet(index) == 0) {
102-
throw new IllegalStateException("Value at index is null");
102+
return null;
103103
}
104104
final int startOffset = getStartOffset(index);
105105
final int dataLength = getEndOffset(index) - startOffset;

vector/src/main/java/org/apache/arrow/vector/ViewVarBinaryVector.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ public MinorType getMinorType() {
9797
public byte[] get(int index) {
9898
assert index >= 0;
9999
if (NULL_CHECKING_ENABLED && isSet(index) == 0) {
100-
throw new IllegalStateException("Value at index is null");
100+
return null;
101101
}
102102
return getData(index);
103103
}

vector/src/main/java/org/apache/arrow/vector/ViewVarCharVector.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ public MinorType getMinorType() {
101101
public byte[] get(int index) {
102102
assert index >= 0;
103103
if (NULL_CHECKING_ENABLED && isSet(index) == 0) {
104-
throw new IllegalStateException("Value at index is null");
104+
return null;
105105
}
106106
return getData(index);
107107
}

0 commit comments

Comments
 (0)