line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
2
|
|
|
2
|
|
79770
|
use strict; |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
58
|
|
2
|
2
|
|
|
2
|
|
8
|
use warnings; |
|
2
|
|
|
|
|
5
|
|
|
2
|
|
|
|
|
91
|
|
3
|
|
|
|
|
|
|
|
4
|
|
|
|
|
|
|
package Neo4j::Types::Node; |
5
|
|
|
|
|
|
|
# ABSTRACT: Describes a node from a Neo4j graph |
6
|
|
|
|
|
|
|
$Neo4j::Types::Node::VERSION = '1.00'; |
7
|
|
|
|
|
|
|
|
8
|
2
|
|
|
2
|
|
10
|
use Carp qw(croak); |
|
2
|
|
|
|
|
5
|
|
|
2
|
|
|
|
|
484
|
|
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
sub get { |
12
|
6
|
|
|
6
|
1
|
1413
|
my ($self, $property) = @_; |
13
|
|
|
|
|
|
|
|
14
|
6
|
100
|
|
|
|
20
|
return unless defined $self->{properties}; |
15
|
5
|
|
|
|
|
26
|
return $self->{properties}->{$property}; |
16
|
|
|
|
|
|
|
} |
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
sub id { |
20
|
3
|
|
|
3
|
1
|
3671
|
my ($self) = @_; |
21
|
|
|
|
|
|
|
|
22
|
3
|
|
|
|
|
16
|
return $self->{id}; |
23
|
|
|
|
|
|
|
} |
24
|
|
|
|
|
|
|
|
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
sub labels { |
27
|
4
|
|
|
4
|
1
|
2205
|
my ($self) = @_; |
28
|
|
|
|
|
|
|
|
29
|
4
|
100
|
|
|
|
36
|
croak 'labels() in scalar context not supported' unless wantarray; |
30
|
2
|
100
|
|
|
|
5
|
return unless defined $self->{labels}; |
31
|
1
|
|
|
|
|
2
|
return @{$self->{labels}}; |
|
1
|
|
|
|
|
3
|
|
32
|
|
|
|
|
|
|
} |
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
sub properties { |
36
|
3
|
|
|
3
|
1
|
7
|
my ($self) = @_; |
37
|
|
|
|
|
|
|
|
38
|
3
|
100
|
|
|
|
11
|
return {} unless defined $self->{properties}; |
39
|
2
|
|
|
|
|
6
|
return $self->{properties}; |
40
|
|
|
|
|
|
|
} |
41
|
|
|
|
|
|
|
|
42
|
|
|
|
|
|
|
|
43
|
|
|
|
|
|
|
1; |
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
__END__ |