日期:2014-05-20 浏览次数:20890 次
public interface IActionUtils
{
bool Execute(string sqlStr);
int[] Execute(string[] sqlArr);
DataTable Query(string sqlStr);
DataTable Query(string table, string fields, string condition, Pager pager);
DataTable QueryPage(string table, string fields, string condition, Pager pager, ref int totalRecords);
T QueryEntity<T>(string sqlStr) where T : class, new();
IList<T> QueryEntities<T>(string sqlStr) where T : class, new();
IList<T> QueryEntities<T>(string table, string fields, string condition, Pager pager) where T : class, new();
bool Add(object obj);
bool Update(object obj);
IList<T> QueryEntities<T>(string table, string fields, string condition, Pager pager, ref int totalRecords) where T : class, new();
}
public <T extends Object> T get(){
return (T)new StringBuffer("test");
}
public <T> List<T> getList(){
return new ArrayList<T>();
}
Object QueryBean(String classPath){
Object obj = null;
try {
Class clazz = Class.forName(classPath);
obj = clazz.newInstance();
} catch (InstantiationException e) {
e.printStackTrace();