e Moose;
use MooseX::FollowPBP;
use LWP::UserAgent;
use Log::Log4perl qw( :easy );
use JSON::Parse qw( parse_json );
our $VERSION = 1.04;
=head1 ATTRIBUTES
=over 2
=cut
#=item B<api_base>
#Base
and more information about the results.
=over 2
=item B<get_run>
Accesses the API's C<getRun> JSON endpoint and returns analysis information for
a single run, passed in the arguments.
Arguments s
function takes an anonymous array of run accessions and sequentially
accesses the API's C<getRun> JSON endpoint to collect the analysis information
for each run in the list provided.
my $runInfo = $
th to that file. For example, this command:
search_inc('JSON/Tiny.pm')
might return somethng like this:
/usr/local/share/perl/5.18.2/JSON/Tiny.pm
The given path must be the full path within the
not return the path to JSON/Tiny.pm:
search_inc('Tiny.pm')
That feature might be added later.
If you prefer, you can give the path in Perl module format:
search_inc('JSON::Tiny')
=cut
sub sea
r
histogram
hrz
html
htm
icb
icon
ico
iiq
info
inline
ipl
isobrl
isobrl6
jng
jnx
jpeg
jpe
jpg
jps
json
k
k25
kdc
label
m
m2v
m4v
mac
magick
map
mask
matte
mat
mef
miff
mkv
mng
mono
mov
mp4
mpc
mpeg
mp
yId.
#
use strict;
use warnings;
use Carp qw( carp confess croak cluck );
use HTTP::Status;
use JSON::XS;
use POE::XUL::Logging;
use POE::XUL::State;
use POE::XUL::Encode;
use Scalar::Util qw( weake
prepend => [],
other_windows => []
}, $package;
$self->build_json;
return $self;
}
##############################################################
sub current_
#################################
sub build_json
{
my( $self ) = @_;
my $coder = JSON::XS->new->space_after( 1 );
$coder->ascii;
$self->{json_coder} = $coder;
}
######################
or transmitting data
# to the browser. But JavaScript fails when it comes to binary formats
# so JSON is used
#
use strict;
use warnings;
use Encode ();
sub content_type { return "application/vnd.p
>new({
recorded_date => $dt,
events => $arr_events
});
=cut
use Moose;
use JSON;
extends 'Quant::Framework::Utils::MarketData';
use Date::Utility;
use List::MoreUtils qw(first
on => $VERSION,
base => 'XAS::Base',
utils => ':validation dotid',
codec => 'JSON',
constants => 'HASHREF',
mixins => 'check_parameters',
;
#use Data::Dumper;
# ---------
ameters. It expects a "profile" method to be defined. Exceptions are thrown,
and the message is a JSON data structure of the errors.
=head2 check_parameters($params, $type)
A basic validation routin
arch instance
use Mojo::Base 'Mojolicious::Plugin';
use Time::HiRes qw/time/;
use Mojo::JSON qw/encode_json/;
sub register {
my ($self, $app, $conf) = @_;
my $index = $conf->{index} || die "n
}
}
};
my $url = "${es_url}/${index}/${type}/_mapping";
my $tx = $app->ua->post($url, json => $index_meta);
$app->hook(before_dispatch => sub {
my $c = shift;
$c->stash->{'mojol
};
}
my $url = "${es_url}/${index}/${type}/?timestamp=${t}";
$c->app->ua->post($url, json => $data, sub {
my ($ua, $tx) = @_;
if (! $tx) {
$c->app->log->warn("could no
ervice::CheckParameters',
accessors => 'profile',
utils => ':validation',
codec => 'JSON',
vars => {
PARAMS => {
-columns => { type => ARRAYREF },
}
}
;
use Data::Dump
a source is implemented with these parameters.
=over 4
=item B<sort>
This will be a serialized JSON data structure. This needs to be converted
into a Perl data structure. This data structure will b
source is implemented with these parameters.
=over 4
=item B<group>
This will be a serialized JSON data structure. This needs to be converted
into a Perl data structure. This data structure will b
gs->{'template'}
? $args->{'template'}
: undef;
$self->{'json'} = exists $args->{'json'}
? $args->{'json'}
: undef;
$self->{'app_name'} = exists $args->{'app_name'}
return 1;
}
sub content_types_accepted {
return [
{ 'application/json' => 'from_json' },
{ 'application/x-www-form-urlencoded' => 'from_html' },
];
}
su
{
return [
{ 'text/html' => 'to_html' },
{ 'application/hal+json' => 'to_json' },
];
}
sub charset_provided { return ['UTF-8']; }
sub finish_request {
my $se
ed from IUP::Internal::Canvas
#XXX-CHECKLATER hack to make the following modules apper in META.json provide=>...
package IUP::Canvas::Bitmap;
package IUP::Canvas::Palette;
package IUP::Canvas::P
:Infrastructure::Config::Hash';
use IPC::Run;
use JSON;
has 'command' => ( is => 'ro', isa => 'ArrayRef[Str]',
default => sub { [ 'facter', '--json' ] },
);
has 'config' => ( is => 'rw', lazy => 1
n($self->command, \$in, \$out, \$err )
or die("error running facter: $err");
my $data = from_json( $out );
return( $data );
},
);
1;
__END__
=pod
=encoding UTF-8
=head1 NAME
Test::BDD::I
# the app is using a serializer and we were sent a blob of JSON, they could
# have come from that JSON, and thus could be hashrefs (JSON SQL injection)
# - for database providers, feeding a c
package XAS::Apps::Service::Testd;
use Template;
use JSON::XS;
use Web::Machine;
use Plack::Builder;
use Plack::App::File;
use Plack::App::URLMap;
use XAS::Service::Server;
use XAS::Class
version
rvices');
my $description = $self->cfg->val('app', 'description', 'Test api using RESTFUL HAL-JSON');
# Template config
my $config = {
INCLUDE_PATH => File($base, 'root')->path,
ext
};
# create various objects
my $template = Template->new($config);
my $json = JSON::XS->new->utf8();
# allow variables with preceeding _
$Template::Stash::PRIVATE =
a message, it creates a spool file. The spool file
is a serialized Perl data structure in L<JSON|http://json.org/> format, with
special headers. The spooler scans the spool directory and sends the pa
Carp;
use Params::Validate qw(:all);
use File::Spec;
use File::Path 'make_path';
use IO::All;
use JSON::XS;
use Expect;
our $VERSION = '1.2.1'; # VERSION
extends "Rex::Repositorio::Repository::Base"
Carp;
use Params::Validate qw(:all);
use File::Spec;
use File::Path 'make_path';
use IO::All;
use JSON::XS;
use Mojo::DOM;
our $VERSION = '1.2.1'; # VERSION
extends "Rex::Repositorio::Repository::Ba
e strict;
use warnings;
use feature ':5.10';
use base qw{ Tie::Handle Exporter };
use Symbol;
use JSON;
use Errno qw{ ENOENT EISDIR EINVAL EPERM EACCES EAGAIN ECANCELED EFBIG };
use Fcntl qw{ SEEK_CUR
sponse->code != 200;
$self->{'meta'} = from_json($response->content())
if $self->{'closed'};
unless ($self->{'upload_id'}) {
$response = from_json($response->content());
$self->{'upload_id'}
eaders__);
my $code = $response->code();
if ($code == 200) {
$meta = $self->{'meta'} = from_json($response->content());
# XXX: Dropbox returns metadata for recently deleted files
if ($meta-
tence object
use JSON;
use Ubic::Lockf;
use Ubic::AtomicFile;
{
# support the compatibility with JSON.pm v1 just because we can
# see also: Ubic::ServiceLoader::Ext::json
no strict;
sub jsonToObj; *jsonToObj = (*{JSON::from_json}{CODE}) ? \&JSON::from_json : \&JSON::jsonToObj;
sub objToJson; *objToJson = (*{JSON::to_json}{CODE}) ? \&JSON::to_json : \&JSON::objToJson;
}
my
+)};
$data = { status => $status, enabled => $enabled };
}
else {
$data = jsonToObj($str);
}
return $data;
}
sub load {
my ($class, $fname) = @_;
return _load
Carp;
use Params::Validate qw(:all);
use File::Spec;
use File::Path 'make_path';
use IO::All;
use JSON::XS;
our $VERSION = '1.2.1'; # VERSION
extends "Rex::Repositorio::Repository::Yum";
sub mirror