在Flex项目中使用Maven之FlexMojo
来源:互联网 发布:王逗逗淘宝店铺号 编辑:程序博客网 时间:2024/05/22 01:35
http://www.riameeting.com/node/453
1.Creating a Flex Mojos Project from an Archetype
以下命令使用的flex-mojos版本为3.5
Creates a simple Flex Library project which produces a SWC
Creates a simple Flex Application with produces a SWF
Creates a Multimodule project which consists of a project that produces a SWC which is consumed by a project which produces a SWF that is ultimately presented in a project that generates a WAR
2.指定flash player版本
第一步:
<plugins>
<plugin>
省略----
<!--添加的部分-->
<configuration>
<targetPlayer>10.0.0</targetPlayer> <!-- 指定Flash Player版本 -->
</configuration>
省略----
第二部:指定com.adobe.flex.framework.playerglobal 版本
<dependency>
<groupId>com.adobe.flex.framework</groupId>
<artifactId>playerglobal</artifactId>
<version>3.4.0.9271</version>
<classifier>10</classifier>
<type>swc</type>
</dependency>
第三部:取消默认设置,flex3指定的默认设置为flash player9
<dependency>
<groupId>com.adobe.flex.framework</groupId>
<artifactId>flex-framework</artifactId>
<version>3.4.0.9271</version>
<type>pom</type>
<exclusions>
<exclusion>
<groupId>com.adobe.flex.framework</groupId>
<artifactId>playerglobal</artifactId>
</exclusion>
</exclusions>
</dependency>
完整pom.xml实例:
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.company</groupId>
<artifactId>test</artifactId>
<version>1.0.0-SNAPSHOT</version>
<packaging>swf</packaging>
<name>TEST</name>
<dependencies>
<dependency>
<groupId>com.adobe.flex.framework</groupId>
<artifactId>flex-framework</artifactId>
<version>3.4.0.9271</version>
<type>pom</type>
<exclusions>
<!-- make sure to exclude the default 'playerglobal' transitive dependency -->
<exclusion>
<groupId>com.adobe.flex.framework</groupId>
<artifactId>playerglobal</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>com.adobe.flex.framework</groupId>
<artifactId>playerglobal</artifactId>
<version>3.4.0.9271</version> <!-- this artifact version must match the flex SDK version used in this project -->
<classifier>10</classifier> <!-- the classifier specifies the target flash player major version -->
<type>swc</type>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.sonatype.flexmojos</groupId>
<artifactId>flexmojos-maven-plugin</artifactId>
<version>3.3.0</version>
<extensions>true</extensions>
<!-- explicitly define the Flex SDK compiler version to use -->
<dependencies>
<dependency>
<groupId>com.adobe.flex</groupId>
<artifactId>compiler</artifactId>
<version>3.4.0.9271</version>
<type>pom</type>
</dependency>
</dependencies>
<!-- configuration for the Flex compilation -->
<configuration>
<targetPlayer>10.0.0</targetPlayer> <!-- compiler option specifying the target flash player version -->
<incremental>false</incremental>
<debug>false</debug>
<locale>en_US</locale>
<optimize>true</optimize>
<showWarnings>true</showWarnings>
<strict>true</strict>
<useNetwork>true</useNetwork>
<allowSourcePathOverlap>true</allowSourcePathOverlap>
<sourcePaths>
<path>${basedir}/src/main/flex</path>
</sourcePaths>
</configuration>
</plugin>
</plugins>
</build>
<repositories>
<repository>
<id>flex-mojos-repository</id>
<url>http://repository.sonatype.org/content/groups/flexgroup/</url>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>flex-mojos-repository</id>
<url>http://repository.sonatype.org/content/groups/flexgroup/</url>
</pluginRepository>
</pluginRepositories>
</project>
- 在Flex项目中使用Maven(四)之FlexMojo
- 在Flex项目中使用Maven之FlexMojo
- memcached之在maven项目中使用spymemcached
- memcached之在maven项目中使用spymemcached
- maven学习之从搭建maven环境到在项目中如何使用maven
- 成功在wtp项目中使用maven
- 在Eclipse中使用maven创建项目
- memcached 在maven项目中使用
- memcached 在maven项目中使用
- 在eclipse中如何使用maven项目
- nuxus maven库在maven项目中如何使用
- 在Flex项目中使用Flash媒体组件播放视频
- 在Flex库项目中使用defaults.css文件
- 在eclipse项目中使用maven管理依赖(转)
- 在eclipse项目中使用maven管理依赖
- 在eclipse项目中使用maven管理依赖
- 在Eclipse中使用resin调试maven war项目
- 在ECLIPSE中使用maven插件创建webapp类型项目
- 想要积分的菜鸟灌水吧...
- 收索文件夹及子文件夹下的txt,并统计txt文件的单词出现的个数
- POJ 1001 Exponentiation解题报告
- 关于GridView的分页-万能分页代码
- 找不到 make 找不到 phpize
- 在Flex项目中使用Maven之FlexMojo
- 不争气啊!
- 同体积的正方体和立方体谁面积大?
- Cache-control
- ASP.NET PK PHP,谁是速度之王?
- 难忘的一天
- 什么是PHP?网站开发为什么选择PHP?
- 问题:何时使用Thread.getContextClassLoader()?
- 穿越NAT总结(转)