File Coverage

blib/lib/WWW/NOS/Open/AudioFragment.pm
Criterion Covered Total %
statement 20 20 100.0
branch n/a
condition n/a
subroutine 7 7 100.0
pod n/a
total 27 27 100.0


line stmt bran cond sub pod time code
1             # -*- cperl; cperl-indent-level: 4 -*-
2             # Copyright (C) 2011-2021, Roland van Ipenburg
3             package WWW::NOS::Open::AudioFragment v1.0.4;
4 4     4   37 use strict;
  4         13  
  4         192  
5 4     4   25 use warnings;
  4         10  
  4         153  
6              
7 4     4   23 use utf8;
  4         12  
  4         36  
8 4     4   169 use 5.014000;
  4         15  
9              
10 4     4   24 use Moose qw/extends/;
  4         10  
  4         37  
11 4     4   23030 use namespace::autoclean '-also' => qr/^__/sxm;
  4         18  
  4         61  
12              
13             extends 'WWW::NOS::Open::MediaResource';
14              
15 4     4   430 no Moose;
  4         19  
  4         57  
16              
17             __PACKAGE__->meta->make_immutable;
18              
19             1;
20              
21             __END__
22              
23             =encoding utf8
24              
25             =for stopwords Bitbucket DateTime URI Ipenburg MERCHANTABILITY
26              
27             =head1 NAME
28              
29             WWW::NOS::Open::AudioFragment - client side audio fragment.
30              
31             =head1 VERSION
32              
33             This document describes WWW::NOS::Open::AudioFragment version C<v1.0.4>.
34              
35             =head1 SYNOPSIS
36              
37             use WWW::NOS::Open::AudioFragment;
38              
39             =head1 DESCRIPTION
40              
41             This class represents an audio fragment as returned in the latest ten audio
42             fragments list.
43              
44             =head1 SUBROUTINES/METHODS
45              
46             =head2 C<new>
47              
48             Create a new audio fragment object.
49              
50             =over
51              
52             =item 1. A hash containing the properties and their values.
53              
54             =back
55              
56             =head2 C<get_id>
57              
58             Returns the id of the audio fragment as integer.
59              
60             =head2 C<get_title>
61              
62             Returns the title of the audio fragment as string.
63              
64             =head2 C<get_description>
65              
66             Returns the description of the audio fragment as string.
67              
68             =head2 C<get_published>
69              
70             Returns the publishing date of the audio fragment as a L<DateTime|DateTime>
71             object.
72              
73             =head2 C<get_last_update>
74              
75             Returns the date of the last update for the audio fragment as a
76             L<DateTime|DateTime> object.
77              
78             =head2 C<get_thumbnail_xs>
79              
80             Returns the URL of the extra small thumbnail for the audio fragment as an
81             L<URI|URI> object.
82              
83             =head2 C<get_thumbnail_s>
84              
85             Returns the URL of the small thumbnail for the audio fragment as an L<URI|URI>
86             object.
87              
88             =head2 C<get_thumbnail_m>
89              
90             Returns the URL of the medium sized thumbnail for the audio fragment as an
91             L<URI|URI> object.
92              
93             =head2 C<get_link>
94              
95             Returns the URL of the main audio fragment as an L<URI|URI> object.
96              
97             =head2 C<get_embed_code>
98              
99             Return the HTML code to embed the audio fragment in an HTML page.
100              
101             =head2 C<get_keywords>
102              
103             Returns the list of keywords for the audio fragment as a reference to an array
104             of strings.
105              
106             =head1 CONFIGURATION AND ENVIRONMENT
107              
108             =head1 DEPENDENCIES
109              
110             =over 4
111              
112             =item * L<Moose|Moose>
113              
114             =item * L<namespace::autoclean|namespace::autoclean>
115              
116             =item * L<WWW::NOS::Open::MediaResource|WWW::NOS::Open::MediaResource>
117              
118             =back
119              
120             =head1 INCOMPATIBILITIES
121              
122             =head1 DIAGNOSTICS
123              
124             =head1 BUGS AND LIMITATIONS
125              
126             Please report any bugs or feature requests at
127             L<Bitbucket|https://bitbucket.org/rolandvanipenburg/www-nos-open/issues>.
128              
129             =head1 AUTHOR
130              
131             Roland van Ipenburg, E<lt>roland@rolandvanipenburg.comE<gt>
132              
133             =head1 LICENSE AND COPYRIGHT
134              
135             Copyright 2011-2021 by Roland van Ipenburg
136              
137             This library is free software; you can redistribute it and/or modify
138             it under the same terms as Perl itself, either Perl version 5.14.0 or,
139             at your option, any later version of Perl 5 you may have available.
140              
141             =head1 DISCLAIMER OF WARRANTY
142              
143             BECAUSE THIS SOFTWARE IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
144             FOR THE SOFTWARE, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
145             OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
146             PROVIDE THE SOFTWARE "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER
147             EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
148             WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE
149             ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE SOFTWARE IS WITH
150             YOU. SHOULD THE SOFTWARE PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL
151             NECESSARY SERVICING, REPAIR, OR CORRECTION.
152              
153             IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
154             WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
155             REDISTRIBUTE THE SOFTWARE AS PERMITTED BY THE ABOVE LICENSE, BE
156             LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL,
157             OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE
158             THE SOFTWARE (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING
159             RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A
160             FAILURE OF THE SOFTWARE TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF
161             SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
162             SUCH DAMAGES.
163              
164             =cut