NAME

XML::RDDL - Interface to RDDL (http://www.rddl.org/)

SYNOPSIS

use XML::RDDL;
use MySAX2Driver;

my $handler = XML::RDDL->new(
                              default_lang     => 'en',
                              default_base_uri => 'http://foo/doc.xml',
                            );
my $driver = MySAX2Driver->new(Handler => $handler);
my $rddl = $driver->parse($some_rddl);

DESCRIPTION

RDDL (Resource Directory Description Language) is an XML vocabulary used to described resources associated with a namespace. It can be embedded inside other XML vocabularies (most frequently XHTML).

This module is meant to be used as a SAX2 handler that will return a Directory instance containing all resource descriptions at the end of the parse.

If you don't know where to find a SAX2 parser, you may wish to use either XML::SAX::Expat, XML::SAX::PurePerl, or XML::Filter::SAX1toSAX2 provided they are on CPAN when you read this. If they are not, or if they seem too alpha, you might want to grab the versions available from:

http://berjon.com/perl/XML-SAX-Expat-0.01.tar.gz
(requires http://berjon.com/perl/XML-NodeFactory-SAX2-0.01.tar.gz)
http://hampton.ws/download/files/XML-Filter-SAX1toSAX2-0.11.tar.gz
(requires http://hampton.ws/download/files/XML-Filter-Base-0.21.tar.gz)

The best, until the said versions are released to CPAN, is to keep up to date with the perl-xml list.

METHODS

XML::RDDL->new(%options)

Creates an XML::RDDL instance which is a SAX2 handler. The options are:

- default_lang
  the default language (as described in an xml:lang attribute) to
  be used. It is recommended that this be used if you want to have
  multilingual resources and your document doesn't contain
  sufficient xml:lang attributes.

- default_base_uri
  the default base URI (as described in an xml:base attribute) to
  be used (principally in xlink:href resolution). It is recommended
  that this be used if you want to resolve the xlink:hrefs and the
  document doesn't contain the appropriate xml:base attributes.

AUTHOR

Robin Berjon, robin@knowscape.com

COPYRIGHT

Copyright (c) 2001 Robin Berjon. All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

SEE ALSO

http://www.rddl.org/, XML::RDDL::Directory, XML::RDDL::Resource, XML::RDDL::Driver