line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package XML::NewsML_G2::Media_Topic; |
2
|
|
|
|
|
|
|
|
3
|
18
|
|
|
18
|
|
120
|
use Moose; |
|
18
|
|
|
|
|
43
|
|
|
18
|
|
|
|
|
116
|
|
4
|
18
|
|
|
18
|
|
108769
|
use namespace::autoclean; |
|
18
|
|
|
|
|
41
|
|
|
18
|
|
|
|
|
136
|
|
5
|
|
|
|
|
|
|
|
6
|
|
|
|
|
|
|
with( |
7
|
|
|
|
|
|
|
'XML::NewsML_G2::Role::HasQCode', |
8
|
|
|
|
|
|
|
'XML::NewsML_G2::Role::HasTranslations' |
9
|
|
|
|
|
|
|
); |
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
has 'parent', isa => __PACKAGE__, is => 'rw'; |
12
|
|
|
|
|
|
|
has 'direct', isa => 'Bool', is => 'rw', default => ''; |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
__PACKAGE__->meta->make_immutable; |
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
1; |
17
|
|
|
|
|
|
|
__END__ |
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
=head1 NAME |
20
|
|
|
|
|
|
|
|
21
|
|
|
|
|
|
|
XML::NewsML_G2::Media_Topic - a subject covered in the news item, |
22
|
|
|
|
|
|
|
taken from a standardized controlled vocabulary |
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
=head1 SYNOPSIS |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
my $mm = XML::NewsML_G2::Media_Topic->new |
27
|
|
|
|
|
|
|
(name => 'mass media', qcode => 20000045); |
28
|
|
|
|
|
|
|
my $tv = XML::NewsML_G2::Media_Topic->new |
29
|
|
|
|
|
|
|
(name => 'television', qcode => 20000051, parent => $mm); |
30
|
|
|
|
|
|
|
$tv->add_translation(de => 'Fernsehen') |
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
=head1 ATTRIBUTES |
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
=over 4 |
35
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
=item translations |
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
hash mapping IANA language codes to the translation of the name in that language |
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
=item parent |
41
|
|
|
|
|
|
|
|
42
|
|
|
|
|
|
|
points to the broader media topic |
43
|
|
|
|
|
|
|
|
44
|
|
|
|
|
|
|
=item direct |
45
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
whether the media topic has been manually specified by the editor |
47
|
|
|
|
|
|
|
|
48
|
|
|
|
|
|
|
=back |
49
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
|
=head1 METHODS |
51
|
|
|
|
|
|
|
|
52
|
|
|
|
|
|
|
=over 4 |
53
|
|
|
|
|
|
|
|
54
|
|
|
|
|
|
|
=item add_translation |
55
|
|
|
|
|
|
|
|
56
|
|
|
|
|
|
|
=back |
57
|
|
|
|
|
|
|
|
58
|
|
|
|
|
|
|
=head1 AUTHOR |
59
|
|
|
|
|
|
|
|
60
|
|
|
|
|
|
|
Philipp Gortan C<< <philipp.gortan@apa.at> >> |
61
|
|
|
|
|
|
|
|
62
|
|
|
|
|
|
|
=head1 LICENCE AND COPYRIGHT |
63
|
|
|
|
|
|
|
|
64
|
|
|
|
|
|
|
Copyright (c) 2013-2019, APA-IT. All rights reserved. |
65
|
|
|
|
|
|
|
|
66
|
|
|
|
|
|
|
See L<XML::NewsML_G2> for the license. |