line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Faker::Plugin::EsEs::PersonNamePrefix; |
2
|
|
|
|
|
|
|
|
3
|
2
|
|
|
2
|
|
20697
|
use 5.018; |
|
2
|
|
|
|
|
7
|
|
4
|
|
|
|
|
|
|
|
5
|
2
|
|
|
2
|
|
10
|
use strict; |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
41
|
|
6
|
2
|
|
|
2
|
|
10
|
use warnings; |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
52
|
|
7
|
|
|
|
|
|
|
|
8
|
2
|
|
|
2
|
|
10
|
use Venus::Class 'base'; |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
12
|
|
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
base 'Faker::Plugin::EsEs'; |
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
# VERSION |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
our $VERSION = '1.18'; |
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
# METHODS |
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
sub execute { |
19
|
4
|
|
|
4
|
1
|
1320
|
my ($self, $data) = @_; |
20
|
|
|
|
|
|
|
|
21
|
4
|
100
|
|
|
|
14
|
return lc($self->faker->person_gender) eq 'male' |
22
|
|
|
|
|
|
|
? $self->faker->random->select(data_for_name_prefix_male()) |
23
|
|
|
|
|
|
|
: $self->faker->random->select(data_for_name_prefix_female()); |
24
|
|
|
|
|
|
|
} |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
sub data_for_name_prefix_male { |
27
|
1
|
|
|
1
|
0
|
6
|
state $name_prefix = [ |
28
|
|
|
|
|
|
|
'Señor', |
29
|
|
|
|
|
|
|
] |
30
|
|
|
|
|
|
|
} |
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
sub data_for_name_prefix_female { |
33
|
3
|
|
|
3
|
0
|
14
|
state $name_prefix = [ |
34
|
|
|
|
|
|
|
'Señora', |
35
|
|
|
|
|
|
|
'Señorita', |
36
|
|
|
|
|
|
|
] |
37
|
|
|
|
|
|
|
} |
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
1; |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
|
42
|
|
|
|
|
|
|
|
43
|
|
|
|
|
|
|
=head1 NAME |
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
Faker::Plugin::EsEs::PersonNamePrefix - Person Name Prefix |
46
|
|
|
|
|
|
|
|
47
|
|
|
|
|
|
|
=cut |
48
|
|
|
|
|
|
|
|
49
|
|
|
|
|
|
|
=head1 ABSTRACT |
50
|
|
|
|
|
|
|
|
51
|
|
|
|
|
|
|
Person Name Prefix for Faker |
52
|
|
|
|
|
|
|
|
53
|
|
|
|
|
|
|
=cut |
54
|
|
|
|
|
|
|
|
55
|
|
|
|
|
|
|
=head1 VERSION |
56
|
|
|
|
|
|
|
|
57
|
|
|
|
|
|
|
1.18 |
58
|
|
|
|
|
|
|
|
59
|
|
|
|
|
|
|
=cut |
60
|
|
|
|
|
|
|
|
61
|
|
|
|
|
|
|
=head1 SYNOPSIS |
62
|
|
|
|
|
|
|
|
63
|
|
|
|
|
|
|
package main; |
64
|
|
|
|
|
|
|
|
65
|
|
|
|
|
|
|
use Faker::Plugin::EsEs::PersonNamePrefix; |
66
|
|
|
|
|
|
|
|
67
|
|
|
|
|
|
|
my $plugin = Faker::Plugin::EsEs::PersonNamePrefix->new; |
68
|
|
|
|
|
|
|
|
69
|
|
|
|
|
|
|
# bless(..., "Faker::Plugin::EsEs::PersonNamePrefix") |
70
|
|
|
|
|
|
|
|
71
|
|
|
|
|
|
|
=cut |
72
|
|
|
|
|
|
|
|
73
|
|
|
|
|
|
|
=head1 DESCRIPTION |
74
|
|
|
|
|
|
|
|
75
|
|
|
|
|
|
|
This package provides methods for generating fake data for person name prefix. |
76
|
|
|
|
|
|
|
|
77
|
|
|
|
|
|
|
=encoding utf8 |
78
|
|
|
|
|
|
|
|
79
|
|
|
|
|
|
|
=cut |
80
|
|
|
|
|
|
|
|
81
|
|
|
|
|
|
|
=head1 INHERITS |
82
|
|
|
|
|
|
|
|
83
|
|
|
|
|
|
|
This package inherits behaviors from: |
84
|
|
|
|
|
|
|
|
85
|
|
|
|
|
|
|
L |
86
|
|
|
|
|
|
|
|
87
|
|
|
|
|
|
|
=cut |
88
|
|
|
|
|
|
|
|
89
|
|
|
|
|
|
|
=head1 METHODS |
90
|
|
|
|
|
|
|
|
91
|
|
|
|
|
|
|
This package provides the following methods: |
92
|
|
|
|
|
|
|
|
93
|
|
|
|
|
|
|
=cut |
94
|
|
|
|
|
|
|
|
95
|
|
|
|
|
|
|
=head2 execute |
96
|
|
|
|
|
|
|
|
97
|
|
|
|
|
|
|
execute(HashRef $data) (Str) |
98
|
|
|
|
|
|
|
|
99
|
|
|
|
|
|
|
The execute method returns a returns a random fake person name prefix. |
100
|
|
|
|
|
|
|
|
101
|
|
|
|
|
|
|
I> |
102
|
|
|
|
|
|
|
|
103
|
|
|
|
|
|
|
=over 4 |
104
|
|
|
|
|
|
|
|
105
|
|
|
|
|
|
|
=item execute example 1 |
106
|
|
|
|
|
|
|
|
107
|
|
|
|
|
|
|
package main; |
108
|
|
|
|
|
|
|
|
109
|
|
|
|
|
|
|
use Faker::Plugin::EsEs::PersonNamePrefix; |
110
|
|
|
|
|
|
|
|
111
|
|
|
|
|
|
|
my $plugin = Faker::Plugin::EsEs::PersonNamePrefix->new; |
112
|
|
|
|
|
|
|
|
113
|
|
|
|
|
|
|
# bless(..., "Faker::Plugin::EsEs::PersonNamePrefix") |
114
|
|
|
|
|
|
|
|
115
|
|
|
|
|
|
|
# my $result = $plugin->execute; |
116
|
|
|
|
|
|
|
|
117
|
|
|
|
|
|
|
# 'Señor'; |
118
|
|
|
|
|
|
|
|
119
|
|
|
|
|
|
|
# my $result = $plugin->execute; |
120
|
|
|
|
|
|
|
|
121
|
|
|
|
|
|
|
# 'Señora'; |
122
|
|
|
|
|
|
|
|
123
|
|
|
|
|
|
|
# my $result = $plugin->execute; |
124
|
|
|
|
|
|
|
|
125
|
|
|
|
|
|
|
# 'Señora'; |
126
|
|
|
|
|
|
|
|
127
|
|
|
|
|
|
|
=back |
128
|
|
|
|
|
|
|
|
129
|
|
|
|
|
|
|
=cut |
130
|
|
|
|
|
|
|
|
131
|
|
|
|
|
|
|
=head2 new |
132
|
|
|
|
|
|
|
|
133
|
|
|
|
|
|
|
new(HashRef $data) (Plugin) |
134
|
|
|
|
|
|
|
|
135
|
|
|
|
|
|
|
The new method returns a new instance of the class. |
136
|
|
|
|
|
|
|
|
137
|
|
|
|
|
|
|
I> |
138
|
|
|
|
|
|
|
|
139
|
|
|
|
|
|
|
=over 4 |
140
|
|
|
|
|
|
|
|
141
|
|
|
|
|
|
|
=item new example 1 |
142
|
|
|
|
|
|
|
|
143
|
|
|
|
|
|
|
package main; |
144
|
|
|
|
|
|
|
|
145
|
|
|
|
|
|
|
use Faker::Plugin::EsEs::PersonNamePrefix; |
146
|
|
|
|
|
|
|
|
147
|
|
|
|
|
|
|
my $plugin = Faker::Plugin::EsEs::PersonNamePrefix->new; |
148
|
|
|
|
|
|
|
|
149
|
|
|
|
|
|
|
# bless(..., "Faker::Plugin::EsEs::PersonNamePrefix") |
150
|
|
|
|
|
|
|
|
151
|
|
|
|
|
|
|
=back |
152
|
|
|
|
|
|
|
|
153
|
|
|
|
|
|
|
=cut |
154
|
|
|
|
|
|
|
|
155
|
|
|
|
|
|
|
=head1 AUTHORS |
156
|
|
|
|
|
|
|
|
157
|
|
|
|
|
|
|
Awncorp, C |
158
|
|
|
|
|
|
|
|
159
|
|
|
|
|
|
|
=cut |
160
|
|
|
|
|
|
|
|
161
|
|
|
|
|
|
|
=head1 LICENSE |
162
|
|
|
|
|
|
|
|
163
|
|
|
|
|
|
|
Copyright (C) 2000, Al Newkirk. |
164
|
|
|
|
|
|
|
|
165
|
|
|
|
|
|
|
This program is free software, you can redistribute it and/or modify it under |
166
|
|
|
|
|
|
|
the terms of the Apache license version 2.0. |
167
|
|
|
|
|
|
|
|
168
|
|
|
|
|
|
|
=cut |