} else if (type == Type.DATE) {
return (T) converter.toDate();
} else if (type == Type.DECIMAL) {
return (T) converter.toDecimal();
} else if (type == Type.DOUBLE) {
return (T) Double.valueOf(converter.toDouble());
} else if (type == Type.LONG) {
return (T) Long.valueOf(converter.toLong());
} else {
throw new UnsupportedOperationException(
"Unknown type: " + type);