diff --git a/src/org/nutz/dao/impl/sql/NutStatement.java b/src/org/nutz/dao/impl/sql/NutStatement.java index f0eebb0a7..63becb609 100644 --- a/src/org/nutz/dao/impl/sql/NutStatement.java +++ b/src/org/nutz/dao/impl/sql/NutStatement.java @@ -115,6 +115,10 @@ public T getObject(Class classOfT) { public int getInt() { return getObject(Integer.class); } + + public Number getNumber() { + return getObject(Number.class); + } public String getString() { return getObject(String.class); diff --git a/src/org/nutz/dao/sql/DaoStatement.java b/src/org/nutz/dao/sql/DaoStatement.java index 21523049e..f669984cb 100644 --- a/src/org/nutz/dao/sql/DaoStatement.java +++ b/src/org/nutz/dao/sql/DaoStatement.java @@ -140,6 +140,8 @@ public interface DaoStatement { * @return 将结果对象作为 int 返回 */ int getInt(); + + Number getNumber(); /** * @return 将结果对象作为 String 返回