摘要: @Transient public static List<Article> queryByPosition(PositionInfo pinfo){ //System.out.println(" query "); //String hql="from Article art where art. 阅读全文
posted @ 2017-01-03 18:23 大峰1992 阅读(340) 评论(0) 推荐(0) 编辑
摘要: 当转集合泛型时候 请这样GsonUtils.getGson().fromJson(exhiMain.getQiTaFressJson(), new TypeToken<List<QiTaFree>>(){}.getType()); 如果比如这样转List<String> fanList = Gson 阅读全文
posted @ 2017-01-03 12:08 大峰1992 阅读(3101) 评论(0) 推荐(0) 编辑
摘要: public static <T> T get(String hql, Class<T> t) { EntityManager em = getFactory().createEntityManager(); try { return em.createQuery(hql, t).getSingle 阅读全文
posted @ 2017-01-03 12:00 大峰1992 阅读(3079) 评论(0) 推荐(0) 编辑
摘要: jedis UniqueConstraint定义在Table或SecondaryTable元数据里,用来指定建表时需要建唯一约束的列。 元数据属性说明: columnNames:定义一个字符串数组,指定要建唯一约束的列名。 @Entity @Table(name="EMPLOYEE", unique 阅读全文
posted @ 2017-01-03 11:58 大峰1992 阅读(3963) 评论(0) 推荐(0) 编辑