line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
|
2
|
|
|
|
|
|
|
our $VERSION = '0.15'; |
3
|
|
|
|
|
|
|
|
4
|
|
|
|
|
|
|
use Catmandu::Sane; |
5
|
1
|
|
|
1
|
|
414510
|
use Moo; |
|
1
|
|
|
|
|
9
|
|
|
1
|
|
|
|
|
10
|
|
6
|
1
|
|
|
1
|
|
279
|
use WWW::ORCID; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
7
|
|
7
|
1
|
|
|
1
|
|
786
|
use Catmandu::Fix::Has; |
|
1
|
|
|
|
|
3985
|
|
|
1
|
|
|
|
|
36
|
|
8
|
1
|
|
|
1
|
|
7
|
|
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
15
|
|
9
|
|
|
|
|
|
|
has path => (fix_arg => 1); |
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
with 'Catmandu::Fix::Condition::SimpleAllTest'; |
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
my ($self, $var) = @_; |
14
|
|
|
|
|
|
|
|
15
|
4
|
|
|
4
|
0
|
27816
|
"(is_value(${var}) && ${var} =~/^(\\d{4})-(\\d{4})-(\\d{4})-(\\d{3}[0-9X])\$/)"; |
16
|
|
|
|
|
|
|
} |
17
|
4
|
|
|
|
|
20
|
|
18
|
|
|
|
|
|
|
=head1 NAME |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
Catmandu::Fix::Condition::is_valid_orcid - checks of a field looks like an ORCID |
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
=head1 SYNOPSIS |
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
# Checks is a field looks like an ORCID |
25
|
|
|
|
|
|
|
if is_valid_orcid(orcid) |
26
|
|
|
|
|
|
|
... |
27
|
|
|
|
|
|
|
else |
28
|
|
|
|
|
|
|
... |
29
|
|
|
|
|
|
|
end |
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
=head1 SEE ALSO |
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
L<Catmandu::Fix> |
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
=cut |
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
1; |