Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -131,8 +131,10 @@ public float asFloat() {
public int asInt() {
if (value instanceof Byte || value instanceof Short || value instanceof Integer) {
return value.intValue();
} else if (value instanceof Long && (long) value >= Integer.MIN_VALUE && (long) value <= Integer.MAX_VALUE) {
return value.intValue();
} else {
throw new IllegalStateException("Node cannot be represented as long");
throw new IllegalStateException("Node cannot be represented as int");
}
}

Expand Down
Loading