Group
Extension

Matches 12

GraphQL ( E/ET/ETJ/GraphQL-0.54.tar.gz, ETJ, 2022; MetaCPAN )
GraphQL/lib/GraphQL.pm ( view source; MetaCPAN )
(<<'EOF');
  type Query {
    helloWorld: String
  }
  EOF
  post '/graphql' => sub {
    send_as JSON => execute(
      $schema,
      body_parameters->{query},
      { helloWorld => 'Hello world!' }
GraphQL ( E/ET/ETJ/GraphQL-0.54.tar.gz, ETJ, 2022; MetaCPAN )
GraphQL/lib/GraphQL/Plugin/Type/DateTime.pm ( view source; MetaCPAN )
doc(<<'EOF');
  type Query { dateTimeNow: DateTime }
  EOF
  post '/graphql' => sub {
    send_as JSON => execute(
      $schema,
      body_parameters->{query},
      { dateTimeNow => sub { DateTime-
GraphQL ( E/ET/ETJ/GraphQL-0.54.tar.gz, ETJ, 2022; MetaCPAN )
GraphQL/lib/GraphQL/Introspection.pm ( view source; MetaCPAN )
L::Type::Enum;
use GraphQL::Type::Scalar qw($String $Boolean);
use GraphQL::Debug qw(_debug);
use JSON::MaybeXS;

=head1 NAME

GraphQL::Introspection - Perl implementation of GraphQL

=cut

our $VERSI
A_FIELD_DEF
  $TYPE_NAME_META_FIELD_DEF
);

use constant DEBUG => $ENV{GRAPHQL_DEBUG};
my $JSON_noutf8 = JSON::MaybeXS->new->utf8(0)->allow_nonref;

=head1 SYNOPSIS

  use GraphQL::Introspection qw($Q
    'a placeholder for a string or numeric value. However an Enum value is ' .
    'returned in a JSON response as a string.',
  fields => {
    name => { type => $String->non_null },
    description 
GraphQL ( E/ET/ETJ/GraphQL-0.54.tar.gz, ETJ, 2022; MetaCPAN )
GraphQL/lib/GraphQL/Error.pm ( view source; MetaCPAN )
nsions

Hash-ref of L<GraphQL::Type::Library/JSONable>s providing additional
information.

=cut

has extensions => (is => 'ro', isa => Optional[HashRef[JSONable]]);

=head1 METHODS

=head2 is

Is the 
{
  $self->message;
}

=head2 to_json

Converts to a JSON-able hash, in the format to send back as a member of
the C<errors> array in the results.

=cut

method to_json() :ReturnType(HashRef) {
  +{ m
GraphQL ( E/ET/ETJ/GraphQL-0.54.tar.gz, ETJ, 2022; MetaCPAN )
GraphQL/lib/GraphQL/Language/Receiver.pm ( view source; MetaCPAN )
e 'Pegex::Receiver';
use Types::Standard -all;
use GraphQL::MaybeTypeCheck;
use JSON::MaybeXS;
use Carp;

my $JSON = JSON::MaybeXS->new->allow_nonref->canonical;

my @KINDHASH = qw(
  scalar
  union
 
_boolean (Any $param = undef) {
  return unless defined $param;
  return $param eq 'true' ? JSON->true : JSON->false;
}

method got_null (Any $param = undef) {
  return unless defined $param;
  return
GraphQL ( E/ET/ETJ/GraphQL-0.54.tar.gz, ETJ, 2022; MetaCPAN )
GraphQL/lib/GraphQL/Type.pm ( view source; MetaCPAN )
 Perl representation and the "GraphQL
representation". A "GraphQL representation" means something
JSON-encodeable: an "object" (in Perl terms, a hash), an array (Perl:
array-reference), string, number
n> be JSON-encoded, not things that I<have been> so encoded: this
means, among other things, do not surround strings in C<">, and for
boolean values, use the mechanism in L<JSON::MaybeXS>: C<JSON->tru
GraphQL ( E/ET/ETJ/GraphQL-0.54.tar.gz, ETJ, 2022; MetaCPAN )
GraphQL/lib/GraphQL/Type/Library.pm ( view source; MetaCPAN )
umentLocation JSONable
    ErrorResult FieldsGot
  );
use Type::Utils -all;
use Types::TypeTiny -all;
use Types::Standard -all;
use JSON::MaybeXS;

our $VERSION = '0.02';
my $JSON = JSON::MaybeXS->new
ype as
the C<type> (implemented with type L</ValuesMatchTypes>.
B<NB> this is a Perl value, not a JSON/GraphQL value.

=item description

Description.

=back

=cut

declare "FieldMapInput", as Map[
  
t[
    line => Int,
    column => Int,
  ];

=head2 JSONable

A value that will be JSON-able.

=cut

declare "JSONable",
  as Any,
    where { $JSON->encode($_); 1 };

=head2 ErrorResult

Hash-ref tha
GraphQL ( E/ET/ETJ/GraphQL-0.54.tar.gz, ETJ, 2022; MetaCPAN )
GraphQL/lib/GraphQL/Role/FieldDeprecation.pm ( view source; MetaCPAN )
Moo::Role;
use GraphQL::MaybeTypeCheck;
use Types::Standard -all;
use JSON::MaybeXS;

our $VERSION = '0.02';
my $JSON_noutf8 = JSON::MaybeXS->new->utf8(0)->allow_nonref;

=head1 NAME

GraphQL::Role::F

  return $line if !$value->{is_deprecated};
  $line .= ' @deprecated';
  $line .= '(reason: ' . $JSON_noutf8->encode($value->{deprecation_reason}) . ')'
    if $value->{deprecation_reason} ne
      $
GraphQL ( E/ET/ETJ/GraphQL-0.54.tar.gz, ETJ, 2022; MetaCPAN )
GraphQL/lib/GraphQL/Role/FieldsEither.pm ( view source; MetaCPAN )
 Types::Standard -all;
use JSON::MaybeXS;
with qw(GraphQL::Role::FieldDeprecation);

our $VERSION = '0.02';
use constant DEBUG => $ENV{GRAPHQL_DEBUG};
my $JSON_noutf8 = JSON::MaybeXS->new->utf8(0)->al
(', ', @argtuples).')' if @argtuples;
    $line .= ': ' . $type->to_string;
    $line .= ' = ' . $JSON_noutf8->encode(
      $type->perl_to_graphql($field->{default_value})
    ) if exists $field->{de
   my @directives = map {
      my $args = $_->{arguments};
      my @argtuples = map { "$_: " . $JSON_noutf8->encode($args->{$_}) } keys %$args;
      '@' . $_->{name} . (@argtuples ? '(' . join(', '
GraphQL ( E/ET/ETJ/GraphQL-0.54.tar.gz, ETJ, 2022; MetaCPAN )
GraphQL/lib/GraphQL/Plugin/Type.pm ( view source; MetaCPAN )
doc(<<'EOF');
  type Query { dateTimeNow: DateTime }
  EOF
  post '/graphql' => sub {
    send_as JSON => execute(
      $schema,
      body_parameters->{query},
      { dateTimeNow => sub { DateTime-
GraphQL ( E/ET/ETJ/GraphQL-0.54.tar.gz, ETJ, 2022; MetaCPAN )
GraphQL/lib/GraphQL/Type/Scalar.pm ( view source; MetaCPAN )
GraphQL::Type::Library -all;
use GraphQL::Debug qw(_debug);
use Types::Standard -all;
use JSON::MaybeXS qw(JSON is_bool);
use Exporter 'import';
extends qw(GraphQL::Type);
with qw(
  GraphQL::Role::In
ORT_OK = qw($Int $Float $String $Boolean $ID);

use constant DEBUG => $ENV{GRAPHQL_DEBUG};
my $JSON = JSON::MaybeXS->new->allow_nonref->canonical;

=head1 NAME

GraphQL::Type::Scalar - GraphQL scalar 
 _leave_undef(sub { !is_Bool($_[0]) and !is_bool($_[0]) and die "Not a Boolean.\n"; $_[0] ? JSON->true : JSON->false }),
  parse_value => _leave_undef(sub { !is_Bool($_[0]) and !is_bool($_[0]) and die
GraphQL ( E/ET/ETJ/GraphQL-0.54.tar.gz, ETJ, 2022; MetaCPAN )
GraphQL/lib/GraphQL/Execution.pm ( view source; MetaCPAN )
ll;
use GraphQL::MaybeTypeCheck;
use GraphQL::Language::Parser qw(parse);
use GraphQL::Error;
use JSON::MaybeXS;
use GraphQL::Debug qw(_debug);
use GraphQL::Introspection qw(
  $SCHEMA_META_FIELD_DEF 
- Execute GraphQL queries

=cut

our @EXPORT_OK = qw(
  execute
);
our $VERSION = '0.02';

my $JSON = JSON::MaybeXS->new->allow_nonref;
use constant DEBUG => $ENV{GRAPHQL_DEBUG}; # "DEBUG and" gets op
decoded JSON object supplied by a
client. E.g. for this query:

  query q($input: TestInputObject) {
    fieldWithObjectInput(input: $input)
  }

The C<$variable_values> will need to be a JSON object 

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