File Coverage

blib/lib/WebService/GData/YouTube/Constants.pm
Criterion Covered Total %
statement 9 9 100.0
branch n/a
condition n/a
subroutine 3 3 100.0
pod n/a
total 12 12 100.0


line stmt bran cond sub pod time code
1             package WebService::GData::YouTube::Constants;
2 10     10   110186 use strict;
  10         19  
  10         344  
3 10     10   54 use warnings;
  10         23  
  10         1208  
4              
5             our $VERSION = 1.02;
6              
7             use constant {
8              
9 10         5305 PROJECTION => 'api',
10             BASE_URI => 'http://gdata.youtube.com/feeds/',
11             STAGING_BASE_URI => 'http://stage.gdata.youtube.com/feeds/',
12             API_DOMAIN_URI => 'http://gdata.youtube.com/',
13             STAGING_API_DOMAIN_URI =>'http://stage.gdata.youtube.com/',
14             UPLOAD_BASE_URI => 'http://uploads.gdata.youtube.com/feeds/',
15             STAGING_UPLOAD_BASE_URI=>'http://uploads.stage.gdata.youtube.com/feeds/',
16            
17             YOUTUBE_NAMESPACE => 'xmlns:yt="http://gdata.youtube.com/schemas/2007"',
18              
19             MOBILE_H263 => 1,
20             H263 => 1,
21             MPEG4 => 6,
22             MOBILE_MPEG4 => 6,
23             EMBEDDABLE => 5,
24              
25             TODAY => 'today',
26             WEEK => 'this_week',
27             MONTH => 'this_month',
28             ALL_TIME => 'all_time',
29              
30             NONE => 'none',
31             MODERATE => 'moderate',
32             STRICT => 'strict',
33             L0 => 'none',
34             L1 => 'moderate',
35             L2 => 'strict',
36              
37             RELEVANCE => 'relevance',
38             PUBLISHED => 'published',
39             VIEW_COUNT => 'viewCount',
40             RATING => 'rating',
41             POSITION => 'position',
42             COMMENT_COUNT => 'commentCount',
43             DURATION => 'duration'
44 10     10   57 };
  10         30  
45              
46             my @general = qw(PROJECTION BASE_URI UPLOAD_BASE_URI API_DOMAIN_URI STAGING_BASE_URI STAGING_UPLOAD_BASE_URI STAGING_API_DOMAIN_URI);
47             my @namespace = qw(YOUTUBE_NAMESPACE);
48             my @format = qw(MOBILE_H263 H263 MPEG4 MOBILE_MPEG4 EMBEDDABLE);
49             my @time = qw(TODAY WEEK MONTH ALL_TIME);
50             my @safe = qw(NONE MODERATE STRICT L0 L1 L2);
51             my @order =
52             qw(RELEVANCE PUBLISHED VIEW_COUNT RATING POSITION COMMENT_COUNT DURATION);
53              
54             require Exporter;
55             our @ISA = qw(Exporter);
56             our @EXPORT_OK = ( @format, @time, @safe, @order, @general,@namespace );
57             our %EXPORT_TAGS = (
58             general => [@general],
59             format => [@format],
60             'time' => [@time],
61             safe => [@safe],
62             order => [@order],
63             namespace=>[@namespace],
64             all => [ @format, @time, @safe, @order, @general, @namespace]
65             );
66              
67             "The Earth is blue like an orange.";
68              
69             __END__