`

web.xml is missing and <failOnMissingWebXml> is set to true

 
阅读更多
在学习maven模块化构建项目的时候遇到了如下报错信息:

web.xml is missing and <failOnMissingWebXml> is set to true

。这时候需要右击项目——>Java EE Tools——>Generate Deployment Descriptor Stub.然后系统会在src/main/webapp/WEB_INF文件加下创建web.xml文件。错误解决!

当然这个方法是针对web项目的解决方案,如果你的工程不是web项目,那么还有另外一种解决方案,就是在pom文件中配置一下failOnMissingWebXml。具体配置如下:

引用
<build>

  <plugins>

   <plugin>

    <groupId>org.apache.maven.plugins</groupId>

    <artifactId>maven-war-plugin</artifactId>

    <version>2.6</version>

    <configuration>

     <failOnMissingWebXml>false</failOnMissingWebXml>

    </configuration>

   </plugin>

  </plugins>

</build>


参考:http://my.oschina.net/799835984/blog/540242
分享到:
评论

相关推荐

    apktool documentation

    In addition to XMLs, resources such as 9 patch images, layouts, strings and much more are correctly decoded to source form. Decoding The decode option on Apktool can be invoked either from d or ...

    Android TextToSpeech简单使用

    HashMap&lt;String, String&gt; params = new HashMap&lt;&gt;(); params.put(TextToSpeech.Engine.KEY_PARAM_VOLUME, "1.0"); // 设置音量,范围0.0到1.0 params.put(TextToSpeech.Engine.KEY_PARAM_PITCH, "1.5"); // 设置音调...

    dp18_ap6330整理完工20170209_1129.7z

    &lt;bool translatable="false" name="config_wifi_dual_band_support"&gt;true&lt;/bool&gt; 6、 Z:\home\wwt\dp18_ap6330\android\device\softwinner\tulip-d1\bluetooth\vnd_tulip-d1.txt BLUETOOTH_UART_DEVICE_PORT = ...

    Android 调用安卓自带文本朗读-IT计算机-毕业设计.zip

    HashMap&lt;String, String&gt; params = new HashMap&lt;&gt;(); params.put(TextToSpeech.Engine.KEY_PARAM_SPEED, "1.5"); // 设置语速为1.5倍 params.put(TextToSpeech.Engine.KEY_PARAM_VOLUME, "1.0"); // 设置音量为最大 ...

    Android TTS 文字转语音实例

    最后,由于TTS服务需要网络权限,因此在AndroidManifest.xml中添加了`&lt;uses-permission android:name="android.permission.INTERNET" /&gt;`。同时,`&lt;uses-feature&gt;`标签声明了对TTS的支持,`android:required="true"`...

    Android-Text2Speach语音合成文字转语音

    HashMap&lt;String, String&gt; params = new HashMap&lt;&gt;(); params.put(TextToSpeech.Engine.KEY_PARAM_VOLUME, "1.0"); // 设置音量,范围0.0-1.0 params.put(TextToSpeech.Engine.KEY_PARAM_PITCH, "1.5"); // 设置语调...

    php.ini-development

    in production environments and one that is recommended to be used in ; development environments. ; php.ini-production contains settings which hold security, performance and ; best practices at its ...

    安卓开发-调用安卓自带文本朗读.zip

    &lt;uses-feature android:name="android.software.text_to_speech" android:required="true" /&gt; ``` 接下来,我们需要在代码中初始化TextToSpeech对象。在Activity或Service中,我们可以创建一个TextToSpeech实例,并...

    ZendFramework中文文档

    1. Introduction to Zend Framework 1.1. 概述 1.2. 安装 2. Zend_Acl 2.1. 简介 2.1.1. 关于资源(Resource) 2.1.2. 关于角色(Role) 2.1.3. 创建访问控制列表(ACL) 2.1.4. 注册角色(Role) 2.1.5. 定义访问...

    eac3to V3.17

    * log file now contains "&lt;WARNING&gt;" and "&lt;ERROR&gt;" indicators * workaround for movie playlists which want the same m2ts file played twice * added version check for eac3to (doh!) * when a read error ...

    android 语音播报

    &lt;uses-feature android:name="android.software.tts" android:required="true" /&gt; ``` `INTERNET`权限是用于下载语音库,而`android.software.tts`则表明应用需要TTS功能。 接下来,我们需要创建一个TTS引擎实例,...

    (通配符条目)带有Toast的Listview数组的Android文本到语音合成

    ArrayAdapter&lt;String&gt; adapter = new ArrayAdapter&lt;&gt;(this, android.R.layout.simple_list_item_1, items); ListView listView = findViewById(R.id.list_view); listView.setAdapter(adapter); ``` 为了实现TTS,...

    Android-一个基于Java的粤语发音TTS文字转语音.

    &lt;uses-feature android:name="android.software.text_to_speech" android:required="true" /&gt; ``` 接着,在代码中创建TextToSpeech实例: ```java TextToSpeech tts = new TextToSpeech(context, new TextTo...

    Ofbiz10.04改用mysql数据库配置

    在`entityengine.xml`中,找到`&lt;delegator&gt;`标签,设置默认的数据源为`localmysql`。这告诉Ofbiz使用我们刚刚配置的`localmysql`数据源来处理`org.ofbiz`和`org.ofbiz.olap`组的数据。 ```xml &lt;delegator name=...

    TongWeb7的JPA.doc

    : Missing required persistence.xml for @PersistenceContext ref "em" to unit ""]`提示缺少了`persistence.xml`文件,这是JPA配置的核心文件,用于定义数据源、实体类和持久化单元等信息。如果在应用部署时找不...

    Fortify解决方案手册.docx

    Set&lt;String&gt; validProperties = new HashSet&lt;&gt;(Arrays.asList("username", "email")); // 在填充bean之前验证属性名 if (validProperties.contains(propertyName)) { // 执行bean填充逻辑 } ``` #### 二、Command...

    Android TTs 文本转语音朗读源码

    &lt;uses-feature android:name="android.software.text_to_speech" android:required="true" /&gt; ``` 2. **初始化TextToSpeech** 在Activity或Service中,创建TextToSpeech对象并进行初始化,通常在onCreate()方法...

    c#生成excel示例sql数据库导出excel

    wb.SaveAs(fileName, XlFileFormat.xlWorkbookNormal, Missing.Value, Missing.Value, Missing.Value, Missing.Value, XlSaveAsAccessMode.xlExclusive, Missing.Value, Missing.Value, Missing.Value, Missing....

    linux全志R16的linux系统编译的资料_20170502_1655.7z

    Preparing to unpack .../libhtml-tagset-perl_3.20-2_all.deb ... Unpacking libhtml-tagset-perl (3.20-2) ... Selecting previously unselected package libhtml-parser-perl. Preparing to unpack .../libhtml-...

Global site tag (gtag.js) - Google Analytics