it!"
unless $self->exists($key);
}
return $self->$orig($key, $maybe_value);
};
sub TO_JSON { +{shift->elements} }
sub AUTOLOAD {
my ($self, @args) = @_;
my $key = our $AUTOLOAD;
$ke
::Perl::Collection::Hash>
and addes a bit of error checking and a method it ease integration with JSON encoders.
This is a 'per-request' Catalyst model, which means that each new request can get one
original will be the same references in the clone.
=head2 TO_JSON
Returns a hashref of all the existing data suitable to send to a JSON serializer.
=head1 SEE ALSO
L<Catalyst>, L<Data::Perl>.
=h