ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Conelly, Luis (GNF, Contractor)" <Luis.Cone...@gnf.com>
Subject RE: xmlvalidate task and external catalogs
Date Tue, 06 Apr 2004 00:34:59 GMT
Which error you get? ClassNotFound or some stuff like that? Can you provide more info?

-Luis

PS. Not pretty sure, but line:

<pathelement location="d:\sandbox\realms\realmsPublisher\resources\schema\catalog.xml"/>

might work better if you change backslashes to slashes (\ to /) or use double backslash (\\)

Regards

-----Original Message-----
From: Jeremy Aston [mailto:jez@pigbite.com]
Sent: Monday, April 05, 2004 7:32 PM
To: user@ant.apache.org
Subject: xmlvalidate task and external catalogs


Hi,
Can anyone pls tell me how to get xmlvalidate (in 1.6) to see external
catalogs. I can see from the docs that for this to work v1.1 of xml-commons
resolver.jar must be on the classpath but I cannot get it working. I have
put a reference to the jar on my system environment classpath (win xp btw),
as a lib argument on the cmd line and as a classpath element inside the
xmlvalidate task. All to no avail... I've also copied the jar into ant/lib
as well for good measure! What am I doing wrong?
This is my build.xml complete with it's extra classpath stuff ;-)

<project name="contentproject" default="validate">
  <property name="src.dir" value="src/content/xml/sample"/>
  <xmlcatalog id="adl">
    <catalogpath>
      <pathelement
location="d:\sandbox\realms\realmsPublisher\resources\schema\catalog.xml"/>
    </catalogpath>
  </xmlcatalog>
  <target name="validate" description="Validate structure files">
    <xmlvalidate
      failonerror="no"
      lenient="no"
      warn="yes"
      file="${src.dir}/structure.xml"
      classname="org.apache.xerces.parsers.SAXParser">
      <classpath>
        <fileset dir="d:/java/xerces-2_6_2/">
          <include name="x*.jar"/>
        </fileset>
        <fileset dir="d:/java/xml-commons-resolver-1.1/">
          <include name="*.jar"/>
        </fileset>
      </classpath>
      <attribute name="http://apache.org/xml/features/validation/schema"
value="true"/>
      <xmlcatalog refid="adl"/>
    </xmlvalidate>
  </target>
</project>

Brgds and tia
Jeremy



---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message