line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
# |
2
|
|
|
|
|
|
|
# This file is part of Audio-MPD-Common |
3
|
|
|
|
|
|
|
# |
4
|
|
|
|
|
|
|
# This software is copyright (c) 2007 by Jerome Quelin. |
5
|
|
|
|
|
|
|
# |
6
|
|
|
|
|
|
|
# This is free software; you can redistribute it and/or modify it under |
7
|
|
|
|
|
|
|
# the same terms as the Perl 5 programming language system itself. |
8
|
|
|
|
|
|
|
# |
9
|
1
|
|
|
1
|
|
31
|
use 5.008; |
|
1
|
|
|
|
|
4
|
|
10
|
1
|
|
|
1
|
|
6
|
use warnings; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
37
|
|
11
|
1
|
|
|
1
|
|
6
|
use strict; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
44
|
|
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
package Audio::MPD::Common::Types; |
14
|
|
|
|
|
|
|
# ABSTRACT: types used in the distribution |
15
|
|
|
|
|
|
|
$Audio::MPD::Common::Types::VERSION = '2.003'; |
16
|
1
|
|
|
1
|
|
5
|
use Moose::Util::TypeConstraints; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
10
|
|
17
|
|
|
|
|
|
|
|
18
|
1
|
|
|
1
|
|
1960
|
use Audio::MPD::Common::Time; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
84
|
|
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
enum 'State' => [ qw{ play stop pause } ]; |
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
coerce 'Audio::MPD::Common::Time' |
23
|
|
|
|
|
|
|
=> from 'Str' |
24
|
|
|
|
|
|
|
=> via { Audio::MPD::Common::Time->new(time=>$_) }; |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
1; |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
__END__ |
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
=pod |
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
=encoding UTF-8 |
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
=head1 NAME |
35
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
Audio::MPD::Common::Types - types used in the distribution |
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
=head1 VERSION |
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
version 2.003 |
41
|
|
|
|
|
|
|
|
42
|
|
|
|
|
|
|
=head1 DESCRIPTION |
43
|
|
|
|
|
|
|
|
44
|
|
|
|
|
|
|
This module implements the specific types used by the distribution, and |
45
|
|
|
|
|
|
|
exports them (exporting is done by L<Moose::Util::TypeConstraints>). |
46
|
|
|
|
|
|
|
|
47
|
|
|
|
|
|
|
Current types defined: |
48
|
|
|
|
|
|
|
|
49
|
|
|
|
|
|
|
=over 4 |
50
|
|
|
|
|
|
|
|
51
|
|
|
|
|
|
|
=item * State - a simple enumeration, allowing C<play>, C<stop> |
52
|
|
|
|
|
|
|
and C<pause>. |
53
|
|
|
|
|
|
|
|
54
|
|
|
|
|
|
|
=back |
55
|
|
|
|
|
|
|
|
56
|
|
|
|
|
|
|
It also defines a type coertion from C<Str> to C<Audio::MPD::Common::Time>. |
57
|
|
|
|
|
|
|
|
58
|
|
|
|
|
|
|
=head1 AUTHOR |
59
|
|
|
|
|
|
|
|
60
|
|
|
|
|
|
|
Jerome Quelin |
61
|
|
|
|
|
|
|
|
62
|
|
|
|
|
|
|
=head1 COPYRIGHT AND LICENSE |
63
|
|
|
|
|
|
|
|
64
|
|
|
|
|
|
|
This software is copyright (c) 2007 by Jerome Quelin. |
65
|
|
|
|
|
|
|
|
66
|
|
|
|
|
|
|
This is free software; you can redistribute it and/or modify it under |
67
|
|
|
|
|
|
|
the same terms as the Perl 5 programming language system itself. |
68
|
|
|
|
|
|
|
|
69
|
|
|
|
|
|
|
=cut |