line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Net::ISC::DHCPClient::InetLease; |
2
|
|
|
|
|
|
|
|
3
|
1
|
|
|
1
|
|
13
|
use 5.006; |
|
1
|
|
|
|
|
3
|
|
4
|
1
|
|
|
1
|
|
4
|
use strict; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
15
|
|
5
|
1
|
|
|
1
|
|
3
|
use warnings; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
301
|
|
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
=head1 NAME |
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
Net::ISC::DHCPClient - ISC dhclient AF inet lease object |
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
=head1 VERSION |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
Version 0.01 |
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
=cut |
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
our $VERSION = '0.01'; |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
|
21
|
|
|
|
|
|
|
sub new { |
22
|
0
|
|
|
0
|
0
|
|
my $proto = shift; |
23
|
0
|
|
0
|
|
|
|
my $class = ref($proto) || $proto; |
24
|
0
|
|
|
|
|
|
my $self = {}; |
25
|
0
|
|
|
|
|
|
$self->{INTERFACE} = undef; |
26
|
0
|
|
|
|
|
|
$self->{FIXED_ADDRESS} = undef; |
27
|
0
|
|
|
|
|
|
$self->{OPTION} = {}; |
28
|
0
|
|
|
|
|
|
$self->{RENEW} = undef; |
29
|
0
|
|
|
|
|
|
$self->{REBIND} = undef; |
30
|
0
|
|
|
|
|
|
$self->{EXPIRE} = undef; |
31
|
|
|
|
|
|
|
|
32
|
0
|
|
|
|
|
|
bless ($self, $class); |
33
|
|
|
|
|
|
|
|
34
|
0
|
|
|
|
|
|
return $self; |
35
|
|
|
|
|
|
|
} |
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
sub interface { |
38
|
0
|
|
|
0
|
0
|
|
my $self = shift; |
39
|
0
|
0
|
|
|
|
|
if (@_) { $self->{INTERFACE} = shift } |
|
0
|
|
|
|
|
|
|
40
|
0
|
|
|
|
|
|
return $self->{INTERFACE}; |
41
|
|
|
|
|
|
|
} |
42
|
|
|
|
|
|
|
sub fixed_address { |
43
|
0
|
|
|
0
|
0
|
|
my $self = shift; |
44
|
0
|
0
|
|
|
|
|
if (@_) { $self->{FIXED_ADDRESS} = shift } |
|
0
|
|
|
|
|
|
|
45
|
0
|
|
|
|
|
|
return $self->{FIXED_ADDRESS}; |
46
|
|
|
|
|
|
|
} |
47
|
|
|
|
|
|
|
sub option { |
48
|
0
|
|
|
0
|
0
|
|
my $self = shift; |
49
|
0
|
0
|
|
|
|
|
if (@_) { $self->{OPTION} = shift } |
|
0
|
|
|
|
|
|
|
50
|
0
|
|
|
|
|
|
return $self->{OPTION}; |
51
|
|
|
|
|
|
|
} |
52
|
|
|
|
|
|
|
sub renew { |
53
|
0
|
|
|
0
|
0
|
|
my $self = shift; |
54
|
0
|
0
|
|
|
|
|
if (@_) { $self->{RENEW} = shift } |
|
0
|
|
|
|
|
|
|
55
|
0
|
|
|
|
|
|
return $self->{RENEW}; |
56
|
|
|
|
|
|
|
} |
57
|
|
|
|
|
|
|
sub rebind { |
58
|
0
|
|
|
0
|
0
|
|
my $self = shift; |
59
|
0
|
0
|
|
|
|
|
if (@_) { $self->{REBIND} = shift } |
|
0
|
|
|
|
|
|
|
60
|
0
|
|
|
|
|
|
return $self->{REBIND}; |
61
|
|
|
|
|
|
|
} |
62
|
|
|
|
|
|
|
sub expire { |
63
|
0
|
|
|
0
|
0
|
|
my $self = shift; |
64
|
0
|
0
|
|
|
|
|
if (@_) { $self->{EXPIRE} = shift } |
|
0
|
|
|
|
|
|
|
65
|
0
|
|
|
|
|
|
return $self->{EXPIRE}; |
66
|
|
|
|
|
|
|
} |
67
|
|
|
|
|
|
|
|
68
|
|
|
|
|
|
|
# vim: tabstop=4 shiftwidth=4 softtabstop=4 expandtab: |
69
|
|
|
|
|
|
|
|
70
|
|
|
|
|
|
|
1; |