/;
our $VERSION = '0.08';
#@EXPORT_OK = qw//;
my $json = eval {
require JSON;
JSON->import();
1;
}; # true if we support reading from json
BEGIN {
my @accessors = qw/fh file line headers h
| !$self->{diamond} ) ) {
croak("No filename given in constructor. Aborting");
}
$self->{json_file} = 0;
$self->{names} = [ $self->readheader() ];
$self->{fields} = $self->{names};
$sel
# Json file. stuff line in saved_line and try to extract header fields...
croak("Parsing json formatted log files needs JSON module") unless ( $json );
my $val = decode_json($line
olean qw(false true);
use Data::HAL::URI qw();
use HTTP::Headers::Util qw(join_header_words);
use JSON qw();
use Log::Any qw($log);
use MIME::Type qw();
use Moo; # has
use Safe::Isa qw($_can $_isa);
u
tf.org/html/draft-kelly-json-hal#section-8.2>
=head3 C<href>
Type L<Data::HAL::URI>, B<required>,
L<link target URI or URI template|http://tools.ietf.org/html/draft-kelly-json-hal#section-5.1>
=hea
json-hal#section-5.2 >>
Perl boolean values are coerced to the L<boolean> type.
=head3 C<type>
Type L<MIME::Type>,
L<< media type of the C<href> resource|http://tools.ietf.org/html/draft-kelly-json
/;
our $VERSION = '0.08';
#@EXPORT_OK = qw//;
my $json = eval {
require JSON;
JSON->import();
1;
}; # true if we support reading from json
BEGIN {
my @accessors = qw/fh file line headers h
| !$self->{diamond} ) ) {
croak("No filename given in constructor. Aborting");
}
$self->{json_file} = 0;
$self->{names} = [ $self->readheader() ];
$self->{fields} = $self->{names};
$sel
# Json file. stuff line in saved_line and try to extract header fields...
croak("Parsing json formatted log files needs JSON module") unless ( $json );
my $val = decode_json($line
onitoring System|http://www.bro.org>.
If the L<JSON> module is installed, this module can also be used to parse Bro log
files that were written in JSON format.
=head1 Constructor
The base construct
ecurity Monitor|http://www.zeek.org>.
If the L<JSON> module is installed, this module can also be used to parse Zeek log
files that were written in JSON format.
=head1 Constructor
The base construc
onitoring System|http://www.bro.org>.
If the L<JSON> module is installed, this module can also be used to parse Bro log
files that were written in JSON format.
=head1 Constructor
The base construct
us instance. Modelled on L<CPAN::Uploader>.
use utf8;
use Moose;
use Carp;
use File::Slurp;
use JSON;
use REST::Client;
use Log::Any qw($log);
use namespace::autoclean;
has username => (
is
;
$log->debug( Dumper($self) );
my $headers = HTTP::Headers->new( Accept => 'application/json' );
$headers->authorization_basic( $self->username, $self->password );
my $Nexus = REST:
use Data::Visitor::Callback qw();
use failures qw(Data::HAL::InvalidJSON);
use HTTP::Headers::Util qw(join_header_words);
use JSON qw();
use Moo; # has
use Safe::Isa qw($_isa);
use Scalar::Util qw(re
g;
return;
}
sub from_json {
my ($self, $json, $relation) = @_;
my $nested = clone JSON::from_json($json);
failure::Data::HAL::InvalidJSON->throw('not a JSON object') unless reftype $
my (undef, $val) = @_;
if (JSON::is_bool($val)) {
$val = false if $val == JSON::false;
$val = true if $val == JSON::true;
}
return
$h->content_type('application/json;charset=UTF-8');
}
unless (defined $h->header('Accept')) {
$h->header('Accept', 'application/json');
}
$headers = $h
use strict;
use warnings;
package AWS::SNS::Verify;
$AWS::SNS::Verify::VERSION = '0.0105';
use JSON;
use HTTP::Tiny;
use MIME::Base64;
use Moo;
use Ouch;
use Crypt::PK::RSA;
use URI::URL;
use Data::St
o',
lazy => 1,
default => sub {
my $self = shift;
return JSON::decode_json($self->body);
}
);
has certificate_string => (
is => 'ro',
lazy
gCertURL ($url_string) isn't an Amazon endpoint", $self;
}
return $url_string;
}
sub TO_JSON {
my $self = shift;
return unbless($self);
}
=head1 NAME
AWS::SNS::Verify - Verifies au
iringPi::Meta;
use strict;
use warnings;
use Carp qw(croak);
use IPC::ShareLite qw(:flock);
use JSON::XS;
our $VERSION = '2.3633_03';
sub meta {
my ($self) = @_;
return $self->{meta_shm}
}
sub meta_fetch {
my ($self) = @_;
my $json;
$json = $self->meta->fetch;
$json = "{}" if $json eq '';
my $perl = decode_json $json;
return $perl
}
sub meta_store {
my ($s
croak "meta_store() requires a hash reference sent in...\n";
}
$self->meta->store(encode_json $data) or die $!;
}
sub meta_delete {
my ($self, $name) = @_;
if (! defined $name){
strict;
use Benchmark qw(timethis timethese cmpthese);
use Data::Dumper;
use IPC::ShareLite;
use JSON::XS;
use Storable qw(freeze thaw);
die "need run count" if ! $ARGV[0];
my $s = IPC::ShareLite->
/data';
cmpthese $ARGV[0], {
json_file => \&json_file,
json_share => \&json_share,
stor_file => \&stor_file,
stor_share => \&stor_share,
};
sub json_file {
my $p = {a => 1, b =>
$fh, '>', $f or die $!;
print $fh encode_json($p);
close $fh;
{
local $/;
open $fh, '<', $f or die $!;
$p = decode_json <$fh>;
close $fh;
}
open $f
>
#pod
#pod =item *
#pod
#pod L<Catalyst::View::TT>
#pod
#pod =item *
#pod
#pod L<Catalyst::View::JSON>
#pod
#pod =item *
#pod
#pod L<Catalyst::Model::DBIC::Schema>
#pod
#pod =item *
#pod
#pod L<Catal
tem *
L<DBIx::Class::Schema::Loader>
=item *
L<Catalyst::View::TT>
=item *
L<Catalyst::View::JSON>
=item *
L<Catalyst::Model::DBIC::Schema>
=item *
L<Catalyst::Model::DBIC::File>
=item *
L<
an efficient binary serialization format. It lets you exchange
data among multiple languages like JSON, but it's faster and smaller. Small
integers are encoded into a single byte, and typical short st
eature qw(:5.10);
use Data::Util qw(:check);
use Moo;
use Plack::Request;
use Plack::Session;
use JSON;
our $VERSION = "0.0137";
with "Plack::Auth::SSO";
#cf. https://github.com/toyokazu/omniauth-s
/;
$env->{"HTTP_${key}"};
}
sub to_app {
my $self = $_[0];
sub {
state $json = JSON->new()->utf8(1);
my $env = $_[0];
my $request = Plack::Request->new($env);
response => {
content => $json->encode($content),
content_type => "application/json"
}
}
);
$self->
use Moo;
use Plack::Request;
use Plack::Session;
use URI;
use LWP::UserAgent;
use WWW::ORCID;
use JSON;
use Plack::Auth::SSO::ResponseParser::ORCID;
our $VERSION = "0.0137";
with "Plack::Auth::SSO";
ponseParser::ORCID->new();
},
init_arg => undef
);
has json => (
is => "ro",
lazy => 1,
default => sub {
JSON->new->utf8(1);
},
init_arg => undef
);
sub _build_orc
pp {
my $self = $_[0];
sub {
state $orcid = $self->orcid;
state $json = $self->json;
state $response_parser = $self->response_parser;
my $env = $_[0];
NAME
DBIx::Result::Convert::JSONSchema - Convert DBIx result schema to JSON schema
=begin html
<a href='https://travis-ci.org/Humanstate/p5-dbix-result-convert-jsonschema?branch=master'><img sr
umanstate/p5-dbix-result-convert-jsonschema.svg?branch=master' alt='Build Status' /></a>
<a href='https://coveralls.io/github/Humanstate/p5-dbix-result-convert-jsonschema?branch=master'><img src='
p5-dbix-result-convert-jsonschema/badge.svg?branch=master' alt='Coverage Status' /></a>
=end html
=head1 VERSION
0.06
=head1 SYNOPSIS
use DBIx::Result::Convert::JSONSchema;
my $Schem
my $path = $uri->path;
# print STDERR "parse path $path\n";
if ($path =~ s!^/ws/(plain|json|xml)/!!) {
$r->notes(PATH => $path);
# print STDERR "parse new path [$1]\n";
} elsif ($type eq "json") {
my $r = $rec->hash;
# use DDS; print STDERR Dump $r;
print JSON->new->objToJson({ rec => $r });
} e
} elsif ($type eq "json") {
my $r = $_->hash;
# use DDS; print STDERR Dump $r;
print JSON->new->objToJson($r);
} els
(:check);
use JSON;
use Moo;
use Clone qw();
our $VERSION = "0.0137";
with "Plack::Auth::SSO::ResponseParser";
has json => (
is => "ro",
lazy => 1,
builder => "_build_json",
init_ar
g => undef
);
sub _build_json {
JSON->new();
}
sub dig {
my( $hash, @keys ) = @_;
while( my $key = shift(@keys) ){
return unless exists $hash->{$key};
return $hash->{$k
{
$obj = $self->json()->decode( $obj );
}
else {
$obj = Clone::clone( $obj );
}
if ( is_string( $obj2 ) ) {
$obj2 = $self->json()->decode( $obj2 );
8;
use Log::Any '$log';
use Path::Tiny;
use Git::Hooks;
use LWP::UserAgent;
use URI::Builder;
use JSON::XS;
$Git::Hooks::CheckYoutrack::VERSION = '1.0.2';
=head1 NAME
Git::Hooks::CheckYoutrack - Gi
_token");
$ua->default_header('Accept' => 'application/json');
$ua->default_header('Content-Type' => 'application/json');
my $ticket_fields = 'fields=numberInProject,project(short
et->status_line);
return;
}
my $json = decode_json($ticket->decoded_content);
my $ticket_details = _process_ticket($json);
if (!$ticket_details->{ticket_id}) {