1 package YAML::Marshall;
13 unless (grep { $_ eq $class} @{$package . '::ISA'}) {
14 push @{$package . '::ISA'}, $class;
20 $YAML::TagClass->{$tag} = $package;
21 ${$package . "::YamlTag"} = $tag;
28 my $tag = ${ref($self) . "::YamlTag"} || 'perl/' . ref($self);
29 $self->yaml_node($self, $tag);
33 my ($class, $node) = @_;
34 if (my $ynode = $class->yaml_ynode($node)) {
35 $node = $ynode->{NODE};
47 YAML::Node::ynode(@_);
56 YAML::Marshall - YAML marshalling class you can mixin to your classes
62 use YAML::Marshall -mixin;
66 For classes that want to handle their own YAML serialization.
70 Ingy döt Net <ingy@cpan.org>
74 Copyright (c) 2006. Ingy döt Net. All rights reserved.
76 This program is free software; you can redistribute it and/or modify it
77 under the same terms as Perl itself.
79 See L<http://www.perl.com/perl/misc/Artistic.html>