| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428 |
- <?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:gml="http://www.opengis.net/gml"
- 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:bcgtht="http://biuro.biall-net.pl/xmlschema_procesy5/WPS_Functions/bocian-graph-to-html/bcgtht.xsd"
- xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- xmlns:default_db__x3A__BI_audit_ENERGA_PRACOWNICY="https://biuro.biall-net.pl/wfs/default_db/BI_audit_ENERGA_PRACOWNICY"
- xmlns:p5="https://biuro.biall-net.pl/wfs"
- xmlns:default_db__x3A__BI_audit_ENERGA_RUM_KONTRAHENCI_POWIAZANIA_row_object="https://biuro.biall-net.pl/wfs/default_db/BI_audit_ENERGA_RUM_KONTRAHENCI_POWIAZANIA_row_object"
- xmlns:default_db__x3A__BI_audit_ENERGA_RUM_KONTRAHENCI_POWIAZANIA_row="https://biuro.biall-net.pl/wfs/default_db/BI_audit_ENERGA_RUM_KONTRAHENCI_POWIAZANIA_row"
- xmlns:default_db__x3A__BI_audit_KRS="https://biuro.biall-net.pl/wfs/default_db/BI_audit_KRS"
- xmlns:default_db__x3A__BI_audit_ENERGA_RUM_KONTRAHENCI="https://biuro.biall-net.pl/wfs/default_db/BI_audit_ENERGA_RUM_KONTRAHENCI"
-
- xmlns:default_db__x3A__BI_audit_MSIG="https://biuro.biall-net.pl/wfs/default_db/BI_audit_MSIG"
- xmlns:default_db__x3A__BI_audit_CEIDG="https://biuro.biall-net.pl/wfs/default_db/BI_audit_CEIDG"
- xmlns:system_cache__dita="http://biuro.biall-net.pl/xmlschema_procesy5/default_db_xml_cache/dita.xsd"
- xmlns:default_db__x3A__BI_audit_KRS_person="https://biuro.biall-net.pl/wfs/default_db/BI_audit_KRS_person"
- xmlns:default_db__x3A__BI_audit_taxpayer="https://biuro.biall-net.pl/wfs/default_db/BI_audit_taxpayer"
- xmlns:default_db__x3A__BI_audit_KRS_company="https://biuro.biall-net.pl/wfs/default_db/BI_audit_KRS_company"
- xmlns:default_db__x3A__BI_audit_MSIG_company="https://biuro.biall-net.pl/wfs/default_db/BI_audit_MSIG_company"
- xmlns:default_db__x3A__TERYT_adresy="https://biuro.biall-net.pl/wfs/default_db/TERYT_adresy"
- xmlns:default_db__x3A__BI_audit_MSIG_person="https://biuro.biall-net.pl/wfs/default_db/BI_audit_MSIG_person"
- xmlns:default_db__x3A__BI_audit_operational_raport_note="https://biuro.biall-net.pl/wfs/default_db/BI_audit_operational_raport_note"
- xmlns:default_db__x3A__BI_audit_MSIG_address="https://biuro.biall-net.pl/wfs/default_db/BI_audit_MSIG_address"
- xmlns:p5yed="http://biuro.biall-net.pl/xmlschema_procesy5/WPS_Functions/yed/p5yed.xsd"
- xmlns:p5suis="http://biuro.biall-net.pl/xmlschema_procesy5/WPS_Functions/system_ui_info_speech/system_ui_info_speech.xsd"
- xmlns:p5xmli="http://biuro.biall-net.pl/xmlschema_procesy5/WPS_Functions/xmlschema_interface/p5xmli.xsd"
-
- version="2.0">
-
-
- <xsl:output indent="yes"/>
- <xsl:strip-space elements="*"/> <!-- -->
-
-
-
- <xsl:key name="bcgtht:id" match="//path.clousure.following" use="@bcgtht:id"/> <!-- path.included -->
- <xsl:key name="bcgtht:clousure.from" match="//path.clousure.following" use="@bcgtht:clousure.from" />
- <xsl:key name="bcgtht:clousure.node" match="//path.clousure.following" use="@bcgtht:clousure.node"/>
- <!--<xsl:key name="bcgtht:clousure.node.from" match="path.clousure.following|path.included" use="@bcgtht:clousure.node or @bcgtht:clousure.from "/>-->
-
- <xsl:key name="bcgtht:clousure.node.from" match="//path.clousure.following" use="@bcgtht:clousure.node or @bcgtht:clousure.from "/>
-
- <xsl:param name="bcgtht.clousure.len_max" select="'999'"/>
-
- <xsl:param name="bcgtht:debug.nodes" select="'BI_audit_KRS.161323 BI_audit_KRS_person.747001 BI_audit_KRS_person.747001 BI_audit_KRS.151308'"/>
-
- <xsl:template name="bcgtht:clousure.analys">
- <xsl:param name="bcgtht:clousure" required="yes"/>
- <xsl:message>#37 template name="bcgtht:clousure.analys"</xsl:message>
- <!--<bcgtht:clousure.analys>
- <xsl:for-each-group select="$bcgtht:clousure//path.clousure.following" group-by="concat(@bcgtht:clousure.from,'-',@to.node)">
- <xsl:copy copy-namespaces="no">
- <xsl:copy-of select="@*"/>
- <xsl:copy-of select="bcgtht:clousure.analys.debug.child.attr(@to.node)"/>
- <xsl:copy-of select="bcgtht:clousure.analys.debug.child.attr(@bcgtht:clousure.from)"/>
- <xsl:attribute name="count" select="count(current-group())"/>
- <xsl:apply-templates mode="p5yed:node.attr" select="."/>
- <xsl:for-each select="current-group()/bcgtht:clousure.node.unique.descriptor[ position() = 1]">
- <xsl:sort select="count(*)" order="descending"/>
- <xsl:if test="position() = 1">
- <xsl:apply-templates mode="bcgtht:clousure.node.unique.descriptor.analys" select="."/>
- <!-\-<xsl:copy-of select="."/>-\->
- </xsl:if>
- </xsl:for-each>
- <xsl:for-each-group select="current-group()" group-by="@bcgtht:clousure.from.len">
- <path.included.group key="{current-grouping-key()}" count="{count(current-group())}">
- <!-\-<xsl:copy-of select="path.included"/>-\->
- <xsl:apply-templates mode="bcgtht:clousure.analys" select="path.included"/>
- </path.included.group>
- </xsl:for-each-group>
- </xsl:copy>
- </xsl:for-each-group>
-
- </bcgtht:clousure.analys>-->
-
-
- <bcgtht:clousure.analys>
- <xsl:copy-of select="p5xmli:xsi.schemaLocation($bcgtht.clousure.xsd,'http://biuro.biall-net.pl/xmlschema_procesy5/WPS_Functions/bocian-graph-to-html/bcgtht.xsd')"/>
- <xsl:apply-templates mode="bcgtht:clousure.analys" select="$bcgtht:clousure"/>
- </bcgtht:clousure.analys>
- </xsl:template>
-
-
-
- <xsl:template mode="bcgtht:clousure.analys" match="bcgtht:clousure|BI_audit_ENERGA_RUM_KONTRAHENCI_POWIAZANIA_row">
- <xsl:apply-templates mode="#current"/>
- </xsl:template>
-
- <xsl:template mode="bcgtht:clousure.analys" match="path.clousure.following[number(@bcgtht:clousure.from.len) <= number($bcgtht.clousure.len_max) or @bcgtht:clousure.node.pos = '0']">
- <xsl:copy copy-namespaces="no">
- <xsl:copy-of select="@*"/>
- <xsl:copy-of select="bcgtht:clousure.analys.debug.child.attr(@bcgtht:clousure.node)"/>
- <xsl:copy-of select="bcgtht:clousure.analys.debug.child.attr(@bcgtht:clousure.from)"/>
- <!--<xsl:apply-templates mode="p5yed:node.attr" select="."/>SSS-->
- <xsl:apply-templates mode="bcgtht:clousure.analys.clousure.node.unique.descriptor.neigh" select="." >
- <xsl:with-param name="id" select="@bcgtht:id"/>
- </xsl:apply-templates>
- <xsl:apply-templates mode="bcgtht:clousure.analys.closure" select=".">
- <xsl:with-param name="bcgtht:id" select="@bcgtht:id"/>
- <xsl:with-param name="bcgtht:clousure.len" select="1"/>
- <xsl:with-param name="id" select="@bcgtht:id"/>
- <xsl:with-param name="bcgtht:clousure.from" select="@bcgtht:clousure.from"/>
- <xsl:with-param name="bcgtht:clousure.analys.log" select="bcgtht:clousure.analys.log()"/>
- </xsl:apply-templates>
- <xsl:apply-templates mode="bcgtht:clousure.analys.closure" select=".">
- <xsl:with-param name="bcgtht:id" select="@bcgtht:id"/>
- <xsl:with-param name="bcgtht:clousure.len" select="1"/>
- <xsl:with-param name="id" select="@bcgtht:id"/>
- <xsl:with-param name="bcgtht:clousure.node" select="@bcgtht:clousure.node"/>
- <xsl:with-param name="bcgtht:clousure.analys.log" select="bcgtht:clousure.analys.log()"/>
- </xsl:apply-templates>
-
- <!-- @bcgtht:clousure.node or @bcgtht:clousure.from --> <!-- key('bcgtht:clousure.node.from', @bcgtht:clousure.node or @bcgtht:clousure.from )[ not(@bcgtht:id = current()/@bcgtht:id)] -->
-
- </xsl:copy>
- <xsl:apply-templates mode="#current"/>
- </xsl:template>
-
- <xsl:template mode="bcgtht:clousure.analys.closure" match="path.clousure.following">
- <xsl:param name="bcgtht:id" required="yes"/>
- <xsl:param name="id" />
- <xsl:param name="bcgtht:clousure.analys.log" required="yes"/>
- <xsl:param name="bcgtht:clousure.len" select="1"/>
- <xsl:param name="bcgtht:clousure.from"/>
- <xsl:param name="bcgtht:clousure.node" />
- <xsl:message> #120 bcgtht:clousure.analys.a @bcgtht:id=<xsl:value-of select="@bcgtht:id"/> $bcgtht:clousure.from=<xsl:value-of select="$bcgtht:clousure.from"/> ; $bcgtht:clousure.node=<xsl:value-of select="$bcgtht:clousure.node"/>; </xsl:message>
- <bcgtht:closure par="{$id}" chld="{@bcgtht:id}" len="{@bcgtht:clousure.from.len}" bcgtht:clousure.node="{$bcgtht:clousure.node}" bcgtht:clousure.from="{$bcgtht:clousure.from}" bcgtht:clousure.len="{$bcgtht:clousure.len}" debug="#136">
- <!--<xsl:attribute name="DEBUG122">#122 count key('bcgtht:clousure.node.from <xsl:value-of select="count(key('bcgtht:clousure.node.from',@bcgtht:clousure.node or @bcgtht:clousure.from )[ not(@bcgtht:id = current()/@bcgtht:id) and not(bcgtht:clousure.analys.log.loop-check(@bcgtht:id,$bcgtht:clousure.analys.log)) ])"/></xsl:attribute>-->
- <xsl:attribute name="DEBUG122_N">#122 count key('bcgtht:clousure.node <xsl:value-of select="count(key('bcgtht:clousure.node',@bcgtht:clousure.node )[ not(@bcgtht:id = current()/@bcgtht:id) and not(bcgtht:clousure.analys.log.loop-check(@bcgtht:id,$bcgtht:clousure.analys.log)) ])"/></xsl:attribute>
- <xsl:attribute name="DEBUG122_F">#122 count key('bcgtht:clousure.from <xsl:value-of select="count(key('bcgtht:clousure.from', @bcgtht:clousure.from )[ not(@bcgtht:id = current()/@bcgtht:id) and not(bcgtht:clousure.analys.log.loop-check(@bcgtht:id,$bcgtht:clousure.analys.log)) ])"/></xsl:attribute>
- <!--<xsl:attribute name="DEBUG122_2">#123 count no filter key('bcgtht:clousure.node.from <xsl:value-of select="count(key('bcgtht:clousure.node.from',@bcgtht:clousure.node or @bcgtht:clousure.from )[ @bcgtht:id = current()/@bcgtht:id ])"/></xsl:attribute>-->
- <!--<xsl:attribute name="DEBUG122_3">#124 $bcgtht:id=<xsl:value-of select="$bcgtht:id"/> ; $bcgtht:clousure.from=<xsl:value-of select="$bcgtht:clousure.from"/> ; <xsl:value-of select="$bcgtht:clousure.node"/> ; </xsl:attribute>-->
- <xsl:choose>
- <!-- ten modul odwraca konce, kolejny respektuje wywolanie wprost -->
- <xsl:when test="$bcgtht:clousure.from">
- <xsl:apply-templates mode="bcgtht:clousure.analys.a" select="key('bcgtht:clousure.from', @bcgtht:clousure.from )[ not(@bcgtht:id = current()/@bcgtht:id) and not(bcgtht:clousure.analys.log.loop-check(@bcgtht:id,$bcgtht:clousure.analys.log)) ]"> <!-- and not(bcgtht:clousure.analys.log.loop-check(@bcgtht:id,$bcgtht:clousure.analys.log)) -->
- <xsl:with-param name="bcgtht:id" select="@bcgtht:id"/>
- <!--<xsl:with-param name="bcgtht:clousure.from"/>-->
- <xsl:with-param name="bcgtht:clousure.from" select="@bcgtht:clousure.from"/>
- <xsl:with-param name="bcgtht:clousure.analys.log" select="$bcgtht:clousure.analys.log"/>
- <xsl:with-param name="bcgtht:clousure.len" select="$bcgtht:clousure.len + 1"/>
- </xsl:apply-templates>
- </xsl:when>
- <xsl:when test="$bcgtht:clousure.node">
- <xsl:apply-templates mode="bcgtht:clousure.analys.a" select="key('bcgtht:clousure.node',@bcgtht:clousure.node )[ not(@bcgtht:id = current()/@bcgtht:id) and not(bcgtht:clousure.analys.log.loop-check(@bcgtht:id,$bcgtht:clousure.analys.log)) ]"> <!-- and not(bcgtht:clousure.analys.log.loop-check(@bcgtht:id,$bcgtht:clousure.analys.log)) -->
- <xsl:with-param name="bcgtht:id" select="@bcgtht:id"/>
- <!--<xsl:with-param name="bcgtht:clousure.from"/>-->
- <xsl:with-param name="bcgtht:clousure.node" select="@bcgtht:clousure.node"/>
- <xsl:with-param name="bcgtht:clousure.analys.log" select="$bcgtht:clousure.analys.log"/>
- <xsl:with-param name="bcgtht:clousure.len" select="$bcgtht:clousure.len + 1"/>
- </xsl:apply-templates>
- </xsl:when>
- <xsl:otherwise><xsl:message terminate="yes">#180 error for $id = <xsl:value-of select="$id"/></xsl:message></xsl:otherwise>
- </xsl:choose>
- </bcgtht:closure>
-
-
- </xsl:template>
-
- <xsl:function name="bcgtht:clousure.analys.log">
- <bcgtht:clousure.analys.log>
- <bcgtht:id/>
- </bcgtht:clousure.analys.log>
- </xsl:function>
-
-
- <xsl:function name="bcgtht:clousure.analys.log">
- <xsl:param name="bcgtht:id"/>
- <xsl:param name="bcgtht:clousure.analys.log"/>
- <xsl:choose>
- <xsl:when test="$bcgtht:clousure.analys.log//*[@bcgtht:id]"/>
- <xsl:otherwise>
- <bcgtht:clousure.analys.log>
- <xsl:for-each select="$bcgtht:clousure.analys.log//bcgtht:id">
- <xsl:copy-of select="."/>
- </xsl:for-each>
- <bcgtht:id xml:id="{$bcgtht:id}"/>
- </bcgtht:clousure.analys.log>
- </xsl:otherwise>
- </xsl:choose>
- </xsl:function>
-
- <xsl:function name="bcgtht:clousure.analys.log.loop-check">
- <xsl:param name="bcgtht:id"/>
- <xsl:param name="bcgtht:clousure.analys.log"/>
- <xsl:choose>
- <xsl:when test="$bcgtht:clousure.analys.log//*[@bcgtht:id = $bcgtht:id]">
- <xsl:message>#167 bcgtht:clousure.analys.log.loop-check for <xsl:value-of select="$bcgtht:id"/></xsl:message>
- </xsl:when>
- <xsl:otherwise><xsl:value-of select="true()"/></xsl:otherwise>
- </xsl:choose>
- </xsl:function>
-
- <xsl:template mode="bcgtht:clousure.analys.a" match="path.clousure.following|path.included">
- <!-- doczepienie zaleznosci wszelkich -->
- <xsl:param name="bcgtht:id"/>
- <xsl:param name="bcgtht:clousure.from"/>
- <xsl:param name="bcgtht:clousure.node"/>
- <xsl:param name="bcgtht:clousure.analys.log" select="bcgtht:clousure.analys.log()"/>
- <xsl:param name="bcgtht:clousure.len" select="1"/>
- <xsl:variable name="bcgtht:clousure.analys.log" select="bcgtht:clousure.analys.log(@bcgtht:id,$bcgtht:clousure.analys.log)"/>
- <xsl:choose>
- <xsl:when test="$bcgtht:clousure.analys.log/*">
- <!-- jak wchodzi na bcgtht:clousure.from, to wychodzi potem na bcgtht:clousure.node-->
- <xsl:message>#143 bcgtht:id=<xsl:value-of select="$bcgtht:id"/>.log.count = <xsl:value-of select="count($bcgtht:clousure.analys.log//*)"/></xsl:message>
- <bcgtht:a>
- <xsl:copy-of select="@bcgtht:id"/>
- <xsl:copy-of select="bcgtht:clousure.analys.debug.child.attr(@bcgtht:clousure.node)"/>
- <xsl:copy-of select="bcgtht:clousure.analys.debug.child.attr(@bcgtht:clousure.from)"/>
- <xsl:attribute name="bcgtht:l" select="$bcgtht:clousure.len"/>
- <xsl:attribute name="debug">191 bcgtht:clousure.analys.closure $bcgtht:clousure.from=<xsl:value-of select="$bcgtht:clousure.from"/> ; $bcgtht:clousure.node=<xsl:value-of select="$bcgtht:clousure.node"/> </xsl:attribute>
- <xsl:choose>
- <xsl:when test="$bcgtht:clousure.len > 6">
- <xsl:message>bcgtht:clousure.len hit <xsl:value-of select="$bcgtht:clousure.len"/></xsl:message>
- </xsl:when>
- <xsl:when test="$bcgtht:clousure.node">
- <xsl:message>#201 bcgtht:clousure.analys.closure applyng for $bcgtht:clousure.node = <xsl:value-of select="$bcgtht:clousure.node"/></xsl:message>
- <xsl:apply-templates mode="bcgtht:clousure.analys.a" select="key('bcgtht:clousure.node.from',@bcgtht:clousure.node or @bcgtht:clousure.from )[ not(bcgtht:clousure.analys.log.loop-check(@bcgtht:id,$bcgtht:clousure.analys.log)) ]">
- <xsl:with-param name="bcgtht:id" select="@bcgtht:id"/>
- <!--<xsl:with-param name="bcgtht:clousure.from"/>-->
- <xsl:with-param name="bcgtht:clousure.node" select="@bcgtht:clousure.from"/>
- <xsl:with-param name="bcgtht:clousure.analys.log" select="$bcgtht:clousure.analys.log"/>
- <xsl:with-param name="bcgtht:clousure.len" select="$bcgtht:clousure.len + 1"/>
- </xsl:apply-templates>
- </xsl:when>
- <xsl:when test="$bcgtht:clousure.from">
- <xsl:message>#201 bcgtht:clousure.analys.closure applyng for $bcgtht:clousure.from = <xsl:value-of select="$bcgtht:clousure.from"/></xsl:message>
- <xsl:apply-templates mode="bcgtht:clousure.analys.a" select="key('bcgtht:clousure.node.from',@bcgtht:clousure.node or @bcgtht:clousure.from )[ not(bcgtht:clousure.analys.log.loop-check(@bcgtht:id,$bcgtht:clousure.analys.log)) ]">
- <xsl:with-param name="bcgtht:id" select="@bcgtht:id"/>
- <!--<xsl:with-param name="bcgtht:clousure.from"/>-->
- <xsl:with-param name="bcgtht:clousure.node" select="@bcgtht:clousure.node"/>
- <xsl:with-param name="bcgtht:clousure.analys.log" select="$bcgtht:clousure.analys.log"/>
- <xsl:with-param name="bcgtht:clousure.len" select="$bcgtht:clousure.len + 1"/>
- </xsl:apply-templates>
- </xsl:when>
- <xsl:when test="$bcgtht:id or @bcgtht:id">
- <xsl:message>#201 bcgtht:clousure.analys.closure applyng for both $by not $bcgtht:id <xsl:value-of select="@bcgtht:id"/></xsl:message>
- <xsl:comment>#216 bcgtht:clousure.analys.closure test="$bcgtht:id or @bcgtht:id"</xsl:comment>
- <xsl:apply-templates mode="bcgtht:clousure.analys.a" select="key('bcgtht:clousure.node.from',@bcgtht:clousure.node or @bcgtht:clousure.from )[ not(bcgtht:clousure.analys.log.loop-check(@bcgtht:id,$bcgtht:clousure.analys.log)) ]">
- <xsl:with-param name="bcgtht:id" select="@bcgtht:id"/>
- <!--<xsl:with-param name="bcgtht:clousure.from"/>-->
- <xsl:with-param name="bcgtht:clousure.node" select="@bcgtht:clousure.node"/>
- <xsl:with-param name="bcgtht:clousure.analys.log" select="$bcgtht:clousure.analys.log"/>
- <xsl:with-param name="bcgtht:clousure.len" select="$bcgtht:clousure.len + 1"/>
- </xsl:apply-templates>
- <xsl:apply-templates mode="bcgtht:clousure.analys.a" select="key('bcgtht:clousure.node.from',@bcgtht:clousure.node or @bcgtht:clousure.from )[ not(bcgtht:clousure.analys.log.loop-check(@bcgtht:id,$bcgtht:clousure.analys.log)) ]">
- <xsl:with-param name="bcgtht:id" select="@bcgtht:id"/>
- <!--<xsl:with-param name="bcgtht:clousure.from"/>-->
- <xsl:with-param name="bcgtht:clousure.from" select="@bcgtht:clousure.from"/>
- <xsl:with-param name="bcgtht:clousure.analys.log" select="$bcgtht:clousure.analys.log"/>
- <xsl:with-param name="bcgtht:clousure.len" select="$bcgtht:clousure.len + 1"/>
- </xsl:apply-templates>
- </xsl:when>
- </xsl:choose>
- </bcgtht:a>
- </xsl:when>
- <xsl:otherwise>
- <xsl:comment>#159 bcgtht:clousure.analys.closure L:at:<xsl:value-of select="@bcgtht:id"/> $bcgtht:l=<xsl:value-of select="$bcgtht:clousure.len"/></xsl:comment>
- <xsl:message>#159 bcgtht:clousure.analys.closure L:at:<xsl:value-of select="@bcgtht:id"/> $bcgtht:l=<xsl:value-of select="$bcgtht:clousure.len"/></xsl:message>
- </xsl:otherwise>
- </xsl:choose>
- </xsl:template>
-
- <xsl:template mode="bcgtht:clousure.analys" match="path.included[number(@bcgtht:clousure.from.len) <= $bcgtht.clousure.len_max or @bcgtht:clousure.node.pos = '0']">
- <xsl:element name="path.clousure.following">
- <xsl:copy-of select="@*"/>
- <xsl:copy-of select="bcgtht:clousure.analys.debug.child.attr(@bcgtht:clousure.node)"/>
- <xsl:copy-of select="bcgtht:clousure.analys.debug.child.attr(@bcgtht:clousure.from)"/>
- <!--SSS<xsl:apply-templates mode="p5yed:node.attr" select="."/>-->
- <xsl:apply-templates mode="bcgtht:clousure.analys.clousure.node.unique.descriptor.neigh" select="." >
- <xsl:with-param name="id" select="@bcgtht:id"/>
- </xsl:apply-templates>
- <!--<xsl:apply-templates mode="bcgtht:clousure.analys" select="following-sibling::path.included[ ( @bcgtht:clousure.from = current()/@bcgtht:clousure.from or @bcgtht:clousure.node = current()/@bcgtht:clousure.node ) and not(@bcgtht:id = current()/@bcgtht:id)][1]">
- <xsl:with-param name="bcgtht:id" select="@bcgtht:id"/>
- <xsl:with-param name="bcgtht:clousure.from" select="@bcgtht:clousure.from"/>
- </xsl:apply-templates>-->
- <xsl:comment>#100 up from/dwn node</xsl:comment>
- <xsl:message>#100 up from/dwn node</xsl:message>
- <!--<xsl:apply-templates mode="bcgtht:clousure.analys" select="preceding-sibling::path.included[ ( @bcgtht:clousure.from = current()/@bcgtht:clousure.from or @bcgtht:clousure.node = current()/@bcgtht:clousure.node ) and not(@bcgtht:id = current()/@bcgtht:id)][1]">
- <xsl:with-param name="bcgtht:id" select="@bcgtht:id"/>
- <xsl:with-param name="bcgtht:clousure.node" select="@bcgtht:clousure.node"/>
- </xsl:apply-templates>-->
- </xsl:element>
- </xsl:template>
-
- <xsl:template mode="bcgtht:clousure.analys.closure bcgtht:clousure.analys" match="*"/>
- <xsl:template mode="bcgtht:clousure.analys.closure bcgtht:clousure.analys" match="path|text()|comment()"/>
-
- <xsl:template mode="bcgtht:clousure.analys.a bcgtht:clousure.analys.clousure.node.unique.descriptor.neigh" match="text()|comment()"/>
- <xsl:template mode="bcgtht:clousure.analys.a bcgtht:clousure.analys.clousure.node.unique.descriptor.neigh" match="*">
- <xsl:param name="id" required="yes"/>
- <!--<xsl:param name="bcgtht:clousure.from" required="yes"/>-->
- <!--<xsl:param name="bcgtht:clousure.node" required="yes"/>-->
- <!--<xsl:param name="bcgtht:clousure" required="yes"/>-->
- <xsl:comment>#99 matched <xsl:value-of select="name()"/>; </xsl:comment>
- <!--<xsl:variable name="bcgtht:edge.root">
- <bcgtht:edge.root>-->
- <xsl:for-each-group select="*/bcgtht:clousure.node.unique.descriptor/*[ @bcgtht:clousure.node.unique.descriptor.group ]" group-by="concat(parent::*/@bcgtht:edge.node,':',@bcgtht:clousure.node.unique.descriptor.group.oper.arg)"> <!-- @bcgtht:clousure.node.unique.descriptor.group.oper.arg -->
- <xsl:sort select="local-name()"/>
- <bcgtht:edge>
-
- <xsl:attribute name="bcgtht:id" select="$id"/>
- <xsl:attribute name="bcgtht:edge.group" select="parent::*/@bcgtht:edge.node"/>
- <!--<xsl:attribute name="bcgtht:edge.node" select="current-group()/parent::bcgtht:clousure.node.unique.descriptor/@bcgtht:edge.node"/>-->
-
- <!-- <xsl:attribute name="bcgtht:clousure.node.unique.descriptor.group.oper.arg.eval" select="current-grouping-key()"/>-->
- <xsl:for-each-group select="current-group()" group-by="local-name()">
- <xsl:attribute name="bcgtht:id.edge" >
- <xsl:value-of select="@bcgtht:clousure.node.unique.descriptor.group"/><xsl:value-of select="'|'"/>
- <xsl:for-each select="current-group()"><xsl:value-of select="."/>|</xsl:for-each>
- </xsl:attribute>
- </xsl:for-each-group>
- </bcgtht:edge>
- </xsl:for-each-group>
- <xsl:for-each-group select="*/bcgtht:clousure.node.unique.descriptor/*[ @bcgtht:clousure.node.unique.descriptor.group ]" group-by="@bcgtht:clousure.node.unique.descriptor.group.oper.arg"> <!-- @bcgtht:clousure.node.unique.descriptor.group.oper.arg -->
- <xsl:sort select="local-name()"/>
- <xsl:for-each-group select="." group-by="local-name()">
- <bcgtht:edge>
- <xsl:attribute name="bcgtht:id" select="$id"/>
- <!--<xsl:attribute name="bcgtht:edge.group" select="current-grouping-key()"/>-->
- <!--<xsl:attribute name="bcgtht:edge.node" select="current-group()/parent::bcgtht:clousure.node.unique.descriptor/@bcgtht:edge.node"/>-->
-
- <!-- <xsl:attribute name="bcgtht:clousure.node.unique.descriptor.group.oper.arg.eval" select="current-grouping-key()"/>-->
- <xsl:for-each-group select="current-group()" group-by="local-name()">
- <xsl:attribute name="bcgtht:id.edge" >
- <xsl:value-of select="@bcgtht:clousure.node.unique.descriptor.group"/><xsl:value-of select="'|'"/>
- <xsl:for-each select="current-group()"><xsl:value-of select="."/>|</xsl:for-each>
- </xsl:attribute>
- </xsl:for-each-group>
- </bcgtht:edge>
- </xsl:for-each-group>
- </xsl:for-each-group>
-
- <!--</bcgtht:edge.root>
- </xsl:variable>-->
- <!--<xsl:variable name="bcgtht:clousure.node.unique.descriptor" select="."/>-->
- <!--<xsl:for-each select="$bcgtht:edge.root/bcgtht:edge.root/*">
- <xsl:variable name="bcgtht:edge.root.current" select="."/>
- <xsl:element name="{name()}">
- <xsl:copy-of select="@*"/>
- <xsl:for-each-group select="$bcgtht:clousure.node.unique.descriptor/*/bcgtht:clousure.node.unique.descriptor" group-by="@bcgtht:edge.node">
- <xsl:variable name="bcgtht:id.edge.test">
- <xsl:for-each-group select="current-group()/*[@bcgtht:clousure.node.unique.descriptor.group]" group-by="@bcgtht:clousure.node.unique.descriptor.group">
- <xsl:value-of select="@bcgtht:clousure.node.unique.descriptor.group"/><xsl:value-of select="'|'"/>
- <xsl:for-each select="current-group()"><xsl:value-of select="."/>|</xsl:for-each>
- </xsl:for-each-group>
- </xsl:variable>
- <xsl:attribute name="debug_test{position()}" select="$bcgtht:id.edge.test"/>
- <xsl:if test="$bcgtht:id.edge.test = $bcgtht:edge.root.current/@bcgtht:id.edge">
- <xsl:attribute name="bcgtht:edge.node" select="@bcgtht:edge.node"/>
- </xsl:if>
- </xsl:for-each-group>
- </xsl:element>
- </xsl:for-each>-->
- </xsl:template>
-
-
-
-
-
- <xsl:template mode="bcgtht:clousure.analys.debug" match="*">
- <bcgtht:clousure.analys.debug>
- <xsl:apply-templates mode="bcgtht:clousure.analys.debug.child"/>
- </bcgtht:clousure.analys.debug>
- </xsl:template>
-
- <xsl:template mode="bcgtht:clousure.analys.debug.child" match="*">
- <xsl:apply-templates mode="#current"/>
- </xsl:template>
-
- <xsl:function name="bcgtht:clousure.analys.debug.child">
- <xsl:param name="node"/>
- <xsl:choose>
- <xsl:when test="contains($bcgtht:debug.nodes,$node)"> debug cust node<xsl:value-of select="$node"/></xsl:when>
- <xsl:when test="$node='BI_audit_KRS.161323'"><xsl:value-of select="'DEBUG_BI_audit_KRS.161323'"/></xsl:when>
- <xsl:when test="$node='BI_audit_KRS_person.747001'"><xsl:value-of select="'DEBUG_BI_audit_KRS_person.747001'"/></xsl:when>
- </xsl:choose>
- </xsl:function>
-
- <xsl:function name="bcgtht:clousure.analys.debug.child.attr">
- <xsl:param name="node"/>
- <xsl:choose>
- <xsl:when test="bcgtht:clousure.analys.debug.child($node)">
- <xsl:attribute name="DEBUG" select="bcgtht:clousure.analys.debug.child($node)"/>
- </xsl:when>
- </xsl:choose>
- </xsl:function>
-
- <xsl:template mode="bcgtht:clousure.analys.debug.child" match="*[bcgtht:clousure.analys.debug.child(@node)]">
- <xsl:copy copy-namespaces="no">
- <xsl:copy-of select="@*"/>
- <xsl:copy-of select="bcgtht:clousure.analys.debug.child.attr(@node)"/>
- <xsl:comment> #84 DEBUG <xsl:value-of select="bcgtht:clousure.analys.debug.child(@node)"/></xsl:comment>
- <xsl:copy-of select="."/>
- </xsl:copy>
- </xsl:template>
-
- <xsl:template mode="bcgtht:clousure.analys.debug.child" match="*[*[bcgtht:clousure.analys.debug.child(@node)]]">
- <xsl:copy copy-namespaces="no">
- <xsl:copy-of select="@*"/>
- <xsl:comment> #92 DEBUG <xsl:value-of select="bcgtht:clousure.analys.debug.child(*/@node)"/> </xsl:comment>
- <xsl:copy-of select="."/>
- <!--<xsl:apply-templates mode="#current"/>-->
- </xsl:copy>
- </xsl:template>
-
- <xsl:template mode="bcgtht:clousure.analys.debug.child" match="*[*[*[bcgtht:clousure.analys.debug.child(@node)]]]">
- <xsl:copy copy-namespaces="no">
- <xsl:copy-of select="@*"/>
- <xsl:comment> #101 DEBUG </xsl:comment>
-
- <xsl:apply-templates mode="#current"/>
- </xsl:copy>
- </xsl:template>
-
-
-
-
- <xsl:template mode="bcgtht:clousure.analys.debug.child" match="text()|comment()"/>
-
-
-
-
-
- </xsl:stylesheet>
|