Group
Extension

Matches 35358

Dancer-Plugin-Progress ( M/MS/MSTPLBG/Dancer-Plugin-Progress-0.001.tar.gz, MSTPLBG, 2011; MetaCPAN )
Dancer-Plugin-Progress/lib/Dancer/Plugin/Progress.pm ( view source; MetaCPAN )
{_progress};
};

get '/_progress/:name' => sub {
    header 'Content-Type' => 'application/json';
    to_json(_progress(params->{name}));
};

register_plugin;

1;

=pod

=head1 NAME

Dancer::Plugin::P
iv>

    <script type="text/javascript">
    function pollProgress(name, interval) {
        $.getJSON('/_progress/' + name, function(pg) {
            if (pg.progress === null) {
                $('#
Net-SMS-TxtLocal ( E/EV/EVDB/Net-SMS-TxtLocal-0.03.tar.gz, EVDB, 2011; MetaCPAN )
Net-SMS-TxtLocal/lib/Net/SMS/TxtLocal.pm ( view source; MetaCPAN )
ckage Net::SMS::TxtLocal;

use Carp;
use LWP::UserAgent;
use Moose;
use namespace::autoclean;
use JSON;

use 5.006;

our $VERSION = '0.03';

=head1 NAME

Net::SMS::TxtLocal - Send SMS messages using t
ath;
    my $post_query = {
        uname => $self->uname,
        pword => $self->pword,
        json  => 1,
        %$query,
    };

    my $response = $self->ua->post( $url, $post_query );
    croa
return the response unless it looks like JSON
    return $content unless $content =~ m{ \A \s* \{ \s* "\w }x;

    # decode the JSON
    my $data = decode_json($content);

    # check for the error ke
Project-Easy ( A/AP/APLA/Project-Easy-0.30.tar.gz, APLA, 2011; MetaCPAN )
Project-Easy/lib/Project/Easy/Daemon.pm ( view source; MetaCPAN )
unning after kill, please kill manually\n";
				exit;
			}
		}
		
		$self->launch;
	}
	
}

sub TO_JSON {
	my $self = shift;
	
	my $result = {map {$_ => $self->{$_}} keys %$self};
	$result->{pid_file} 
Giddy ( I/ID/IDOPEREL/Giddy-0.013_001.tar.gz, IDOPEREL, 2011; MetaCPAN )
Giddy/lib/Giddy/Manual.pod ( view source; MetaCPAN )
chosen as the serialization
format since YAML is well suited as a human editable format; however, JSON
support is planned). This module provides an API for usage by Perl applications.

Main database f
 of the document. Quite frankly, Giddy will not care if the files
are in fact binary. They can be JSON or plain text files for all it cares, but as
long as they are separate from attributes.yaml, they
 A document file (implies '_body' attribute holds HTML data)
		data.json				<-- A document file (implies '_body' attribute holds JSON text)
		about/					<-- A document directory
			attributes.yaml				
Giddy ( I/ID/IDOPEREL/Giddy-0.013_001.tar.gz, IDOPEREL, 2011; MetaCPAN )
Giddy/lib/Giddy.pm ( view source; MetaCPAN )
chosen as the serialization
format since YAML is well suited as a human editable format; however, JSON
support is planned). This module provides an API for usage by Perl applications.

Main database f
Project-Easy ( A/AP/APLA/Project-Easy-0.30.tar.gz, APLA, 2011; MetaCPAN )
Project-Easy/lib/Project/Easy/Helper.pm ( view source; MetaCPAN )
	# TODO: store database config
	$etc->append ("$project_id.json")->as_file->store_if_empty ('{}');
	$etc->append ($instance, "$project_id.json")->as_file->store_if_empty ('{}');
	
	$etc->append ('proj
};

use Class::Easy;

use base qw(Project::Easy);

has id => '{$project_id}';
has conf_format => 'json';

my $class = __PACKAGE__;

has entity_prefix => join '::', $class, 'Entity', '';

$class->init;
Mojolicious-Plugin-Disqus ( M/MA/MADCAT/Mojolicious-Plugin-Disqus-1.22.tar.gz, MADCAT, 2011; MetaCPAN )
Mojolicious-Plugin-Disqus/lib/Mojolicious/Plugin/Disqus.pm ( view source; MetaCPAN )
te with the Disqus API
    pass_api_errors (optional)  When set, any API errors are returned as a JSON object instead of
                                throwing an exception.

=head1 METHODS/HELPERS
Project-Easy ( A/AP/APLA/Project-Easy-0.30.tar.gz, APLA, 2011; MetaCPAN )
Project-Easy/lib/Project/Easy/Config.pm ( view source; MetaCPAN )
xpansion);
	
	patch ($conf, $alt);
	
	return $conf;
}

my $ext_syn = {
	'pl' => 'perl',
	'js' => 'json',
};

sub serializer {
	shift;
	my $type = shift;
	
	$type = $ext_syn->{$type}
		if exists $ext_s
Project-Easy ( A/AP/APLA/Project-Easy-0.30.tar.gz, APLA, 2011; MetaCPAN )
Project-Easy/lib/Project/Easy/Helper/Config.pm ( view source; MetaCPAN )
o parse config file
	my $serializer_json = $conf_package->serializer ('json');
	
	if ($command =~ /^(?:--)?dump$/) {
		print "\"$key\" => ";
		print $serializer_json->dump_struct ($struct);
		print "\
les
		
		my $fixup_struct = {};
		
		if ($command eq 'template') {

			my $template = $serializer_json->parse_string (
				$templates->{'template-' . $remains[0]}
			);
			
			eval "\$fixup_struct->$k
WebService-Futu ( V/VA/VASEKD/WebService-Futu-0.02.tar.gz, VASEKD, 2011; MetaCPAN )
WebService-Futu/lib/WebService/Futu.pm ( view source; MetaCPAN )
package WebService::Futu;

use warnings;
use strict;

use LWP::UserAgent;
use JSON::XS;
use HTTP::Status qw(:constants :is status_message);
use HTTP::Cookies;

use Data::Dumper;

=head1 NAME

WebServi
 $content) = @_;

	my $json_content = encode_json($content) if $content;
	my $max = 10;

	for (my $i = 0; $i < $max; $i++){
	
		my $body = $self->_perform($method, $query, $json_content); 

		# run co
mmand
    	if ($body->code eq HTTP_OK) {
        	if ($body->content){
				return decode_json($body->content)
			}else{
				return {};
			};
    	} elsif ($body->code eq HTTP_UNAUTHORIZED) {
				# mak
POE-Component-IRC-Plugin-Eval ( H/HI/HINRIK/POE-Component-IRC-Plugin-Eval-0.07.tar.gz, HINRIK, 2011; MetaCPAN )
POE-Component-IRC-Plugin-Eval/lib/POE/Component/IRC/Plugin/Eval.pm ( view source; MetaCPAN )
DARK_GREEN ORANGE TEAL BROWN);
use POE::Component::IRC::Plugin qw(PCI_EAT_NONE);
use POE::Filter::JSON;
use POE::Wheel::ReadWrite;
use POE::Wheel::SocketFactory;

sub new {
    my ($package, %args) = 
} = POE::Wheel::ReadWrite->new(
        Handle     => $socket,
        Filter     => POE::Filter::JSON->new(),
        InputEvent => 'eval_read',
        ErrorEvent => 'eval_error',
    );

    $eval-
POE-Component-Client-Stomp-Utils ( K/KE/KESTEB/POE-Component-Client-Stomp-Utils-0.02.tar.gz, KESTEB, 2011; MetaCPAN )
POE-Component-Client-Stomp-Utils/lib/POE/Component/Client/Stomp/Utils.pm ( view source; MetaCPAN )
n before 
calling these methods. I have found the JSON is a light, and efficent 
serialization method. And just about every other lanaguage has a JSON 
implementation readily avaiable.

Some terminolo
              data => 'this is my packet'});
 $heap->{server}->put($frame);

or

 $message = objToJson($data);
 $frame = $stomp->send({destination => 'test', 
                        data => $message,
HEAP, ARG0];

     my $frame = $stomp->ack({'message-id' => $stomp->message_id});
     my $data = jsonToObj($frame->body);

     handle_data($data);
     $heap->{server}->put($frame);

 }

=back

=hea
RDF-AllegroGraph-Easy ( D/DR/DRRHO/RDF-AllegroGraph-Easy-0.08.tar.gz, DRRHO, 2011; MetaCPAN )
RDF-AllegroGraph-Easy/lib/RDF/AllegroGraph/Repository.pm ( view source; MetaCPAN )
 $ua->post ($self->{path} . '/statements',
				       'Content-Type' => 'application/json', 'Content' => encode_json (\@stmts) );
		die "protocol error: ".$resp->status_line.' ('.$resp->content.')' un
->new (PUT => $self->{path} . '/statements',
					       [ 'Content-Type' => 'application/json' ], encode_json (\@stmts));
		my $resp = $ua->request ($requ);
		die "protocol error: ".$resp->status_lin
OST => $self->{path} . '/statements/delete',
					       [ 'Content-Type' => 'application/json' ], encode_json (\@facts));
		my $resp = $ua->request ($requ);
		die "protocol error: ".$resp->status_lin
RDF-AllegroGraph-Easy ( D/DR/DRRHO/RDF-AllegroGraph-Easy-0.08.tar.gz, DRRHO, 2011; MetaCPAN )
RDF-AllegroGraph-Easy/lib/RDF/AllegroGraph/Server3.pm ( view source; MetaCPAN )
le for the AGv3 series

=head1 SYNOPSIS

# same interface as RDF::AllegroGraph::Server

=cut

use JSON;
use Data::Dumper;

use RDF::AllegroGraph::Catalog3;

=pod

=head1 INTERFACE

=head2 Methods

=ov
gs');
    die "protocol error: ".$resp->status_line unless $resp->is_success;
    my $cats = from_json ($resp->content);
#    warn Dumper $cats;
    return 
	map { $_ => RDF::AllegroGraph::Catalog3->n
App-EvalServer ( H/HI/HINRIK/App-EvalServer-0.08.tar.gz, HINRIK, 2011; MetaCPAN )
App-EvalServer/lib/App/EvalServer.pm ( view source; MetaCPAN )
Spec::Functions qw<catdir catfile rel2abs>;
use File::Temp qw<tempdir>;
use POE;
use POE::Filter::JSON;
use POE::Filter::Reference;
use POE::Filter::Stream;
use POE::Wheel::SocketFactory;
use POE::Whe
POE::Wheel::ReadWrite->new(
        Handle       => $handle,
        Filter       => POE::Filter::JSON->new(),
        InputEvent   => 'client_read',
        FlushedEvent => 'client_write',
        Er
 = $self->{clients}{$wheel_id};

    if (ref $input ne 'HASH') {
        $client->put({ error => 'JSON data must be a hash' });
    }
    elsif (!defined $input->{lang}) {
        $client->put({ error
VKontakte-API ( A/AS/ASDEEVA/VKontakte-API-0.04.tar.gz, ASDEEVA, 2011; MetaCPAN )
VKontakte-API/lib/VKontakte/API.pm ( view source; MetaCPAN )
I;

use warnings;
use strict;
use utf8;

use Digest::MD5 qw(md5 md5_hex);
use WWW::Mechanize;
use JSON;

=pod

=head1 NAME

VKontakte::API - Module for login into vkontakte.ru and sending requests

=h
;
	$params->{'method'}    = $method;
	$params->{'timestamp'} = time();
	$params->{'format'}    = 'json';
	$params->{'rnd'}    = int(rand()*10000);

	my $sig = defined $self->{'mid'} ? $self->{'mid'} :
_get_contents($query);
	my $response = $mech->content();
	utf8::encode($response);
	return decode_json($response);
}

=head2 _params

prepares parameters for request

=cut

sub _params {
	my $self   =
RDF-AllegroGraph-Easy ( D/DR/DRRHO/RDF-AllegroGraph-Easy-0.08.tar.gz, DRRHO, 2011; MetaCPAN )
RDF-AllegroGraph-Easy/lib/RDF/AllegroGraph/Server.pm ( view source; MetaCPAN )

    $self->timeout(10);
    $self->env_proxy;
    $self->default_header('Accept' => "application/json");
    if ($options{AUTHENTICATION}) {
	( $self->{USERNAME}, $self->{PASSWORD} ) = ($options{AUTH
Plack-App-ImageMagick ( A/AJ/AJGB/Plack-App-ImageMagick-1.110990.tar.gz, AJGB, 2011; MetaCPAN )
Plack-App-ImageMagick/lib/Plack/App/ImageMagick.pm ( view source; MetaCPAN )
e parent qw( Plack::Component );

use Image::Magick;
use Plack::App::File;
use File::Spec ();
use JSON::XS ();
use Digest::MD5 ();
use Plack::Request;
use HTTP::Date ();
use Plack::Util ();
use String
with_query ) {
            my $req = Plack::Request->new($env);
            my $encoded = JSON::XS::encode_json( $commands );

            my $query_params = $req->query_parameters;
            my $pa
          };

            # params expanded
            try {
                $commands = JSON::XS::decode_json( String::Bash::bash($encoded, $params) );
            } catch {
                warn "Pa
RDF-AllegroGraph-Easy ( D/DR/DRRHO/RDF-AllegroGraph-Easy-0.08.tar.gz, DRRHO, 2011; MetaCPAN )
RDF-AllegroGraph-Easy/lib/RDF/AllegroGraph/Transaction4.pm ( view source; MetaCPAN )
arnings;

use base qw(RDF::AllegroGraph::Session4);

use Data::Dumper;
use feature "switch";

use JSON;
use URI::Escape qw/uri_escape_utf8/;

use HTTP::Request::Common;

=pod

=head1 NAME

RDF::Allegr
RDF-AllegroGraph-Easy ( D/DR/DRRHO/RDF-AllegroGraph-Easy-0.08.tar.gz, DRRHO, 2011; MetaCPAN )
RDF-AllegroGraph-Easy/lib/RDF/AllegroGraph/Server4.pm ( view source; MetaCPAN )
::AllegroGraph::Server4;

use strict;
use warnings;

use base qw(RDF::AllegroGraph::Server);

use JSON;
use Data::Dumper;

use RDF::AllegroGraph::Catalog4;
use HTTP::Request::Common;
use HTTP::Status;
gs');
    die "protocol error: ".$resp->status_line unless $resp->is_success;
    my $cats = from_json ($resp->content);
    return 
	map { $_ => RDF::AllegroGraph::Catalog4->new (NAME => $_, SERVER =

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