blib/lib/XML/NewsML_G2/News_Item_Graphics.pm

filter: Statementstmt 100% 10 / 10 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 2 / 2 Podpod n/a totaltotal 100% 12 / 12 CC 1 SCAR 0.0
CC
1
Cov
100%
BEGIN
1.0
BEGIN
1.0
CRAP 1.0
« blib/lib/XML/NewsML_G2/News_Item_Audio.pm ↑ Summary blib/lib/XML/NewsML_G2/News_Item_Picture.pm »
1 package XML::NewsML_G2::News_Item_Graphics;
2  
3 19 ▶use Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 19 ▶use namespace::autoclean;
Subroutine BEGIN: called CC=1 SCAR=0.0
5  
6 19 extends 'XML::NewsML_G2::News_Item_Picture';
7  
8 19 has '+nature', default => 'graphics';
9  
10 19 __PACKAGE__->meta->make_immutable;
11  
12 19 1;
13 __END__
14  
15 =head1 NAME
16  
17 XML::NewsML_G2::News_Item_Graphics - a picture news item
18  
19 =for test_synopsis
20 my ($provider, $service, $genre1, $genre2);
21  
22 =head1 SYNOPSIS
23  
24 my $ni = XML::NewsML_G2::News_Item_Graphics->new
25 (guid => "tag:example.com,2013:service:date:number",
26 title => "Story title",
27 slugline => "the/slugline",
28 language => 'de',
29 provider => $provider,
30 service => $service,
31 photographer => 'Homer Simpson'
32 );
33  
34 my $ai = XML::NewsML_G2::Graphics->new
35 (mimetype => 'application/illustrator',
36 );
37  
38 my $pic = XML::NewsML_G2::Picture->new
39 (mimetype => 'image/jpg',
40 rendition => 'highRes',
41 width => 1600,
42 height => 1024
43 );
44  
45 my $thumb = XML::NewsML_G2::Picture->new
46 (mimetype => 'image/jpg',
47 rendition => 'thumb',
48 width => 48,
49 height => 32
50 );
51 $ni->add_remote('file://tmp/files/123.ai', $ai);
52 $ni->add_remote('file://tmp/files/123.hires.jpg', $pic);
53 $ni->add_remote('file://tmp/files/123.thumb.jpg', $thumb);
54  
55 =head1 ATTRIBUTES
56  
57 =head1 AUTHOR
58  
59 Mario Paumann C<< <mario.paumann@apa.at> >>
60  
61 =head1 LICENCE AND COPYRIGHT
62  
63 Copyright (c) 2014, APA-IT. All rights reserved.
64  
65 See L<XML::NewsML_G2> for the license.
« blib/lib/XML/NewsML_G2/News_Item_Audio.pm ↑ Summary blib/lib/XML/NewsML_G2/News_Item_Picture.pm »