File Coverage

blib/lib/Authen/CAS/External/Library.pm
Criterion Covered Total %
statement 13 15 86.6
branch n/a
condition n/a
subroutine 5 5 100.0
pod n/a
total 18 20 90.0


line stmt bran cond sub pod time code
1             package Authen::CAS::External::Library;
2              
3 3     3   66 use 5.008001;
  3         11  
  3         136  
4 3     3   19 use strict;
  3         6  
  3         100  
5 3     3   14 use utf8;
  3         6  
  3         13  
6 3     3   77 use warnings 'all';
  3         5  
  3         254  
7              
8             # Module metadata
9             our $AUTHORITY = 'cpan:DOUGDUDE';
10             our $VERSION = '0.08';
11              
12 0           use MooseX::Types 0.08 -declare => [qw(
13             ServiceTicket
14             TicketGrantingCookie
15 3     3   3911 )];
  0            
16              
17             # Import built-in types
18             use MooseX::Types::Moose qw(Int Str);
19              
20             # Clean the imports are the end of scope
21             use namespace::clean 0.04 -except => [qw(meta)];
22              
23             # Type definitions
24             subtype ServiceTicket,
25             as Str,
26             where { m{\A ST-.{1,256}}msx };
27              
28             subtype TicketGrantingCookie,
29             as Str,
30             where { m{\A (?:TGC-)? [A-Za-z0-9-]+ (?:-[A-Za-z0-9\.-]+)? \z}msx };
31              
32             1;
33              
34             __END__
35              
36             =head1 NAME
37              
38             Authen::CAS::External::Library - Types library
39              
40             =head1 VERSION
41              
42             This documentation refers to version 0.08.
43              
44             =head1 SYNOPSIS
45              
46             use Authen::CAS::External::Library qw(ServiceTicket);
47             # This will import ServiceTicket type into your namespace as well as some
48             # helpers like to_ServiceTicket and is_ServiceTicket. See MooseX::Types
49             # for more information.
50              
51             =head1 DESCRIPTION
52              
53             This module provides types for Authen::CAS::External
54              
55             =head1 METHODS
56              
57             No methods.
58              
59             =head1 TYPES PROVIDED
60              
61             =head2 ServiceTicket
62              
63             B<Provides no coercions.>
64              
65             =head2 TicketGrantingCookie
66              
67             B<Provides no coercions.>
68              
69             This is the ticket-granting cookie as defined in section 3.6 of the
70             L<CAS Protocol|http://www.jasig.org/cas/protocol>. This also allows for a domain
71             name to be present at the end as per discussed in
72             L<Clustering CAS|http://www.ja-sig.org/wiki/display/CASUM/Clustering+CAS>.
73              
74             =head1 DEPENDENCIES
75              
76             This module is dependent on the following modules:
77              
78             =over 4
79              
80             =item * L<MooseX::Types|MooseX::Types> 0.08
81              
82             =item * L<MooseX::Types::Moose|MooseX::Types::Moose>
83              
84             =item * L<namespace::clean|namespace::clean> 0.04
85              
86             =back
87              
88             =head1 AUTHOR
89              
90             Douglas Christopher Wilson, C<< <doug at somethingdoug.com> >>
91              
92             =head1 BUGS AND LIMITATIONS
93              
94             Please report any bugs or feature requests to
95             C<bug-authen-cas-external at rt.cpan.org>, or through the web interface at
96             L<http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Authen-CAS-External>.
97             I will be notified, and then you'll automatically be notified of progress on
98             your bug as I make changes.
99              
100             I highly encourage the submission of bugs and enhancements to my modules.
101              
102             =head1 LICENSE AND COPYRIGHT
103              
104             Copyright 2009 Douglas Christopher Wilson.
105              
106             This program is free software; you can redistribute it and/or
107             modify it under the terms of either:
108              
109             =over 4
110              
111             =item * the GNU General Public License as published by the Free
112             Software Foundation; either version 1, or (at your option) any
113             later version, or
114              
115             =item * the Artistic License version 2.0.
116              
117             =back