Types::Namespace - type constraints for dealing with namespaces
package Namespace::Counter { use Moo; # or Moose use Types::Namespace qw( Namespace ); has ns => ( is => "ro", isa => Namespace, required => 1, ); sub count_uses_in_document { ... } }
Types::Namespace is a type constraint library suitable for use with Moo/Moose attributes, Kavorka sub signatures, and so forth. It builds on Types::URI.
Namespace
A class type for URI::Namespace.
Can coerce from URI, IRI, Path::Tiny, Attean::IRI, RDF::Trine::Namespace, RDF::Trine::Node::Resource and strings.
NamespaceMap
A class type for URI::NamespaceMap.
Can coerce from a hashref of prefix => URI pairs and from RDF::Trine::NamespaceMap.
prefix => URI
Uri
Iri
These namespaces are re-exported from Types::URI, but with an additional coercion from the Namespace type.
See URI::NamespaceMap for further details about authors, license, etc.
To install URI::NamespaceMap, copy and paste the appropriate command in to your terminal.
cpanm
cpanm URI::NamespaceMap
CPAN shell
perl -MCPAN -e shell install URI::NamespaceMap
For more information on module installation, please visit the detailed CPAN module installation guide.