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

NAME

RDF::LinkedData - Linked Data implementation default class

VERSION

Version 0.12

SYNOPSIS

A simple Plack server illustrates the usage nicely:

  use RDF::LinkedData;
  use Plack::Request;
  use RDF::Trine;

  $linked_data = sub {
    my $env = shift;
    my $req = Plack::Request->new($env);
    my $parser = RDF::Trine::Parser->new( 'turtle' );
    my $model = RDF::Trine::Model->temporary_model;
    my $base_uri = 'http://localhost:5000';
    $parser->parse_file_into_model( $base_uri, 't/data/basic.ttl', $model );
    my $ld = RDF::LinkedData->new(model => $model, base=>$base_uri);
    my $uri = $req->path_info;
    if ($req->path_info =~ m!^(.+?)/?(page|data)$!) {
        $uri = $1;
        $ld->type($2);
    }
    $ld->headers_in($req->headers);
    return $ld->response($uri)->finalize;
  }

METHODS

This module simply uses the default implementation in RDF::LinkedData::ProviderRole, and does nothing on its own.

AUTHOR

This module was started by by Gregory Todd Williams <gwilliams@cpan.org> for RDF::LinkedData::Apache, but heavily refactored and rewritten by Kjetil Kjernsmo, <kjetilk@cpan.org>

BUGS

Please report any bugs or feature requests to bug-rdf-linkeddata at rt.cpan.org, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=RDF-LinkedData. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.

WARNING

Do not rely in the current API unless you are planning to keep track of the development of this module. It is still very much in flux, and may change without warning!

SUPPORT

You can find documentation for this module with the perldoc command.

    perldoc RDF::LinkedData

The perlrdf mailing list is the right place to seek help and discuss this module:

http://lists.perlrdf.org/listinfo/dev

You can also look for information at:

ACKNOWLEDGEMENTS

COPYRIGHT & LICENSE

Copyright 2010 Gregory Todd Williams and ABC Startsiden AS.

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