line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Net::ISC::DHCPd::Config::Filename; |
2
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
=head1 NAME |
4
|
|
|
|
|
|
|
|
5
|
|
|
|
|
|
|
Net::ISC::DHCPd::Config::Filename - Filename config parameter |
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
=head1 DESCRIPTION |
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
See L<Net::ISC::DHCPd::Config::Role> for methods and attributes without |
10
|
|
|
|
|
|
|
documentation. |
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
An instance from this class, comes from / will produce: |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
filename "$file_attribute_value"; |
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
=head1 SYNOPSIS |
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
See L<Net::ISC::DHCPd::Config/SYNOPSIS>. |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
=cut |
21
|
|
|
|
|
|
|
|
22
|
21
|
|
|
21
|
|
12114
|
use Moose 0.90; |
|
21
|
|
|
|
|
560
|
|
|
21
|
|
|
|
|
152
|
|
23
|
21
|
|
|
21
|
|
109768
|
use Path::Class::File 0.19; |
|
21
|
|
|
|
|
625
|
|
|
21
|
|
|
|
|
577
|
|
24
|
21
|
|
|
21
|
|
99
|
use MooseX::Types::Path::Class 0.05 qw(File); |
|
21
|
|
|
|
|
329
|
|
|
21
|
|
|
|
|
156
|
|
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
with 'Net::ISC::DHCPd::Config::Role'; |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
=head1 ATTRIBUTES |
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
=head2 file |
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
This attribute hold a L<Path::Class::File> object. |
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
=cut |
35
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
has file => ( |
37
|
|
|
|
|
|
|
is => 'rw', |
38
|
|
|
|
|
|
|
isa => File, |
39
|
|
|
|
|
|
|
coerce => 1, |
40
|
|
|
|
|
|
|
); |
41
|
|
|
|
|
|
|
|
42
|
|
|
|
|
|
|
=head2 regex |
43
|
|
|
|
|
|
|
|
44
|
|
|
|
|
|
|
See L<Net::ISC::DHCPd::Config::Role/regex>. |
45
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
=cut |
47
|
|
|
|
|
|
|
|
48
|
|
|
|
|
|
|
our $regex = qr{^\s* filename \s+ (\S+) ;}x; |
49
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
|
=head1 METHODS |
51
|
|
|
|
|
|
|
|
52
|
|
|
|
|
|
|
=head2 captured_to_args |
53
|
|
|
|
|
|
|
|
54
|
|
|
|
|
|
|
See L<Net::ISC::DHCPd::Config::Role/captured_to_args>. |
55
|
|
|
|
|
|
|
|
56
|
|
|
|
|
|
|
=cut |
57
|
|
|
|
|
|
|
|
58
|
|
|
|
|
|
|
sub captured_to_args { |
59
|
0
|
|
|
0
|
1
|
|
return { file => Path::Class::File->new($_[0]) }; |
60
|
|
|
|
|
|
|
} |
61
|
|
|
|
|
|
|
|
62
|
|
|
|
|
|
|
=head2 generate |
63
|
|
|
|
|
|
|
|
64
|
|
|
|
|
|
|
See L<Net::ISC::DHCPd::Config::Role/generate>. |
65
|
|
|
|
|
|
|
|
66
|
|
|
|
|
|
|
=cut |
67
|
|
|
|
|
|
|
|
68
|
|
|
|
|
|
|
sub generate { |
69
|
0
|
|
|
0
|
1
|
|
return 'filename ' .shift->file .';'; |
70
|
|
|
|
|
|
|
} |
71
|
|
|
|
|
|
|
|
72
|
|
|
|
|
|
|
=head1 COPYRIGHT & LICENSE |
73
|
|
|
|
|
|
|
|
74
|
|
|
|
|
|
|
=head1 AUTHOR |
75
|
|
|
|
|
|
|
|
76
|
|
|
|
|
|
|
See L<Net::ISC::DHCPd>. |
77
|
|
|
|
|
|
|
|
78
|
|
|
|
|
|
|
=cut |
79
|
|
|
|
|
|
|
__PACKAGE__->meta->make_immutable; |
80
|
|
|
|
|
|
|
1; |