XML Related Terms Description

Source: Internet
Author: User

<project xmlns= "http://maven.apache.org/POM/4.0.0"-namespace, similar to package name, because XML tags can be customized, namespaces are required to differentiate
Xmlns:xsi= "Http://www.w3.org/2001/XMLSchema-instance"--xml follow the label specification
Xsi:schemalocation= "http://maven.apache.org/POM/4.0.0
Http://maven.apache.org/xsd/maven-4.0.0.xsd ">
--the address used to define XmlSchema, which is the syntax to be followed when writing XML,
Two parts, the front part is the name of the namespace, followed by the XSD (xmlschema) address


XSI full name: XML Schema Instance

Web-app is the root node tag name for Web. xml
Version is the meaning of the edition
Xmlns is the namespace used by the Web. xml file
Xmlns:xsi refers to the Web. XML compliance
Xsi:schemalocation refers to the specific schema resources used


Let me explain to you, first this file is an XML file, then everything inside of him conforms to the XML syntax specification,
The beginning of <project></project> the outermost layer is also a label for the XML file,
The long list behind that is the so-called attribute,
Where xmlns represents the namespace, xmlns= "http://maven.apache.org/POM/4.0.0" which represents the default namespace,
and the following xmlns:xsi= "Http://www.w3.org/2001/XMLSchema-instance"
The elements or attributes within this namespace must be written in xsi: this way,
For example schemalocation is one of his attributes, so write xsi:schemalocation,
And the default namespace does not take similar xsi this, in fact, the XML tag name has a professional term called QName,
And if there is no previous xsi: this is generally called NCName.
So you see, the <dependency> inside the MVN is the element below the default namespace,
The last line represents a reference to the schema file that defines this namespace,
So that the Eclipse type tool can parse and verify that your XML file conforms to the syntax specification.
Equivalent to <import namespace= "xxx" schemalocation= "xxx.xsd"/>.

Reference
http://bbs.csdn.net/topics/390751819



XML Related Terms Description

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.