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

NAME

MooseX::Semantic::Role::Resource - Handle Moose objects as RDF resources

SYNOPSIS

    package My::Model::Person;
    with qw(MooseX::Semantic::Role::Resource);
    1;

    package main;
    my $p = My::Model::Person->new(
        rdf_about => 'http://someone.org/#me'
    );

ATTRIBUTES

rdf_about

The URI of the resource this object represents. When not specified, this defaults to a random urn:UUID URI.

METHODS

is_blank

Delegation to RDF::Trine::Node. Returns a true value if the rdf_about node is a blank node.

is_resource

Delegation to RDF::Trine::Node. Returns a true value if the rdf_about node is a resource node.

is_auto_generated

Returns true value if the 'rdf_about' attribute was aut-generated, false if it has been explicitly set (at constructor time or using the 'rdf_about' accessor)

AUTHOR

Konstantin Baierer (<kba@cpan.org>)

SEE ALSO

MooseX::Semantic

LICENCE AND COPYRIGHT

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

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.