line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Test::Shared::Fixture::Wikibase::Datatype::Snak::Wikidata::SexOrGender::Male; |
2
|
|
|
|
|
|
|
|
3
|
9
|
|
|
9
|
|
340739
|
use base qw(Wikibase::Datatype::Snak); |
|
9
|
|
|
|
|
46
|
|
|
9
|
|
|
|
|
1906
|
|
4
|
9
|
|
|
9
|
|
172
|
use strict; |
|
9
|
|
|
|
|
74
|
|
|
9
|
|
|
|
|
241
|
|
5
|
9
|
|
|
9
|
|
60
|
use warnings; |
|
9
|
|
|
|
|
26
|
|
|
9
|
|
|
|
|
253
|
|
6
|
|
|
|
|
|
|
|
7
|
9
|
|
|
9
|
|
4473
|
use Test::Shared::Fixture::Wikibase::Datatype::Value::Item::Wikidata::Male; |
|
9
|
|
|
|
|
26
|
|
|
9
|
|
|
|
|
965
|
|
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
our $VERSION = 0.29; |
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
sub new { |
12
|
3
|
|
|
3
|
1
|
128
|
my $class = shift; |
13
|
|
|
|
|
|
|
|
14
|
3
|
|
|
|
|
23
|
my @params = ( |
15
|
|
|
|
|
|
|
'datatype' => 'wikibase-item', |
16
|
|
|
|
|
|
|
'datavalue' => Test::Shared::Fixture::Wikibase::Datatype::Value::Item::Wikidata::Male->new, |
17
|
|
|
|
|
|
|
'property' => 'P21', |
18
|
|
|
|
|
|
|
); |
19
|
|
|
|
|
|
|
|
20
|
3
|
|
|
|
|
28
|
my $self = $class->SUPER::new(@params); |
21
|
|
|
|
|
|
|
|
22
|
3
|
|
|
|
|
49
|
return $self; |
23
|
|
|
|
|
|
|
} |
24
|
|
|
|
|
|
|
|
25
|
|
|
|
|
|
|
1; |
26
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
__END__ |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
=pod |
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
=encoding utf8 |
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
=head1 NAME |
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
Test::Shared::Fixture::Wikibase::Datatype::Snak::Wikidata::SexOrGender::Male - Test instance for Wikidata snak. |
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
=head1 SYNOPSIS |
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
use Test::Shared::Fixture::Wikibase::Datatype::Snak::Wikidata::SexOrGender::Male; |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
my $obj = Test::Shared::Fixture::Wikibase::Datatype::Snak::Wikidata::SexOrGender::Male->new; |
42
|
|
|
|
|
|
|
my $datatype = $obj->datatype; |
43
|
|
|
|
|
|
|
my $datavalue = $obj->datavalue; |
44
|
|
|
|
|
|
|
my $property = $obj->property; |
45
|
|
|
|
|
|
|
my $snaktype = $obj->snaktype; |
46
|
|
|
|
|
|
|
|
47
|
|
|
|
|
|
|
=head1 METHODS |
48
|
|
|
|
|
|
|
|
49
|
|
|
|
|
|
|
=head2 C<new> |
50
|
|
|
|
|
|
|
|
51
|
|
|
|
|
|
|
my $obj = Test::Shared::Fixture::Wikibase::Datatype::Snak::Wikidata::SexOrGender::Male->new; |
52
|
|
|
|
|
|
|
|
53
|
|
|
|
|
|
|
Constructor. |
54
|
|
|
|
|
|
|
|
55
|
|
|
|
|
|
|
Returns instance of object. |
56
|
|
|
|
|
|
|
|
57
|
|
|
|
|
|
|
=head2 C<datatype> |
58
|
|
|
|
|
|
|
|
59
|
|
|
|
|
|
|
my $datatype = $obj->datatype; |
60
|
|
|
|
|
|
|
|
61
|
|
|
|
|
|
|
Get data type. |
62
|
|
|
|
|
|
|
|
63
|
|
|
|
|
|
|
Returns string. |
64
|
|
|
|
|
|
|
|
65
|
|
|
|
|
|
|
=head2 C<datavalue> |
66
|
|
|
|
|
|
|
|
67
|
|
|
|
|
|
|
my $datavalue = $obj->datavalue; |
68
|
|
|
|
|
|
|
|
69
|
|
|
|
|
|
|
Get data value. |
70
|
|
|
|
|
|
|
|
71
|
|
|
|
|
|
|
Returns instance of Wikibase::Datatype::Value. |
72
|
|
|
|
|
|
|
|
73
|
|
|
|
|
|
|
=head2 C<property> |
74
|
|
|
|
|
|
|
|
75
|
|
|
|
|
|
|
my $property = $obj->property; |
76
|
|
|
|
|
|
|
|
77
|
|
|
|
|
|
|
Get property name. |
78
|
|
|
|
|
|
|
|
79
|
|
|
|
|
|
|
Returns string. |
80
|
|
|
|
|
|
|
|
81
|
|
|
|
|
|
|
=head2 C<snaktype> |
82
|
|
|
|
|
|
|
|
83
|
|
|
|
|
|
|
my $snaktype = $obj->snaktype; |
84
|
|
|
|
|
|
|
|
85
|
|
|
|
|
|
|
Get snak type. |
86
|
|
|
|
|
|
|
|
87
|
|
|
|
|
|
|
Returns string. |
88
|
|
|
|
|
|
|
|
89
|
|
|
|
|
|
|
=head1 EXAMPLE |
90
|
|
|
|
|
|
|
|
91
|
|
|
|
|
|
|
=for comment filename=fixture_create_and_print_snak_wd_sex_or_gender_male.pl |
92
|
|
|
|
|
|
|
|
93
|
|
|
|
|
|
|
use strict; |
94
|
|
|
|
|
|
|
use warnings; |
95
|
|
|
|
|
|
|
|
96
|
|
|
|
|
|
|
use Test::Shared::Fixture::Wikibase::Datatype::Snak::Wikidata::SexOrGender::Male; |
97
|
|
|
|
|
|
|
use Wikibase::Datatype::Print::Snak; |
98
|
|
|
|
|
|
|
|
99
|
|
|
|
|
|
|
# Object. |
100
|
|
|
|
|
|
|
my $obj = Test::Shared::Fixture::Wikibase::Datatype::Snak::Wikidata::SexOrGender::Male->new; |
101
|
|
|
|
|
|
|
|
102
|
|
|
|
|
|
|
# Print out. |
103
|
|
|
|
|
|
|
print scalar Wikibase::Datatype::Print::Snak::print($obj); |
104
|
|
|
|
|
|
|
|
105
|
|
|
|
|
|
|
# Output: |
106
|
|
|
|
|
|
|
# P21: Q6581097 |
107
|
|
|
|
|
|
|
|
108
|
|
|
|
|
|
|
=head1 DEPENDENCIES |
109
|
|
|
|
|
|
|
|
110
|
|
|
|
|
|
|
L<Test::Shared::Fixture::Wikibase::Datatype::Value::Item::Wikidata::Male>, |
111
|
|
|
|
|
|
|
L<Wikibase::Datatype::Snak>. |
112
|
|
|
|
|
|
|
|
113
|
|
|
|
|
|
|
=head1 SEE ALSO |
114
|
|
|
|
|
|
|
|
115
|
|
|
|
|
|
|
=over |
116
|
|
|
|
|
|
|
|
117
|
|
|
|
|
|
|
=item L<Wikibase::Datatype> |
118
|
|
|
|
|
|
|
|
119
|
|
|
|
|
|
|
Wikibase datatypes. |
120
|
|
|
|
|
|
|
|
121
|
|
|
|
|
|
|
=item L<Wikibase::Datatype::Snak> |
122
|
|
|
|
|
|
|
|
123
|
|
|
|
|
|
|
Wikibase snak datatype. |
124
|
|
|
|
|
|
|
|
125
|
|
|
|
|
|
|
=back |
126
|
|
|
|
|
|
|
|
127
|
|
|
|
|
|
|
=head1 REPOSITORY |
128
|
|
|
|
|
|
|
|
129
|
|
|
|
|
|
|
L<https://github.com/michal-josef-spacek/Wikibase-Datatype> |
130
|
|
|
|
|
|
|
|
131
|
|
|
|
|
|
|
=head1 AUTHOR |
132
|
|
|
|
|
|
|
|
133
|
|
|
|
|
|
|
Michal Josef Špaček L<mailto:skim@cpan.org> |
134
|
|
|
|
|
|
|
|
135
|
|
|
|
|
|
|
L<http://skim.cz> |
136
|
|
|
|
|
|
|
|
137
|
|
|
|
|
|
|
=head1 LICENSE AND COPYRIGHT |
138
|
|
|
|
|
|
|
|
139
|
|
|
|
|
|
|
© Michal Josef Špaček 2020-2023 |
140
|
|
|
|
|
|
|
|
141
|
|
|
|
|
|
|
BSD 2-Clause License |
142
|
|
|
|
|
|
|
|
143
|
|
|
|
|
|
|
=head1 VERSION |
144
|
|
|
|
|
|
|
|
145
|
|
|
|
|
|
|
0.29 |
146
|
|
|
|
|
|
|
|
147
|
|
|
|
|
|
|
=cut |