line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
5
|
|
|
5
|
|
62
|
use 5.006; |
|
5
|
|
|
|
|
10
|
|
2
|
5
|
|
|
5
|
|
15
|
use strict; |
|
5
|
|
|
|
|
5
|
|
|
5
|
|
|
|
|
74
|
|
3
|
5
|
|
|
5
|
|
10
|
use warnings; |
|
5
|
|
|
|
|
5
|
|
|
5
|
|
|
|
|
184
|
|
4
|
|
|
|
|
|
|
|
5
|
|
|
|
|
|
|
package Metabase::Resource::metabase::fact; |
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
our $VERSION = '0.025'; |
8
|
|
|
|
|
|
|
|
9
|
5
|
|
|
5
|
|
15
|
use Carp (); |
|
5
|
|
|
|
|
5
|
|
|
5
|
|
|
|
|
58
|
|
10
|
|
|
|
|
|
|
|
11
|
5
|
|
|
5
|
|
14
|
use Metabase::Resource::metabase; |
|
5
|
|
|
|
|
9
|
|
|
5
|
|
|
|
|
750
|
|
12
|
|
|
|
|
|
|
our @ISA = qw/Metabase::Resource::metabase/; |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
sub _metadata_types { |
15
|
1
|
|
|
1
|
|
7
|
return { guid => '//str', }; |
16
|
|
|
|
|
|
|
} |
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
sub _init { |
19
|
27
|
|
|
27
|
|
25
|
my ($self) = @_; |
20
|
27
|
|
|
|
|
208
|
my ($guid) = $self =~ m{\Ametabase:[^:]+:(.+)\z}; |
21
|
27
|
50
|
33
|
|
|
88
|
Carp::confess("could not determine guid from '$self'\n") |
22
|
|
|
|
|
|
|
unless defined $guid && length $guid; |
23
|
27
|
|
|
|
|
69
|
$self->_add( guid => $guid ); |
24
|
27
|
|
|
|
|
37
|
return $self; |
25
|
|
|
|
|
|
|
} |
26
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
sub validate { |
28
|
27
|
|
|
27
|
1
|
27
|
my $self = shift; |
29
|
27
|
|
|
|
|
48
|
$self->_validate_guid( $self->guid ); |
30
|
27
|
|
|
|
|
33
|
return 1; |
31
|
|
|
|
|
|
|
} |
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
1; |
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
# ABSTRACT: class for Metabase facts |
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
__END__ |