Group
Extension

Net-Fluidinfo/lib/Net/Fluidinfo/Value/Integer.pm

package Net::Fluidinfo::Value::Integer;
use Moose;
extends 'Net::Fluidinfo::Value::Native';

# A Perl integer is a JSON integer. Sanitize with int().
sub to_json {
    my $self = shift;
    no warnings; # the value may not be an integer indeed
    int $self->value;
}

no Moose;
__PACKAGE__->meta->make_immutable;

1;


Powered by Groonga
Maintained by Kenichi Ishigaki <ishigaki@cpan.org>. If you find anything, submit it on GitHub.