Sha256: 2a1c1116b8a7db34d02d9489da10794b8b3acdbc71ece268f04b126f9d17e521
Contents?: true
Size: 514 Bytes
Versions: 10
Compression:
Stored size: 514 Bytes
Contents
# frozen_string_literal: true require_relative './base' module GQLi # Query node class Query < Base # Serializes to a GraphQL string def to_gql result = <<~GQL query #{__name ? __name + ' ' : ''}{ #{__nodes.map(&:to_gql).join("\n")} } GQL result.lstrip end # Delegates itself to the client to be executed def __execute(client) client.execute(self) end # Serializes to a GraphQL string def to_s to_gql end end end
Version data entries
10 entries across 10 versions & 1 rubygems