NAME
Cake::Utils::Serializer - serializing object from json to perl and vise verca
SYNOPSIS
get '/serialize' => sub {
my $self = shift;
my $c = shift;
my $hash = {
something => {
somethingelse => ['data',2]
}
};
my $json = $c->serialize($hash)->to_json;
$c->body($json);
#now back to perl
my $newhash = $c->serialize($json)->to_perl;
$c->dumper($newhash);
};
DESCRIPTION
Very minimal json serializer written in pure perl and work in most cases where you need a simple fast way to send json objects
It doesn't validate json string before converting it to perl but does not give a specific error message about the error.