我觉得只能是在你的类内部,使得输入的参数转变成一个整型值例如:
function(Integer.valueOf(args[0]).intValue())
当参数是float型时,可以用
function(Float.valueOf(args[0]).floatValue())