build_object_modeling.xml 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <project basedir="../../." name="object_modeling" default="system_cache__appinfo:new_object_by_prototype"
  3. xmlns:system_cache__appinfo="http://biuro.biall-net.pl/xmlschema_procesy5/default_db_xml_cache/appinfo.xsd">
  4. <description>
  5. TO model objects capabilities
  6. </description>
  7. <!-- modules WPS_Functions - to be copied to any module needed -->
  8. <property name="WPS_Functions" location="${basedir}/WPS_Functions"/>
  9. <property name="build_WPS_Functions.xml" location="${WPS_Functions}/build_WPS_Functions.xml"/> <!-- call it to get properties -->
  10. <property name="build_WPS_Functions.xml.properties" location="${build_WPS_Functions.xml}.properties"/>
  11. <!-- eof modules WPS_Functions -->
  12. <property name="object_modeling_basedir" location="${basedir}/WPS_Functions/${ant.project.name}" />
  13. <property name="build_object_modeling.childproperties" location="${WPS_Functions.childproperties}/build_object_modeling.properties"/>
  14. <!--<property name="object_modeling_build" location="${object_modeling_basedir}/build_object_modeling.xml" />-->
  15. <property name="public_html" location="${basedir}" />
  16. <property name="root_build.xml" location="${public_html}/build.xml"/>
  17. <!--<property name="build_properties.xml" location="${public_html}/build_properties.xml" />-->
  18. <property name="object_modeling.xsl" location="${public_html}/default_db_xml_cache.public/object_modeling.xsl"/>
  19. <property name="build_properties" location="${public_html}/build_properties" />
  20. <property name="targetNamespace.base" value="${targetNamespace.base}"/> <!-- to be set by WPS_Functions/object_modeling_build_infrastructure/temp/build_object_modeling_build_infrastructure_child.xml -->
  21. <!-- <property name="table.local" location="${public_html}/table"/>
  22. <property name="transformed.local" location="${default_db.instance.xml}/transformed"/>
  23. <property name="procesy5_system_schema.xml" value="${transformed.local}/procesy5_system_schema.xml"/>
  24. -->
  25. <target name="write_child_props_to_config_dir" depends="read_build_properties">
  26. <echoproperties destfile="${build_object_modeling.childproperties}"/>
  27. </target>
  28. <target name="read_build_properties">
  29. <!-- <ant antfile="${root_build.xml}" target="save_build_properties"/>
  30. <loadproperties srcfile="${build_properties}"/>-->
  31. <ant antfile="${build_WPS_Functions.xml}" target="save_build_properties"/>
  32. <loadproperties srcfile="${build_WPS_Functions.xml.properties}"/>
  33. <property name="new_object_by_prototype.xml" value="${transformed.local}/system_cache__appinfo/new_object_by_prototype.xml"/>
  34. <echo>We try to refresh ${default_db.xml} or ${detect_objects_parent_relations.xsl} or ${procesy5_system_schema.xml}</echo>
  35. </target>
  36. <target name="system_cache__appinfo:new_object_by_prototype" depends="read_build_properties" description="ANT_TARGET new object by using prototype from Types" >
  37. <input addproperty="prototype_object_namespace" /> <!-- https://biuro.biall-net.pl/wfs/default_db/Types/Infrastructure.xsd -->
  38. <input addproperty="new_object_namespace" /> <!-- https://biuro.biall-net.pl/wfs/default_db/table/Rozdzielcza_struktura_wewnetrzna_wsg84.xsd -->
  39. <ant antfile="${root_build.xml}" target="procesy5_system_schema.xml_if_not_exists" />
  40. <echo> #50
  41. object_modeling_basedir= ${object_modeling_basedir}
  42. procesy5_system_schema.xml= ${procesy5_system_schema.xml}
  43. generating from ${prototype_object_namespace}
  44. generating to ${new_object_namespace}
  45. generating grom base
  46. targetNamespace.base ${targetNamespace.base}
  47. object_modeling.Error.Handling = ${object_modeling.Error.Handling}
  48. NamespaceObjectInstanceTable = ${NamespaceObjectInstanceTable}
  49. </echo>
  50. <delete file="${new_object_by_prototype.xml}"/>
  51. <xslt basedir="./" style="${object_modeling.xsl}" in="${procesy5_system_schema.xml}" destdir="./" out="${new_object_by_prototype.xml}" force="yes" >
  52. <factory name="net.sf.saxon.TransformerFactoryImpl">
  53. <attribute name="http://saxon.sf.net/feature/xinclude-aware" value="true"/>
  54. <attribute name="http://saxon.sf.net/feature/initialMode" value="{http://biuro.biall-net.pl/xmlschema_procesy5/default_db_xml_cache/appinfo.xsd}new_object_by_prototype"/>
  55. </factory>
  56. <param name="prototype_object_namespace" expression="${prototype_object_namespace}"/>
  57. <param name="new_object_namespace" expression="${new_object_namespace}"/>
  58. <param name="procesy5_system_schema_collection_dir" expression="${public_html}"/>
  59. <param name="external_schema_table.path" expression="${external_schema_table.path}"/>
  60. <param name="targetNamespace.base" expression="${targetNamespace.base}"/>
  61. <param name="object_modeling_build" expression="${object_modeling_build}"/>
  62. <param name="default_db.instance.xml" expression="${default_db.instance.xml}"/>
  63. <param name="object_modeling.Error.Handling" expression="${object_modeling.Error.Handling}"/>
  64. <param name="NamespaceObjectInstanceTable" expression="${NamespaceObjectInstanceTable}"/>
  65. <param name="vrtfNamespaces.xml" expression="${vrtfNamespaces.xml}"/>
  66. <classpath location="/opt/local/share/java/saxon9he.jar"/>
  67. </xslt>
  68. <!--<loadfile property="new_object_by_prototype.xml_result" srcfile="${new_object_by_prototype.xml}"/>
  69. <echo message="${new_object_by_prototype.xml_result}"/>-->
  70. </target>
  71. </project>