| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174 |
- <?xml version="1.0" encoding="UTF-8"?>
- <xsl:stylesheet xmlns:vc="http://www.w3.org/2007/XMLSchema-versioning"
- xmlns:xs="http://www.w3.org/2001/XMLSchema"
- xmlns:p5dkp="http://biuro.biall-net.pl/xmlschema_procesy5/WPS_Functions/dita_kosztorys_projektowy/p5dkp.xsd"
- xmlns:p5bws="http://biuro.biall-net.pl/xmlschema_procesy5/WPS_Functions/WPS_Functions.xsd"
- xmlns:system_cache__appinfo="http://biuro.biall-net.pl/xmlschema_procesy5/default_db_xml_cache/appinfo.xsd"
- xmlns:d2a="http://biuro.biall-net.pl/xmlschema_procesy5/WPS_Functions/dita-to-ant/d2a.xsd"
- xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- xmlns:p5dg="http://biuro.biall-net.pl/xmlschema_procesy5/WPS_Functions/documentation_generator/documentation_generator.xsd"
- exclude-result-prefixes="xs d2a"
- version="2.0">
-
-
-
-
- <xsl:output indent="yes"/>
- <xsl:strip-space elements="*"/>
-
-
- <xsl:template match="task" mode="d2a:PRODUCT.new_ant_project.child" >
- <xsl:param name="p5dkp:ditafiles.xml" required="yes"/>
- <d2a:PRODUCT.new_ant_project>
- <project
- basedir="{d2a:basedir($p5dkp:ditafiles.xml/ancestor-or-self::*/descendant-or-self::*,$d2a:basedir_ROOT_DITA_KEYREF)}"
- name="{$d2a.new_module.INPUT}.PRODUCT">
- <xsl:variable name="p5dg:filename.d2a.new_module.INPUT" select="$p5dkp:ditafiles.xml/ancestor-or-self::*[@p5dkp:true.path][1]/p5dg:filename(@p5dkp:true.path)"/>
- <property name="{$d2a.new_module.INPUT}.basedir" location="{$p5dkp:ditafiles.xml/ancestor-or-self::*[@p5dkp:true.path][1]/p5dg:filepath.dir(@p5dkp:true.path)}"/>
- <property name="{$d2a.new_module.INPUT}.temp" > <!-- location="{d2a:keyref($p5dkp:ditafiles.xml/ancestor-or-self::*,'public_html__WPS_Functions.WPS_Functions.temp')}" -->
- <xsl:copy-of select="d2a:ditamap.INPUT.temp.xmlatt($p5dkp:ditafiles.xml,'location')" copy-namespaces="no"/>
-
- <!--<TEST location="{d2a:keyref($p5dkp:ditafiles.xml/ancestor-or-self::*,'public_html__WPS_Functions.WPS_Functions.temp')}">
-
- </TEST>-->
- <!-- example <property name="html2image.temp" location="/opt/local/pl.procesy5/p5build_SE/temp/WPS_Functions/html2image"/> -->
- <!--<xsl:attribute name="location">
- <xsl:value-of select="d2a:keyref.element.root($p5dkp:ditafiles.xml/ancestor-or-self::*,'public_html__WPS_Functions.WPS_Functions.temp')"/>
- <!-\-<xsl:text>/</xsl:text>-\-><xsl:value-of select="$p5dkp:ditafiles.xml/ancestor-or-self::*[@p5dkp:true.path][1]/p5dg:filename(p5dg:filepath.dir(@p5dkp:true.path))"/>
- </xsl:attribute>-->
- <!--<TEST>
- <xsl:copy-of select="$p5dkp:ditafiles.xml/ancestor-or-self::*[@p5dkp:true.path][1]/p5dg:filename(p5dg:filepath.dir(@p5dkp:true.path))"/>
- </TEST>-->
- <!--<test>
- <xsl:for-each select="$p5dkp:ditafiles.xml/ancestor-or-self::*">
- <name name="{name()}" href="{@href}" >
- <xsl:for-each select="descendant-or-self::*">
- <desc name="{name()}">
- <xsl:choose>
- <xsl:when test="@map.keys.eval='public_html__WPS_Functions.WPS_Functions.temp'">
- <OOKS>found</OOKS>
- </xsl:when>
- </xsl:choose>
- </desc>
- </xsl:for-each>
-
- </name>
- </xsl:for-each>
- </test>-->
- </property>
- <!-- public_html__WPS_Functions.WPS_Functions.temp -->
- <xsl:apply-templates mode="d2a:PRODUCT.new_ant_project.child.task">
- <xsl:with-param name="p5dkp:ditafiles.xml" select="$p5dkp:ditafiles.xml"/>
- </xsl:apply-templates>
- </project>
- </d2a:PRODUCT.new_ant_project>
- </xsl:template>
-
- <xsl:template match="steps|step|cmd|apiname|info|syntaxdiagram|groupcomp" mode="d2a:PRODUCT.new_ant_project.child.task">
- <xsl:param name="p5dkp:ditafiles.xml" required="yes"/>
- <xsl:comment>#64 <xsl:value-of select="name()"/></xsl:comment>
- <xsl:apply-templates mode="#current">
- <xsl:with-param name="p5dkp:ditafiles.xml" select="$p5dkp:ditafiles.xml"/>
- </xsl:apply-templates>
- </xsl:template>
-
- <xsl:template match="var[varname[@keyref]]" mode="d2a:PRODUCT.new_ant_project.child.task">
- <xsl:param name="p5dkp:ditafiles.xml" required="yes"/>
- <xsl:comment>#72__AC <xsl:value-of select="name()"/> ;
- <xsl:value-of select="$p5dkp:ditafiles.xml/ancestor-or-self::*[ descendant-or-self::keys[@map.keys.eval = current()/varname/@keyref]]/ancestor-or-self::p5dkp:ditafiles.file[1]/concat('id=',@id,' @format=',@format,' @scope=',@scope)"/></xsl:comment>
- <xsl:choose>
- <xsl:when test="contains(d2a:keyref($p5dkp:ditafiles.xml/ancestor-or-self::*/descendant-or-self::*,varname/@keyref),'.dita')"> <!-- $p5dkp:ditafiles.xml/ancestor-or-self::*[ descendant-or-self::keys[@map.keys.eval = current()/varname/@keyref]]/ancestor-or-self::p5dkp:ditafiles.file[1][( not(@format) and not(@scope='external') and not(@format='ditamap') )] -->
- <xsl:comment>#76 problem - missing force keyref wrong --window-size <xsl:value-of select="$p5dkp:ditafiles.xml/ancestor-or-self::*[descendant-or-self::keys[@map.keys.eval = current()/varname/@keyref]]/@format"/></xsl:comment>
- <!--<xsl:choose>
- <xsl:when test="$p5dkp:ditafiles.xml/ancestor-or-self::*[descendant-or-self::keys[@map.keys.eval = current()/varname/@keyref]]/ancestor-or-self::p5dkp:ditafiles.file[1]/descendant-or-self::keyword[1]">-->
- <!--<xsl:value-of select="$p5dkp:ditafiles.xml/ancestor-or-self::*[descendant-or-self::keys[@map.keys.eval = current()/varname/@keyref]]/ancestor-or-self::p5dkp:ditafiles.file[1]/descendant-or-self::keyword[1]"/>-->
- <xsl:comment>#82 used keyword</xsl:comment>
- <property name="{varname/@keyref}">
- <xsl:copy-of select="d2a:keyref.keyword_prio($p5dkp:ditafiles.xml/ancestor-or-self::*/descendant-or-self::*,varname/@keyref)"/>
- </property>
- <!--</xsl:when>
- </xsl:choose>-->
- </xsl:when>
- <xsl:otherwise>
- <xsl:comment>#82-B due to not @format=dita not keyword</xsl:comment>
- <property name="{varname/@keyref}">
- <xsl:copy-of select="d2a:keyref($p5dkp:ditafiles.xml/ancestor-or-self::*/descendant-or-self::*,varname/@keyref)"/>
- </property>
- </xsl:otherwise>
- </xsl:choose>
- <xsl:apply-templates mode="#current">
- <xsl:with-param name="p5dkp:ditafiles.xml" select="$p5dkp:ditafiles.xml"/>
- </xsl:apply-templates>
- </xsl:template>
-
-
- <xsl:template match="cmd[apiname[@keyref]]" mode="d2a:PRODUCT.new_ant_project.child.task">
- <xsl:param name="p5dkp:ditafiles.xml" required="yes"/>
- <xsl:comment>#72__AC <xsl:value-of select="name()"/> ;
- <xsl:value-of select="$p5dkp:ditafiles.xml/ancestor-or-self::*[ descendant-or-self::keys[@map.keys.eval = current()/apiname/@keyref]]/ancestor-or-self::p5dkp:ditafiles.file[1]/concat('id=',@id,' @format=',@format,' @scope=',@scope)"/></xsl:comment>
- <xsl:choose>
- <xsl:when test="contains(d2a:keyref($p5dkp:ditafiles.xml/ancestor-or-self::*/descendant-or-self::*,apiname/@keyref),'.dita')"> <!-- $p5dkp:ditafiles.xml/ancestor-or-self::*[ descendant-or-self::keys[@map.keys.eval = current()/varname/@keyref]]/ancestor-or-self::p5dkp:ditafiles.file[1][( not(@format) and not(@scope='external') and not(@format='ditamap') )] -->
- <xsl:comment>#76-1110 problem - missing force keyref wrong --window-size <xsl:value-of select="$p5dkp:ditafiles.xml/ancestor-or-self::*[descendant-or-self::keys[@map.keys.eval = current()/apiname/@keyref]]/@format"/></xsl:comment>
-
-
- <xsl:comment>#82-1110 used keyword</xsl:comment>
- <property name="{apiname/@keyref}">
- <xsl:copy-of select="d2a:keyref.keyword_prio($p5dkp:ditafiles.xml/ancestor-or-self::*/descendant-or-self::*,apiname/@keyref)"/>
- </property>
- <!--</xsl:when>
- </xsl:choose>-->
- </xsl:when>
- <xsl:otherwise>
- <xsl:comment>#82-B-1100 due to not @format=dita not keyword</xsl:comment>
- <property name="{apiname/@keyref}">
-
- <xsl:copy-of select="d2a:keyref($p5dkp:ditafiles.xml/ancestor-or-self::*/descendant-or-self::*,apiname/@keyref)"/>
- </property>
- </xsl:otherwise>
- </xsl:choose>
- <xsl:apply-templates mode="#current">
- <xsl:with-param name="p5dkp:ditafiles.xml" select="$p5dkp:ditafiles.xml"/>
- </xsl:apply-templates>
- </xsl:template>
-
- <xsl:template mode="d2a:PRODUCT.new_ant_project.child.task.abbreviated-form" match="text()">
- <xsl:comment>#109 <xsl:value-of select="."/> ;</xsl:comment>
- </xsl:template>
-
- <xsl:template match="abbreviated-form|kwd|var" mode="d2a:PRODUCT.new_ant_project.child.task">
- <xsl:param name="p5dkp:ditafiles.xml" required="yes"/>
- <xsl:apply-templates select="@*" mode="d2a:PRODUCT.new_ant_project.child.task.abbreviated-form">
- <xsl:with-param name="p5dkp:ditafiles.xml" select="$p5dkp:ditafiles.xml"/>
- </xsl:apply-templates>
- <xsl:apply-templates mode="d2a:PRODUCT.new_ant_project.child.task.abbreviated-form">
- <xsl:with-param name="p5dkp:ditafiles.xml" select="$p5dkp:ditafiles.xml"/>
- </xsl:apply-templates>
- </xsl:template>
-
- <xsl:template match="@keyref" mode="d2a:PRODUCT.new_ant_project.child.task.abbreviated-form">
- <xsl:param name="p5dkp:ditafiles.xml" required="yes"/>
- <xsl:comment>#35 todo keyref resolve</xsl:comment>
- <property name="{.}">
- <xsl:copy-of select="d2a:keyref($p5dkp:ditafiles.xml/ancestor-or-self::*/descendant-or-self::*,.)" copy-namespaces="no"/>
- <!--<xsl:attribute name="value"><!-\-<xsl:for-each select="$p5dkp:ditafiles.xml/ancestor-or-self::*/descendant-or-self::*[map.keys.eval[keys[@map.keys.eval='module.bocian-graph-to-html.graph-part-first.html']]][1]">
- <xsl:value-of select="@href"/>
- </xsl:for-each>-\->
- <xsl:value-of select="d2a:keyref($p5dkp:ditafiles.xml/ancestor-or-self::*/descendant-or-self::*,.)"/>
- </xsl:attribute>-->
- </property>
- </xsl:template>
- <xsl:template match="@*" mode="d2a:PRODUCT.new_ant_project.child.task.abbreviated-form"/>
-
- <xsl:template match="*" mode="d2a:PRODUCT.new_ant_project.child" >
- <xsl:comment>#27 bypassed name=<xsl:value-of select="name()"/> mode="d2a:PRODUCT.new_ant_project.child"</xsl:comment>
- </xsl:template>
-
- <xsl:template match="text()" mode="d2a:PRODUCT.new_ant_project.child" >
- <xsl:comment>#27-A bypassed name=<xsl:value-of select="name()"/> mode="d2a:PRODUCT.new_ant_project.child"</xsl:comment>
- </xsl:template>
-
- <xsl:template mode="d2a:PRODUCT.new_ant_project.child.task.abbreviated-form" match="*"/>
-
- <xsl:template mode="d2a:PRODUCT.new_ant_project.child d2a:PRODUCT.new_ant_project.child.task" match="text()|comment()"/>
-
- </xsl:stylesheet>
|