line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Test::Shared::Fixture::Wikibase::Datatype::Snak::Wikidata::GivenName::Douglas; |
2
|
|
|
|
|
|
|
|
3
|
9
|
|
|
9
|
|
346092
|
use base qw(Wikibase::Datatype::Snak); |
|
9
|
|
|
|
|
50
|
|
|
9
|
|
|
|
|
4020
|
|
4
|
9
|
|
|
9
|
|
69
|
use strict; |
|
9
|
|
|
|
|
58
|
|
|
9
|
|
|
|
|
218
|
|
5
|
9
|
|
|
9
|
|
53
|
use warnings; |
|
9
|
|
|
|
|
19
|
|
|
9
|
|
|
|
|
247
|
|
6
|
|
|
|
|
|
|
|
7
|
9
|
|
|
9
|
|
4620
|
use Test::Shared::Fixture::Wikibase::Datatype::Value::Item::Wikidata::Douglas; |
|
9
|
|
|
|
|
25
|
|
|
9
|
|
|
|
|
969
|
|
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
our $VERSION = 0.29; |
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
sub new { |
12
|
3
|
|
|
3
|
1
|
141
|
my $class = shift; |
13
|
|
|
|
|
|
|
|
14
|
3
|
|
|
|
|
25
|
my @params = ( |
15
|
|
|
|
|
|
|
'datatype' => 'wikibase-item', |
16
|
|
|
|
|
|
|
'datavalue' => Test::Shared::Fixture::Wikibase::Datatype::Value::Item::Wikidata::Douglas->new, |
17
|
|
|
|
|
|
|
'property' => 'P735', |
18
|
|
|
|
|
|
|
); |
19
|
|
|
|
|
|
|
|
20
|
3
|
|
|
|
|
42
|
my $self = $class->SUPER::new(@params); |
21
|
|
|
|
|
|
|
|
22
|
3
|
|
|
|
|
50
|
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::GivenName::Douglas - Test instance for Wikidata snak. |
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
=head1 SYNOPSIS |
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
use Test::Shared::Fixture::Wikibase::Datatype::Snak::Wikidata::GivenName::Douglas; |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
my $obj = Test::Shared::Fixture::Wikibase::Datatype::Snak::Wikidata::GivenName::Douglas->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::GivenName::Douglas->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_givenname_douglas.pl |
92
|
|
|
|
|
|
|
|
93
|
|
|
|
|
|
|
use strict; |
94
|
|
|
|
|
|
|
use warnings; |
95
|
|
|
|
|
|
|
|
96
|
|
|
|
|
|
|
use Test::Shared::Fixture::Wikibase::Datatype::Snak::Wikidata::GivenName::Douglas; |
97
|
|
|
|
|
|
|
use Wikibase::Datatype::Print::Snak; |
98
|
|
|
|
|
|
|
|
99
|
|
|
|
|
|
|
# Object. |
100
|
|
|
|
|
|
|
my $obj = Test::Shared::Fixture::Wikibase::Datatype::Snak::Wikidata::GivenName::Douglas->new; |
101
|
|
|
|
|
|
|
|
102
|
|
|
|
|
|
|
# Print out. |
103
|
|
|
|
|
|
|
print scalar Wikibase::Datatype::Print::Snak::print($obj); |
104
|
|
|
|
|
|
|
|
105
|
|
|
|
|
|
|
# Output: |
106
|
|
|
|
|
|
|
# P735: Q463035 |
107
|
|
|
|
|
|
|
|
108
|
|
|
|
|
|
|
=head1 DEPENDENCIES |
109
|
|
|
|
|
|
|
|
110
|
|
|
|
|
|
|
L<Test::Shared::Fixture::Wikibase::Datatype::Value::Item::Wikidata::Douglas>, |
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 |