Group
Extension

Matches 2

Catalyst-Plugin-Server-JSONRPC ( J/JL/JLMARTIN/Catalyst-Plugin-Server-JSONRPC-0.07.tar.gz, JLMARTIN, 2010; MetaCPAN )
Catalyst-Plugin-Server-JSONRPC/lib/JSON/RPC/Common/Marshal/Catalyst.pm ( view source; MetaCPAN )
package JSON::RPC::Common::Marshal::Catalyst;
use Moose;

use Carp qw(croak);

extends qw(JSON::RPC::Common::Marshal::HTTP);

#OVERRIDE TO CATALYST REQUEST
sub post_request_to_call {
	my ( $self, $req
equest body
    my $body    = $request->body;
    my $content = do { local $/; <$body> };
	$self->json_to_call( $content );
}

sub write_result_to_response {
        my ( $self, $result, $response, @a
->$key(delete $args{$key});
                }
        }

        #Copied from base class
        #JSON::RPC::Common::Marshal::HTTP introduced a "die" here. The
        # following keys where left over
Catalyst-Plugin-Server-JSONRPC ( J/JL/JLMARTIN/Catalyst-Plugin-Server-JSONRPC-0.07.tar.gz, JLMARTIN, 2010; MetaCPAN )
Catalyst-Plugin-Server-JSONRPC/lib/Catalyst/Plugin/Server/JSONRPC.pm ( view source; MetaCPAN )

=head1 NAME

Catalyst::Plugin::Server::JSONRPC -- Catalyst JSONRPC Server Plugin

=head1 SYNOPSIS

    package MyApp;
    use Catalyst qw/Server Server::JSONRPC/;

    package MyApp::Controller::Exam
   sub echo : JSONRPC {                     # available as: example.echo
        my ( $self, $c, @args ) = @_;
        $c->stash->{jsonrpc} = join ', ', @args;
    }

    sub ping : JSONRPCPath('/ping
sh->{jsonrpc} = 'Pong';
    }

    sub world : JSONRPCRegex(/hello/) {      # available as: *hello*
        my ($self, $c) = @_;
        $c->stash->{jsonrpc} = 'World';
    }

    sub echo : JSONRPCLo

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