| 1 | package Net::ISC::DHCPd::Config::OptionSpace; | ||
| 2 | |||
| 3 | =head1 NAME | ||
| 4 | |||
| 5 | Net::ISC::DHCPd::Config::OptionSpace - Optionspace 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 | option space $name_attribute_value; | ||
| 15 | |||
| 16 | =head1 SYNOPSIS | ||
| 17 | |||
| 18 | See L<Net::ISC::DHCPd::Config/SYNOPSIS>. | ||
| 19 | |||
| 20 | =cut | ||
| 21 | |||
| 22 | 27 | ▶ | use Moose; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 23 | |||
| 24 | 27 | with 'Net::ISC::DHCPd::Config::Role'; | |
| 25 | |||
| 26 | =head1 ATTRIBUTES | ||
| 27 | |||
| 28 | =head2 name | ||
| 29 | |||
| 30 | Name of the option namespace as a string. | ||
| 31 | |||
| 32 | =cut | ||
| 33 | |||
| 34 | 27 | has name => ( | |
| 35 | is => 'rw', | ||
| 36 | isa => 'Str', | ||
| 37 | ); | ||
| 38 | |||
| 39 | =head2 regex | ||
| 40 | |||
| 41 | See L<Net::ISC::DHCPd::Config::Role/regex>. | ||
| 42 | |||
| 43 | =cut | ||
| 44 | 27 | our $regex = qr{^\s* option \s+ space \s+ (.*) ;}x; | |
| 45 | |||
| 46 | =head1 METHODS | ||
| 47 | |||
| 48 | =head2 captured_to_args | ||
| 49 | |||
| 50 | See L<Net::ISC::DHCPd::Config::Role/captured_to_args>. | ||
| 51 | |||
| 52 | =cut | ||
| 53 | |||
| 54 | 5 | ▶ | sub captured_to_args { |
|
Subroutine
captured_to_args: called CC=1 SCAR=0.0
Pod
documented
| |||
| 55 | 5 | return { name => $_[0] } | |
| 56 | } | ||
| 57 | |||
| 58 | =head2 generate | ||
| 59 | |||
| 60 | See L<Net::ISC::DHCPd::Config::Role/generate>. | ||
| 61 | |||
| 62 | =cut | ||
| 63 | |||
| 64 | 2 | ▶ | sub generate { |
|
Subroutine
generate: called CC=1 SCAR=0.0
Pod
documented
| |||
| 65 | 2 | return 'option space ' . shift->name. ';'; | |
| 66 | } | ||
| 67 | |||
| 68 | =head1 COPYRIGHT & LICENSE | ||
| 69 | |||
| 70 | =head1 AUTHOR | ||
| 71 | |||
| 72 | See L<Net::ISC::DHCPd>. | ||
| 73 | |||
| 74 | =cut | ||
| 75 | 27 | __PACKAGE__->meta->make_immutable; | |
| 76 | 27 | 1; | |