in src/main/java/net/hydromatic/linq4j/expressions/Primitive.java [705:737]
public void arrayItem(Source source, Object dataSet, int ordinal) {
switch (this) {
case DOUBLE:
Array.setDouble(dataSet, ordinal, source.getDouble());
return;
case FLOAT:
Array.setFloat(dataSet, ordinal, source.getFloat());
return;
case BOOLEAN:
Array.setBoolean(dataSet, ordinal, source.getBoolean());
return;
case BYTE:
Array.setByte(dataSet, ordinal, source.getByte());
return;
case CHAR:
Array.setChar(dataSet, ordinal, source.getChar());
return;
case SHORT:
Array.setShort(dataSet, ordinal, source.getShort());
return;
case INT:
Array.setInt(dataSet, ordinal, source.getInt());
return;
case LONG:
Array.setLong(dataSet, ordinal, source.getLong());
return;
case OTHER:
Array.set(dataSet, ordinal, source.getObject());
return;
default:
throw new AssertionError("unexpected " + this);
}
}