(當時心想,哇~我真的可以開始設計模組了嗎?...真是不可思議 XD)
第一步就是先將自己所有能夠想到的解法都寫下來,然後對其做優缺點分析 (就像 SWOP 那樣,但沒那麼麻煩就是),接著請教前輩看看這樣子方法是不是可行,再把想法畫出來然後就開始動手實作,最後做出來也將它順利的套上各個專案了,真的滿開心的!


mvn install:install-file
-Dfile=<path-to-file>-DgroupId=<group-id>-DartifactId=<artifact-id>-Dversion=<version>-Dpackaging=<packaging>-DgeneratePom=true
Where: <path-to-file> the path to the file to load
<group-id> the group that the file should be registered under
<artifact-id> the artifact name for the file
<version> the version of the file
<packaging> the packaging of the file e.g. jar
EntityManagerFactory emf = ... ; EntityManager em = emf.createEntityManager(); try { EntityTransaction t = em.getTransaction(); try { t.begin(); // business logic to update the customer em.merge(cust); t.commit(); } finally { if (t.isActive()) t.rollback(); } } finally { em.close(); }