134 |
$key eq 'libconf' and return $obj->{libconf}; |
$key eq 'libconf' and return $obj->{libconf}; |
135 |
substr($key, 0, 1) eq '_' and return $obj->{$key}; |
substr($key, 0, 1) eq '_' and return $obj->{$key}; |
136 |
my $section_position = $obj->{libconf}->findAtomPos( { type => 'SECTION', section_name => $key, sections => [ ] }); |
my $section_position = $obj->{libconf}->findAtomPos( { type => 'SECTION', section_name => $key, sections => [ ] }); |
137 |
|
defined $section_position or $section_position = $obj->{libconf}->appendAtom({ section_name => $key, type => 'SECTION', sections => [ ] }); |
138 |
my %ret; |
my %ret; |
139 |
tie %ret, 'Libconf::Glueconf::Samba::SectionWrapper', $obj->{libconf}, $section_position; |
tie %ret, 'Libconf::Glueconf::Samba::SectionWrapper', $obj->{libconf}, $section_position; |
140 |
\%ret; |
\%ret; |
173 |
sub CLEAR { |
sub CLEAR { |
174 |
my ($obj) = @_; |
my ($obj) = @_; |
175 |
debug; |
debug; |
176 |
$obj->{lastatom} -= $obj->{libconf}->clearSection($obj->{firstatom}); |
$obj->{lastatom} -= $obj->{libconf}->clearSection($obj->{firstatom}, 1); |
177 |
$obj->{lastatom} == $obj->{firstatom} + 1 or die "removed atoms number is wrong"; |
$obj->{lastatom} == $obj->{firstatom} + 1 or die "removed atoms number is wrong"; |
178 |
} |
} |
179 |
|
|