Problem to use a catalog with ANT script
Posted: Thu Nov 26, 2015 4:51 pm
Hello,
I would like to use a XML catalog in my ANT script. See below an extract of my script :
I tried to put the acces to resolver but it didn't work. I have always this message "Warning: XML resolver not found; external catalogs will be ignored"
See below the complete trace of my script :
Thank you for your help
I would like to use a XML catalog in my ANT script. See below an extract of my script :
Code: Select all
<xmlvalidate failonerror="yes" lenient="no" warn="yes"
classname="org.apache.xerces.parsers.SAXParser">
<classpath location="../tools/xercesImpl.jar"/>
<classpath location="../apache-ant-1.9.6/lib/ant-apache-resolver.jar"/>
<fileset dir="${outdir}" includes="*.ata"/>
<!--<property name="http://apache.org/xml/properties/schema/external-noNamespaceSchemaLocation"
value="${xsd.file}"/>-->
<attribute name="http://apache.org/xml/features/validation/schema" value="true"/>
<attribute name="http://xml.org/sax/features/namespaces" value="true"/>
<xmlcatalog>
<catalogpath path="..\catalog.xml" location="..\catalog.xml"/>
</xmlcatalog>
</xmlvalidate>
See below the complete trace of my script :
Code: Select all
Executing:
"c:\mesprogrammes\oxygen xml editor 16\jre/bin/java" -Xmx256m -classpath "C:\Mesprogrammes\Oxygen XML Editor 16\tools\ant/lib/ant-launcher.jar" "-Dant.home=C:\Mesprogrammes\Oxygen XML Editor 16\tools\ant" org.apache.tools.ant.launch.Launcher -lib "C:\Mesprogrammes\Oxygen XML Editor 16\tools\ant\lib\ant-apache-resolver.jar" -f "S1000d2Ata.xml" "-Dmanuel=ESM" "-Dwebhelp.trial.license=no"
Buildfile: C:\Users\jvanhille\Documents\SNECMA\03-DEVELOPPEMENT\INDIGO\BATCHConverter\build\S1000d2Ata.xml
[echo] DEBUT C:\Users\jvanhille\Documents\SNECMA\03-DEVELOPPEMENT\INDIGO\BATCHConverter\DATA\INPUT_ESM
[xslt] Transforming into C:\Users\jvanhille\Documents\SNECMA\03-DEVELOPPEMENT\INDIGO\BATCHConverter\DATA\OUTPUT_ESM
Warning: XML resolver not found; external catalogs will be ignored
[xmlvalidate] C:\Users\jvanhille\Documents\SNECMA\03-DEVELOPPEMENT\INDIGO\BATCHConverter\DATA\OUTPUT_ESM\procedure_DMC-LEAP-1C-722413-01A-250A-C_000-01_SX-US_DELETED.ata:1:480: schema_reference.4: Failed to read schema document 'http://www.snecma.com/techpub/schemas/ata/em.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
[xmlvalidate] C:\Users\jvanhille\Documents\SNECMA\03-DEVELOPPEMENT\INDIGO\BATCHConverter\DATA\OUTPUT_ESM\procedure_DMC-LEAP-1C-722413-01A-250A-C_000-01_SX-US_DELETED.ata:1:480: cvc-elt.1: Cannot find the declaration of element 'task'.
[xmlvalidate] C:\Users\jvanhille\Documents\SNECMA\03-DEVELOPPEMENT\INDIGO\BATCHConverter\DATA\OUTPUT_ESM\procedure_DMC-LEAP-1C-722413-01A-250A-C_000-01_SX-US_DELETED.ata:1:480: schema_reference.4: Failed to read schema document 'http://www.snecma.com/techpub/schemas/ata/em.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
[xmlvalidate] C:\Users\jvanhille\Documents\SNECMA\03-DEVELOPPEMENT\INDIGO\BATCHConverter\DATA\OUTPUT_ESM\procedure_DMC-LEAP-1C-722413-01A-250A-C_000-01_SX-US_DELETED.ata:1:480: schema_reference.4: Failed to read schema document 'http://www.snecma.com/techpub/schemas/ata/em.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
The process finished with exit code: 1