bli:
- 1
- 2
- 3
bla:
- 4
- 5
- 6
auslesen mit (und auch einfach demonstriert was "bless" eigentlich macht)
use strict;
use warnings;
use YAML;
use Data::Dumper;
{
my $cf = YAML::LoadFile('config.yaml');
print Dumper $cf;
my $bla = $cf->{bla};
my $bli = $cf->{bli};
print Dumper $bla;
printf "%s\n", ref $bla;
bless ($bla, 'HuType');
printf "%s\n", ref $bla;
print Dumper $bla;
}