RDF::Server::Semantic::Atom - RDF service with Atom-ic semantics
package My::Server; semantic 'Atom'; --- my $server = My::Server -> new( handler => [ workspace => { collections => [ { entry_handler => { }, categories => [ ] } ] ] );
The Atom semantic module modifies the server configuration by adding an ArrayRef to Handler coercion that allows configuration from plain text files without Perl code. The Atom semantic assumes a heirarchy of document types: Services :> Workspaces :> Collections :> Categories :> Entries. Collections can also manage Entries without Categories.
The top-level handler can be any of the available Atom document types, but sub-handlers are expected to be the proper child type.
The Atom semantic allows you to configure the top-level handler by setting it to an array reference. The semantic will coerce it into the proper set of objects working within the Atom semantic space.
The top level handler should be one of service, workspace, or collection. You can also use category, but categories are of limited use at the top level.
service
workspace
collection
category
The Atom specification defines a clear heirarchy of documents: services contain workspaces, workspaces contain collections, and collections contain categories and entries.
A service is a collection of workspaces.
The Atom semantic defines a subtype of the Handler type and a coercion that uses build_atomic_handler. This method manages the conversion from an array reference to a handler object appropriate for the server's interface role.
If you subclass the Atom semantic, you will need to provide additional classes for Service, Workspace, Collection, and Category. For example, if you create My::Semantic, then you will also need to create My::Semantic::Service, My::Semantic::Workspace, etc. These can be subclasses of the equivalent classes provided by the stock Atom semantic.
This method assumes the following relationships in the configuration being coerced:
Handler Type Child Type Entries Child Configuration ------------ ---------- ------- ------------------- service workspace workspaces workspace collection collections collection category X categories category X
RDF::Server::Style::Atom::Service, RDF::Server::Style::Atom::Workspace, RDF::Server::Style::Atom::Collection, RDF::Server::Style::Atom::Category
James Smith, <jsmith@cpan.org>
<jsmith@cpan.org>
Copyright (c) 2008 Texas A&M University.
This library is free software. You can redistribute it and/or modify it under the same terms as Perl itself.
To install RDF::Server, copy and paste the appropriate command in to your terminal.
cpanm
cpanm RDF::Server
CPAN shell
perl -MCPAN -e shell install RDF::Server
For more information on module installation, please visit the detailed CPAN module installation guide.