Group
Extension

Matches 35358

JSON-RPC2-AnyEvent ( Y/YA/YANOTHER/JSON-RPC2-AnyEvent-0.03.tar.gz, YANOTHER, 2020; MetaCPAN )
JSON-RPC2-AnyEvent/lib/JSON/RPC2/AnyEvent/Constants.pm ( view source; MetaCPAN )
package JSON::RPC2::AnyEvent::Constants;
use 5.010;
use strict;
use warnings;


my %constants;
BEGIN{
    # Based upon JSON-RPC spec 2.0 - http://www.jsonrpc.org/specification
    %constants = (
     
valid JSON was received by the server.
                                         # An error occurred on the server while parsing the JSON text.
        ERR_INVALID_REQUEST  => -32600,  # The JSON sent 
   => -32602,  # Invalid method parameter(s).
        ERR_INTERNAL_ERROR   => -32603,  # Internal JSON-RPC error.
        ERR_SERVER_ERROR     => -32000,  # -32000 to -32099: Reserved for implementati
JSON-RPC2-AnyEvent ( Y/YA/YANOTHER/JSON-RPC2-AnyEvent-0.03.tar.gz, YANOTHER, 2020; MetaCPAN )
JSON-RPC2-AnyEvent/lib/JSON/RPC2/AnyEvent/Server.pm ( view source; MetaCPAN )
package JSON::RPC2::AnyEvent::Server;
use 5.010;
use strict;
use warnings;

our $VERSION = "0.03";

use AnyEvent;
use Carp 'croak';
use Scalar::Util 'reftype';
use Try::Tiny;

use JSON::RPC2::AnyEvent
lf = shift;
    my $json = shift;
    my $ret_cv = AE::cv;
    try{
        my $type = _check_format($json);  # die when $json's format is invalid
        my $method = $self->{$json->{method}};
      
  unless ( $method ) {  # Method not found
            $ret_cv->send(_make_error_response($json->{id}, ERR_METHOD_NOT_FOUND, 'Method not found'));
            return $ret_cv;
        }
        if ( $t
JSON-RPC2-AnyEvent ( Y/YA/YANOTHER/JSON-RPC2-AnyEvent-0.03.tar.gz, YANOTHER, 2020; MetaCPAN )
JSON-RPC2-AnyEvent/lib/JSON/RPC2/AnyEvent.pm ( view source; MetaCPAN )
package JSON::RPC2::AnyEvent;

our $VERSION = "0.03";

use JSON::RPC2::AnyEvent::Server;

1;
__END__

=encoding utf-8

=head1 NAME

JSON::RPC2::AnyEvent - Yet-another, transport-independent and asynch
ronous JSON-RPC 2.0 implementation

=head1 SYNOPSIS

    use JSON::RPC2::AnyEvent::Server;

    my $srv = JSON::RPC2::AnyEvent::Server->new(
        hello => "[family_name, first_name]" => sub{
      
= $srv->dispatch({
        jsonrpc => "2.0",
        id      => 1,
        method  => 'hello',
        params  => [qw(Sogoru Kyo)],
    });
    my $res = $cv->recv;  # { jsonrpc => "2.0", id => 1, res
Dancer2-Session-JSON ( C/CR/CROMEDOME/Dancer2-Session-JSON-0.003.tar.gz, CROMEDOME, 2020; MetaCPAN )
Dancer2-Session-JSON/lib/Dancer2/Session/JSON.pm ( view source; MetaCPAN )
rnings;

package Dancer2::Session::JSON;
# ABSTRACT: Dancer 2 session storage in files with JSON

our $VERSION = '0.003';

use Moo;
use Dancer2::Core::Types;
use JSON;

#------------------------------
     => 'ro',
    isa     => Str,
    default => sub { ".json" },
);

has _encoder => (
    is      => 'lazy',
    isa     => InstanceOf ['JSON'],
    handles => {
        '_freeze' => 'encode',
     
   '_thaw'   => 'decode'
    },
);

sub _build__encoder {
    my ($self) = @_;
    return JSON->new->allow_blessed->convert_blessed;
}

#---------------------------------------------------------------
Test-Mojo-Role-Debug-JSON ( A/AT/ATOOMIC/Test-Mojo-Role-Debug-JSON-0.005.tar.gz, ATOOMIC, 2020; MetaCPAN )
Test-Mojo-Role-Debug-JSON/lib/Test/Mojo/Role/Debug/JSON.pm ( view source; MetaCPAN )
package Test::Mojo::Role::Debug::JSON;
$Test::Mojo::Role::Debug::JSON::VERSION = '0.005';
# ABSTRACT: a JSON extension to Test::Mojo::Role::Debug

use Mojo::Base -role;

with 'Test::Mojo::Role::Debug'
::JSON qw{from_json};
use Mojo::JSON::Pointer;
use Test::More ();

# VERSION

sub djson {
    my ( $self, $pointer ) = @_;
    return $self->success ? $self : $self->djsona( $pointer );
}

sub djsona 


    local $@;
    my $json = eval { from_json( $self->tx->res->content->asset->slurp ) };

    Test::More::diag( $@ ) && return $self if $@;
    Test::More::diag( "DEBUG JSON DUMPER:\n",
      Test:
Ark ( S/SO/SONGMU/Ark-1.22.tar.gz, SONGMU, 2020; MetaCPAN )
Ark/lib/Ark/View/JSON.pm ( view source; MetaCPAN )
package Ark::View::JSON;
use strict;
use warnings;
use Ark 'View';
use JSON;

has allow_callback => (
    is      => 'rw',
    isa     => 'Bool',
    default => 0,
);

has callback_param => (
    is  
;

has json_driver => (
    is      => 'rw',
    isa     => 'Object',
    lazy    => 1,
    default => sub {
        my $self = shift;
        JSON->new->utf8->allow_nonref;
    },
);

has json_dumper
 'CodeRef',
    lazy    => 1,
    default => sub {
        my $self = shift;
        sub { $self->json_driver->encode(@_) };
    },
);

has status_code_field => (
    is  => 'ro',
    isa => "Str",
);
Log-ger-Layout-JSON ( P/PE/PERLANCAR/Log-ger-Layout-JSON-0.002.tar.gz, PERLANCAR, 2020; MetaCPAN )
Log-ger-Layout-JSON/lib/Log/ger/Layout/JSON.pm ( view source; MetaCPAN )
package Log::ger::Layout::JSON;

our $AUTHORITY = 'cpan:PERLANCAR'; # AUTHORITY
our $DATE = '2020-03-07'; # DATE
our $DIST = 'Log-ger-Layout-JSON'; # DIST
our $VERSION = '0.002'; # VERSION

use 5.0100
ub _encode {
    my ($pkg, $msg) = @_;

    state $json = do {
        require JSON::MaybeXS;
        JSON::MaybeXS->new->canonical;
    };
    $json->encode($msg);
}

sub get_hooks {
    __PACKAGE__-


1;
# ABSTRACT: Layout log message as a JSON object (hash)

__END__

=pod

=encoding UTF-8

=head1 NAME

Log::ger::Layout::JSON - Layout log message as a JSON object (hash)

=head1 VERSION

This docu
Pegex-JSON ( I/IN/INGY/Pegex-JSON-0.31.tar.gz, INGY, 2020; MetaCPAN )
Pegex-JSON/lib/Pegex/JSON/Data.pm ( view source; MetaCPAN )
package Pegex::JSON::Data;
use Pegex::Base;
extends 'Pegex::Tree';

use boolean;

sub got_json { shift @{(pop)} }

sub got_object { +{map @$_, @{(pop)}} }

my %escapes = (
    '"' => '"',
    '/' => "
ing {
    my $string = pop;
    $string =~ s/\\(["\/\\bfnrt])/$escapes{$1}/ge;
    # This handles JSON encoded Unicode surrogate pairs
    $string =~ s/\\u([0-9a-f]{4})\\u([0-9a-f]{4})/pack "U*", hex(
Data-Serializer ( N/NE/NEELY/Data-Serializer-0.65.tar.gz, NEELY, 2020; MetaCPAN )
Data-Serializer/lib/Data/Serializer/JSON.pm ( view source; MetaCPAN )
ializer::JSON;
BEGIN { @Data::Serializer::JSON::ISA = qw(Data::Serializer) }

use warnings;
use strict;
use JSON;
use vars qw($VERSION @ISA);

$VERSION = '0.04';

sub serialize {
	return JSON->VERSION
jToJson($_[1]) : JSON->new->utf8->encode($_[1]);
}

sub deserialize {
	#return JSON->VERSION < 2 ? JSON->new->jsonToObj($_[1]) : JSON->new->decode($_[1]);
	$_[1] and return JSON->VERSION < 2 ? JSON->n
ew->jsonToObj($_[1]) : JSON->new->utf8->decode($_[1]);
}

1;
__END__



=head1 NAME

Data::Serializer::JSON - Creates bridge between Data::Serializer and JSON

=head1 SYNOPSIS

  use Data::Serializer:
Pegex-JSON ( I/IN/INGY/Pegex-JSON-0.31.tar.gz, INGY, 2020; MetaCPAN )
Pegex-JSON/lib/Pegex/JSON/Grammar.pm ( view source; MetaCPAN )
x::JSON::Grammar;
use Pegex::Base;
extends 'Pegex::Grammar';

use constant file => '../json-pgx/json.pgx';

sub make_tree {   # Generated/Inlined by Pegex::Grammar (0.73)
  {
    '+grammar' => 'json',

    '+include' => 'pegex-atoms',
    '+toprule' => 'json',
    '+version' => '0.0.1',
    '_' => {
      '.rgx' => qr/\G\s*/
    },
    'array' => {
      '.all' => [
        {
          '-skip' => 1
 qr/\G\s*\]\s*/
        }
      ]
    },
    'false' => {
      '.rgx' => qr/\Gfalse/
    },
    'json' => {
      '.all' => [
        {
          '.ref' => '_'
        },
        {
          '.ref' =
Pegex-JSON ( I/IN/INGY/Pegex-JSON-0.31.tar.gz, INGY, 2020; MetaCPAN )
Pegex-JSON/lib/Pegex/JSON.pm ( view source; MetaCPAN )
ackage Pegex::JSON;
BEGIN { $ENV{PERL_PEGEX_AUTO_COMPILE} = 'Pegex::JSON::Grammar' }
our $VERSION = '0.31';

use Pegex::Base;

use Pegex::Parser;
use Pegex::JSON::Grammar;
use Pegex::JSON::Data;

sub 
load {
    my ($self, $json) = @_;
    Pegex::Parser->new(
        grammar => Pegex::JSON::Grammar->new,
        receiver => Pegex::JSON::Data->new,
        # debug => 1,
    )->parse($json);
}

1;
Data-Serializer ( N/NE/NEELY/Data-Serializer-0.65.tar.gz, NEELY, 2020; MetaCPAN )
Data-Serializer/lib/Data/Serializer/JSON/Syck.pm ( view source; MetaCPAN )
package Data::Serializer::JSON::Syck;
BEGIN { @Data::Serializer::JSON::Syck::ISA = qw(Data::Serializer) }

use warnings;
use strict;
use JSON::Syck;
use vars qw($VERSION @ISA);

$VERSION = '0.02';

su
 return JSON::Syck::Load($_[1]);
}

1;
__END__

=head1 NAME

Data::Serializer::JSON::Syck - Creates bridge between Data::Serializer and JSON::Syck

=head1 SYNOPSIS

  use Data::Serializer::JSON::Syck;
head1 COPYRIGHT

  This program is free software; you can redistribute it
  and/or modify it under the same terms as Perl itself.

=head1 SEE ALSO

perl(1), Data::Serializer(3), JSON::Syck(3).

=cut

JSON-MultiValueOrdered ( T/TO/TOBYINK/JSON-MultiValueOrdered-0.006.tar.gz, TOBYINK, 2020; MetaCPAN )
JSON-MultiValueOrdered/lib/JSON/MultiValueOrdered.pm ( view source; MetaCPAN )
 if $] < 5.010, 'UNIVERSAL::DOES';

{
	package JSON::MultiValueOrdered;
	
	our $AUTHORITY = 'cpan:TOBYINK';
	our $VERSION   = '0.006';
	
	use base qw(JSON::Tiny::Subclassable);
	
	use Tie::Hash::Multi
__END__

=head1 NAME

JSON::MultiValueOrdered - handle JSON like {"a":1, "a":2}

=head1 SYNOPSIS

   use Test::More tests => 4;
   use JSON::MultiValueOrdered;
   
   my $j = JSON::MultiValueOrdered->
   isa_ok $j, 'JSON::Tiny';
   
   my $data = $j->decode(<<'JSON');
   {
      "a": 1,
      "b": 2,
      "a": 3,
      "b": 4
   }
   JSON
   
   # As you'd expect, for repeated values, the last val
JSON-MultiValueOrdered ( T/TO/TOBYINK/JSON-MultiValueOrdered-0.006.tar.gz, TOBYINK, 2020; MetaCPAN )
JSON-MultiValueOrdered/lib/JSON/Tiny/Subclassable.pm ( view source; MetaCPAN )
.008;
use strict;
use warnings;

{
	package JSON::Tiny::Subclassable;

	our $AUTHORITY = 'cpan:TOBYINK';
	our $VERSION   = '0.006';
	our @ISA       = qw(JSON::Tiny);
	
	use B;
	use Encode ();
	use Sca
mport('j');
	
	# Literal names
	my $FALSE = bless \(my $false = 0), 'JSON::Tiny::_Bool';
	my $TRUE  = bless \(my $true  = 1), 'JSON::Tiny::_Bool';
	
	# Escaped special character map (with u2028 and u2
= qr/[\x20\x09\x0a\x0d]*/;
	
	sub DOES {
		my ($proto, $role) = @_;
		return 1 if $role eq 'Mojo::JSON';
		return $proto->SUPER::DOES($role);
	}
	
	sub decode {
		my ($self, $bytes) = @_;
		
		# Clean
JSON-Transform ( E/ET/ETJ/JSON-Transform-0.03.tar.gz, ETJ, 2020; MetaCPAN )
JSON-Transform/lib/JSON/Transform/Grammar.pm ( view source; MetaCPAN )
package JSON::Transform::Grammar;

use strict;
use warnings;
use base 'Pegex::Grammar';
use constant file => './json-transform.pgx';

=head1 NAME

JSON::Transform::Grammar - JSON::Transform grammar

=
SYNOPSIS

  use Pegex::Parser;
  use JSON::Transform::Grammar;
  use Pegex::Tree::Wrap;
  use Pegex::Input;

  my $parser = Pegex::Parser->new(
    grammar => JSON::Transform::Grammar->new,
    receiv
e JSON::Transform grammar.

=head1 METHODS

=head2 make_tree

Override method from L<Pegex::Grammar>.

=cut

sub make_tree {   # Generated/Inlined by Pegex::Grammar (0.67)
  {
    '+grammar' => 'json-
Spreadsheet-Wright ( T/TO/TOBYINK/Spreadsheet-Wright-0.107.tar.gz, TOBYINK, 2020; MetaCPAN )
Spreadsheet-Wright/lib/Spreadsheet/Wright/JSON.pm ( view source; MetaCPAN )
sheet::Wright::JSON;

use 5.010;
use strict;
use warnings;
no warnings qw( uninitialized numeric );

BEGIN {
	$Spreadsheet::Wright::JSON::VERSION   = '0.107';
	$Spreadsheet::Wright::JSON::AUTHORITY = 
'cpan:TOBYINK';
}

use Carp;
use JSON;

use parent qw(Spreadsheet::Wright);

sub new
{
	my ($class, %args) = @_;
	my $self = bless { 'options' => \%args }, $class;
	$self->{'_FILENAME'} = $args{'file'
{'_FH'}->print(
			to_json($self->{'data'}->{$self->{'_WORKSHEET'}}, $self->{'json_options'})
			);
	}
	else
	{
		$self->{'_FH'}->print(
			to_json($self->{'data'}, $self->{'json_options'})
			);
	}
	
portable-loader ( T/TO/TOBYINK/portable-loader-0.003.tar.gz, TOBYINK, 2020; MetaCPAN )
portable-loader/lib/portable/loader/JSON.pm ( view source; MetaCPAN )
JSON;

our $AUTHORITY = 'cpan:TOBYINK';
our $VERSION   = '0.003';

use portable::lib;
use portable::loader;

sub init {
	my $me = shift;
	my ($loader) = @_;
	$loader->register_extension('portable.json
ur $decoder;

sub parse {
	my $me = shift;
	my ($filename) = @_;
	require JSON::Eval;
	$decoder ||= JSON::Eval->new;
	my $jsontext = do {
		open my $fh, '<', $filename
			or die "Could not open $filen
ame: $!";
		local $/;
		<$fh>;
	};
	return ($filename => $decoder->decode($jsontext));
}

1;

JSON-Transform ( E/ET/ETJ/JSON-Transform-0.03.tar.gz, ETJ, 2020; MetaCPAN )
JSON-Transform/lib/JSON/Transform.pm ( view source; MetaCPAN )
kage JSON::Transform;

use strict;
use warnings;
use Exporter 'import';
use Storable qw(dclone);
use JSON::Transform::Grammar;
use XML::Invisible qw(make_parser);

use constant DEBUG => $ENV{JSON_TRAN
 %IS_BACKSLASH_ENTITY = map {$_=>1} qw(
  jsonBackslashDouble
  jsonBackslashDollar
  jsonBackslashQuote
  jsonBackslashGrave
);

my $parser = make_parser(JSON::Transform::Grammar->new);
sub parse_tra
$topdata, $destptr, $newdata, $uservals) = @_;
  my $name = $destptr->{nodename};
  if ($name eq 'jsonPointer') {
    $destptr = _eval_expr($topdata, $destptr, _make_sysvals(), $uservals, 1);
    _poi
DateTime-Format-JSON-MicrosoftDateFormat ( M/MR/MRDVT/DateTime-Format-JSON-MicrosoftDateFormat-0.05.tar.gz, MRDVT, 2019; MetaCPAN )
DateTime-Format-JSON-MicrosoftDateFormat/lib/DateTime/Format/JSON/MicrosoftDateFormat.pm ( view source; MetaCPAN )
JSON::MicrosoftDateFormat;
use strict;
use warnings;
use DateTime;

our $VERSION = '0.05';
our $PACKAGE = __PACKAGE__;

=head1 NAME

DateTime::Format::JSON::MicrosoftDateFormat - Parse and format JSON
osoftDateFormat strings

=head1 SYNOPSIS

  use DateTime::Format::JSON::MicrosoftDateFormat;

  my $formatter = DateTime::Format::JSON::MicrosoftDateFormat->new;
  my $dt        = $formatter->parse_da
:JSON::MicrosoftDateFormat -e 'print DateTime::Format::JSON::MicrosoftDateFormat->new->parse_datetime(shift), "\n";' '/Date(1392606509000-0500)/'

=head1 DESCRIPTION

This module understands the JSON 
JSON-Eval ( T/TO/TOBYINK/JSON-Eval-0.002.tar.gz, TOBYINK, 2019; MetaCPAN )
JSON-Eval/lib/JSON/Eval.pm ( view source; MetaCPAN )
JSON::Eval;
	require Carp;
	Carp::croak($@);
};

package JSON::Eval;

our $AUTHORITY = 'cpan:TOBYINK';
our $VERSION   = '0.002';

use Scalar::Util qw(blessed);

sub new {
	my $class = shift;
	my $json
 = @_ ? $_[0] : do { require JSON::MaybeXS; JSON::MaybeXS->new };
	bless \$json, $class;
}

sub AUTOLOAD {
	my $self = shift;
	our $AUTOLOAD;
	( my $method = $AUTOLOAD ) =~ s/.*:://;
	my $r = $$self->
{
			require Carp;
			Carp::croak("Cannot serialize coderef that closes over lexical variables to JSON: ".join ",", sort keys %$lexicals);
		}
		require B::Deparse;
		my $dp = 'B::Deparse'->new;
		$dp

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