GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages


Manual Reference Pages  -  RDF::CORE::PARSER (3)

.ds Aq ’

NAME

RDF::Core::Parser - RDF Parser

CONTENTS

DESCRIPTION

A module for parsing XML documents containing RDF data. It’s based on XML::Parser. Parser goes through XML and calls what is referenced in Assert option for each statement found. CAUTION: If you parse more documents into one model, you need to set distinct BNodePrefix (see below) for each document. This way you avoid mixing anonymous resources from distinct documents together.

SYNOPSIS



  require RDF::Core::Parser;

  my %options = (Assert => \&handleAssert,
                 BaseURI => "http://www.foo.com/",
                 BNodePrefix => "genid"
                );
  my $parser = new RDF::Core::Parser(%options);
  $parser->parseFile(./rdfFile.xml);
  #or
  $parser->parse($rdfString);



    Interface

o new(%options)

Available options are
o Assert

A reference to a subroutine, that is called for every assertion that parser generates.

o BaseURI

A base URI of parsed document. It will be used to resolve relative URI references.

o BNodePrefix

Blank node identifier is generated as _: concatenated with BNodePrefix value concatenated with counter number. Default BnodePrefix is a.

o InlineURI

Deprecated.

o parse($string)
o parseFile($fileName)

    Assert handler

Assert handler is called with key value pairs in a parameters array.

Keys are:
o subject_ns, subject_name, subject_uri

namespace, local value and URI of subject

o predicate_ns, predicate_name, predicate_uri

namespace, local value and URI of predicate

o object_ns, object_name, object_uri

namespace, local value and URI of object, if the object is a resource

or

o object_literal, object_lang, object_datatype

object value for literal, it’s language and datatype

LICENSE

This package is subject to the MPL (or the GPL alternatively).

AUTHOR

Ginger Alliance, rdf@gingerall.cz

SEE ALSO

RDF::Core::Model::Parser
Search for    or go to Top of page |  Section 3 |  Main Index


perl v5.20.3 RDF::CORE::PARSER (3) 2006-07-14

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.