hibernate-tools maven插件
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>hibernate3-maven-plugin</artifactId>
<version>3.1-SNAPSHOT</version>
<!-- <version>3.0</version> -->
<executions>
<execution>
<id>Generate hbm.xml mappings</id>
<phase>generate-sources</phase>
<configuration>
<hibernatetool destdir="src/main/java">
<jdbcconfiguration propertyfile="hibernate.properties" packagename="entity" />
<!-- <hbm2hbmxml/> <hbm2cfgxml/>
<classpath>
<path location="target/classes"/>
</classpath> -->
<!--基于注解-->
<hbm2java ejb3="true">
<!-- <configuration configurationfile="target/classes/hibernate.cfg.xml"/> -->
</hbm2java>
</hibernatetool>
</configuration>
<goals>
<goal>run</goal>
</goals>
</execution>
</executions>
</plugin>
<dependency>
<groupId>org.hibernate</groupId>
<artifactId>hibernate-annotations</artifactId>
<version>3.4.0.GA </version>
</dependency>
上一篇: js中关于el表达式的使用方法
下一篇: grub 引导Win7