line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Net::DNS::RR::ISDN; |
2
|
|
|
|
|
|
|
|
3
|
1
|
|
|
1
|
|
7
|
use strict; |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
29
|
|
4
|
1
|
|
|
1
|
|
5
|
use warnings; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
46
|
|
5
|
|
|
|
|
|
|
our $VERSION = (qw$Id: ISDN.pm 1896 2023-01-30 12:59:25Z willem $)[2]; |
6
|
|
|
|
|
|
|
|
7
|
1
|
|
|
1
|
|
17
|
use base qw(Net::DNS::RR); |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
95
|
|
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
=head1 NAME |
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
Net::DNS::RR::ISDN - DNS ISDN resource record |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
=cut |
15
|
|
|
|
|
|
|
|
16
|
1
|
|
|
1
|
|
7
|
use integer; |
|
1
|
|
|
|
|
11
|
|
|
1
|
|
|
|
|
7
|
|
17
|
|
|
|
|
|
|
|
18
|
1
|
|
|
1
|
|
472
|
use Net::DNS::Text; |
|
1
|
|
|
|
|
5
|
|
|
1
|
|
|
|
|
410
|
|
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
|
21
|
|
|
|
|
|
|
sub _decode_rdata { ## decode rdata from wire-format octet string |
22
|
1
|
|
|
1
|
|
2
|
my ( $self, $data, $offset ) = @_; |
23
|
|
|
|
|
|
|
|
24
|
1
|
|
|
|
|
3
|
( $self->{address}, $offset ) = Net::DNS::Text->decode( $data, $offset ); |
25
|
1
|
|
|
|
|
4
|
( $self->{sa}, $offset ) = Net::DNS::Text->decode( $data, $offset ); |
26
|
1
|
|
|
|
|
3
|
return; |
27
|
|
|
|
|
|
|
} |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
sub _encode_rdata { ## encode rdata as wire-format octet string |
31
|
5
|
|
|
5
|
|
9
|
my $self = shift; |
32
|
|
|
|
|
|
|
|
33
|
5
|
|
|
|
|
7
|
my $address = $self->{address}; |
34
|
5
|
|
|
|
|
13
|
return join '', $address->encode, $self->{sa}->encode; |
35
|
|
|
|
|
|
|
} |
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
sub _format_rdata { ## format rdata portion of RR string. |
39
|
2
|
|
|
2
|
|
3
|
my $self = shift; |
40
|
|
|
|
|
|
|
|
41
|
2
|
|
|
|
|
12
|
my $address = $self->{address}; |
42
|
2
|
|
|
|
|
7
|
return join ' ', $address->string, $self->{sa}->string; |
43
|
|
|
|
|
|
|
} |
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
sub _parse_rdata { ## populate RR from rdata in argument list |
47
|
1
|
|
|
1
|
|
3
|
my ( $self, @argument ) = @_; |
48
|
|
|
|
|
|
|
|
49
|
1
|
|
|
|
|
4
|
$self->address( shift @argument ); |
50
|
1
|
|
|
|
|
3
|
$self->sa(@argument); |
51
|
1
|
|
|
|
|
3
|
return; |
52
|
|
|
|
|
|
|
} |
53
|
|
|
|
|
|
|
|
54
|
|
|
|
|
|
|
|
55
|
|
|
|
|
|
|
sub _defaults { ## specify RR attribute default values |
56
|
1
|
|
|
1
|
|
2
|
my $self = shift; |
57
|
|
|
|
|
|
|
|
58
|
1
|
|
|
|
|
4
|
$self->sa(''); |
59
|
1
|
|
|
|
|
2
|
return; |
60
|
|
|
|
|
|
|
} |
61
|
|
|
|
|
|
|
|
62
|
|
|
|
|
|
|
|
63
|
|
|
|
|
|
|
sub address { |
64
|
6
|
|
|
6
|
1
|
18
|
my ( $self, @value ) = @_; |
65
|
6
|
|
|
|
|
9
|
for (@value) { $self->{address} = Net::DNS::Text->new($_) } |
|
2
|
|
|
|
|
6
|
|
66
|
6
|
100
|
|
|
|
24
|
return $self->{address} ? $self->{address}->value : undef; |
67
|
|
|
|
|
|
|
} |
68
|
|
|
|
|
|
|
|
69
|
|
|
|
|
|
|
|
70
|
|
|
|
|
|
|
sub sa { |
71
|
5
|
|
|
5
|
1
|
819
|
my ( $self, @value ) = @_; |
72
|
5
|
|
|
|
|
9
|
for (@value) { $self->{sa} = Net::DNS::Text->new($_) } |
|
3
|
|
|
|
|
7
|
|
73
|
5
|
100
|
|
|
|
19
|
return $self->{sa} ? $self->{sa}->value : undef; |
74
|
|
|
|
|
|
|
} |
75
|
|
|
|
|
|
|
|
76
|
|
|
|
|
|
|
|
77
|
2
|
|
|
2
|
1
|
528
|
sub ISDNaddress { return &address; } |
78
|
|
|
|
|
|
|
|
79
|
|
|
|
|
|
|
|
80
|
|
|
|
|
|
|
1; |
81
|
|
|
|
|
|
|
__END__ |