Perl Diver 2.31
Main Environment Variables Perl Default Values Perl Config - Summary Perl Config - Full Installed Modules List Directory uptime Docs

Module Documentation
Details and documentation about a specific module, including version and documentation (if available). Note that while links to perldoc.com and search.cpan.org are provided, the module may be part of a larger distribution. If you reach a File Not Found page on either site, please try the parent module.

Types::URI

Name Types::URI
Version 0.006
Located at /usr/share/perl5/vendor_perl
File /usr/share/perl5/vendor_perl/Types/URI.pm
Is Core No
Search CPAN for this module Types::URI
Documentation Types::URI
Module Details Types::URI


NAME

Types::URI - type constraints and coercions for URIs


SYNOPSIS

   package FroobleDocument;

   use Moose;
   use Types::URI -all;

   has source => (
      is      => 'ro',
      isa     => Uri,
      coerce  => 1,
   );


DESCRIPTION

the Types::URI manpage is a type constraint library suitable for use with Moo/Moose attributes, Kavorka sub signatures, and so forth.

Types

This module provides some type constraints broadly compatible with those provided by the MooseX::Types::URI manpage, plus a couple of extra type constraints.

Uri
A class type for URI/the URI::WithBase manpage. Coercions from:
from Uuid
Coerces to a URI in the urn:uuid: schema. (See the Types::UUID manpage.)

from Str
Uses URI/new.

from Path
Uses new in the URI::file manpage. (See the Types::Path::Tiny manpage.)

from ScalarRef
Uses new in the URI::data manpage.

from HashRef
Coerces using the URI::FromHash manpage.

from Iri
Uses URI/new.

from RDF::Trine::Node::Resource, RDF::Trine::Namespace, XML::Namespace
Uses URI/new.

FileUri
A subtype of Uri covering the URI::file manpage. Coercions from:
from Strfrom Str
Uses new in the URI::file manpage.

from Pathfrom Path
Uses new in the URI::file manpage. (See the Types::Path::Tiny manpage.)

from HashReffrom HashRef
Coerces using the URI::FromHash manpage.

from Irifrom Iri
Uses URI/new.

from the RDF::Trine::Node::Resource manpage, the RDF::Trine::Namespace manpage, the XML::Namespace manpagefrom RDF::Trine::Node::Resource, RDF::Trine::Namespace, XML::Namespace
Uses URI/new.

DataUri
A subtype of Uri covering the URI::data manpage. Coercions from:
from Strfrom Str
Uses new in the URI::data manpage.

from ScalarReffrom ScalarRef
Uses new in the URI::data manpage.

from HashReffrom HashRef
Coerces using the URI::FromHash manpage.

from Irifrom Iri
Uses URI/new.

from the RDF::Trine::Node::Resource manpage, the RDF::Trine::Namespace manpage, the XML::Namespace manpagefrom RDF::Trine::Node::Resource, RDF::Trine::Namespace, XML::Namespace
Uses URI/new.

Iri
A class type for IRI. Coercions as per Uri above, plus can coerce from Uri.


BUGS

Please report any bugs to http://rt.cpan.org/Dist/Display.html.


SEE ALSO

the MooseX::Types::URI manpage, the Type::Tiny::Manual manpage, URI, the URI::file manpage, the URI::data manpage, the URI::FromHash manpage, the RDF::Trine::Node::Resource manpage, IRI.

the Types::UUID manpage, the Types::Path::Tiny manpage, the Types::Standard manpage.


AUTHOR

Toby Inkster <tobyink@cpan.org>.


COPYRIGHT AND LICENCE

This software is copyright (c) 2014 by Toby Inkster.

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


DISCLAIMER OF WARRANTIES

THIS PACKAGE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.

Perl Diver brought to you by ScriptSolutions.com © 1997- 2025