标题: 反射问题 [打印本页] 作者: 张邦庆 时间: 2011-10-23 00:02 标题: 反射问题 Class.forName("")中的字符串有什么要求?有哪几种情况啊作者: 黄晓天 时间: 2011-10-23 11:44
可能我的理解很浅显,Class.forName(""),括号里面放的应该是数据库的驱动名称吧,例如MYSQL的驱动名"com.mysql.jdbc.Driver"作者: 郭敏 时间: 2011-10-23 12:11
Parameters:
className - the fully qualified name of the desired class.
换名话说: 就是你所期望得到某个类字节码的全称。
For example, the following code fragment returns the runtime Class descriptor for the class named java.lang.Thread: