问题描述:

Element 'xxxxxxx' cannot have character [children],because the type's content type is element-only

原因:

配置文件中的beans节点下面只能是元素节点,不能有字符或文本存在。

比如多余的标点符号,点,也有可能是空格。

解决:

将配置文件之间的空格删掉,有时候眼睛看着明明没有什么问题,但是删掉就没有问题了。。。。

类似于:

<plugin> <groupId> org.apache.maven.plugins </ groupId> <artifactId> maven-shade-plugin </ artifactId> <version> 1.2.1 </ version> <executions> <execution> <phase> package < / phase> <goals> <goal> shade </ goal> </ goals> <configuration> <transformers> <transformer implementation =“org.apache.maven.plugins.shade.resource.ManifestResourceTransformer”> <mainClass> com.cloume .project.App </ mainClass> </ transformer> </ transformers> </ configuration> </ execution> </ executions> </ plugin>

最后option+command+L回复格式就行了。

Element 'dependencies' cannot have character[children],because the type's content type is elemen的更多相关文章

  1. Springs Element 'beans' cannot have character [children], because the type's content type is element-only

    Springs Element 'beans' cannot have character [children], because the type's content type is element ...

  2. cvc-complex-type.2.3: Element 'beans' cannot have character [children]

    当启动spring的项目时,有时候会抛如下异常: Line 33 in XML document from ServletContext resource [/WEB-INF/backend-serv ...

  3. 万能的ctrl+shift+F(Element 'beans' cannot have character [children], because the type's content type is element-only.错误)

    今天在spring-servlet.xml文件中出现了一个莫名其妙的错误:Element 'beans' cannot have character [children], because the t ...

  4. Element 'beans' cannot have character [children]

    在编写spring的applicationContext.xml文件时,出现了: Element 'beans' cannot have character [children], because t ...

  5. Element 'beans' cannot have character [children], because the type's content type is element-only

    这个小问题快搞死我了,找了大半个小时. Element 'beans' cannot have character [children], because the type's content typ ...

  6. xml文件报Element 'beans' cannot have character [children],because the type's content type is element

    写springMvc.xml文件时,偶然遇到 Element 'beans' cannot have character [children],because the type's content t ...

  7. vc-complex-type.2.3: Element 'filter-mapping' cannot have character [children], because the type's content type is element-only.

    报这种错一般是因为导入的项目或者黏贴的代码中有中文空格或者中文编码,只需将报错代码重写一遍即可.

  8. Element 'plugin' cannot have character [children], because the type's content type is element-only

    原因是你复制的时候,带了一些特殊符号. 解决方案: 将那一串代码复制到notpad++ 或者文本上面,再复制到你的编译器里面,就可以解决问题了

  9. cvc-complex-type.2.3: Element 'dependency' cannot have character [children], because the type's cont

    直接复制网上的pom引入,报错 解决:自己手动输入一遍,不用直接复制,因为复制的时候,项目中编码跟网页上编码不一致,很容易导致出问题.

随机推荐

  1. 字典(Trie树)

    4189 字典  时间限制: 1 s  空间限制: 256000 KB  题目等级 : 大师 Master     题目描述 Description 最经,skyzhong得到了一本好厉害的字典,这个 ...

  2. PropertyInfo 类

    [AttributeUsage(AttributeTargets.Property)] //Models 特性        public class CanWriteAttribute : Attr ...

  3. 51nod1565 FFT

    思路: 显然拆位FFT 不解释 //By SiriusRen #include <bits/stdc++.h> using namespace std; ; ); ,L,S,T,k,sa[ ...

  4. flask 初始

    一.flask安装 这里提供两种安装方式: 第一种: pip3 install flask 第二种: pip3 install -i https://pypi.douban.com/simple/ f ...

  5. Java系列学习(十四)-集合

    1.java中的集合学习 2.Collection中常用方法 1.添加功能 boolean add(E e):添加一个元素 boolean addAll(Collection<? extends ...

  6. Objective-C——Runtime理解

    动态语言 OC是一门不折不扣的动态语言,所以它的很多机制都是动态运行时决定的.这点和C语言不一样,C语言是静态绑定,也就是编译后所有的一切都已经决定了.这一点和C语言的函数指针有些类似,很多时候函数指 ...

  7. CF832B Petya and Exam

    思路: 模拟. 实现: #include <iostream> using namespace std; string a, b; ]; bool solve() { ) return f ...

  8. Count the consecutive zero bits (trailing) on the right with multiply and lookup

    我在网上看到了一点神奇的代码,用来计算一个数字末尾连续零的个数. 刚好我在优化一个I2C读写函数(只写入I2C特定bit),觉得这个很有用.经过尝试,确实没问题. 下面我隆重介绍一下: Count t ...

  9. Android 基础知识图谱

    四大组件 Activity Service BroadcastReceiver ContentProvider Application 常用组件 Fragment RecyclerView WebVi ...

  10. fastjson——json工具库

    fastjson alibaba fastjson是阿里巴巴公司开源维护的一个处理json格式数据的java工具库. 功能特性: 数据绑定databind (json string <--> ...