# HG changeset patch # User Edouard Tisserant <edouard.tisserant@gmail.com> # Date 1518742128 -3600 # Node ID b85b13b1c2ec3019c1b61e116220921b26e329ba # Parent f2b0d849ea77debbff2764b9d70812d22f0c97b9 YSLT auto indent trick is useless here, added yslt_noindent.yml2, regenerated XSLT files diff -r f2b0d849ea77 -r b85b13b1c2ec plcopen/Makefile --- a/plcopen/Makefile Fri Feb 16 01:38:34 2018 +0100 +++ b/plcopen/Makefile Fri Feb 16 01:48:48 2018 +0100 @@ -6,10 +6,10 @@ all:$(xsltfiles) -%.xslt: %.ysl2 +%.xslt: %.ysl2 yslt_noindent.yml2 $(yml)/yml2c -I $(yml) $< -o $@.tmp xmlstarlet fo $@.tmp > $@ rm $@.tmp clean: - rm -f $(xsltfiles) \ No newline at end of file + rm -f $(xsltfiles) diff -r f2b0d849ea77 -r b85b13b1c2ec plcopen/instance_tagname.xslt --- a/plcopen/instance_tagname.xslt Fri Feb 16 01:38:34 2018 +0100 +++ b/plcopen/instance_tagname.xslt Fri Feb 16 01:48:48 2018 +0100 @@ -1,8 +1,6 @@ <?xml version="1.0"?> -<xsl:stylesheet xmlns:func="http://exslt.org/functions" xmlns:dyn="http://exslt.org/dynamic" xmlns:str="http://exslt.org/strings" xmlns:math="http://exslt.org/math" xmlns:exsl="http://exslt.org/common" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:yml="http://fdik.org/yml" xmlns:set="http://exslt.org/sets" xmlns:ppx="http://www.plcopen.org/xml/tc6_0201" xmlns:ns="instance_tagname_ns" xmlns:regexp="http://exslt.org/regular-expressions" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" extension-element-prefixes="ns" version="1.0" exclude-result-prefixes="ns"> +<xsl:stylesheet xmlns:exsl="http://exslt.org/common" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:ppx="http://www.plcopen.org/xml/tc6_0201" xmlns:ns="instance_tagname_ns" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" extension-element-prefixes="ns" version="1.0" exclude-result-prefixes="ns"> <xsl:output method="xml"/> - <xsl:variable name="space" select="' '"/> - <xsl:param name="autoindent" select="4"/> <xsl:param name="instance_path"/> <xsl:variable name="project"> <xsl:copy-of select="document('project')/project/*"/> @@ -14,7 +12,6 @@ <xsl:copy-of select="document('extensions')/extensions/*"/> </xsl:variable> <xsl:template name="element_name"> - <xsl:param name="_indent" select="0"/> <xsl:param name="path"/> <xsl:choose> <xsl:when test="contains($path,'.')"> @@ -26,7 +23,6 @@ </xsl:choose> </xsl:template> <xsl:template name="next_path"> - <xsl:param name="_indent" select="0"/> <xsl:param name="path"/> <xsl:choose> <xsl:when test="contains($path,'.')"> @@ -35,14 +31,12 @@ </xsl:choose> </xsl:template> <xsl:template match="ppx:project"> - <xsl:param name="_indent" select="0"/> <xsl:variable name="config_name"> <xsl:call-template name="element_name"> <xsl:with-param name="path" select="$instance_path"/> </xsl:call-template> </xsl:variable> <xsl:apply-templates select="ppx:instances/ppx:configurations/ppx:configuration[@name=$config_name]"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="element_path"> <xsl:call-template name="next_path"> <xsl:with-param name="path" select="$instance_path"/> @@ -51,7 +45,6 @@ </xsl:apply-templates> </xsl:template> <xsl:template match="ppx:configuration"> - <xsl:param name="_indent" select="0"/> <xsl:param name="element_path"/> <xsl:choose> <xsl:when test="$element_path!=''"> @@ -61,7 +54,6 @@ </xsl:call-template> </xsl:variable> <xsl:apply-templates select="ppx:resource[@name=$child_name] | ppx:globalVars/ppx:variable[@name=$child_name]/ppx:type/*[self::ppx:derived or self::ppx:struct or self::ppx:array]"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="element_path"> <xsl:call-template name="next_path"> <xsl:with-param name="path" select="$element_path"/> @@ -75,7 +67,6 @@ </xsl:choose> </xsl:template> <xsl:template match="ppx:resource"> - <xsl:param name="_indent" select="0"/> <xsl:param name="element_path"/> <xsl:choose> <xsl:when test="$element_path!=''"> @@ -87,7 +78,6 @@ </xsl:call-template> </xsl:variable> <xsl:apply-templates select="ppx:pouInstance[@name=$child_name] | ppx:task/ppx:pouInstance[@name=$child_name] | ppx:globalVars/ppx:variable[@name=$child_name]/ppx:type/*[self::ppx:derived or self::ppx:struct or self::ppx:array]"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="element_path"> <xsl:call-template name="next_path"> <xsl:with-param name="path" select="$element_path"/> @@ -101,18 +91,15 @@ </xsl:choose> </xsl:template> <xsl:template match="ppx:pouInstance"> - <xsl:param name="_indent" select="0"/> <xsl:param name="element_path"/> <xsl:variable name="type_name"> <xsl:value-of select="@typeName"/> </xsl:variable> <xsl:apply-templates select="exsl:node-set($project)/ppx:project/ppx:types/ppx:pous/ppx:pou[@name=$type_name] | exsl:node-set($project)/ppx:project/ppx:types/ppx:dataTypes/ppx:dataType[@name=$type_name] | exsl:node-set($stdlib)/ppx:project/ppx:types/ppx:pous/ppx:pou[@name=$type_name] | exsl:node-set($stdlib)/ppx:project/ppx:types/ppx:dataTypes/ppx:dataType[@name=$type_name] | exsl:node-set($extensions)/ppx:project/ppx:types/ppx:pous/ppx:pou[@name=$type_name] | exsl:node-set($extensions)/ppx:project/ppx:types/ppx:dataTypes/ppx:dataType[@name=$type_name]"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="element_path" select="$element_path"/> </xsl:apply-templates> </xsl:template> <xsl:template match="ppx:pou"> - <xsl:param name="_indent" select="0"/> <xsl:param name="element_path"/> <xsl:choose> <xsl:when test="$element_path!=''"> @@ -122,16 +109,13 @@ </xsl:call-template> </xsl:variable> <xsl:apply-templates select="ppx:interface/*/ppx:variable[@name=$child_name]/ppx:type/*[self::ppx:derived or self::ppx:struct or self::ppx:array]"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="element_path"> <xsl:call-template name="next_path"> <xsl:with-param name="path" select="$element_path"/> </xsl:call-template> </xsl:with-param> </xsl:apply-templates> - <xsl:apply-templates select="ppx:actions/ppx:action[@name=$child_name] | ppx:transitions/ppx:transition[@name=$child_name]"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates select="ppx:actions/ppx:action[@name=$child_name] | ppx:transitions/ppx:transition[@name=$child_name]"/> </xsl:when> <xsl:otherwise> <xsl:variable name="name"> @@ -142,42 +126,33 @@ </xsl:choose> </xsl:template> <xsl:template match="ppx:action"> - <xsl:param name="_indent" select="0"/> <xsl:value-of select="ns:ActionTagName(ancestor::ppx:pou/@name, @name)"/> </xsl:template> <xsl:template match="ppx:transition"> - <xsl:param name="_indent" select="0"/> <xsl:value-of select="ns:TransitionTagName(ancestor::ppx:pou/@name, @name)"/> </xsl:template> <xsl:template match="ppx:dataType"> - <xsl:param name="_indent" select="0"/> <xsl:param name="element_path"/> <xsl:apply-templates select="ppx:baseType/*[self::ppx:derived or self::ppx:struct or self::ppx:array]"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="element_path" select="$element_path"/> </xsl:apply-templates> </xsl:template> <xsl:template match="ppx:derived"> - <xsl:param name="_indent" select="0"/> <xsl:param name="element_path"/> <xsl:variable name="type_name"> <xsl:value-of select="@name"/> </xsl:variable> <xsl:apply-templates select="exsl:node-set($project)/ppx:project/ppx:types/ppx:pous/ppx:pou[@name=$type_name] | exsl:node-set($project)/ppx:project/ppx:types/ppx:dataTypes/ppx:dataType[@name=$type_name] | exsl:node-set($stdlib)/ppx:project/ppx:types/ppx:pous/ppx:pou[@name=$type_name] | exsl:node-set($stdlib)/ppx:project/ppx:types/ppx:dataTypes/ppx:dataType[@name=$type_name] | exsl:node-set($extensions)/ppx:project/ppx:types/ppx:pous/ppx:pou[@name=$type_name] | exsl:node-set($extensions)/ppx:project/ppx:types/ppx:dataTypes/ppx:dataType[@name=$type_name]"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="element_path" select="$element_path"/> </xsl:apply-templates> </xsl:template> <xsl:template match="ppx:array"> - <xsl:param name="_indent" select="0"/> <xsl:param name="element_path"/> <xsl:apply-templates select="ppx:baseType/*[self::ppx:derived or self::ppx:struct or self::ppx:array]"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="element_path" select="$element_path"/> </xsl:apply-templates> </xsl:template> <xsl:template match="ppx:struct"> - <xsl:param name="_indent" select="0"/> <xsl:param name="element_path"/> <xsl:variable name="child_name"> <xsl:call-template name="element_name"> @@ -185,7 +160,6 @@ </xsl:call-template> </xsl:variable> <xsl:apply-templates select="ppx:variable[@name=$child_name]/ppx:type/*[self::ppx:derived or self::ppx:struct or self::ppx:array]"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="element_path"> <xsl:call-template name="next_path"> <xsl:with-param name="path" select="$element_path"/> diff -r f2b0d849ea77 -r b85b13b1c2ec plcopen/instance_tagname.ysl2 --- a/plcopen/instance_tagname.ysl2 Fri Feb 16 01:38:34 2018 +0100 +++ b/plcopen/instance_tagname.ysl2 Fri Feb 16 01:48:48 2018 +0100 @@ -1,5 +1,5 @@ -include yslt.yml2 -estylesheet xmlns:ppx="http://www.plcopen.org/xml/tc6_0201" +include yslt_noindent.yml2 +istylesheet xmlns:ppx="http://www.plcopen.org/xml/tc6_0201" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:ns="instance_tagname_ns" extension-element-prefixes="ns" diff -r f2b0d849ea77 -r b85b13b1c2ec plcopen/instances_path.xslt --- a/plcopen/instances_path.xslt Fri Feb 16 01:38:34 2018 +0100 +++ b/plcopen/instances_path.xslt Fri Feb 16 01:48:48 2018 +0100 @@ -1,12 +1,8 @@ <?xml version="1.0"?> -<xsl:stylesheet xmlns:func="http://exslt.org/functions" xmlns:dyn="http://exslt.org/dynamic" xmlns:str="http://exslt.org/strings" xmlns:math="http://exslt.org/math" xmlns:exsl="http://exslt.org/common" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:yml="http://fdik.org/yml" xmlns:set="http://exslt.org/sets" xmlns:ppx="http://www.plcopen.org/xml/tc6_0201" xmlns:ns="instances_ns" xmlns:regexp="http://exslt.org/regular-expressions" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" extension-element-prefixes="ns" version="1.0" exclude-result-prefixes="ns"> +<xsl:stylesheet xmlns:exsl="http://exslt.org/common" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:ppx="http://www.plcopen.org/xml/tc6_0201" xmlns:ns="instances_ns" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" extension-element-prefixes="ns" version="1.0" exclude-result-prefixes="ns"> <xsl:output method="xml"/> - <xsl:variable name="space" select="' '"/> - <xsl:param name="autoindent" select="4"/> <xsl:param name="instance_type"/> - <xsl:template match="text()"> - <xsl:param name="_indent" select="0"/> - </xsl:template> + <xsl:template match="text()"/> <xsl:variable name="project"> <xsl:copy-of select="document('project')/project/*"/> </xsl:variable> @@ -17,24 +13,18 @@ <xsl:copy-of select="document('extensions')/extensions/*"/> </xsl:variable> <xsl:template match="ppx:project"> - <xsl:param name="_indent" select="0"/> <instances> - <xsl:apply-templates select="ppx:instances/ppx:configurations/ppx:configuration"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates select="ppx:instances/ppx:configurations/ppx:configuration"/> </instances> </xsl:template> <xsl:template match="ppx:configuration"> - <xsl:param name="_indent" select="0"/> <xsl:apply-templates select="ppx:globalVars/ppx:variable[ppx:type/ppx:derived] | ppx:resource"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="parent_path"> <xsl:value-of select="@name"/> </xsl:with-param> </xsl:apply-templates> </xsl:template> <xsl:template match="ppx:resource"> - <xsl:param name="_indent" select="0"/> <xsl:param name="parent_path"/> <xsl:variable name="resource_path"> <xsl:value-of select="$parent_path"/> @@ -42,14 +32,12 @@ <xsl:value-of select="@name"/> </xsl:variable> <xsl:apply-templates select="ppx:globalVars/ppx:variable[ppx:type/ppx:derived] | ppx:pouInstance | ppx:task/ppx:pouInstance"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="parent_path"> <xsl:value-of select="$resource_path"/> </xsl:with-param> </xsl:apply-templates> </xsl:template> <xsl:template match="ppx:pouInstance"> - <xsl:param name="_indent" select="0"/> <xsl:param name="parent_path"/> <xsl:variable name="pou_instance_path"> <xsl:value-of select="$parent_path"/> @@ -65,7 +53,6 @@ <xsl:value-of select="@typeName"/> </xsl:variable> <xsl:apply-templates select="exsl:node-set($project)/ppx:project/ppx:types/ppx:pous/ppx:pou[@name=$type_name] | exsl:node-set($project)/ppx:project/ppx:types/ppx:dataTypes/ppx:dataType[@name=$type_name] | exsl:node-set($stdlib)/ppx:project/ppx:types/ppx:pous/ppx:pou[@name=$type_name] | exsl:node-set($stdlib)/ppx:project/ppx:types/ppx:dataTypes/ppx:dataType[@name=$type_name] | exsl:node-set($extensions)/ppx:project/ppx:types/ppx:pous/ppx:pou[@name=$type_name] | exsl:node-set($extensions)/ppx:project/ppx:types/ppx:dataTypes/ppx:dataType[@name=$type_name]"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="instance_path"> <xsl:value-of select="$pou_instance_path"/> </xsl:with-param> @@ -74,27 +61,22 @@ </xsl:choose> </xsl:template> <xsl:template match="ppx:pou"> - <xsl:param name="_indent" select="0"/> <xsl:param name="instance_path"/> <xsl:apply-templates select="ppx:interface/*/ppx:variable[ppx:type/ppx:derived]"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="parent_path"> <xsl:value-of select="$instance_path"/> </xsl:with-param> </xsl:apply-templates> </xsl:template> <xsl:template match="ppx:dataType"> - <xsl:param name="_indent" select="0"/> <xsl:param name="instance_path"/> <xsl:apply-templates select="ppx:baseType/*[self::ppx:derived or self::ppx:struct or self::ppx:array]"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="parent_path"> <xsl:value-of select="$instance_path"/> </xsl:with-param> </xsl:apply-templates> </xsl:template> <xsl:template match="ppx:variable"> - <xsl:param name="_indent" select="0"/> <xsl:param name="parent_path"/> <xsl:variable name="variable_path"> <xsl:value-of select="$parent_path"/> @@ -102,14 +84,12 @@ <xsl:value-of select="@name"/> </xsl:variable> <xsl:apply-templates select="ppx:type/ppx:derived"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="variable_path"> <xsl:value-of select="$variable_path"/> </xsl:with-param> </xsl:apply-templates> </xsl:template> <xsl:template match="ppx:derived"> - <xsl:param name="_indent" select="0"/> <xsl:param name="variable_path"/> <xsl:choose> <xsl:when test="@name=$instance_type"> @@ -120,7 +100,6 @@ <xsl:value-of select="@name"/> </xsl:variable> <xsl:apply-templates select="exsl:node-set($project)/ppx:project/ppx:types/ppx:pous/ppx:pou[@name=$type_name] | exsl:node-set($project)/ppx:project/ppx:types/ppx:dataTypes/ppx:dataType[@name=$type_name] | exsl:node-set($stdlib)/ppx:project/ppx:types/ppx:pous/ppx:pou[@name=$type_name] | exsl:node-set($stdlib)/ppx:project/ppx:types/ppx:dataTypes/ppx:dataType[@name=$type_name] | exsl:node-set($extensions)/ppx:project/ppx:types/ppx:pous/ppx:pou[@name=$type_name] | exsl:node-set($extensions)/ppx:project/ppx:types/ppx:dataTypes/ppx:dataType[@name=$type_name]"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="instance_path"> <xsl:value-of select="$variable_path"/> </xsl:with-param> @@ -129,7 +108,6 @@ </xsl:choose> </xsl:template> <xsl:template match="ppx:struct"> - <xsl:param name="_indent" select="0"/> <xsl:param name="variable_path"/> <xsl:for-each select="ppx:variable[ppx:type/ppx:derived or ppx:type/ppx:struct or ppx:type/ppx:array]"> <xsl:variable name="element_path"> @@ -139,17 +117,14 @@ </xsl:variable> </xsl:for-each> <xsl:apply-templates select="ppx:type/*[self::ppx:derived or self::ppx:struct or self::ppx:array]"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="variable_path"> <xsl:value-of select="$element_path"/> </xsl:with-param> </xsl:apply-templates> </xsl:template> <xsl:template match="ppx:array"> - <xsl:param name="_indent" select="0"/> <xsl:param name="variable_path"/> <xsl:apply-templates select="ppx:baseType/*[self::ppx:derived or self::ppx:struct or self::ppx:array]"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="variable_path"> <xsl:value-of select="$variable_path"/> </xsl:with-param> diff -r f2b0d849ea77 -r b85b13b1c2ec plcopen/instances_path.ysl2 --- a/plcopen/instances_path.ysl2 Fri Feb 16 01:38:34 2018 +0100 +++ b/plcopen/instances_path.ysl2 Fri Feb 16 01:48:48 2018 +0100 @@ -1,5 +1,5 @@ -include yslt.yml2 -estylesheet xmlns:ppx="http://www.plcopen.org/xml/tc6_0201" +include yslt_noindent.yml2 +istylesheet xmlns:ppx="http://www.plcopen.org/xml/tc6_0201" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:ns="instances_ns" extension-element-prefixes="ns" diff -r f2b0d849ea77 -r b85b13b1c2ec plcopen/pou_block_instances.xslt --- a/plcopen/pou_block_instances.xslt Fri Feb 16 01:38:34 2018 +0100 +++ b/plcopen/pou_block_instances.xslt Fri Feb 16 01:48:48 2018 +0100 @@ -1,24 +1,15 @@ <?xml version="1.0"?> -<xsl:stylesheet xmlns:func="http://exslt.org/functions" xmlns:dyn="http://exslt.org/dynamic" xmlns:str="http://exslt.org/strings" xmlns:math="http://exslt.org/math" xmlns:exsl="http://exslt.org/common" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:yml="http://fdik.org/yml" xmlns:set="http://exslt.org/sets" xmlns:ppx="http://www.plcopen.org/xml/tc6_0201" xmlns:ns="pou_block_instances_ns" xmlns:regexp="http://exslt.org/regular-expressions" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" extension-element-prefixes="ns" version="1.0" exclude-result-prefixes="ns"> +<xsl:stylesheet xmlns:exsl="http://exslt.org/common" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:ppx="http://www.plcopen.org/xml/tc6_0201" xmlns:ns="pou_block_instances_ns" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" extension-element-prefixes="ns" version="1.0" exclude-result-prefixes="ns"> <xsl:output method="xml"/> - <xsl:variable name="space" select="' '"/> - <xsl:param name="autoindent" select="4"/> - <xsl:template match="text()"> - <xsl:param name="_indent" select="0"/> - </xsl:template> + <xsl:template match="text()"/> <xsl:template match="ppx:pou[ppx:body]|ppx:transition[ppx:body]|ppx:action[ppx:body]"> - <xsl:param name="_indent" select="0"/> - <xsl:apply-templates select="ppx:body/*[self::ppx:FBD or self::ppx:LD or self::ppx:SFC]/*"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates select="ppx:body/*[self::ppx:FBD or self::ppx:LD or self::ppx:SFC]/*"/> </xsl:template> <xsl:template name="add_instance"> - <xsl:param name="_indent" select="0"/> <xsl:param name="type"/> <xsl:value-of select="ns:AddBlockInstance($type, @localId, ppx:position/@x, ppx:position/@y, @width, @height)"/> </xsl:template> <xsl:template name="execution_order"> - <xsl:param name="_indent" select="0"/> <xsl:choose> <xsl:when test="@executionOrderId"> <xsl:value-of select="@executionOrderId"/> @@ -29,7 +20,6 @@ </xsl:choose> </xsl:template> <xsl:template name="ConnectionInfos"> - <xsl:param name="_indent" select="0"/> <xsl:param name="type"/> <xsl:param name="negated"/> <xsl:param name="edge"/> @@ -37,18 +27,13 @@ <xsl:value-of select="ns:AddInstanceConnection($type, $formalParameter, $negated, $edge, ppx:relPosition/@x, ppx:relPosition/@y)"/> </xsl:template> <xsl:template match="ppx:position"> - <xsl:param name="_indent" select="0"/> <xsl:value-of select="ns:AddLinkPoint(@x, @y)"/> </xsl:template> <xsl:template match="ppx:connection"> - <xsl:param name="_indent" select="0"/> <xsl:value-of select="ns:AddConnectionLink(@refLocalId, @formalParameter)"/> - <xsl:apply-templates select="ppx:position"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates select="ppx:position"/> </xsl:template> <xsl:template match="ppx:connectionPointIn"> - <xsl:param name="_indent" select="0"/> <xsl:param name="negated"/> <xsl:param name="edge"/> <xsl:param name="formalParameter"/> @@ -66,12 +51,9 @@ <xsl:value-of select="$formalParameter"/> </xsl:with-param> </xsl:call-template> - <xsl:apply-templates select="ppx:connection"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates select="ppx:connection"/> </xsl:template> <xsl:template match="ppx:connectionPointOut"> - <xsl:param name="_indent" select="0"/> <xsl:param name="negated"/> <xsl:param name="edge"/> <xsl:param name="formalParameter"/> @@ -91,7 +73,6 @@ </xsl:call-template> </xsl:template> <xsl:template match="ppx:connectionPointOutAction"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="ConnectionInfos"> <xsl:with-param name="type"> <xsl:text>output</xsl:text> @@ -99,7 +80,6 @@ </xsl:call-template> </xsl:template> <xsl:template match="ppx:comment"> - <xsl:param name="_indent" select="0"/> <xsl:value-of select="ns:SetSpecificValues(ppx:content/xhtml:p/text())"/> <xsl:call-template name="add_instance"> <xsl:with-param name="type"> @@ -108,7 +88,6 @@ </xsl:call-template> </xsl:template> <xsl:template match="ppx:block"> - <xsl:param name="_indent" select="0"/> <xsl:variable name="execution_order"> <xsl:call-template name="execution_order"/> </xsl:variable> @@ -120,7 +99,6 @@ </xsl:call-template> <xsl:for-each select="ppx:inputVariables/ppx:variable"> <xsl:apply-templates select="ppx:connectionPointIn"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="negated" select="@negated"/> <xsl:with-param name="edge" select="@edge"/> <xsl:with-param name="formalParameter" select="@formalParameter"/> @@ -128,7 +106,6 @@ </xsl:for-each> <xsl:for-each select="ppx:outputVariables/ppx:variable"> <xsl:apply-templates select="ppx:connectionPointOut"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="negated" select="@negated"/> <xsl:with-param name="edge" select="@edge"/> <xsl:with-param name="formalParameter" select="@formalParameter"/> @@ -136,23 +113,18 @@ </xsl:for-each> </xsl:template> <xsl:template match="*[self::ppx:type or self::ppx:baseType or self::ppx:returnType]/ppx:derived"> - <xsl:param name="_indent" select="0"/> <xsl:value-of select="@name"/> </xsl:template> <xsl:template match="*[self::ppx:type or self::ppx:baseType or self::ppx:returnType]/ppx:string"> - <xsl:param name="_indent" select="0"/> <xsl:text>STRING</xsl:text> </xsl:template> <xsl:template match="*[self::ppx:type or self::ppx:baseType or self::ppx:returnType]/ppx:wstring"> - <xsl:param name="_indent" select="0"/> <xsl:text>WSTRING</xsl:text> </xsl:template> <xsl:template match="*[self::ppx:type or self::ppx:baseType or self::ppx:returnType]/*"> - <xsl:param name="_indent" select="0"/> <xsl:value-of select="local-name()"/> </xsl:template> <xsl:template name="VariableBlockInfos"> - <xsl:param name="_indent" select="0"/> <xsl:param name="type"/> <xsl:variable name="expression"> <xsl:value-of select="ppx:expression/text()"/> @@ -163,14 +135,10 @@ <xsl:text>BOOL</xsl:text> </xsl:when> <xsl:when test="ancestor::ppx:pou[@name=$expression]"> - <xsl:apply-templates select="ancestor::ppx:pou/child::ppx:interface/ppx:returnType"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> - </xsl:when> - <xsl:otherwise> - <xsl:apply-templates select="ancestor::ppx:pou/child::ppx:interface/*/ppx:variable[@name=$expression]/ppx:type"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates select="ancestor::ppx:pou/child::ppx:interface/ppx:returnType"/> + </xsl:when> + <xsl:otherwise> + <xsl:apply-templates select="ancestor::ppx:pou/child::ppx:interface/*/ppx:variable[@name=$expression]/ppx:type"/> </xsl:otherwise> </xsl:choose> </xsl:variable> @@ -184,51 +152,40 @@ </xsl:with-param> </xsl:call-template> <xsl:apply-templates select="ppx:connectionPointIn"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="negated" select="@negatedIn"/> <xsl:with-param name="edge" select="@edgeIn"/> </xsl:apply-templates> <xsl:apply-templates select="ppx:connectionPointOut"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="negated" select="@negatedOut"/> <xsl:with-param name="edge" select="@edgeOut"/> </xsl:apply-templates> </xsl:template> <xsl:template match="ppx:inVariable"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="VariableBlockInfos"> <xsl:with-param name="type" select="'input'"/> </xsl:call-template> </xsl:template> <xsl:template match="ppx:outVariable"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="VariableBlockInfos"> <xsl:with-param name="type" select="'output'"/> </xsl:call-template> </xsl:template> <xsl:template match="ppx:inOutVariable"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="VariableBlockInfos"> <xsl:with-param name="type" select="'inout'"/> </xsl:call-template> </xsl:template> <xsl:template match="ppx:connector|ppx:continuation"> - <xsl:param name="_indent" select="0"/> <xsl:value-of select="ns:SetSpecificValues(@name)"/> <xsl:call-template name="add_instance"> <xsl:with-param name="type"> <xsl:value-of select="local-name()"/> </xsl:with-param> </xsl:call-template> - <xsl:apply-templates select="ppx:connectionPointIn"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> - <xsl:apply-templates select="ppx:connectionPointOut"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates select="ppx:connectionPointIn"/> + <xsl:apply-templates select="ppx:connectionPointOut"/> </xsl:template> <xsl:template match="ppx:leftPowerRail|ppx:rightPowerRail"> - <xsl:param name="_indent" select="0"/> <xsl:variable name="type" select="local-name()"/> <xsl:variable name="connectors"> <xsl:choose> @@ -248,19 +205,14 @@ </xsl:call-template> <xsl:choose> <xsl:when test="$type='leftPowerRail'"> - <xsl:apply-templates select="ppx:connectionPointOut"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates select="ppx:connectionPointOut"/> </xsl:when> <xsl:otherwise> - <xsl:apply-templates select="ppx:connectionPointIn"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates select="ppx:connectionPointIn"/> </xsl:otherwise> </xsl:choose> </xsl:template> <xsl:template match="ppx:contact|ppx:coil"> - <xsl:param name="_indent" select="0"/> <xsl:variable name="type" select="local-name()"/> <xsl:variable name="storage"> <xsl:choose> @@ -278,18 +230,12 @@ <xsl:value-of select="$type"/> </xsl:with-param> </xsl:call-template> - <xsl:apply-templates select="ppx:connectionPointIn"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> - <xsl:apply-templates select="ppx:connectionPointOut"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates select="ppx:connectionPointIn"/> + <xsl:apply-templates select="ppx:connectionPointOut"/> </xsl:template> <xsl:template match="ppx:step"> - <xsl:param name="_indent" select="0"/> <xsl:value-of select="ns:SetSpecificValues(@name, @initialStep)"/> <xsl:apply-templates select="ppx:connectionPointOutAction"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="negated" select="@negated"/> </xsl:apply-templates> <xsl:call-template name="add_instance"> @@ -297,15 +243,10 @@ <xsl:value-of select="local-name()"/> </xsl:with-param> </xsl:call-template> - <xsl:apply-templates select="ppx:connectionPointIn"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> - <xsl:apply-templates select="ppx:connectionPointOut"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates select="ppx:connectionPointIn"/> + <xsl:apply-templates select="ppx:connectionPointOut"/> </xsl:template> <xsl:template match="ppx:transition"> - <xsl:param name="_indent" select="0"/> <xsl:variable name="priority"> <xsl:choose> <xsl:when test="@priority"> @@ -341,7 +282,6 @@ </xsl:variable> <xsl:value-of select="ns:SetSpecificValues($priority, $condition_type, $condition)"/> <xsl:apply-templates select="ppx:condition/ppx:connectionPointIn"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="negated" select="ppx:condition/@negated"/> </xsl:apply-templates> <xsl:call-template name="add_instance"> @@ -349,15 +289,10 @@ <xsl:value-of select="local-name()"/> </xsl:with-param> </xsl:call-template> - <xsl:apply-templates select="ppx:connectionPointIn"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> - <xsl:apply-templates select="ppx:connectionPointOut"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates select="ppx:connectionPointIn"/> + <xsl:apply-templates select="ppx:connectionPointOut"/> </xsl:template> <xsl:template match="ppx:selectionDivergence|ppx:selectionConvergence|ppx:simultaneousDivergence|ppx:simultaneousConvergence"> - <xsl:param name="_indent" select="0"/> <xsl:variable name="type"> <xsl:value-of select="local-name()"/> </xsl:variable> @@ -377,15 +312,10 @@ <xsl:value-of select="$type"/> </xsl:with-param> </xsl:call-template> - <xsl:apply-templates select="ppx:connectionPointIn"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> - <xsl:apply-templates select="ppx:connectionPointOut"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates select="ppx:connectionPointIn"/> + <xsl:apply-templates select="ppx:connectionPointOut"/> </xsl:template> <xsl:template match="ppx:jumpStep"> - <xsl:param name="_indent" select="0"/> <xsl:variable name="type"> <xsl:text>jump</xsl:text> </xsl:variable> @@ -395,12 +325,9 @@ <xsl:value-of select="$type"/> </xsl:with-param> </xsl:call-template> - <xsl:apply-templates select="ppx:connectionPointIn"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates select="ppx:connectionPointIn"/> </xsl:template> <xsl:template match="ppx:action"> - <xsl:param name="_indent" select="0"/> <xsl:variable name="type"> <xsl:choose> <xsl:when test="ppx:reference"> @@ -434,18 +361,14 @@ <xsl:value-of select="ns:AddAction($qualifier, $type, $value, @duration, @indicator)"/> </xsl:template> <xsl:template match="ppx:actionBlock"> - <xsl:param name="_indent" select="0"/> <xsl:value-of select="ns:SetSpecificValues()"/> - <xsl:apply-templates select="ppx:action"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates select="ppx:action"/> <xsl:call-template name="add_instance"> <xsl:with-param name="type"> <xsl:value-of select="local-name()"/> </xsl:with-param> </xsl:call-template> <xsl:apply-templates select="ppx:connectionPointIn"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="negated" select="@negated"/> </xsl:apply-templates> </xsl:template> diff -r f2b0d849ea77 -r b85b13b1c2ec plcopen/pou_block_instances.ysl2 --- a/plcopen/pou_block_instances.ysl2 Fri Feb 16 01:38:34 2018 +0100 +++ b/plcopen/pou_block_instances.ysl2 Fri Feb 16 01:48:48 2018 +0100 @@ -1,5 +1,5 @@ -include yslt.yml2 -estylesheet xmlns:ppx="http://www.plcopen.org/xml/tc6_0201" +include yslt_noindent.yml2 +istylesheet xmlns:ppx="http://www.plcopen.org/xml/tc6_0201" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:ns="pou_block_instances_ns" extension-element-prefixes="ns" @@ -312,4 +312,4 @@ with "negated", "@negated"; } } -} \ No newline at end of file +} diff -r f2b0d849ea77 -r b85b13b1c2ec plcopen/pou_variables.xslt --- a/plcopen/pou_variables.xslt Fri Feb 16 01:38:34 2018 +0100 +++ b/plcopen/pou_variables.xslt Fri Feb 16 01:48:48 2018 +0100 @@ -1,23 +1,11 @@ <?xml version="1.0"?> -<xsl:stylesheet xmlns:func="http://exslt.org/functions" xmlns:dyn="http://exslt.org/dynamic" xmlns:str="http://exslt.org/strings" xmlns:math="http://exslt.org/math" xmlns:exsl="http://exslt.org/common" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:yml="http://fdik.org/yml" xmlns:set="http://exslt.org/sets" xmlns:ppx="http://www.plcopen.org/xml/tc6_0201" xmlns:ns="pou_vars_ns" xmlns:regexp="http://exslt.org/regular-expressions" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" extension-element-prefixes="ns" version="1.0" exclude-result-prefixes="ns"> +<xsl:stylesheet xmlns:exsl="http://exslt.org/common" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:ppx="http://www.plcopen.org/xml/tc6_0201" xmlns:ns="pou_vars_ns" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" extension-element-prefixes="ns" version="1.0" exclude-result-prefixes="ns"> <xsl:output method="xml"/> - <xsl:variable name="space" select="' '"/> - <xsl:param name="autoindent" select="4"/> - <xsl:template match="text()"> - <xsl:param name="_indent" select="0"/> - </xsl:template> - <xsl:template mode="var_class" match="text()"> - <xsl:param name="_indent" select="0"/> - </xsl:template> - <xsl:template mode="var_type" match="text()"> - <xsl:param name="_indent" select="0"/> - </xsl:template> - <xsl:template mode="var_edit" match="text()"> - <xsl:param name="_indent" select="0"/> - </xsl:template> - <xsl:template mode="var_debug" match="text()"> - <xsl:param name="_indent" select="0"/> - </xsl:template> + <xsl:template match="text()"/> + <xsl:template mode="var_class" match="text()"/> + <xsl:template mode="var_type" match="text()"/> + <xsl:template mode="var_edit" match="text()"/> + <xsl:template mode="var_debug" match="text()"/> <xsl:variable name="project"> <xsl:copy-of select="document('project')/project/*"/> </xsl:variable> @@ -28,7 +16,6 @@ <xsl:copy-of select="document('extensions')/extensions/*"/> </xsl:variable> <xsl:template name="add_root"> - <xsl:param name="_indent" select="0"/> <xsl:param name="class"/> <xsl:param name="type"/> <xsl:param name="edit"> @@ -40,7 +27,6 @@ <xsl:value-of select="ns:SetRoot($class, $type, $edit, $debug)"/> </xsl:template> <xsl:template match="ppx:pou"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="add_root"> <xsl:with-param name="class"> <xsl:value-of select="@pouType"/> @@ -49,37 +35,26 @@ <xsl:value-of select="@name"/> </xsl:with-param> </xsl:call-template> - <xsl:apply-templates select="ppx:interface"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> - <xsl:apply-templates mode="variable_list" select="ppx:actions/ppx:action | ppx:transitions/ppx:transition"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates select="ppx:interface"/> + <xsl:apply-templates mode="variable_list" select="ppx:actions/ppx:action | ppx:transitions/ppx:transition"/> </xsl:template> <xsl:template match="ppx:action"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="add_root"> <xsl:with-param name="class"> <xsl:text>action</xsl:text> </xsl:with-param> </xsl:call-template> - <xsl:apply-templates select="ancestor::ppx:pou/child::ppx:interface"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates select="ancestor::ppx:pou/child::ppx:interface"/> </xsl:template> <xsl:template match="ppx:transition"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="add_root"> <xsl:with-param name="class"> <xsl:text>transition</xsl:text> </xsl:with-param> </xsl:call-template> - <xsl:apply-templates select="ancestor::ppx:pou/child::ppx:interface"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates select="ancestor::ppx:pou/child::ppx:interface"/> </xsl:template> <xsl:template match="ppx:configuration"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="add_root"> <xsl:with-param name="class"> <xsl:text>configuration</xsl:text> @@ -88,15 +63,10 @@ <xsl:text>false</xsl:text> </xsl:with-param> </xsl:call-template> - <xsl:apply-templates mode="variable_list" select="ppx:resource"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> - <xsl:apply-templates select="ppx:globalVars"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates mode="variable_list" select="ppx:resource"/> + <xsl:apply-templates select="ppx:globalVars"/> </xsl:template> <xsl:template match="ppx:resource"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="add_root"> <xsl:with-param name="class"> <xsl:text>resource</xsl:text> @@ -105,45 +75,32 @@ <xsl:text>false</xsl:text> </xsl:with-param> </xsl:call-template> - <xsl:apply-templates mode="variable_list" select="ppx:pouInstance | ppx:task/ppx:pouInstance"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> - <xsl:apply-templates select="ppx:globalVars"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates mode="variable_list" select="ppx:pouInstance | ppx:task/ppx:pouInstance"/> + <xsl:apply-templates select="ppx:globalVars"/> </xsl:template> <xsl:template name="variables_infos"> - <xsl:param name="_indent" select="0"/> <xsl:param name="var_class"/> <xsl:for-each select="ppx:variable"> <xsl:variable name="class"> <xsl:apply-templates mode="var_class" select="ppx:type"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> <xsl:with-param name="default_class"> <xsl:value-of select="$var_class"/> </xsl:with-param> </xsl:apply-templates> </xsl:variable> <xsl:variable name="type"> - <xsl:apply-templates mode="var_type" select="ppx:type"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates mode="var_type" select="ppx:type"/> </xsl:variable> <xsl:variable name="edit"> - <xsl:apply-templates mode="var_edit" select="ppx:type"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates mode="var_edit" select="ppx:type"/> </xsl:variable> <xsl:variable name="debug"> - <xsl:apply-templates mode="var_debug" select="ppx:type"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates mode="var_debug" select="ppx:type"/> </xsl:variable> <xsl:value-of select="ns:AddVariable(@name, $class, $type, $edit, $debug)"/> </xsl:for-each> </xsl:template> <xsl:template match="ppx:localVars"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="variables_infos"> <xsl:with-param name="var_class"> <xsl:text>Local</xsl:text> @@ -151,7 +108,6 @@ </xsl:call-template> </xsl:template> <xsl:template match="ppx:globalVars"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="variables_infos"> <xsl:with-param name="var_class"> <xsl:text>Global</xsl:text> @@ -159,7 +115,6 @@ </xsl:call-template> </xsl:template> <xsl:template match="ppx:externalVars"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="variables_infos"> <xsl:with-param name="var_class"> <xsl:text>External</xsl:text> @@ -167,7 +122,6 @@ </xsl:call-template> </xsl:template> <xsl:template match="ppx:tempVars"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="variables_infos"> <xsl:with-param name="var_class"> <xsl:text>Temp</xsl:text> @@ -175,7 +129,6 @@ </xsl:call-template> </xsl:template> <xsl:template match="ppx:inputVars"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="variables_infos"> <xsl:with-param name="var_class"> <xsl:text>Input</xsl:text> @@ -183,7 +136,6 @@ </xsl:call-template> </xsl:template> <xsl:template match="ppx:outputVars"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="variables_infos"> <xsl:with-param name="var_class"> <xsl:text>Output</xsl:text> @@ -191,7 +143,6 @@ </xsl:call-template> </xsl:template> <xsl:template match="ppx:inOutVars"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="variables_infos"> <xsl:with-param name="var_class"> <xsl:text>InOut</xsl:text> @@ -199,7 +150,6 @@ </xsl:call-template> </xsl:template> <xsl:template name="add_variable"> - <xsl:param name="_indent" select="0"/> <xsl:param name="name"/> <xsl:param name="class"/> <xsl:param name="type"/> @@ -212,7 +162,6 @@ <xsl:value-of select="ns:AddVariable($name, $class, $type, $edit, $debug)"/> </xsl:template> <xsl:template mode="variable_list" match="ppx:action"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="add_variable"> <xsl:with-param name="name"> <xsl:value-of select="@name"/> @@ -223,7 +172,6 @@ </xsl:call-template> </xsl:template> <xsl:template mode="variable_list" match="ppx:transition"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="add_variable"> <xsl:with-param name="name"> <xsl:value-of select="@name"/> @@ -234,7 +182,6 @@ </xsl:call-template> </xsl:template> <xsl:template mode="variable_list" match="ppx:resource"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="add_variable"> <xsl:with-param name="name"> <xsl:value-of select="@name"/> @@ -248,7 +195,6 @@ </xsl:call-template> </xsl:template> <xsl:template mode="variable_list" match="ppx:pouInstance"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="add_variable"> <xsl:with-param name="name"> <xsl:value-of select="@name"/> @@ -262,7 +208,6 @@ </xsl:call-template> </xsl:template> <xsl:template mode="var_class" match="*[self::ppx:type or self::ppx:baseType]/ppx:derived"> - <xsl:param name="_indent" select="0"/> <xsl:param name="default_class"/> <xsl:variable name="type_name" select="@name"/> <xsl:variable name="pou_infos"> @@ -270,9 +215,7 @@ </xsl:variable> <xsl:choose> <xsl:when test="$pou_infos != ''"> - <xsl:apply-templates mode="var_class" select="exsl:node-set($pou_infos)"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates mode="var_class" select="exsl:node-set($pou_infos)"/> </xsl:when> <xsl:otherwise> <xsl:value-of select="$default_class"/> @@ -280,20 +223,16 @@ </xsl:choose> </xsl:template> <xsl:template mode="var_class" match="ppx:pou"> - <xsl:param name="_indent" select="0"/> <xsl:value-of select="@pouType"/> </xsl:template> <xsl:template mode="var_class" match="*[self::ppx:type or self::ppx:baseType]/*"> - <xsl:param name="_indent" select="0"/> <xsl:param name="default_class"/> <xsl:value-of select="$default_class"/> </xsl:template> <xsl:template mode="var_type" match="*[self::ppx:type or self::ppx:baseType]/ppx:derived"> - <xsl:param name="_indent" select="0"/> <xsl:value-of select="@name"/> </xsl:template> <xsl:template mode="var_type" match="*[self::ppx:type or self::ppx:baseType]/ppx:array"> - <xsl:param name="_indent" select="0"/> <xsl:text>ARRAY [</xsl:text> <xsl:for-each select="ppx:dimension"> <xsl:value-of select="@lower"/> @@ -301,24 +240,18 @@ <xsl:value-of select="@upper"/> </xsl:for-each> <xsl:text>] OF </xsl:text> - <xsl:apply-templates mode="var_type" select="ppx:baseType"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates mode="var_type" select="ppx:baseType"/> </xsl:template> <xsl:template mode="var_type" match="*[self::ppx:type or self::ppx:baseType]/ppx:string"> - <xsl:param name="_indent" select="0"/> <xsl:text>STRING</xsl:text> </xsl:template> <xsl:template mode="var_type" match="*[self::ppx:type or self::ppx:baseType]/ppx:wstring"> - <xsl:param name="_indent" select="0"/> <xsl:text>WSTRING</xsl:text> </xsl:template> <xsl:template mode="var_type" match="*[self::ppx:type or self::ppx:baseType]/*"> - <xsl:param name="_indent" select="0"/> <xsl:value-of select="local-name()"/> </xsl:template> <xsl:template mode="var_edit" match="*[self::ppx:type or self::ppx:baseType]/ppx:derived"> - <xsl:param name="_indent" select="0"/> <xsl:variable name="type_name" select="@name"/> <xsl:variable name="pou_infos"> <xsl:copy-of select="exsl:node-set($project)/ppx:project/ppx:types/ppx:pous/ppx:pou[@name=$type_name]"/> @@ -333,26 +266,19 @@ </xsl:choose> </xsl:template> <xsl:template mode="var_edit" match="*[self::ppx:type or self::ppx:baseType]/ppx:array"> - <xsl:param name="_indent" select="0"/> - <xsl:apply-templates mode="var_edit" select="ppx:baseType"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates mode="var_edit" select="ppx:baseType"/> </xsl:template> <xsl:template mode="var_edit" match="*[self::ppx:type or self::ppx:baseType]/*"> - <xsl:param name="_indent" select="0"/> <xsl:text>false</xsl:text> </xsl:template> <xsl:template mode="var_debug" match="*[self::ppx:type or self::ppx:baseType]/ppx:derived"> - <xsl:param name="_indent" select="0"/> <xsl:variable name="type_name" select="@name"/> <xsl:variable name="datatype_infos"> <xsl:copy-of select="exsl:node-set($project)/ppx:project/ppx:types/ppx:pous/ppx:pou[@name=$type_name] | exsl:node-set($project)/ppx:project/ppx:types/ppx:dataTypes/ppx:dataType[@name=$type_name] | exsl:node-set($stdlib)/ppx:project/ppx:types/ppx:dataTypes/ppx:dataType[@name=$type_name] | exsl:node-set($extensions)/ppx:project/ppx:types/ppx:dataTypes/ppx:dataType[@name=$type_name]"/> </xsl:variable> <xsl:choose> <xsl:when test="$datatype_infos != ''"> - <xsl:apply-templates mode="var_debug" select="exsl:node-set($datatype_infos)"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates mode="var_debug" select="exsl:node-set($datatype_infos)"/> </xsl:when> <xsl:otherwise> <xsl:text>false</xsl:text> @@ -360,19 +286,15 @@ </xsl:choose> </xsl:template> <xsl:template mode="var_debug" match="ppx:pou"> - <xsl:param name="_indent" select="0"/> <xsl:text>true</xsl:text> </xsl:template> <xsl:template mode="var_debug" match="*[self::ppx:type or self::ppx:baseType]/ppx:array"> - <xsl:param name="_indent" select="0"/> <xsl:text>false</xsl:text> </xsl:template> <xsl:template mode="var_debug" match="*[self::ppx:type or self::ppx:baseType]/ppx:struct"> - <xsl:param name="_indent" select="0"/> <xsl:text>false</xsl:text> </xsl:template> <xsl:template mode="var_debug" match="*[self::ppx:type or self::ppx:baseType]/*"> - <xsl:param name="_indent" select="0"/> <xsl:text>true</xsl:text> </xsl:template> </xsl:stylesheet> diff -r f2b0d849ea77 -r b85b13b1c2ec plcopen/pou_variables.ysl2 --- a/plcopen/pou_variables.ysl2 Fri Feb 16 01:38:34 2018 +0100 +++ b/plcopen/pou_variables.ysl2 Fri Feb 16 01:48:48 2018 +0100 @@ -1,5 +1,5 @@ -include yslt.yml2 -estylesheet xmlns:ppx="http://www.plcopen.org/xml/tc6_0201" +include yslt_noindent.yml2 +istylesheet xmlns:ppx="http://www.plcopen.org/xml/tc6_0201" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:ns="pou_vars_ns" extension-element-prefixes="ns" diff -r f2b0d849ea77 -r b85b13b1c2ec plcopen/variables_infos.xslt --- a/plcopen/variables_infos.xslt Fri Feb 16 01:38:34 2018 +0100 +++ b/plcopen/variables_infos.xslt Fri Feb 16 01:48:48 2018 +0100 @@ -1,12 +1,8 @@ <?xml version="1.0"?> -<xsl:stylesheet xmlns:func="http://exslt.org/functions" xmlns:dyn="http://exslt.org/dynamic" xmlns:str="http://exslt.org/strings" xmlns:math="http://exslt.org/math" xmlns:exsl="http://exslt.org/common" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:yml="http://fdik.org/yml" xmlns:set="http://exslt.org/sets" xmlns:ppx="http://www.plcopen.org/xml/tc6_0201" xmlns:ns="var_infos_ns" xmlns:regexp="http://exslt.org/regular-expressions" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" extension-element-prefixes="ns" version="1.0" exclude-result-prefixes="ns"> +<xsl:stylesheet xmlns:exsl="http://exslt.org/common" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:ppx="http://www.plcopen.org/xml/tc6_0201" xmlns:ns="var_infos_ns" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" extension-element-prefixes="ns" version="1.0" exclude-result-prefixes="ns"> <xsl:output method="xml"/> - <xsl:variable name="space" select="' '"/> - <xsl:param name="autoindent" select="4"/> <xsl:param name="tree"/> - <xsl:template match="text()"> - <xsl:param name="_indent" select="0"/> - </xsl:template> + <xsl:template match="text()"/> <xsl:variable name="project"> <xsl:copy-of select="document('project')/project/*"/> </xsl:variable> @@ -17,32 +13,19 @@ <xsl:copy-of select="document('extensions')/extensions/*"/> </xsl:variable> <xsl:template match="ppx:configuration"> - <xsl:param name="_indent" select="0"/> - <xsl:apply-templates select="ppx:globalVars"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates select="ppx:globalVars"/> </xsl:template> <xsl:template match="ppx:resource"> - <xsl:param name="_indent" select="0"/> - <xsl:apply-templates select="ppx:globalVars"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates select="ppx:globalVars"/> </xsl:template> <xsl:template match="ppx:pou"> - <xsl:param name="_indent" select="0"/> - <xsl:apply-templates select="ppx:interface/*"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates select="ppx:interface/*"/> </xsl:template> <xsl:template match="ppx:returnType"> - <xsl:param name="_indent" select="0"/> <xsl:value-of select="ns:AddTree()"/> - <xsl:apply-templates mode="var_type" select="."> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates mode="var_type" select="."/> </xsl:template> <xsl:template name="variables_infos"> - <xsl:param name="_indent" select="0"/> <xsl:param name="var_class"/> <xsl:variable name="var_option"> <xsl:choose> @@ -59,9 +42,7 @@ </xsl:variable> <xsl:for-each select="ppx:variable"> <xsl:variable name="initial_value"> - <xsl:apply-templates select="ppx:initialValue"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates select="ppx:initialValue"/> </xsl:variable> <xsl:variable name="edit"> <xsl:choose> @@ -69,21 +50,16 @@ <xsl:text>true</xsl:text> </xsl:when> <xsl:otherwise> - <xsl:apply-templates mode="var_edit" select="ppx:type"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates mode="var_edit" select="ppx:type"/> </xsl:otherwise> </xsl:choose> </xsl:variable> <xsl:value-of select="ns:AddTree()"/> - <xsl:apply-templates mode="var_type" select="ppx:type"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates mode="var_type" select="ppx:type"/> <xsl:value-of select="ns:AddVariable(@name, $var_class, $var_option, @address, $initial_value, $edit, ppx:documentation/xhtml:p/text())"/> </xsl:for-each> </xsl:template> <xsl:template match="ppx:localVars"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="variables_infos"> <xsl:with-param name="var_class"> <xsl:text>Local</xsl:text> @@ -91,7 +67,6 @@ </xsl:call-template> </xsl:template> <xsl:template match="ppx:globalVars"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="variables_infos"> <xsl:with-param name="var_class"> <xsl:text>Global</xsl:text> @@ -99,7 +74,6 @@ </xsl:call-template> </xsl:template> <xsl:template match="ppx:externalVars"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="variables_infos"> <xsl:with-param name="var_class"> <xsl:text>External</xsl:text> @@ -107,7 +81,6 @@ </xsl:call-template> </xsl:template> <xsl:template match="ppx:tempVars"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="variables_infos"> <xsl:with-param name="var_class"> <xsl:text>Temp</xsl:text> @@ -115,7 +88,6 @@ </xsl:call-template> </xsl:template> <xsl:template match="ppx:inputVars"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="variables_infos"> <xsl:with-param name="var_class"> <xsl:text>Input</xsl:text> @@ -123,7 +95,6 @@ </xsl:call-template> </xsl:template> <xsl:template match="ppx:outputVars"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="variables_infos"> <xsl:with-param name="var_class"> <xsl:text>Output</xsl:text> @@ -131,7 +102,6 @@ </xsl:call-template> </xsl:template> <xsl:template match="ppx:inOutVars"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="variables_infos"> <xsl:with-param name="var_class"> <xsl:text>InOut</xsl:text> @@ -139,53 +109,35 @@ </xsl:call-template> </xsl:template> <xsl:template mode="var_type" match="ppx:pou"> - <xsl:param name="_indent" select="0"/> - <xsl:apply-templates mode="var_type" select="ppx:interface/*[self::ppx:inputVars or self::ppx:inOutVars or self::ppx:outputVars]/ppx:variable"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates mode="var_type" select="ppx:interface/*[self::ppx:inputVars or self::ppx:inOutVars or self::ppx:outputVars]/ppx:variable"/> </xsl:template> <xsl:template mode="var_type" match="ppx:variable"> - <xsl:param name="_indent" select="0"/> <xsl:variable name="name"> <xsl:value-of select="@name"/> </xsl:variable> <xsl:value-of select="ns:AddTree()"/> - <xsl:apply-templates mode="var_type" select="ppx:type"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates mode="var_type" select="ppx:type"/> <xsl:value-of select="ns:AddVarToTree($name)"/> </xsl:template> <xsl:template mode="var_type" match="ppx:dataType"> - <xsl:param name="_indent" select="0"/> - <xsl:apply-templates mode="var_type" select="ppx:baseType"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates mode="var_type" select="ppx:baseType"/> </xsl:template> <xsl:template mode="var_type" match="*[self::ppx:type or self::ppx:baseType or self::ppx:returnType]/ppx:struct"> - <xsl:param name="_indent" select="0"/> - <xsl:apply-templates mode="var_type" select="ppx:variable"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates mode="var_type" select="ppx:variable"/> </xsl:template> <xsl:template mode="var_type" match="*[self::ppx:type or self::ppx:baseType or self::ppx:returnType]/ppx:derived"> - <xsl:param name="_indent" select="0"/> <xsl:variable name="type_name"> <xsl:value-of select="@name"/> </xsl:variable> <xsl:choose> <xsl:when test="$tree='True'"> - <xsl:apply-templates mode="var_type" select="exsl:node-set($project)/ppx:project/ppx:types/ppx:pous/ppx:pou[@name=$type_name] | exsl:node-set($project)/ppx:project/ppx:types/ppx:dataTypes/ppx:dataType[@name=$type_name] | exsl:node-set($stdlib)/ppx:project/ppx:types/ppx:pous/ppx:pou[@name=$type_name] | exsl:node-set($stdlib)/ppx:project/ppx:types/ppx:dataTypes/ppx:dataType[@name=$type_name] | exsl:node-set($extensions)/ppx:project/ppx:types/ppx:pous/ppx:pou[@name=$type_name] | exsl:node-set($extensions)/ppx:project/ppx:types/ppx:dataTypes/ppx:dataType[@name=$type_name]"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates mode="var_type" select="exsl:node-set($project)/ppx:project/ppx:types/ppx:pous/ppx:pou[@name=$type_name] | exsl:node-set($project)/ppx:project/ppx:types/ppx:dataTypes/ppx:dataType[@name=$type_name] | exsl:node-set($stdlib)/ppx:project/ppx:types/ppx:pous/ppx:pou[@name=$type_name] | exsl:node-set($stdlib)/ppx:project/ppx:types/ppx:dataTypes/ppx:dataType[@name=$type_name] | exsl:node-set($extensions)/ppx:project/ppx:types/ppx:pous/ppx:pou[@name=$type_name] | exsl:node-set($extensions)/ppx:project/ppx:types/ppx:dataTypes/ppx:dataType[@name=$type_name]"/> </xsl:when> </xsl:choose> <xsl:value-of select="ns:SetType($type_name)"/> </xsl:template> <xsl:template mode="var_type" match="*[self::ppx:type or self::ppx:baseType or self::ppx:returnType]/ppx:array"> - <xsl:param name="_indent" select="0"/> - <xsl:apply-templates mode="var_type" select="ppx:baseType"> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates mode="var_type" select="ppx:baseType"/> <xsl:for-each select="ppx:dimension"> <xsl:variable name="lower"> <xsl:value-of select="@lower"/> @@ -197,28 +149,24 @@ </xsl:for-each> </xsl:template> <xsl:template mode="var_type" match="*[self::ppx:type or self::ppx:baseType or self::ppx:returnType]/ppx:string"> - <xsl:param name="_indent" select="0"/> <xsl:variable name="name"> <xsl:text>STRING</xsl:text> </xsl:variable> <xsl:value-of select="ns:SetType($name)"/> </xsl:template> <xsl:template mode="var_type" match="*[self::ppx:type or self::ppx:baseType or self::ppx:returnType]/ppx:wstring"> - <xsl:param name="_indent" select="0"/> <xsl:variable name="name"> <xsl:text>WSTRING</xsl:text> </xsl:variable> <xsl:value-of select="ns:SetType($name)"/> </xsl:template> <xsl:template mode="var_type" match="*[self::ppx:type or self::ppx:baseType or self::ppx:returnType]/*"> - <xsl:param name="_indent" select="0"/> <xsl:variable name="name"> <xsl:value-of select="local-name()"/> </xsl:variable> <xsl:value-of select="ns:SetType($name)"/> </xsl:template> <xsl:template mode="var_edit" match="*[self::ppx:type or self::ppx:baseType or self::ppx:returnType]/ppx:derived"> - <xsl:param name="_indent" select="0"/> <xsl:variable name="type_name"> <xsl:value-of select="@name"/> </xsl:variable> @@ -235,47 +183,35 @@ </xsl:choose> </xsl:template> <xsl:template mode="var_edit" match="*[self::ppx:type or self::ppx:baseType or self::ppx:returnType]/*"> - <xsl:param name="_indent" select="0"/> <xsl:text>true</xsl:text> </xsl:template> <xsl:template match="ppx:value"> - <xsl:param name="_indent" select="0"/> <xsl:choose> <xsl:when test="@repetitionValue"> <xsl:value-of select="@repetitionValue"/> <xsl:text>(</xsl:text> - <xsl:apply-templates> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates/> <xsl:text>)</xsl:text> </xsl:when> <xsl:when test="@member"> <xsl:value-of select="@member"/> <xsl:text> := </xsl:text> - <xsl:apply-templates> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates/> </xsl:when> <xsl:otherwise> - <xsl:apply-templates> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates/> </xsl:otherwise> </xsl:choose> </xsl:template> <xsl:template match="ppx:simpleValue"> - <xsl:param name="_indent" select="0"/> <xsl:value-of select="@value"/> </xsl:template> <xsl:template name="complex_type_value"> - <xsl:param name="_indent" select="0"/> <xsl:param name="start_bracket"/> <xsl:param name="end_bracket"/> <xsl:value-of select="$start_bracket"/> <xsl:for-each select="ppx:value"> - <xsl:apply-templates select="."> - <xsl:with-param name="_indent" select="$_indent + (1) * $autoindent"/> - </xsl:apply-templates> + <xsl:apply-templates select="."/> <xsl:choose> <xsl:when test="position()!=last()"> <xsl:text>, </xsl:text> @@ -285,7 +221,6 @@ <xsl:value-of select="$end_bracket"/> </xsl:template> <xsl:template match="ppx:arrayValue"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="complex_type_value"> <xsl:with-param name="start_bracket"> <xsl:text>[</xsl:text> @@ -296,7 +231,6 @@ </xsl:call-template> </xsl:template> <xsl:template match="ppx:structValue"> - <xsl:param name="_indent" select="0"/> <xsl:call-template name="complex_type_value"> <xsl:with-param name="start_bracket"> <xsl:text>(</xsl:text> diff -r f2b0d849ea77 -r b85b13b1c2ec plcopen/variables_infos.ysl2 --- a/plcopen/variables_infos.ysl2 Fri Feb 16 01:38:34 2018 +0100 +++ b/plcopen/variables_infos.ysl2 Fri Feb 16 01:48:48 2018 +0100 @@ -1,5 +1,5 @@ -include yslt.yml2 -estylesheet xmlns:ppx="http://www.plcopen.org/xml/tc6_0201" +include yslt_noindent.yml2 +istylesheet xmlns:ppx="http://www.plcopen.org/xml/tc6_0201" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:ns="var_infos_ns" extension-element-prefixes="ns" @@ -232,4 +232,4 @@ } - \ No newline at end of file + diff -r f2b0d849ea77 -r b85b13b1c2ec plcopen/yslt_noindent.yml2 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/plcopen/yslt_noindent.yml2 Fri Feb 16 01:48:48 2018 +0100 @@ -0,0 +1,32 @@ +include yslt.yml2 + +in xsl { + decl istylesheet ( + *output="xml", + version="1.0", + xmlns:xsl="http://www.w3.org/1999/XSL/Transform", + xmlns:exsl='http://exslt.org/common', + extension-element-prefixes='exsl' + ) alias stylesheet { + output *output; + content; + }; + + decl template(match) { + content; + }; + + decl function(name) alias template { + content; + }; + + decl call(name) alias call-template { + content; + }; + + decl apply(select) alias apply-templates { + content; + }; +} + +