Hibernate问题...大家帮帮我啊
<set name="MForums" inverse="true" order-by="adddate DESC"> <key> <column name="threadid" length="2" not-null="true" /> </key> <one-to-many name="code">ThreadMoudle tm = new ThreadMoudle ();Session session = HibernateSessionFactory.getSession();Transaction tran = session.beginTransaction();MThreads threads = (MThreads)session.get(MThreads.class, id);tm.threads = threads;for (MForum mf : threads.getMForums()) {tm.forum.add(mf);}tran.commit();HibernateSessionFactory.closeSession();