NAME
Net::OAI::ORE::Constant - Module providing constants used by OAI-ORE Resource Map objects
EXPORTED CONSTANTS
The following constants may be imported either individually or using the tags show:
ORE_PREFIX DC_PREFIX DCT_PREFIX RDF_PREFIX (tag: prefix)
ORE_NS DC_NS DCT_NS RDF_NS (tag: ns)
RESOURCE_MAP AGGREGATION (tag: entity)
DESCRIBES AGGREGATES AGGREGATED_BY HAS_TYPE CREATOR CREATED RIGHTS MODIFIED (tag: rel)
RESOURCE LITERAL (tag: internal)
QUIET WARN FATAL RECKLESS ERROR_LEVEL (tag: err)
for example, to use MODIFIED and other relationships one might want to import as:
use Net::OAI::ORE::Constant qw(:rel);
print "The uri for modified time is ".MODIFIED."\n";
EXPORTED SUBROUTINES
namespace_and_name($element)
FIXME - should probably change all the constants here to use "Clarkian" notation for namespace and element name {ns}name.
expand_qname
Will attempt to expand an input resource matching the qname syntax ([a-z]+:\w+) to a full URI if the prefix is known. Otherwise string left unchanged. It should be safe the call this expansion on something that it either a qname or a URI because a URI will not match the pattern AND the prefixes defined here do not correspond to URI schemes.
See also http://www.w3.org/TR/REC-xml-names/#NT-QName
COPYRIGHT & LICENSE
Copyright 2007-2010 Simeon Warner.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.