提交 4c682e17 authored 作者: Thomas Mueller's avatar Thomas Mueller

Clearer method names.

上级 889c911b
......@@ -429,7 +429,7 @@ public abstract class Value {
}
public Reader getReader() {
return IOUtils.getReader(getString());
return IOUtils.getReaderFromString(getString());
}
/**
......@@ -914,12 +914,23 @@ public abstract class Value {
*
* @param precision the new precision
* @return the new value
* @throws SQLException
*/
public Value convertPrecision(long precision) {
return this;
}
/**
* Trim the value to the requested precision.
* Unlike convertPrecision, this will always work
* (possibly losing precision).
*
* @param precision the maximum precision
* @return the new value
*/
public Value trim(long precision) {
return convertPrecision(precision);
}
private static byte convertToByte(long x) {
if (x > Byte.MAX_VALUE || x < Byte.MIN_VALUE) {
throw DbException.get(ErrorCode.NUMERIC_VALUE_OUT_OF_RANGE);
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论