`
jiasudu1649
  • 浏览: 719645 次
  • 性别: Icon_minigender_1
  • 来自: 上海
社区版块
存档分类
最新评论

Maven AppFuse Plugin

阅读更多


  • appfuse:gen-model:根据数据库的表生成java类 
  • appfuse:gen:  根据 POJOs.生成并安装 Tests, DAOs, Managers, Controllers and Views
  • appfuse:remove: 删除appfuse:gen.生成的代码
  • appfuse:full-source: Converts AppFuse basic projects to full-source with no AppFuse dependencies. Also renames packages to match your project's groupId.

In the pom.xml, insert this segment.

xml 代码
 
  1. <project>  
  2. ...  
  3.   <build>  
  4.     <plugins>  
  5.       <plugin>  
  6.         <groupId>org.codehaus.mojo<!---->groupId>  
  7.         <artifactId>appfuse-maven-plugin<!---->artifactId>  
  8.         <version>2.0<!---->version>  
  9.         <configuration>  
  10.           <genericCore>true<!---->genericCore> <!---->  
  11.           <fullSource>false<!---->fullSource> <!---->  
  12.         <!---->configuration>  
  13.         <dependencies>  
  14.           <dependency>  
  15.             <groupId>${jdbc.groupId}<!---->groupId>  
  16.             <artifactId>${jdbc.artifactId}<!---->artifactId>  
  17.             <version>${jdbc.version}<!---->version>  
  18.           <!---->dependency>  
  19.         <!---->dependencies>  
  20.       <!---->plugin>  
  21.     <!---->plugins>  
  22.   <!---->build>  
  23. ...  
  24. <!---->project>  

File<o:p></o:p>

Comment Replaced<o:p></o:p>

Web Framework<o:p></o:p>

src/main/webapp/WEB-INF/applicationContext.xml<o:p></o:p>

<!----><o:p></o:p>

All<o:p></o:p>

src/main/webapp/WEB-INF/applicationContext.xml<o:p></o:p>

<!----><o:p></o:p>

All<o:p></o:p>

core/src/main/resources/applicationContext.xml<o:p></o:p>

<!----><o:p></o:p>

All<o:p></o:p>

core/src/main/resources/applicationContext.xml<o:p></o:p>

<!----><o:p></o:p>

All<o:p></o:p>

src/main/webapp/WEB-INF/faces-config.xml<o:p></o:p>

<!----><o:p></o:p>

JSF<o:p></o:p>

src/main/webapp/WEB-INF/faces-config.xml<o:p></o:p>

<!----><o:p></o:p>

JSF<o:p></o:p>

src/main/webapp/WEB-INF/dispatcher-servlet.xml<o:p></o:p>

<!----><o:p></o:p>

Spring MVC<o:p></o:p>

src/main/webapp/WEB-INF/applicationContext.xml<o:p></o:p>

<!----><o:p></o:p>

Struts<o:p></o:p>

src/main/resources/struts.xml<o:p></o:p>

<!----><o:p></o:p>

Struts<o:p></o:p>






生成 CRUD 用 AMP
In the AppFuse 2.0 M5 release, you can run the following command to generate

CRUD screens/classes for a POJO:

appfuse:gen -Dentity=Name

If you don't specify the entity name, you're prompted for it. After generating

the code, you can install it using:

appfuse:install -Dentity=Name

Your entity must be defined in your hibernate.cfg.xml file for this to work.

In a modular project, these commands must be run in the "core" and "web"

modules. The plugin is smart enough to figure out when it should/should not

generate stuff based on the packaging type (jar vs. war). In a future release,

we hope to combine "gen" and "install" into a single command.



The Maven Hibernate3 Plugin has seven goals.

    * hibernate3:hbm2cfgxml: Generates hibernate.cfg.xml
    * hibernate3:hbm2ddl: Generates database schema.
    * hibernate3:hbm2doc: Generates HTML documentation for the database

schema.
    * hibernate3:hbm2hbmxml: Generates a set of hbm.xml files
    * hibernate3:hbm2java: Generates Java classes from set of *.hbm.xml files
    * hibernate3:schema-export: Creates SQL DDL file and generates the

database schema from set of *.hbm.xml files
    * hibernate3:schema-update: Updates the database schema based on the set

of *.hbm.xml files
分享到:
评论

相关推荐

    Appfuse1.9至2.0.2

    主要是自己从网络上搜集的一些关于appfuse1.8.2-2.0.2的一些相关资料,间或有点自己试验的记录,还有点maven和quartz的东东,之前我主要是用1.8.2构建项目,感觉还不错,希望对想学习appfuse的人有些帮助.

    appfuse-service-3.0.0.zip

    《AppFuse Service 3.0.0与Closure Compiler Maven Plugin深度解析》 AppFuse Service 3.0.0 是一个开源项目,它提供了一个基础框架,用于快速开发企业级Java应用。这个版本的亮点在于其集成了一系列现代开发工具和...

    appfuse2学习日记

    - 方法三:使用 Maven 插件 `tomcat7-maven-plugin` 或 `tomcat8-maven-plugin` 进行部署。 以上是关于 AppFuse2 学习过程中涉及的关键知识点和步骤,希望能帮助初学者更好地理解和掌握 AppFuse2 的使用方法。

    Maven完全适用手册

    Maven2引入了预定义模板,允许用户自定义项目结构,类似于AppFuse,极大地提高了开发效率。 **5. 生命周期的概念** Maven2引入了明确的生命周期概念,如clean、compile、test、install和deploy等,每个阶段都有对应...

    建立项目原型骨架的步骤(最新版本appfuse)appfuse2.1.0-M2

    3. 接下来,为了让Eclipse识别并导入Maven项目,执行`mvn eclipse:eclipse`,并将pom.xml中maven-eclipse-plugin的版本改为2.5.1。 4. 在Eclipse中,可能需要配置环境变量以指向M2_REPO,即本地Maven仓库。可以通过...

    maven2完全使用手册

    3. **Plugin语言支持**:Maven2开始支持Java、BeanShell和Ant作为插件编写语言,扩展性更强。 4. **预定义模板**:用户可以自定义项目模板,像使用Appfuse那样快速生成项目结构,提高开发效率。 5. **生命周期的...

    Appfuse常用命令.doc

    文档中提到的是AppFuse中与Maven相关的常用命令,特别是针对Hibernate3的插件和maven-eclipse-plugin插件的使用。 1. Maven Hibernate3 Plugin: 这个插件主要用于自动化Hibernate的相关任务,如数据库映射文件的...

    Maven 的41种骨架功能介绍

    ### Maven的41种骨架功能介绍 Maven作为一款强大的构建工具,在软件开发过程中扮演着极其重要的角色。它不仅能够帮助开发者自动化构建过程,还能通过其骨架(Archetype)功能来快速搭建项目的初始结构,极大地提高...

    Maven完全手册

    这点是最有帮助的,用户可以自己定义自己的项目模版了,就像用appfuse一样生成项目结构 5. 生命周期的引入 在Maven2中有了明确的生命周期概念,而且都提供与之对应的命令,使得项目构建更加清晰明了。 6. 新增...

    pom详解示例

    * `artifactId` 元素:指定了项目的工件名,例如 appfuse。 * `version` 元素:指定了项目的版本号。 * `packaging` 元素:指定了项目的打包方式,例如 jar、war、ear 等。 * `classifier` 元素:用于区分同一个 POM...

Global site tag (gtag.js) - Google Analytics