eclipse的xml文件提示templates的模板.md
eclipse的xml文件提示templates的模板
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<templates>
<template autoinsert="true" context="xml_tag" enabled="true" id="org.springframework.ide.eclipse.beans.ui.editor.template.bean" name="Bean"><bean id="${id}" class="${class}">
${cursor}
</bean></template>
<template autoinsert="true" context="xml_tag" deleted="false" description="Inserts a constructor argument tag with one argument" enabled="true" id="org.springframework.ide.eclipse.beans.ui.editor.template.bean.constructor" name="Constructor Argument"><constructor-arg>
<list>
<value>${cursor}</value>
</list>
</constructor-arg></template>
<template autoinsert="true" context="xml_tag" deleted="false" description="Inserts a map" enabled="true" id="org.springframework.ide.eclipse.beans.ui.editor.template.bean.property.map" name="Map"><map>
<entry key="${key}">${cursor}</entry>
</map></template>
<template autoinsert="true" context="xml_tag" deleted="false" description="Inserts a property tag" enabled="true" id="org.springframework.ide.eclipse.beans.ui.editor.template.bean.property" name="Property"><property name="${name}">${cursor}</property></template>
<template autoinsert="true" context="xml_tag" deleted="false" description="Inserts a property tag with a ref attribute" enabled="true" id="org.springframework.ide.eclipse.beans.ui.editor.template.bean.property_with_ref_inline" name="Property with ref attribute"><property name="${name}" ref="${cursor}" /></template>
<template autoinsert="true" context="xml_tag" deleted="false" description="Inserts a property tag with nested value tag" enabled="true" id="org.springframework.ide.eclipse.beans.ui.editor.template.bean.property_with_value" name="Property with value"><property name="${name}">
<value>${cursor}</value>
</property></template>
<template autoinsert="true" context="xml_tag" deleted="false" description="Inserts a property tag with a value attribute" enabled="true" id="org.springframework.ide.eclipse.beans.ui.editor.template.bean.property_with_value_inline" name="Property with value attribute"><property name="${name}" value="${cursor}" /></template>
<template autoinsert="true" context="xml_tag" deleted="false" description="Inserts a bean reference" enabled="true" id="org.springframework.ide.eclipse.beans.ui.editor.template.bean.property.ref.bean" name="Ref bean"><ref bean="${id}"/>${cursor}</template>
<template autoinsert="true" context="xml_tag" deleted="false" description="Inserts a local bean reference" enabled="true" id="org.springframework.ide.eclipse.beans.ui.editor.template.bean.property.ref.local" name="Ref local"><ref local="${id}"/>${cursor}</template>
<template autoinsert="true" context="xml_tag" deleted="false" description="Inserts a Web Flow Executor tag" enabled="true" id="org.springframework.ide.eclipse.webflow.ui.editor.template.executor" name="Web Flow Executor"><!-- Launches new flow executions and resumes existing executions. -->
${cursor}<flow:executor id="${flowExecutor}" registry-ref="${flowRegistry}" repository-type="${singlekey}" />
</template>
<template autoinsert="true" context="xml_tag" deleted="false" description="Inserts a Web Flow Registry tag" enabled="true" id="org.springframework.ide.eclipse.webflow.ui.editor.template.registry" name="Web Flow Registry"><!-- Creates the registry of flow definitions for this application -->
${cursor}<flow:registry id="${flowRegistry}">
<flow:location path="/WEB-INF/fileupload.xml" />
</flow:registry>
</template>
</templates>
这里是eclipse自带的xml模板
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<templates>
<template autoinsert="true" context="xml_tag" deleted="false" description="xml comment" enabled="true" id="org.eclipse.wst.xml.ui.internal.templates.comment" name="comment"><!-- ${cursor} --></template>
<template autoinsert="true" context="xml_tag" deleted="false" description="ContextLoaderListener" enabled="true" id="com.springsource.sts.quickfix.contextloaderlistener" name="contextloaderlistener"><!-- needed for ContextLoaderListener -->
<context-param>
<param-name>contextConfigLocation</param-name>
<param-value>${location}${cursor}</param-value>
</context-param>
<!-- Bootstraps the root web application context before servlet initialization -->
<listener>
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
</listener></template>
<template autoinsert="true" context="xml_attribute" deleted="false" description="Default Namespace Attribute" enabled="true" id="org.eclipse.wst.xml.ui.internal.templates.defaultnsp" name="default namespace">xmlns="default namespace"</template><template autoinsert="true" context="xml_tag" deleted="false" description="DispatcherServlet declaration" enabled="true" id="com.springsource.sts.quickfix.dispatcherservlet" name="dispatcherservlet"><!-- The front controller of this Spring Web application, responsible for handling all application requests -->
<servlet>
<servlet-name>springDispatcherServlet</servlet-name>
<servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
<init-param>
<param-name>contextConfigLocation</param-name>
<param-value>${location}${cursor}</param-value>
</init-param>
<load-on-startup>1</load-on-startup>
</servlet>
<!-- Map all requests to the DispatcherServlet for handling -->
<servlet-mapping>
<servlet-name>springDispatcherServlet</servlet-name>
<url-pattern>${url}</url-pattern>
</servlet-mapping></template>
<template autoinsert="true" context="xml_attribute" deleted="false" description="No Namespace Schema Location" enabled="true" id="org.eclipse.wst.xml.ui.internal.templates.noschemaLoc" name="noschemaLoc">xsi:noNamespaceSchemaLocation="{location}"</template>
<template autoinsert="true" context="xml_attribute" deleted="false" description="XML Schema location attribute" enabled="true" id="org.eclipse.wst.xml.ui.internal.templates.schemaLoc" name="schemaLoc">xsi:schemaLocation="{namespace} {location}"</template>
<template autoinsert="true" context="xml_new" deleted="false" description="xml declaration" enabled="true" id="org.eclipse.wst.xml.ui.internal.templates.xmldeclaration" name="xml declaration"><?xml version="1.0" encoding="${encoding}"?></template>
<template autoinsert="true" context="xml_attribute" deleted="false" description="XML Schema name space" enabled="true" id="org.eclipse.wst.xml.ui.internal.templates.xsinsp" name="xsinsp">xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"</template>
<template autoinsert="true" context="xml_tag" deleted="false" description="XSL processing instruction" enabled="true" id="org.eclipse.wst.xml.ui.internal.templates.xslpi" name="XSL processing instruction"><?xml-stylesheet type="text/xsl" href="${cursor}"?></template></templates>