The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

RDF::RDFa::Template::Document - A parsed Template document

SYNOPSIS

  my $parser = RDF::RDFa::Parser->new($self->{RAT}, 'http://example.org/foo/', 
                                      {
                                       use_rtnlx => 1,
                                       graph => 1,
                                       graph_type => 'about',
                                       graph_attr => '{http://example.org/graph#}graph',
                                      });
  $parser->consume;
  my $doc = RDF::RDFa::Template::Document->($parser);
  $doc->extract;

METHODS

It implements the following methods:

new

The constructor. An RDF::RDFa::Parser object is a required argument.

extract

Extracts the Basic Graph Patterns from the parsed document. Returns the number of patterns extracted.

unit( $graph_name )

Returns a RDF::RDFa::Template::Unit for the specified graph name.

units

Returns an array of RDF::RDFa::Template::Unit objects

dom

Return an XML::LibXML::Document of the parsed source document.

AUTHOR

Kjetil Kjernsmo, <kjetilk at cpan.org>

COPYRIGHT & LICENSE

Copyright 2010 Kjetil Kjernsmo.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.