Re: Help with validating XML (DTD or Schema) with PERL



On Jun 25, 5:06 pm, 1234mar...@xxxxxxxxx wrote:
Can someone tell me if a reliable production PERL package was ever
created to handle either W3C DTD or Schema standards? I realize
libxml2 based packages are very good, but I am not willing to tackle
the maintenance required for compiled libxml2 program in our
production environment.

It is the year 2007 for heavens sake; did anyone ever create something
other than poorly tested, partial W3C standards, barely usable module
to handle DTD or Schemas? I have been search CPAN and tested modules
franticly for months without finding anything that is good (other than
lidxml2 stuff looks good).
I've said as much before on this group but, .....

Amongst the many things I've happily & successfully done with Perl &
CPAN modules in the last 15 years
or so, parsing XML is not one. Pickup "Java & XML" by O'Reilly, and
with little background in the
language you'll probably be able to solve your problem in hours.

Perl SHOULD be good at this sort of thing (and as others have
suggested, the Perl community would love some
help on this, I'm sure) but issues w/ recursion and lack of an
adequate threading model seem to put it
at a disadvantage vis a vis Java, in my opinion, for tasks like this,
while one of Perl's great
strengths over Java (built-in regular expression matching) are
somewhat wasted on data as structured as XML.

If you don't want to re-invent Perl wheels here, and can't or don't
want to use Java, why not go back
to VB (if you're running on Windows only)?

I've had to write my own lexers & parsers for even the lightest of XML
tasks in Perl. As good as it
is for other things, XML seems to be an Achilles heel.

Keith
------
"If all you have is a hammer, everything's a nail"





I am using XML::SAX::ParserFactory (PurePerl) as my parser and
original thought I would easily find a FILTER to handle DTD or Schema
validation; instead after months of reseach, I find myself pleading
for help in the newsgroup. Perl is really treating me bad for this
XML project; I did a similar project with VB6 and it was a breeze.

Anyway, right now I am trying to test XML-DTD-0.06. However the
documentation is gibberish, it keeps referring to $rt without
explaining what $rt is...omg!!! If someone has a working example of
using XML-DTD-0.06, I would love to see it.

Thank you in advance for any guidance you can give me!!!!!!


.



Relevant Pages

  • [ANN] New XML Editor in Visual Studio 2005 Beta 1
    ... Full syntax coloring for all XML and DTD syntax. ... Intellisense based on any DTD, ... Schema picker dialog for overriding schemas used for validation, which is then remembered as a document property in your solution. ... Goto Definition command for navigating between elements and their associated DTD, XDR or XSD schema definitions. ...
    (microsoft.public.dotnet.xml)
  • Re: my first xml schema - I think its good. Is it really?
    ... The current recommendations are either to use just enough of a DTD to provide those and to use schema for the rest, or to use some other macro facility or to define tags for the purpose. ... XML was rushed into use before it was stable. ... but we didn't have that luxury; in order for XML to win acceptance as quickly as it did, it had to be rolled out in stages, syntax first. ...
    (comp.text.xml)
  • Validating XML against a DTD that is not supplied in the XML Schema
    ... I'm talking the problem of trying to validate whether a rss xml feed ... is well formed - i.e corresponds to the DTD and xml schema ... Sometimes a schema is referenced, ...
    (comp.lang.java.programmer)
  • Re: Need opinion on DTD design
    ... I would recommend looking into using a schema language (XML Schema, ... Relax NG) instead of a DTD. ... <!ELEMENT Gasoline EMPTY> ...
    (comp.text.xml)
  • Re: Need opinion on DTD design
    ... I would recommend looking into using a schema language (XML Schema, ... Relax NG) instead of a DTD. ... <!ELEMENT Gasoline EMPTY> ...
    (comp.text.xml)