Jelajahi Sumber

missing func merge schema

a.binder 8 tahun lalu
induk
melakukan
a1e44fb169

+ 49 - 90
SE/schema/default_db_xml_cache.public/graph_relation_elements.xsd

@@ -1,114 +1,73 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
-           xmlns:system_cache__graph_relation_elements="http://biuro.biall-net.pl/xmlschema_procesy5/system_cache/graph_relation_elements.xsd"
-           elementFormDefault="qualified"
-           targetNamespace="http://biuro.biall-net.pl/xmlschema_procesy5/system_cache/graph_relation_elements.xsd">
-   <xs:annotation id="system_cache__graph_relation_elements___d185e3">
-      <xs:documentation>Elementy do interpretacji przez silnik rysowania relacji/paszportyzacji</xs:documentation>
-      
-        
-    </xs:annotation>
-   <xs:complexType name="graphLinkComplex"
+  xmlns:system_cache__graph_relation_elements="http://biuro.biall-net.pl/xmlschema_procesy5/system_cache/graph_relation_elements.xsd"
+  elementFormDefault="qualified"
+  targetNamespace="http://biuro.biall-net.pl/xmlschema_procesy5/system_cache/graph_relation_elements.xsd"
+  vc:minVersion="1.1" xmlns:vc="http://www.w3.org/2007/XMLSchema-versioning">
+  <xs:annotation id="system_cache__graph_relation_elements___d185e3">
+    <xs:documentation>Elementy do interpretacji przez silnik rysowania relacji/paszportyzacji</xs:documentation>
+  </xs:annotation>
+  <xs:complexType name="graphLinkComplex"
                    id="system_cache__graph_relation_elements___d185e9">
-      <xs:annotation id="system_cache__graph_relation_elements___d185e11">
-         <xs:documentation>Situation:
+    <xs:annotation id="system_cache__graph_relation_elements___d185e11">
+      <xs:documentation>Situation:
                 IF:
                 DevicePortLinkL1/DevicePortL1 (2)
                 Than 2 DevicePortLinkL1/DevicePortL1 are linked
                 
             </xs:documentation>
-         
-            
-        </xs:annotation>
-      
-        
-    </xs:complexType>
-   <xs:simpleType name="graphLink" id="system_cache__graph_relation_elements___d185e18">
-      <xs:annotation id="system_cache__graph_relation_elements___d185e20">
-         <xs:documentation>Situation:
+    </xs:annotation>
+  </xs:complexType>
+  <xs:simpleType name="graphLink" id="system_cache__graph_relation_elements___d185e18">
+    <xs:annotation id="system_cache__graph_relation_elements___d185e20">
+      <xs:documentation>Situation:
                 IF:
                 DevicePortLinkL1/DevicePortL1 (2)
                 Than 2 DevicePortLinkL1/DevicePortL1 are linked
                 
             </xs:documentation>
-         
-            
-        </xs:annotation>
-      <xs:restriction base="xs:string" id="system_cache__graph_relation_elements___d185e26"/>
-      
-      
-        
-        
-    </xs:simpleType>
-   <xs:simpleType name="graphLink2Childs"
+    </xs:annotation>
+    <xs:restriction base="xs:string" id="system_cache__graph_relation_elements___d185e26"/>
+  </xs:simpleType>
+  <xs:simpleType name="graphLink2Childs"
                   id="system_cache__graph_relation_elements___d185e29">
-      <xs:annotation id="system_cache__graph_relation_elements___d185e31">
-         <xs:documentation>Situation:
+    <xs:annotation id="system_cache__graph_relation_elements___d185e31">
+      <xs:documentation>Situation:
                 IF:
                 DevicePortLinkL1/DevicePortL1 (2)
                 Than 2 DevicePortLinkL1/DevicePortL1 are linked
             </xs:documentation>
-         
-            
-        </xs:annotation>
-      <xs:restriction base="xs:string" id="system_cache__graph_relation_elements___d185e37"/>
-      
-      
-        
-        
-    </xs:simpleType>
-   <xs:simpleType name="graphLinkChilds"
+    </xs:annotation>
+    <xs:restriction base="xs:string" id="system_cache__graph_relation_elements___d185e37"/>
+  </xs:simpleType>
+  <xs:simpleType name="graphLinkChilds"
                   id="system_cache__graph_relation_elements___d185e40">
-      <xs:annotation id="system_cache__graph_relation_elements___d185e42">
-         <xs:documentation>Make links on graphs for scenario:
+    <xs:annotation id="system_cache__graph_relation_elements___d185e42">
+      <xs:documentation>Make links on graphs for scenario:
                 obj/FibreTube-graphNode
                 obj/FibreThin/Part</xs:documentation>
-         
-            
-        </xs:annotation>
-      <xs:restriction base="xs:string" id="system_cache__graph_relation_elements___d185e48"/>
-      
-      
-        
-        
-    </xs:simpleType>
-   <xs:simpleType name="graph2Links" id="system_cache__graph_relation_elements___d185e52">
-      <xs:annotation id="system_cache__graph_relation_elements___d185e54">
-         <xs:documentation>special link which makes two links . If we have object A1, A2, and B1, than links are make between A1--B1 and B1--A2</xs:documentation>
-         
-            
-        </xs:annotation>
-      <xs:restriction base="xs:string" id="system_cache__graph_relation_elements___d185e60"/>
-      
-      
-        
-        
-    </xs:simpleType>
-   <xs:complexType name="graphNodeComplex"
+    </xs:annotation>
+    <xs:restriction base="xs:string" id="system_cache__graph_relation_elements___d185e48"/>
+  </xs:simpleType>
+  <xs:simpleType name="graph2Links" id="system_cache__graph_relation_elements___d185e52">
+    <xs:annotation id="system_cache__graph_relation_elements___d185e54">
+      <xs:documentation>special link which makes two links . If we have object A1, A2, and B1, than links are make between A1--B1 and B1--A2</xs:documentation>
+    </xs:annotation>
+    <xs:restriction base="xs:string" id="system_cache__graph_relation_elements___d185e60"/>
+  </xs:simpleType>
+  <xs:complexType name="graphNodeComplex"
                    id="system_cache__graph_relation_elements___d185e63"/>
-   <xs:simpleType name="graphNode" id="system_cache__graph_relation_elements___d185e65">
-      <xs:annotation id="system_cache__graph_relation_elements___d185e67">
-         <xs:documentation>This data type makes sens on logic-graph view. 
+  <xs:simpleType name="graphNode" id="system_cache__graph_relation_elements___d185e65">
+    <xs:annotation id="system_cache__graph_relation_elements___d185e67">
+      <xs:documentation>This data type makes sens on logic-graph view. 
                 When used the node-point is placed on the graph with nearest parent's pf5:graphGroup simple-type node.</xs:documentation>
-         
-            
-        </xs:annotation>
-      <xs:restriction base="xs:string" id="system_cache__graph_relation_elements___d185e73"/>
-      
-      
-        
-        
-    </xs:simpleType>
-   <xs:simpleType name="graphGroup" id="system_cache__graph_relation_elements___d185e76">
-      <xs:annotation id="system_cache__graph_relation_elements___d185e78">
-         <xs:documentation>This special data type makes that object is showed on logic graph as a group of parent objects ( box ) </xs:documentation>
-         
-            
-        </xs:annotation>
-      <xs:restriction base="xs:string" id="system_cache__graph_relation_elements___d185e84"/>
-      
-      
-        
-        
-    </xs:simpleType>
+    </xs:annotation>
+    <xs:restriction base="xs:string" id="system_cache__graph_relation_elements___d185e73"/>
+  </xs:simpleType>
+  <xs:simpleType name="graphGroup" id="system_cache__graph_relation_elements___d185e76">
+    <xs:annotation id="system_cache__graph_relation_elements___d185e78">
+      <xs:documentation>This special data type makes that object is showed on logic graph as a group of parent objects ( box ) </xs:documentation>
+    </xs:annotation>
+    <xs:restriction base="xs:string" id="system_cache__graph_relation_elements___d185e84"/>
+  </xs:simpleType>
 </xs:schema>

+ 4 - 0
SE/schema/default_db_xml_cache.public/p5_tr_map.xsd

@@ -214,6 +214,10 @@
         <xs:attributeGroup ref="p5_tr_map:go_recurse_from_root_by_build_element_459b"/>
     </xs:complexType>
     <xs:complexType name="go_recurse_from_root_by_build_element_434b">
+        <xs:annotation>
+            <xs:documentation>local-name()='complexType' and not($p5_tr_map:parent_name) and not($parent_type) and not($p5_tr_map:parent_type) and not(@type)" xpath-default-namespace="http://www.w3.org/2001/XMLSchema
+bylo  warunek 434b przepuszczenie pierszego elementu dla przypadku //schema/element/complexType</xs:documentation>
+        </xs:annotation>
         <xs:attributeGroup ref="p5_tr_map:go_recurse_from_root_by_build_element_434b"/>
     </xs:complexType>
     <xs:group name="go_recurse_from_root_by_build_element_434b">

+ 16 - 0
SE/schema/default_db_xml_cache.public/procesy5_xsd_business_objects.xsd

@@ -243,6 +243,22 @@ Czyli to pole powinno być unikalne jako XS:ID</xs:documentation>
                 id="system_cache__procesy5_xsd_business_objects___d191e277"/>
         </xs:choice>
     </xs:complexType>
+    <!--<xs:simpleType id="default_d___appinfo-1_CRM_PRZYPA" name="CRM_PRZYPADEK__FORM_TREAT">
+        <xs:annotation>
+            <xs:documentation>acl types in simpleType format</xs:documentation>
+        </xs:annotation>
+        <xs:restriction base="xs:string">
+            <xs:enumeration value=""/>
+            <xs:enumeration value="R"/>
+            <xs:enumeration value="W"/>
+            <xs:enumeration value="X"/>
+            <xs:enumeration value="C"/>
+            <xs:enumeration value="S"/>
+            <xs:enumeration value="O"/>
+            <xs:enumeration value="V"/>
+            <xs:enumeration value="E"/>
+        </xs:restriction>
+    </xs:simpleType>-->
     <xs:complexType name="assoc_perm" abstract="true"
         id="system_cache__procesy5_xsd_business_objects___d191e281">
         <xs:annotation id="system_cache__procesy5_xsd_business_objects___d191e283">

+ 157 - 0
SE/schema/default_db_xml_cache.public/system_cache__appinfo/functions.xsl

@@ -0,0 +1,157 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+    xmlns:xs="http://www.w3.org/2001/XMLSchema"
+    xmlns:system_cache__appinfo="http://biuro.biall-net.pl/xmlschema_procesy5/default_db_xml_cache/appinfo.xsd"
+    exclude-result-prefixes="xs"
+    version="2.0">
+    
+    
+    
+    <xsl:include href="escape_functions.xsl"/>
+    
+    <xsl:function name="system_cache__appinfo:document-uri_for_external_schema_id_namespace_prefix">
+        <xsl:param name="system_cache__appinfo:document-uri_from_external_schema"/>
+        <xsl:value-of select="substring-after(replace($system_cache__appinfo:document-uri_from_external_schema,$external_schema,$external_schema_id_namespace_prefix  ), '/public_html/') "/>
+    </xsl:function>
+    
+    <xsl:function name="system_cache__appinfo:document-uri-full_for_external_schema_id_namespace_prefix">
+        <xsl:param name="system_cache__appinfo:document-uri_from_external_schema"/>
+        <xsl:value-of select="replace($system_cache__appinfo:document-uri_from_external_schema,$external_schema,$external_schema_id_namespace_prefix  )"/>
+    </xsl:function>
+    
+    
+    
+    <xsl:function name="system_cache__appinfo:get_object_prefix_from_escaped_prefix_or_not_being_escaped">
+        <xsl:param name="system_cache__appinfo:escape_object_prefix_to_string"/>
+        <xsl:choose>
+            <xsl:when test=" substring-before(system_cache__appinfo:translate_object_escaped_prefix_from_string($system_cache__appinfo:escape_object_prefix_to_string),':')">
+                <xsl:value-of select="system_cache__appinfo:get_object_prefix(system_cache__appinfo:translate_object_escaped_prefix_from_string($system_cache__appinfo:escape_object_prefix_to_string))"/>
+            </xsl:when>
+            <xsl:otherwise>
+                <xsl:value-of select="$system_cache__appinfo:escape_object_prefix_to_string"/>
+            </xsl:otherwise>
+        </xsl:choose>
+        
+    </xsl:function>
+    
+    
+    <xsl:function name="system_cache__appinfo:get_object_prefix_from_escaped_prefix">
+        <xsl:param name="system_cache__appinfo:escape_object_prefix_to_string"/>
+        <xsl:value-of select="system_cache__appinfo:get_object_prefix(system_cache__appinfo:translate_object_escaped_prefix_from_string($system_cache__appinfo:escape_object_prefix_to_string))"/>
+    </xsl:function>
+    
+    <!-- funkcja do wyczyszczenia wyescapowenago prefixu z np. default_db__x3A__IN7_DZIENNIK_KORESP do IN7_DZIENNIK_KORESP -->
+    <xsl:function name="system_cache__appinfo:clean_object_escaped_prefix">
+        <xsl:param name="name" />
+        <xsl:value-of select=" system_cache__appinfo:clean_object_prefix(system_cache__appinfo:translate_object_escaped_prefix_from_string($name))"/>
+    </xsl:function>
+    
+    
+    
+   
+    
+    <xsl:template name="system_cache__appinfo:prefixed_object_info">
+        <xsl:param name="prefixed_object" required="yes"/>
+        <xsl:variable name="prefix_token" select="tokenize(system_cache__appinfo:translate_object_escaped_prefix_from_string($prefixed_object),':')"/>
+        <xsl:choose>
+            <xsl:when test=" string-length($prefix_token[3]) &gt; 0">
+                <system_cache__appinfo:prefixed_object_info>
+                    <xsl:attribute name="prefix" select="$prefix_token[1]"/>
+                    <xsl:attribute name="name" select="$prefix_token[2]"/>
+                    <xsl:attribute name="element" select="$prefix_token[3]"/>
+                </system_cache__appinfo:prefixed_object_info>
+            </xsl:when>
+            <xsl:otherwise>
+                <system_cache__appinfo:prefixed_object_info>
+                    <xsl:attribute name="prefix" select="$prefix_token[1]"/>
+                    <xsl:attribute name="name" select="$prefix_token[2]"/>
+                    <xsl:attribute name="element" select="$prefix_token[2]"/>
+                </system_cache__appinfo:prefixed_object_info>
+            </xsl:otherwise>
+        </xsl:choose>
+    </xsl:template>
+    
+    <!-- @2016-08 funkcje do wykrywania  prefixow, namespace itp itd... 
+      <xsl:attribute name="prefix" select="$vrtfNamespaces/ns[@uri=$targetnamespace][1]/@prefix" xpath-default-namespace=""/>
+                        <xsl:attribute name="targetnamespace" select="$targetnamespace"/>
+                        <xsl:attribute name="type_79" select="$type_79"/>
+                        <xsl:attribute name="prefix_79" select="$prefix_79"/>
+                        <xsl:attribute name="type_79_nopref" select="$type_79_nopref"/>
+    
+    -->
+    <xsl:function name="system_cache__appinfo:prefix_from_targetNamespace">
+        <xsl:param name="system_cache__appinfo:vrtfNamespaces" />
+        <xsl:param name="targetNamespace" />
+        <!--<xsl:message>#115 system_cache__appinfo:prefix_from_targetNamespace elements in system_cache__appinfo:vrtfNamespaces=<xsl:value-of select="count($system_cache__appinfo:vrtfNamespaces//ns)" xpath-default-namespace=""/></xsl:message>-->
+        <!--<xsl:value-of select="$system_cache__appinfo:vrtfNamespaces//ns[substring-after(@uri,'://')=substring-after($targetNamespace,'://')][1]/@prefix" xpath-default-namespace=""/>-->
+        <xsl:choose>
+            <xsl:when test=" contains($targetNamespace,'://')">
+                <xsl:value-of select="$system_cache__appinfo:vrtfNamespaces//ns[substring-after(@uri,'://')=substring-after($targetNamespace,'://') ][1]/@prefix" xpath-default-namespace=""/>
+            </xsl:when>
+            <xsl:otherwise>
+                <xsl:value-of select="$system_cache__appinfo:vrtfNamespaces//ns[@uri=$targetNamespace][1]/@prefix" xpath-default-namespace=""/>
+            </xsl:otherwise>
+        </xsl:choose>
+    </xsl:function>
+    
+    <xsl:function name="system_cache__appinfo:prefix_from_targetNamespace">
+        <xsl:param name="system_cache__appinfo:vrtfNamespaces" />
+        <xsl:param name="targetNamespace" />
+        <xsl:param name="system_cache__appinfo:document-uri" />
+        <!--<xsl:message>#115 system_cache__appinfo:prefix_from_targetNamespace elements in system_cache__appinfo:vrtfNamespaces=<xsl:value-of select="count($system_cache__appinfo:vrtfNamespaces//ns)" xpath-default-namespace=""/></xsl:message>-->
+        <xsl:choose>
+            <xsl:when test=" contains($targetNamespace,'://')">
+                <xsl:value-of select="$system_cache__appinfo:vrtfNamespaces//ns[substring-after(@uri,'://')=substring-after($targetNamespace,'://') and @system_cache__appinfo:document-uri=$system_cache__appinfo:document-uri][1]/@prefix" xpath-default-namespace=""/>
+            </xsl:when>
+            <xsl:otherwise>
+                <xsl:value-of select="$system_cache__appinfo:vrtfNamespaces//ns[@uri=$targetNamespace and @system_cache__appinfo:document-uri=$system_cache__appinfo:document-uri][1]/@prefix" xpath-default-namespace=""/>
+            </xsl:otherwise>
+        </xsl:choose>
+        <xsl:message>#103 targetns another  try for <xsl:value-of select="$targetNamespace"/> todo count all <xsl:value-of select="count($system_cache__appinfo:vrtfNamespaces//ns)"/> / <xsl:value-of select="$system_cache__appinfo:vrtfNamespaces//node()[local-name()='ns' and @uri=$targetNamespace]/@*"/> </xsl:message>
+    </xsl:function>
+    
+    <xsl:function name="system_cache__appinfo:targetNamespace_from_prefix">
+        <xsl:param name="system_cache__appinfo:vrtfNamespaces" />
+        <xsl:param name="prefix" />
+        <xsl:value-of select="$system_cache__appinfo:vrtfNamespaces//ns[@prefix=$prefix][1]/@uri" xpath-default-namespace=""/>
+    </xsl:function>
+    
+    
+    <xsl:function name="system_cache__appinfo:get_default_db_obj_url_table_name"><!-- @2016-10 funkcja do wykrywania nazwy tabeli dla default db, w przypadku braku zgodnosci namespace - nic nie zwraca -->
+        <xsl:param name="parent_complexTypeNamespace" />
+        <xsl:variable name="uri_tokens" select="tokenize($parent_complexTypeNamespace,'/')"/>
+        <xsl:variable name="uri_tokens_count" select="count($uri_tokens)"/>
+        <xsl:if test="$uri_tokens[($uri_tokens_count - 1)]='table' and $uri_tokens[($uri_tokens_count - 2)]='default_db' and $uri_tokens[($uri_tokens_count - 3)]='wfs'">
+            <xsl:variable name="get_default_db_obj_url_table_name" select="tokenize($uri_tokens[$uri_tokens_count],'\.')"/>
+            <xsl:value-of select="$get_default_db_obj_url_table_name[1]"/>
+        </xsl:if>
+    </xsl:function>
+    
+    <xsl:function name="system_cache__appinfo:get_default_db_obj_url_schema"><!-- @2016-10 funkcja do wykrywania nazwy tabeli dla default db, w przypadku braku zgodnosci namespace - nic nie zwraca -->
+        <xsl:param name="parent_complexTypeNamespace" />
+        <xsl:variable name="system_cache__appinfo:get_default_db_obj_url_table_name" select="system_cache__appinfo:get_default_db_obj_url_table_name($parent_complexTypeNamespace)"/>
+        <xsl:choose>
+            <xsl:when test=" string-length($system_cache__appinfo:get_default_db_obj_url_table_name) &gt; 0">
+                <xsl:value-of select="concat($system_cache__appinfo:get_default_db_obj_url_table_name,'.xsd')"/>
+            </xsl:when>
+            <xsl:otherwise>
+                <xsl:message>#127 !!!! in (system_cache__appinfo:get_default_db_obj_url_schema) in functions.xsl TODO system objects etc... !!!!!!!!!!! </xsl:message>
+            </xsl:otherwise>
+        </xsl:choose>
+    </xsl:function>
+    
+    <xsl:function name="system_cache__appinfo:id.int.rand">
+        <xsl:param name="id"/><!-- like DYSTRYBUCJI___d4e7067-1_ID_PROJECT -->
+        <xsl:variable name="id.int" select="replace($id,'([a-z]|[A-Z]|_|-)','')"/>
+        <xsl:variable name="mod.10" select="(number($id.int)+string-length($id)) mod 10"/>
+        <xsl:variable name="mod.9" select="number($id.int) mod 9"/>
+        <xsl:variable name="mod.8" select="number($id.int) mod 8"/>
+        <xsl:value-of select="concat(1,$mod.10,$mod.9,$mod.8)"/>
+    </xsl:function>
+    <!--<xsl:function name="system_cache__appinfo:php_function_name_from_obj_with_prefix">
+        <xsl:param name="object_name" required="yes"/>
+        <xsl:value-of select="replace($object_name,':','__x3A__')"/>
+    </xsl:function>-->
+    
+    
+</xsl:stylesheet>

+ 37 - 0
SE/schema/default_db_xml_cache.public/xinclude_p5_recurse/xinclude_p5_recurse.xsd

@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified"
+  targetNamespace="http://biuro.biall-net.pl/xmlschema_procesy5/default_db_xml_cache.public/xinclude_p5_recurse/xinclude_p5_recurse.xsd"
+  xmlns:xp5r="http://biuro.biall-net.pl/xmlschema_procesy5/default_db_xml_cache.public/xinclude_p5_recurse/xinclude_p5_recurse.xsd">
+  <xs:element name="cache">
+    <xs:complexType>
+      <xs:sequence>
+        <xs:element ref="xp5r:apply-template"/>
+      </xs:sequence>
+      <xs:attribute name="basedir" use="required" form="qualified" type="xs:NMTOKEN"/>
+      <xs:attribute name="id" use="required" form="qualified" type="xs:NCName"/>
+    </xs:complexType>
+  </xs:element>
+  <xs:element name="context-node">
+    <xs:complexType>
+      <xs:attribute name="type" use="required" type="xs:NMTOKEN"/>
+    </xs:complexType>
+  </xs:element>
+  <xs:element name="apply-template">
+    <xs:complexType>
+      <xs:sequence>
+        <xs:element ref="xp5r:context-node"/>
+        <xs:element maxOccurs="unbounded" ref="xp5r:with-param"/>
+      </xs:sequence>
+      <xs:attribute name="mode" use="required"/>
+    </xs:complexType>
+  </xs:element>
+  <xs:element name="with-param">
+    <xs:complexType>
+      <xs:simpleContent>
+        <xs:extension base="xs:anyURI">
+          <xs:attribute name="name" use="required" type="xs:NMTOKEN"/>
+        </xs:extension>
+      </xs:simpleContent>
+    </xs:complexType>
+  </xs:element>
+</xs:schema>

+ 127 - 0
SE/schema/default_db_xml_cache.public/xinclude_p5_recurse/xinclude_p5_recurse.xsl

@@ -0,0 +1,127 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+    xmlns:xs="http://www.w3.org/2001/XMLSchema"
+    xmlns:system_cache__appinfo="http://biuro.biall-net.pl/xmlschema_procesy5/default_db_xml_cache/appinfo.xsd"
+    xmlns:xp5r="http://biuro.biall-net.pl/xmlschema_procesy5/default_db_xml_cache.public/xinclude_p5_recurse/xinclude_p5_recurse.xsd"
+    exclude-result-prefixes="xs"
+    version="2.0">
+    
+    <xsl:output indent="yes" />
+    <xsl:strip-space elements="*"/>
+    
+    <xsl:include href="../../build_SE_basedir/build_SE.properties.xml.xsl"/>
+    <xsl:include href="../system_cache__appinfo/escape_functions.xsl"/>
+    
+    <xsl:import-schema namespace="http://biuro.biall-net.pl/xmlschema_procesy5/default_db_xml_cache.public/xinclude_p5_recurse/xinclude_p5_recurse.xsd" schema-location="xinclude_p5_recurse.xsd"/>
+    
+    
+    <xsl:include href="../system_cache__appinfo/basedir.xsl"/><!-- for <xsl:param name="basedir" required="yes"/> -->
+    <xsl:include href="../system_cache__appinfo/default_db.instance.xml.xsl"/> <!-- for param name="default_db.instance.xml" required="yes" file:/Users/a.binder/Documents/xmlschema_procesy5/src-xmlschema/public_html/default_db.instance.xml/ -->
+    
+    <xsl:template match="xp5r:cache" mode="xp5r:verify"/><!-- Todo to verify integrity -->
+    
+    <xsl:template match="xp5r:cache" >
+        <xp5r:cache>
+            <xsl:attribute name="mode" select="'default'"/>
+
+            <xsl:variable name="xp5r:cache_dir">  <!-- to detect params to save or read -->
+                <xsl:apply-templates mode="xp5r:cache_dir" select="."/>
+            </xsl:variable>
+            <xsl:choose>
+                <xsl:when test=" doc-available($xp5r:cache_dir)">
+                    <xsl:message>#47-A $xp5r:cache_dir aviable at <xsl:value-of select="$xp5r:cache_dir"/></xsl:message>
+                    <xsl:comment>
+                        #47-A $xp5r:cache_dir aviable at <xsl:value-of select="$xp5r:cache_dir"/></xsl:comment>
+                    <xsl:copy-of select="doc($xp5r:cache_dir)"/>
+                </xsl:when>
+                <xsl:otherwise>
+                    <xsl:message>#47-B $xp5r:cache_dir NOT aviable at <xsl:value-of select="$xp5r:cache_dir"/></xsl:message>
+                    <xsl:comment>
+                        #47-B $xp5r:cache_dir NOT aviable at <xsl:value-of select="$xp5r:cache_dir"/></xsl:comment>
+                    TODO to generate xslt to evaluate this cache and make ant build  - paraller?
+                    
+                </xsl:otherwise>
+            </xsl:choose>
+        </xp5r:cache>
+    </xsl:template><!-- Todo to read normally data as regular file -->
+    
+    
+    <xsl:template match="xsl:stylesheet" mode="xp5r:xslt.params"/> <!-- to parse stylesheets relations to retrieve expected params to make ant build to postprocess -->
+    
+    <!--<xsl:function name="xp5r:cache_dir">
+        <xsl:param name="xp5r:apply-template.mode"/>
+        <xsl:param name="xp5r:id"/>
+        <xsl:param name="xp5r:basedir"/>
+    </xsl:function>-->
+    
+    <xsl:template mode="xp5r:cache_dir" match="xp5r:cache">
+        <xsl:value-of select="$default_db.instance.xml"/><xsl:text>/xinclude_p5_recurse/</xsl:text>
+        <xsl:value-of select="system_cache__appinfo:translate_object_escaped_prefix_from_string(xp5r:apply-template/@mode)"/>
+        <xsl:value-of select="system_cache__appinfo:translate_object_escaped_prefix_from_string(xp5r:apply-template/@name)"/>
+            <xsl:value-of select="'/'"/><xsl:value-of select="@xp5r:id"/>
+        <xsl:apply-templates mode="xp5r:cache_dir"/>
+    </xsl:template>
+    
+    <xsl:template mode="xp5r:cache_dir" match="xp5r:apply-template">
+        <xsl:apply-templates mode="xp5r:cache_dir"/>
+    </xsl:template>
+    
+    <xsl:template mode="xp5r:cache_dir" match="xp5r:context-node">
+        <xsl:apply-templates mode="xp5r:cache_dir" select="@*"/>
+    </xsl:template>
+    
+    <xsl:template mode="xp5r:cache_dir" match="xp5r:with-param">
+        <xsl:apply-templates mode="xp5r:cache_dir" select="@*"/>
+        <xsl:if test="text()">
+            <xsl:value-of select="system_cache__appinfo:escape_object_prefix_to_string(substring(text(),1,10))"/>
+        </xsl:if>
+    </xsl:template>
+    
+    
+    <xsl:template match="@*" mode="xp5r:cache_dir">
+        <xsl:value-of select="system_cache__appinfo:translate_object_escaped_prefix_from_string(name())"/>
+    </xsl:template>
+    
+    
+    
+    <!-- to create instance of xp5r:cache in some xml templates @2018-01-01 -EOF -->
+    
+   <!-- <xsl:template match="apply-template" mode="xp5r:cache" xpath-default-namespace="http://www.w3.org/1999/XSL/Transform">
+        <xp5r:cache xp5r:id="{generate-id(../.)}" xp5r:basedir=".">
+            <xp5r:apply-template mode="system_cache__appinfo:build_flat_schema">
+            <xsl:apply-templates mode="xp5r:cache" select="@*"/>
+            <xsl:apply-templates mode="xp5r:cache"/>
+            </xp5r:apply-template>
+        </xp5r:cache>
+    </xsl:template>
+    
+        <xsl:template match="select" mode="xp5r:cache"> <!-\- if select is given -\->
+            <xsl:copy-of select="."/>
+        </xsl:template>
+        <xsl:template match="context-node" mode="xp5r:cache"> <!-\- if select is given -\->
+            <xsl:copy-of select="."/>
+        </xsl:template>
+    
+            <xsl:template match="with-param" mode="xp5r:cache" xpath-default-namespace="http://www.w3.org/1999/XSL/Transform">
+                <xp5r:with-param>
+                    <xsl:apply-templates mode="xp5r:cache" select="@*"/>
+                    <xsl:apply-templates mode="xp5r:cache.with-param"/>
+                </xp5r:with-param>
+            </xsl:template>
+    
+            <xsl:template match="node()" mode="xp5r:cache.with-param">
+                <xsl:copy-of select="node()"/>
+            </xsl:template>
+    
+        <xsl:template match="@mode|@name" mode="xp5r:cache" xpath-default-namespace="http://www.w3.org/1999/XSL/Transform">
+            <xsl:copy-of select="."/>
+        </xsl:template>
+    
+        <xsl:template match="@*" mode="xp5r:cache" xpath-default-namespace="http://www.w3.org/1999/XSL/Transform"/>
+        
+    -->
+    
+    <!-- -EOF to create instance of xp5r:cache in some xml templates @2018-01-01 -->
+    
+    
+</xsl:stylesheet>

+ 17 - 0
SE/schema/default_db_xml_cache.public/xinclude_p5_recurse/xinclude_p5_recurse_example.xml

@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<xp5r:cache xmlns:xp5r="http://biuro.biall-net.pl/xmlschema_procesy5/default_db_xml_cache.public/xinclude_p5_recurse/xinclude_p5_recurse.xsd"
+    xp5r:id="d8e94012"
+    xp5r:basedir=".">
+    
+    <xp5r:apply-template mode="system_cache__appinfo:build_flat_schema">
+        <xp5r:context-node type="wsbpel:tDocumentation"/>
+        <xp5r:with-param name="path">http://docs.oasis-open.org/wsbpel/2.0/process/executable/wsbpel:tActivityContainer/w___d7e94151-1_tActivityC//w___d7e94004-1_tExtensibl//w___d7e94009-1//w___d7e94012-1_documentat/</xp5r:with-param>
+        <xp5r:with-param name="prefix">wsbpel</xp5r:with-param>
+        <xp5r:with-param name="targetNamespace">http://docs.oasis-open.org/wsbpel/2.0/process/executable</xp5r:with-param>
+        <xp5r:with-param name="restriction_base"/>
+        <xp5r:with-param name="xpath_local"/>
+        <xp5r:with-param name="restriction_path">/element:documentation/</xp5r:with-param>
+        <xp5r:with-param name="system_cache__appinfo:root_element_in_schema">true</xp5r:with-param>
+        <xp5r:with-param name="recurse">0</xp5r:with-param>
+    </xp5r:apply-template>
+</xp5r:cache>