|
|
@@ -113,7 +113,7 @@
|
|
|
<xsl:otherwise><xsl:value-of select="concat($simpleSchema_dir,'/',$targetNamespace_DEFAULTS_prefix,'/',$featureID_name_dita,'.xml')"/></xsl:otherwise>
|
|
|
</xsl:choose>
|
|
|
</xsl:variable>
|
|
|
- <xsl:message>#57 get_wfs_recurse_xsl:GetsimpleSchema: from $typeNameRealResource=<xsl:value-of select="$typeNameRealResource"/>; <xsl:value-of select="$simpleSchemaFile"/> for featureID_name_dita=<xsl:value-of select="$featureID_name_dita"/>;</xsl:message>
|
|
|
+ <xsl:message>#57 get_wfs_recurse_xsl:GetsimpleSchema: from $typeNameRealResource=<xsl:value-of select="$typeNameRealResource"/>; <xsl:value-of select="$simpleSchemaFile"/> for featureID_name_dita=<xsl:value-of select="$featureID_name_dita"/>;</xsl:message>
|
|
|
|
|
|
|
|
|
<xsl:if test="not( substring-before(system_cache__appinfo:translate_object_escaped_prefix_from_string(substring-before($typeNameRealResource,':')),':'))">
|
|
|
@@ -613,6 +613,7 @@
|
|
|
<xsl:with-param name="get_wfs_recurse_xsl:context.nodes" select="$get_wfs_recurse_xsl:context.nodes"/>
|
|
|
<xsl:with-param name="get_wfs_recurse_xsl:context.PRIMARYKEY" select="$get_wfs_recurse_xsl:context.PRIMARYKEY"/>
|
|
|
<xsl:with-param name="debug.last_wfs_request" select="$request_string"/>
|
|
|
+ <xsl:with-param name="resolveDepth.current" select="1"/>
|
|
|
</xsl:apply-templates>
|
|
|
</xsl:when>
|
|
|
<xsl:otherwise>
|
|
|
@@ -622,6 +623,7 @@
|
|
|
<xsl:with-param name="get_wfs_recurse_xsl:context.nodes" select="$get_wfs_recurse_xsl:context.nodes"/>
|
|
|
<xsl:with-param name="get_wfs_recurse_xsl:context.PRIMARYKEY" select="$get_wfs_recurse_xsl:context.PRIMARYKEY"/>
|
|
|
<xsl:with-param name="debug.last_wfs_request" select="$request_string"/>
|
|
|
+ <xsl:with-param name="resolveDepth.current" select="1"/>
|
|
|
</xsl:apply-templates>
|
|
|
</RelatedFeatureRoot>
|
|
|
</xsl:otherwise>
|
|
|
@@ -1223,6 +1225,7 @@
|
|
|
<!--<xsl:param name="get_wfs_recurse_xsl:wfs_response" required="yes"/>-->
|
|
|
<xsl:param name="get_wfs_recurse_xsl:typeNameRealResource" select="@typeNameRealResource"/>
|
|
|
<xsl:param name="input_obj_with_xpath" required="yes"/>
|
|
|
+ <xsl:param name="resolveDepth.current" required="yes"/>
|
|
|
<!--<xsl:param name="xpath" select="$xpath"/>-->
|
|
|
<!--<xsl:param name="xpath_value" select="$xpath_value"/>-->
|
|
|
<!--<xsl:variable name="input_obj_with_xpath">
|
|
|
@@ -1283,7 +1286,9 @@
|
|
|
</wfs_response>
|
|
|
</xsl:if>
|
|
|
<xsl:apply-templates mode="after_first_ant_assing_vars" select="." >
|
|
|
+
|
|
|
<xsl:with-param name="get_wfs_recurse_xsl:wfs_response" select="$get_wfs_recurse_xsl:wfs_response"/>
|
|
|
+ <xsl:with-param name="resolveDepth.current" select="$resolveDepth.current"/>
|
|
|
</xsl:apply-templates>
|
|
|
|
|
|
</xsl:template>
|
|
|
@@ -1295,6 +1300,7 @@
|
|
|
<xsl:param name="input_obj_with_xpath" required="yes"/>
|
|
|
<xsl:param name="xpath" select="$xpath"/>
|
|
|
<xsl:param name="xpath_value" select="$xpath_value"/>
|
|
|
+ <xsl:param name="resolveDepth.current" required="yes"/>
|
|
|
<!--<xsl:variable name="input_obj_with_xpath">
|
|
|
<xsl:apply-templates mode="after_first_ant_assing_xpath" select="node()/*"/> <!-\- zeby nie wstawial do xpath nazwy feature - IN7_DZIENNIK_KORESP/ID itp -\->
|
|
|
</xsl:variable>-->
|
|
|
@@ -1359,8 +1365,11 @@
|
|
|
</xsl:if>
|
|
|
<xsl:apply-templates mode="after_first_ant_assing_vars" select="." >
|
|
|
<xsl:with-param name="get_wfs_recurse_xsl:wfs_response" select="$get_wfs_recurse_xsl:wfs_response"/>
|
|
|
+ <xsl:with-param name="resolveDepth.current" select="$resolveDepth.current"/>
|
|
|
</xsl:apply-templates>
|
|
|
</xsl:template>
|
|
|
+
|
|
|
+
|
|
|
<xsl:template mode="get_wfs_recurse_xsl:wfs_response_simpleType" match="*">
|
|
|
<xsl:copy-of select="."/>
|
|
|
</xsl:template>
|
|
|
@@ -1399,6 +1408,7 @@
|
|
|
<xsl:template match="RelatedFeature" mode="after_first_ant_assing_vars">
|
|
|
<xsl:param name="loop_xpath" />
|
|
|
<xsl:param name="get_wfs_recurse_xsl:wfs_response" required="yes"/>
|
|
|
+ <xsl:param name="resolveDepth.current" required="yes"/>
|
|
|
<!--<RelatedFeatureRoot>-->
|
|
|
|
|
|
<!-- first assign xpath to features from -->
|
|
|
@@ -1425,6 +1435,7 @@
|
|
|
<xsl:with-param name="feature_pos" select="position()"/><!-- wiecej features z relacji dokladamy pozycje -->
|
|
|
<xsl:with-param name="feature_pos_parent" select="$feature_pos_parent"/> <!-- @2017-04 byly nadpisywane informacje - trzeba dorzucic jeszcze $feature_pos_parent w nazwie przetwarzania -->
|
|
|
<xsl:with-param name="input_obj_fid" select="$input_obj_fid"/>
|
|
|
+ <xsl:with-param name="resolveDepth.current" select="$resolveDepth.current"/>
|
|
|
</xsl:apply-templates>
|
|
|
<!-- cache tasks ? -->
|
|
|
</xsl:for-each>
|
|
|
@@ -1463,19 +1474,41 @@
|
|
|
</xsl:variable>
|
|
|
<!--<xsl:variable name="curr_xpath_tmpl" select="'asdf'"/>-->
|
|
|
<!--<xsl:element name="{name()}" >-->
|
|
|
- <xsl:copy>
|
|
|
- <xsl:attribute name="xpath" select="$curr_xpath_tmpl"/>
|
|
|
- <xsl:for-each select="@*">
|
|
|
- <xsl:choose>
|
|
|
- <xsl:when test="name()='fid'"/>
|
|
|
- <xsl:otherwise><xsl:attribute name="{name()}"><xsl:value-of select="."/></xsl:attribute></xsl:otherwise>
|
|
|
- </xsl:choose>
|
|
|
- </xsl:for-each>
|
|
|
- <xsl:value-of select="text()"/>
|
|
|
- <xsl:apply-templates mode="after_first_ant_assing_xpath">
|
|
|
- <xsl:with-param name="curr_xpath" select="$curr_xpath_tmpl"/>
|
|
|
- </xsl:apply-templates>
|
|
|
- </xsl:copy>
|
|
|
+
|
|
|
+ <xsl:choose>
|
|
|
+ <xsl:when test="contains(name(),'gml')">
|
|
|
+ <xsl:element name="{local-name()}">
|
|
|
+ <xsl:attribute name="xpath" select="$curr_xpath_tmpl"/>
|
|
|
+ <xsl:for-each select="@*">
|
|
|
+ <xsl:choose>
|
|
|
+ <xsl:when test="name()='fid'"/>
|
|
|
+ <xsl:otherwise><xsl:attribute name="{name()}"><xsl:value-of select="."/></xsl:attribute></xsl:otherwise>
|
|
|
+ </xsl:choose>
|
|
|
+ </xsl:for-each>
|
|
|
+ <xsl:value-of select="text()"/>
|
|
|
+ <xsl:apply-templates mode="after_first_ant_assing_xpath">
|
|
|
+ <xsl:with-param name="curr_xpath" select="$curr_xpath_tmpl"/>
|
|
|
+ </xsl:apply-templates>
|
|
|
+ </xsl:element>
|
|
|
+ </xsl:when>
|
|
|
+ <xsl:otherwise>
|
|
|
+ <xsl:copy>
|
|
|
+ <xsl:attribute name="xpath" select="$curr_xpath_tmpl"/>
|
|
|
+ <xsl:for-each select="@*">
|
|
|
+ <xsl:choose>
|
|
|
+ <xsl:when test="name()='fid'"/>
|
|
|
+ <xsl:otherwise><xsl:attribute name="{name()}"><xsl:value-of select="."/></xsl:attribute></xsl:otherwise>
|
|
|
+ </xsl:choose>
|
|
|
+ </xsl:for-each>
|
|
|
+ <xsl:value-of select="text()"/>
|
|
|
+ <xsl:apply-templates mode="after_first_ant_assing_xpath">
|
|
|
+ <xsl:with-param name="curr_xpath" select="$curr_xpath_tmpl"/>
|
|
|
+ </xsl:apply-templates>
|
|
|
+ </xsl:copy>
|
|
|
+ </xsl:otherwise>
|
|
|
+ </xsl:choose>
|
|
|
+
|
|
|
+
|
|
|
<!--</xsl:element>-->
|
|
|
</xsl:otherwise>
|
|
|
</xsl:choose>
|
|
|
@@ -1497,12 +1530,14 @@
|
|
|
<xsl:param name="feature_pos" required="yes"/>
|
|
|
<xsl:param name="feature_pos_parent" required="yes"/>
|
|
|
<xsl:param name="input_obj_fid" required="no"/>
|
|
|
+ <xsl:param name="resolveDepth.current" required="yes"/>
|
|
|
<xsl:for-each select=".">
|
|
|
<xsl:choose>
|
|
|
|
|
|
<xsl:when test="1=2"/>
|
|
|
<xsl:otherwise>
|
|
|
<xsl:element name="{local-name()}">
|
|
|
+
|
|
|
<!--<xsl:if test="$input_obj_fid">
|
|
|
<!-\-<xsl:attribute name="input_obj_fid_name" select="$input_obj_fid/name()"/>-\->
|
|
|
<xsl:attribute name="fid" select="$input_obj_fid/@fid"/>
|
|
|
@@ -1604,6 +1639,7 @@
|
|
|
<xsl:with-param name="feature_pos" select="$feature_pos"/>
|
|
|
<xsl:with-param name="feature_pos_parent" select="$feature_pos_parent"/>
|
|
|
<xsl:with-param name="input_obj_fid" select="$input_obj_fid"/>
|
|
|
+ <xsl:with-param name="resolveDepth.current" select="$resolveDepth.current"/>
|
|
|
</xsl:apply-templates>
|
|
|
</xsl:element>
|
|
|
</xsl:otherwise>
|
|
|
@@ -1622,6 +1658,7 @@
|
|
|
<xsl:param name="feature_pos_parent" required="yes"/>
|
|
|
<xsl:param name="input_obj_fid" required="yes"/>
|
|
|
<xsl:param name="xpath_query"/> <!-- + added test -->
|
|
|
+ <xsl:param name="resolveDepth.current" required="yes"/>
|
|
|
<xsl:if test="$debug > 2"><xsl:message>#411 $feature_pos=<xsl:value-of select="$feature_pos"/>; mode after_first_ant_assing_vars_childs bylo $loop_xpath=<xsl:value-of select="$loop_xpath"/>;</xsl:message></xsl:if>
|
|
|
<!-- jest okazja do zrobienia bilda aby sciagnal rzeczy nizej -->
|
|
|
<xsl:variable name="featureID_name" select="substring-after(@typeName,':')"/>
|
|
|
@@ -1659,6 +1696,7 @@
|
|
|
<xsl:attribute name="fid" select="$input_obj_fid/@fid"/>-->
|
|
|
<xsl:apply-templates mode="get_wfs_recurse_xsl:wfs_response_RelatedFeature" select=".">
|
|
|
<xsl:with-param name="input_obj_with_xpath" select="$input_obj_with_xpath"/>
|
|
|
+ <xsl:with-param name="resolveDepth.current" select="$resolveDepth.current"/>
|
|
|
</xsl:apply-templates>
|
|
|
<!--</xsl:element>-->
|
|
|
</xsl:when>
|
|
|
@@ -1686,6 +1724,7 @@
|
|
|
<xsl:param name="feature_pos_parent" required="yes"/>
|
|
|
<xsl:param name="input_obj_fid" required="yes"/>
|
|
|
<xsl:param name="xpath_query"/> <!-- + added test -->
|
|
|
+ <xsl:param name="resolveDepth.current" required="yes"/>
|
|
|
<xsl:if test="$debug > 2"><xsl:message>#411 $feature_pos=<xsl:value-of select="$feature_pos"/>; mode after_first_ant_assing_vars_childs bylo $loop_xpath=<xsl:value-of select="$loop_xpath"/>;</xsl:message></xsl:if>
|
|
|
<!-- jest okazja do zrobienia bilda aby sciagnal rzeczy nizej -->
|
|
|
<xsl:variable name="featureID_name" select="substring-after(@typeName,':')"/>
|
|
|
@@ -1710,6 +1749,9 @@
|
|
|
</xsl:call-template>
|
|
|
</xsl:variable>
|
|
|
<xsl:choose>
|
|
|
+ <xsl:when test="$resolveDepth.current > $resolveDepth">
|
|
|
+ <xsl:message>#1722 exceeded $resolveDepth.current > $resolveDepth = <xsl:value-of select="$resolveDepth.current"/></xsl:message>
|
|
|
+ </xsl:when>
|
|
|
<xsl:when test="$test_xpath_query='1'">
|
|
|
<xsl:if test="$debug > 2"><xsl:message>[][][][][]\/\/\/\/\/\/\/\/\/\/\/ #1540 jest okazja do zrobienia bilda $feature_pos_parent = <xsl:value-of select="$feature_pos_parent"/> ; $feature_pos=<xsl:value-of select="$feature_pos"/> $xml_id_parent=<xsl:value-of select="$xml_id_parent"/>; $xml_id=<xsl:value-of select="$xml_id"/>; match=RelatedFeature mode=after_first_ant_assing_vars_childs </xsl:message></xsl:if>
|
|
|
<xsl:comment>#527 there we exec child dig</xsl:comment>
|
|
|
@@ -1721,10 +1763,12 @@
|
|
|
<xsl:attribute name="feature_pos_parent" select="$feature_pos_parent"/>
|
|
|
<xsl:attribute name="fid" select="$input_obj_fid/@fid"/>-->
|
|
|
<xsl:comment>#710 opening new Loop recurse instance for <xsl:value-of select="@typeName"/></xsl:comment>
|
|
|
+ <xsl:message>#710 resolveDepth.current = <xsl:value-of select="$resolveDepth.current"/>; opening new Loop recurse instance for <xsl:value-of select="@typeName"/></xsl:message>
|
|
|
<xsl:apply-templates mode="get_wfs_recurse_xsl:wfs_response_RelatedFeatureLoop" select="get_wfs_recurse_xsl:GetsimpleSchema(@typeName)">
|
|
|
<xsl:with-param name="input_obj_with_xpath" select="$input_obj_with_xpath"/>
|
|
|
<xsl:with-param name="xpath" select="@xpath"/>
|
|
|
<xsl:with-param name="xpath_value" select="@xpath_value"/>
|
|
|
+ <xsl:with-param name="resolveDepth.current" select="$resolveDepth.current + 1"/>
|
|
|
</xsl:apply-templates>
|
|
|
<!--</xsl:element>-->
|
|
|
</xsl:when>
|