NAME
YAML::Visitor - Like visitor style traversal for yaml
SYNOPSIS
use YAML::Visitor;
my $visitor = YAML::Visitor->new(
callback => sub {
my $value = shift;
if (defined $value) {
$value =~ s/path_to/path/g;
}
$value;
}
);
my $config = $visitor->visit( file => $path );
my $config = $visitor->visit( data => $yaml );
DESCRIPTION
YAML::Visitor is like visitor style traversal for yaml
METHODS
new( callback => sub {...} )
visit( file => $path or data => $yaml );
AUTHOR
Kazuhiro Nishikawa <kazuhiro.nishikawa@gmail.com>
SEE ALSO
LICENSE
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.