[
  {
    "path": ".gitignore",
    "content": "# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio and Webstorm\n\n*.iml\n\n## Directory-based project format:\n.idea/\n# if you remove the above rule, at least ignore the following:\n\n# User-specific stuff:\n# .idea/workspace.xml\n# .idea/tasks.xml\n# .idea/dictionaries\n# .idea/shelf\n\n# Sensitive or high-churn files:\n# .idea/dataSources.ids\n# .idea/dataSources.xml\n# .idea/sqlDataSources.xml\n# .idea/dynamic.xml\n# .idea/uiDesigner.xml\n\n# Gradle:\n# .idea/gradle.xml\n# .idea/libraries\n\n# Mongo Explorer plugin:\n# .idea/mongoSettings.xml\n\n## File-based project format:\n*.ipr\n*.iws\n\n## Plugin-specific files:\n\n# IntelliJ\n/out/\n\n# mpeltonen/sbt-idea plugin\n.idea_modules/\n\n# JIRA plugin\natlassian-ide-plugin.xml\n\n# Crashlytics plugin (for Android Studio and IntelliJ)\ncom_crashlytics_export_strings.xml\ncrashlytics.properties\ncrashlytics-build.properties\nfabric.properties\n"
  },
  {
    "path": ".travis.yml",
    "content": "language: java\njdk:\n  - oraclejdk8\nbefore_install:\n - chmod +x gradlew  \nafter_success:\n  - ./gradlew bintrayUpload -x check --info"
  },
  {
    "path": "LICENSE.md",
    "content": "The MIT License (MIT)\n\nCopyright (c) 2016 Oembedler Inc. and Contributors\n\nPermission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE."
  },
  {
    "path": "README.md",
    "content": "<!-- START doctoc generated TOC please keep comment here to allow auto update -->\n<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->\n**Table of Contents**\n\n- [GraphQL Spring Framework Boot Starter](#graphql-spring-framework-boot-starter)\n- [Intro](#intro)\n- [Requires](#requires)\n- [Enable GraphQL Server](#enable-graphql-server)\n- [Enable GraphiQL Tool](#enable-graphiql-tool)\n- [Contributions](#contributions)\n- [License](#license)\n\n<!-- END doctoc generated TOC please keep comment here to allow auto update -->\n\n# GraphQL and GraphiQL Spring Framework Boot Starters\n[![Build Status](https://travis-ci.org/oembedler/graphql-spring-boot.svg?branch=master)](https://travis-ci.org/oembedler/graphql-spring-boot)\n\nGraphQL Starter \n\n[ ![Download](https://api.bintray.com/packages/oembedler/maven/graphql-spring-boot-starter/images/download.svg) ](https://bintray.com/oembedler/maven/graphql-spring-boot-starter/_latestVersion)\n\nGraphiQL Starter \n\n[ ![Download](https://api.bintray.com/packages/oembedler/maven/graphiql-spring-boot-starter/images/download.svg) ](https://bintray.com/oembedler/maven/graphiql-spring-boot-starter/_latestVersion)\n\n# Intro\n\nRepository contains:\n\n* `graphql-spring-boot-starter` to turn your boot application into GraphQL server (see [express-graphql](https://github.com/graphql/express-graphql))\n* `graphiql-spring-boot-starter`to embed `GraphiQL` tool for schema introspection and query debugging (see [graphiql](https://github.com/graphql/graphiql))\n\n# Requires\n\n  * Java 1.8\n  * [Spring Framework GraphQL Common Library](https://github.com/oembedler/spring-graphql-common)\n  * Spring Framework Boot 1.3.x (web)  \n\nAdd repository:\n\n```gradle\nrepositories {\n    // stable build\n    jcenter()\n    // development build\n    maven { url  \"http://dl.bintray.com/oembedler/maven\" }\n}\n```\n\nDependency:\n\n```gradle\ndependencies {\n  compile 'com.embedler.moon.graphql.boot:graphql-spring-boot-starter:INSERT_LATEST_VERSION_HERE'\n  \n  // to embed GraphiQL tool\n  compile 'com.embedler.moon.graphql.boot:graphiql-spring-boot-starter:INSERT_LATEST_VERSION_HERE'\n}\n```\n\nHow to use the latest build with Maven:\n\n```xml\n<repository>\n    <snapshots>\n        <enabled>false</enabled>\n    </snapshots>\n    <id>bintray-oembedler-maven</id>\n    <name>bintray</name>\n    <url>http://dl.bintray.com/oembedler/maven</url>\n</repository>\n```\n\nDependency:\n\n```xml\n<dependency>\n    <groupId>com.embedler.moon.graphql.boot</groupId>\n    <artifactId>graphql-spring-boot-starter</artifactId>\n    <version>INSERT_LATEST_VERSION_HERE</version>\n</dependency>\n\n<!-- to embed GraphiQL tool -->\n<dependency>\n    <groupId>com.embedler.moon.graphql.boot</groupId>\n    <artifactId>graphiql-spring-boot-starter</artifactId>\n    <version>INSERT_LATEST_VERSION_HERE</version>\n</dependency>\n```\n\n\n# Enable GraphQL Server\n\nServer becomes accessible at `/graphql` if `graphql-spring-boot-starter` added as a dependency to a boot application\nand `@EnableGraphQLServer` annotation is set at the main java configuration class.\nGraphQL schemas are automatically discovered extracting all classes from Spring context marked as `@GraphQLSchema`.\n\nRequest parameters:\n\n  * **`query`**: A string GraphQL document to be executed.\n\n  * **`variables`**: The runtime values to use for any GraphQL query variables\n    as a JSON object.\n\n  * **`operationName`**: If the provided `query` contains multiple named\n    operations, this specifies which operation should be executed. If not\n    provided, an error will be returned if the `query` contains multiple\n    named operations.\n\nGraphQL will first look for each parameter in the URL's query-string:\n\n```\n/graphql?query=query+getUser($id:ID){user(id:$id){name}}&variables={\"id\":\"4\"}\n```\n\nIf not found in the query-string, it will look in the POST request body.\n\nServer uses [`commons-fileupload`][] middleware to add support\nfor `multipart/form-data` content, which may be useful for GraphQL mutations\ninvolving uploading files (see test application for more details).\n `GraphQLContext` is a map of objects (context) for the current query execution.\nIn order to get access to uploaded file \n`com.oembedler.moon.graphql.boot.GraphQLContext` should be passed as input parameter to datafetcher or mutation (don't need to be annotated).\nCalling method `GraphQLContext.getUploadedFile()` returns instance of [MultipartFile](https://docs.spring.io/spring/docs/current/javadoc-api/org/springframework/web/multipart/MultipartFile.html).\n\nIf the POST body has not yet been parsed, graphql-express will interpret it\ndepending on the provided *Content-Type* header.\n\n  * **`application/json`**: the POST body will be parsed as a JSON\n    object of parameters.\n\n  * **`application/x-www-form-urlencoded`**: this POST body will be\n    parsed as a url-encoded string of key-value pairs.\n    \n  * **`multipart/form-data`**: this POST body will be\n    parsed as a string of key-value pairs and it supports file upload (see above).    \n\n  * **`application/graphql`**: The POST body will be parsed as GraphQL\n    query string, which provides the `query` parameter.\n\nAvailable Spring Boot configuration parameters (either `application.yml` or `application.properties`):\n\nServer can host multiple schemas (all are registered at the startup time). \n\nTo run query against particular schema - HTTP header `graphql-schema` parameter passed along with the query should contain graphql schema name of interest.\n\n```yaml\ngraphql:\n      server:\n               mapping: /graphql\n               corsEnabled: true\n               suppressSpringResponseCodes: true\n               query-key: query\n               variables-key: variables\n               uploadMaxFileSize: 128KB\n               uploadMaxRequestSize: 128KB\n      schema:\n               clientMutationIdName: clientMutationId\n               injectClientMutationId: true\n               allowEmptyClientMutationId: false\n               mutationInputArgumentName: input\n               outputObjectNamePrefix: Payload\n               inputObjectNamePrefix: Input\n               schemaMutationObjectName: Mutation\n```\n\nTo facilitate access from Nodejs frontend to GraphQL backend by default system enables global CORS filter for `/graphql/**` context.\nThe `corsEnabled` can be set to `false` to disable it.\n\nBy default system register `GlobalDefaultExceptionHandler` which suppresses Spring framework error responses and responds with standard GraphQL server error.\nApplication configuration `suppressSpringResponseCodes` property can be set to `false` to disable that handler.\n\n# Enable GraphiQL Tool\n\nTool becomes accessible at the root `/` if `graphiql-spring-boot-starter` added as a dependency to a boot application.\n\nNote that GraphQL server must be available at `/graphql` context to be discovered by GraphiQL.\n\n# Contributions\n\nContributions are welcome.\n\nTips:\n\n- Respect the [Code of Conduct](http://contributor-covenant.org/version/1/3/0/).\n- Before opening an Issue to report a bug, please try the latest development version. \nIt might happen that the problem is already solved.\n- Please use  Markdown to format your comments properly. \nIf you are not familiar with that: [Getting started with writing and formatting on GitHub](https://help.github.com/articles/getting-started-with-writing-and-formatting-on-github/)\n- For Pull Requests:\n  - Here are some [general tips](https://github.com/blog/1943-how-to-write-the-perfect-pull-request)\n  - Please be a as focused and clear as possible and don't mix concerns. \n    This includes refactorings mixed with bug-fixes/features, see [Open Source Contribution Etiquette](http://tirania.org/blog/archive/2010/Dec-31.html) \n  - It would be good to add an automatic test(s). \n  \n\n# License\n\n`graphql-spring-boot-starter` and `graphiql-spring-boot-starter` are licensed under the MIT License. See [LICENSE](LICENSE.md) for details.\n\n[spring-graphql-common License](https://github.com/oembedler/spring-graphql-common/blob/master/LICENSE.md)\n\n[graphql-java License](https://github.com/andimarek/graphql-java/blob/master/LICENSE.md)\n\n[graphiql License](https://github.com/graphql/graphiql/blob/master/LICENSE)\n\n[graphql-js License](https://github.com/graphql/graphql-js/blob/master/LICENSE)\n"
  },
  {
    "path": "build.gradle",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\n\nimport java.text.SimpleDateFormat\n\nbuildscript {\n    repositories {\n        maven { url \"https://plugins.gradle.org/m2/\" }\n        maven { url 'http://repo.spring.io/plugins-release' }\n    }\n    dependencies {\n        classpath 'org.springframework.build.gradle:propdeps-plugin:0.0.7'\n        classpath \"com.jfrog.bintray.gradle:gradle-bintray-plugin:1.6\"\n    }\n}\n\nsubprojects {\n\n    apply plugin: 'idea'\n    apply plugin: 'java'\n    apply plugin: 'maven'\n    apply plugin: 'maven-publish'\n    apply plugin: 'propdeps'\n    apply plugin: 'propdeps-maven'\n    apply plugin: 'propdeps-idea'\n    apply plugin: 'propdeps-eclipse'\n    apply plugin: \"com.jfrog.bintray\"\n\n    version = System.env.TRAVIS_TAG ? PROJECT_VERSION : PROJECT_VERSION + '-' + new SimpleDateFormat('yyyy-MM-dd\\'T\\'HH-mm-ss').format(new Date())\n    group = PROJECT_GROUP\n\n    repositories {\n        jcenter()\n        maven { url \"http://dl.bintray.com/oembedler/maven\" }\n    }\n\n    idea {\n        module {\n            downloadJavadoc = true\n            downloadSources = true\n        }\n    }\n\n    compileJava {\n        sourceCompatibility = SOURCE_COMPATIBILITY\n        targetCompatibility = TARGET_COMPATIBILITY\n    }\n\n    jar {\n        from \"LICENSE.md\"\n    }\n\n    task sourcesJar(type: Jar) {\n        dependsOn classes\n        classifier 'sources'\n        from sourceSets.main.allSource\n    }\n\n    task javadocJar(type: Jar, dependsOn: javadoc) {\n        classifier = 'javadoc'\n        from javadoc.destinationDir\n    }\n\n    artifacts {\n        archives sourcesJar\n        archives javadocJar\n    }\n\n    publishing {\n        publications {\n            mainProjectPublication(MavenPublication) {\n                version version\n                from components.java\n\n                artifact sourcesJar {\n                    classifier \"sources\"\n                }\n                artifact javadocJar {\n                    classifier \"javadoc\"\n                }\n                pom.withXml {\n                    asNode().children().last() + {\n                        resolveStrategy = Closure.DELEGATE_FIRST\n                        name PROJECT_NAME\n                        description PROJECT_DESC\n                        url PROJECT_GIT_REPO_URL\n                        scm {\n                            url PROJECT_GIT_REPO_URL\n                            connection PROJECT_GIT_REPO_URL\n                            developerConnection PROJECT_GIT_REPO_URL\n                        }\n                        licenses {\n                            license {\n                                name PROJECT_LICENSE\n                                url PROJECT_LICENSE_URL\n                                distribution 'repo'\n                            }\n                        }\n                        developers {\n                            developer {\n                                id PROJECT_DEV_ID\n                                name PROJECT_DEV_NAME\n                            }\n                        }\n                    }\n                }\n            }\n        }\n    }\n\n    bintray {\n        user = System.env.BINTRAY_USER ?: project[\"bintray.user\"]\n        key = System.env.BINTRAY_API_KEY ?: project[\"bintray.key\"]\n        publications = ['mainProjectPublication']\n        publish = true\n        pkg {\n            repo = 'maven'\n            name = PROJECT_NAME\n            desc = PROJECT_DESC\n            licenses = [PROJECT_LICENSE]\n            vcsUrl = PROJECT_GIT_REPO_URL\n        }\n    }\n\n    task wrapper(type: Wrapper) {\n        gradleVersion = \"${GRADLE_WRAPPER_VER}\"\n    }\n}"
  },
  {
    "path": "gradle/wrapper/gradle-wrapper.properties",
    "content": "#Sun Mar 27 20:34:11 BST 2016\ndistributionBase=GRADLE_USER_HOME\ndistributionPath=wrapper/dists\nzipStoreBase=GRADLE_USER_HOME\nzipStorePath=wrapper/dists\ndistributionUrl=https\\://services.gradle.org/distributions/gradle-2.9-bin.zip\n"
  },
  {
    "path": "gradle.properties",
    "content": "#\n# The MIT License (MIT)\n#\n# Copyright (c) 2016 oEmbedler Inc. and Contributors\n#\n# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n#  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n#  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n#  persons to whom the Software is furnished to do so, subject to the following conditions:\n#\n# The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n#\n# THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n# BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n# DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n#\n\nPROJECT_VERSION = 2.1.0\nPROJECT_GROUP = com.embedler.moon.graphql.boot\nPROJECT_NAME = spring-boot-graphql\nPROJECT_DESC = GraphQL Spring Framework Boot\nPROJECT_GIT_REPO_URL = https://github.com/oembedler/graphql-spring-boot\nPROJECT_LICENSE = MIT\nPROJECT_LICENSE_URL = https://github.com/oembedler/spring-boot-graphql/blob/master/LICENSE.md\nPROJECT_DEV_ID = oembedler\nPROJECT_DEV_NAME = Embedler Inc.\n\nVCS=Git\n\n###\n\nSOURCE_COMPATIBILITY = 1.8\nTARGET_COMPATIBILITY = 1.8\n\n###\n\nLIB_SPRING_GRAPHQL_COMMON_VER = 2.1.+\nLIB_JUNIT_VER = 4.12\nLIB_SPRING_CORE_VER = 4.2.4.RELEASE\nLIB_SPRING_BOOT_VER = 1.3.3.RELEASE\nLIB_COMMON_UPLOAD = 1.3.1\n\nGRADLE_WRAPPER_VER = 2.9\n\n###\n\norg.gradle.daemon=true\n\nbintray.user=USER\nbintray.key=KEY\n"
  },
  {
    "path": "gradlew",
    "content": "#!/usr/bin/env bash\n\n##############################################################################\n##\n##  Gradle start up script for UN*X\n##\n##############################################################################\n\n# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.\nDEFAULT_JVM_OPTS=\"\"\n\nAPP_NAME=\"Gradle\"\nAPP_BASE_NAME=`basename \"$0\"`\n\n# Use the maximum available, or set MAX_FD != -1 to use that value.\nMAX_FD=\"maximum\"\n\nwarn ( ) {\n    echo \"$*\"\n}\n\ndie ( ) {\n    echo\n    echo \"$*\"\n    echo\n    exit 1\n}\n\n# OS specific support (must be 'true' or 'false').\ncygwin=false\nmsys=false\ndarwin=false\ncase \"`uname`\" in\n  CYGWIN* )\n    cygwin=true\n    ;;\n  Darwin* )\n    darwin=true\n    ;;\n  MINGW* )\n    msys=true\n    ;;\nesac\n\n# Attempt to set APP_HOME\n# Resolve links: $0 may be a link\nPRG=\"$0\"\n# Need this for relative symlinks.\nwhile [ -h \"$PRG\" ] ; do\n    ls=`ls -ld \"$PRG\"`\n    link=`expr \"$ls\" : '.*-> \\(.*\\)$'`\n    if expr \"$link\" : '/.*' > /dev/null; then\n        PRG=\"$link\"\n    else\n        PRG=`dirname \"$PRG\"`\"/$link\"\n    fi\ndone\nSAVED=\"`pwd`\"\ncd \"`dirname \\\"$PRG\\\"`/\" >/dev/null\nAPP_HOME=\"`pwd -P`\"\ncd \"$SAVED\" >/dev/null\n\nCLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar\n\n# Determine the Java command to use to start the JVM.\nif [ -n \"$JAVA_HOME\" ] ; then\n    if [ -x \"$JAVA_HOME/jre/sh/java\" ] ; then\n        # IBM's JDK on AIX uses strange locations for the executables\n        JAVACMD=\"$JAVA_HOME/jre/sh/java\"\n    else\n        JAVACMD=\"$JAVA_HOME/bin/java\"\n    fi\n    if [ ! -x \"$JAVACMD\" ] ; then\n        die \"ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME\n\nPlease set the JAVA_HOME variable in your environment to match the\nlocation of your Java installation.\"\n    fi\nelse\n    JAVACMD=\"java\"\n    which java >/dev/null 2>&1 || die \"ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.\n\nPlease set the JAVA_HOME variable in your environment to match the\nlocation of your Java installation.\"\nfi\n\n# Increase the maximum file descriptors if we can.\nif [ \"$cygwin\" = \"false\" -a \"$darwin\" = \"false\" ] ; then\n    MAX_FD_LIMIT=`ulimit -H -n`\n    if [ $? -eq 0 ] ; then\n        if [ \"$MAX_FD\" = \"maximum\" -o \"$MAX_FD\" = \"max\" ] ; then\n            MAX_FD=\"$MAX_FD_LIMIT\"\n        fi\n        ulimit -n $MAX_FD\n        if [ $? -ne 0 ] ; then\n            warn \"Could not set maximum file descriptor limit: $MAX_FD\"\n        fi\n    else\n        warn \"Could not query maximum file descriptor limit: $MAX_FD_LIMIT\"\n    fi\nfi\n\n# For Darwin, add options to specify how the application appears in the dock\nif $darwin; then\n    GRADLE_OPTS=\"$GRADLE_OPTS \\\"-Xdock:name=$APP_NAME\\\" \\\"-Xdock:icon=$APP_HOME/media/gradle.icns\\\"\"\nfi\n\n# For Cygwin, switch paths to Windows format before running java\nif $cygwin ; then\n    APP_HOME=`cygpath --path --mixed \"$APP_HOME\"`\n    CLASSPATH=`cygpath --path --mixed \"$CLASSPATH\"`\n    JAVACMD=`cygpath --unix \"$JAVACMD\"`\n\n    # We build the pattern for arguments to be converted via cygpath\n    ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`\n    SEP=\"\"\n    for dir in $ROOTDIRSRAW ; do\n        ROOTDIRS=\"$ROOTDIRS$SEP$dir\"\n        SEP=\"|\"\n    done\n    OURCYGPATTERN=\"(^($ROOTDIRS))\"\n    # Add a user-defined pattern to the cygpath arguments\n    if [ \"$GRADLE_CYGPATTERN\" != \"\" ] ; then\n        OURCYGPATTERN=\"$OURCYGPATTERN|($GRADLE_CYGPATTERN)\"\n    fi\n    # Now convert the arguments - kludge to limit ourselves to /bin/sh\n    i=0\n    for arg in \"$@\" ; do\n        CHECK=`echo \"$arg\"|egrep -c \"$OURCYGPATTERN\" -`\n        CHECK2=`echo \"$arg\"|egrep -c \"^-\"`                                 ### Determine if an option\n\n        if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then                    ### Added a condition\n            eval `echo args$i`=`cygpath --path --ignore --mixed \"$arg\"`\n        else\n            eval `echo args$i`=\"\\\"$arg\\\"\"\n        fi\n        i=$((i+1))\n    done\n    case $i in\n        (0) set -- ;;\n        (1) set -- \"$args0\" ;;\n        (2) set -- \"$args0\" \"$args1\" ;;\n        (3) set -- \"$args0\" \"$args1\" \"$args2\" ;;\n        (4) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" ;;\n        (5) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" ;;\n        (6) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" \"$args5\" ;;\n        (7) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" \"$args5\" \"$args6\" ;;\n        (8) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" \"$args5\" \"$args6\" \"$args7\" ;;\n        (9) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" \"$args5\" \"$args6\" \"$args7\" \"$args8\" ;;\n    esac\nfi\n\n# Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules\nfunction splitJvmOpts() {\n    JVM_OPTS=(\"$@\")\n}\neval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS\nJVM_OPTS[${#JVM_OPTS[*]}]=\"-Dorg.gradle.appname=$APP_BASE_NAME\"\n\nexec \"$JAVACMD\" \"${JVM_OPTS[@]}\" -classpath \"$CLASSPATH\" org.gradle.wrapper.GradleWrapperMain \"$@\"\n"
  },
  {
    "path": "gradlew.bat",
    "content": "@if \"%DEBUG%\" == \"\" @echo off\n@rem ##########################################################################\n@rem\n@rem  Gradle startup script for Windows\n@rem\n@rem ##########################################################################\n\n@rem Set local scope for the variables with windows NT shell\nif \"%OS%\"==\"Windows_NT\" setlocal\n\n@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.\nset DEFAULT_JVM_OPTS=\n\nset DIRNAME=%~dp0\nif \"%DIRNAME%\" == \"\" set DIRNAME=.\nset APP_BASE_NAME=%~n0\nset APP_HOME=%DIRNAME%\n\n@rem Find java.exe\nif defined JAVA_HOME goto findJavaFromJavaHome\n\nset JAVA_EXE=java.exe\n%JAVA_EXE% -version >NUL 2>&1\nif \"%ERRORLEVEL%\" == \"0\" goto init\n\necho.\necho ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.\necho.\necho Please set the JAVA_HOME variable in your environment to match the\necho location of your Java installation.\n\ngoto fail\n\n:findJavaFromJavaHome\nset JAVA_HOME=%JAVA_HOME:\"=%\nset JAVA_EXE=%JAVA_HOME%/bin/java.exe\n\nif exist \"%JAVA_EXE%\" goto init\n\necho.\necho ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%\necho.\necho Please set the JAVA_HOME variable in your environment to match the\necho location of your Java installation.\n\ngoto fail\n\n:init\n@rem Get command-line arguments, handling Windowz variants\n\nif not \"%OS%\" == \"Windows_NT\" goto win9xME_args\nif \"%@eval[2+2]\" == \"4\" goto 4NT_args\n\n:win9xME_args\n@rem Slurp the command line arguments.\nset CMD_LINE_ARGS=\nset _SKIP=2\n\n:win9xME_args_slurp\nif \"x%~1\" == \"x\" goto execute\n\nset CMD_LINE_ARGS=%*\ngoto execute\n\n:4NT_args\n@rem Get arguments from the 4NT Shell from JP Software\nset CMD_LINE_ARGS=%$\n\n:execute\n@rem Setup the command line\n\nset CLASSPATH=%APP_HOME%\\gradle\\wrapper\\gradle-wrapper.jar\n\n@rem Execute Gradle\n\"%JAVA_EXE%\" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% \"-Dorg.gradle.appname=%APP_BASE_NAME%\" -classpath \"%CLASSPATH%\" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%\n\n:end\n@rem End local scope for the variables with windows NT shell\nif \"%ERRORLEVEL%\"==\"0\" goto mainEnd\n\n:fail\nrem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of\nrem the _cmd.exe /c_ return code!\nif  not \"\" == \"%GRADLE_EXIT_CONSOLE%\" exit 1\nexit /b 1\n\n:mainEnd\nif \"%OS%\"==\"Windows_NT\" endlocal\n\n:omega\n"
  },
  {
    "path": "graphiql-spring-boot-autoconfigure/LICENSE.md",
    "content": "The MIT License (MIT)\n\nCopyright (c) 2016 Oembedler Inc. and Contributors\n\nPermission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE."
  },
  {
    "path": "graphiql-spring-boot-autoconfigure/build.gradle",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\nbuildscript {\n    repositories {\n        maven { url \"https://plugins.gradle.org/m2/\" }\n    }\n    dependencies {\n        classpath \"com.jfrog.bintray.gradle:gradle-bintray-plugin:1.6\"\n    }\n}\n\ndependencies{\n    compile \"org.webjars:react:$LIB_WEBJARS_REACT_VER\"\n}\n"
  },
  {
    "path": "graphiql-spring-boot-autoconfigure/gradle/wrapper/gradle-wrapper.properties",
    "content": "#Sun Mar 27 20:34:11 BST 2016\ndistributionBase=GRADLE_USER_HOME\ndistributionPath=wrapper/dists\nzipStoreBase=GRADLE_USER_HOME\nzipStorePath=wrapper/dists\ndistributionUrl=https\\://services.gradle.org/distributions/gradle-2.9-bin.zip\n"
  },
  {
    "path": "graphiql-spring-boot-autoconfigure/gradle.properties",
    "content": "#\n# The MIT License (MIT)\n#\n# Copyright (c) 2016 oEmbedler Inc. and Contributors\n#\n# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n#  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n#  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n#  persons to whom the Software is furnished to do so, subject to the following conditions:\n#\n# The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n#\n# THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n# BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n# DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n#\n\nPROJECT_VERSION = 2.1.0\nPROJECT_GROUP = com.embedler.moon.graphql.boot.autoconfigure\nPROJECT_NAME = graphiql-spring-boot-autoconfigure\nPROJECT_DESC = GraphiQL Spring Framework Boot Autoconfigure\nPROJECT_GIT_REPO_URL = https://github.com/oembedler/graphql-spring-boot\nPROJECT_LICENSE = MIT\nPROJECT_LICENSE_URL = https://github.com/oembedler/spring-boot-graphql/blob/master/LICENSE.md\nPROJECT_DEV_ID = oembedler\nPROJECT_DEV_NAME = Embedler Inc.\n\nVCS=Git\n\n###\n\nSOURCE_COMPATIBILITY = 1.8\nTARGET_COMPATIBILITY = 1.8\n\n###\n\nLIB_WEBJARS_GRAPHIQL_VER = 0.3.1-1\nLIB_WEBJARS_REACT_VER = 0.14.7\n\nGRADLE_WRAPPER_VER = 2.9\n\n###\n\norg.gradle.daemon=true\n\nbintray.user=USER\nbintray.key=KEY"
  },
  {
    "path": "graphiql-spring-boot-autoconfigure/gradlew",
    "content": "#!/usr/bin/env bash\n\n##############################################################################\n##\n##  Gradle start up script for UN*X\n##\n##############################################################################\n\n# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.\nDEFAULT_JVM_OPTS=\"\"\n\nAPP_NAME=\"Gradle\"\nAPP_BASE_NAME=`basename \"$0\"`\n\n# Use the maximum available, or set MAX_FD != -1 to use that value.\nMAX_FD=\"maximum\"\n\nwarn ( ) {\n    echo \"$*\"\n}\n\ndie ( ) {\n    echo\n    echo \"$*\"\n    echo\n    exit 1\n}\n\n# OS specific support (must be 'true' or 'false').\ncygwin=false\nmsys=false\ndarwin=false\ncase \"`uname`\" in\n  CYGWIN* )\n    cygwin=true\n    ;;\n  Darwin* )\n    darwin=true\n    ;;\n  MINGW* )\n    msys=true\n    ;;\nesac\n\n# Attempt to set APP_HOME\n# Resolve links: $0 may be a link\nPRG=\"$0\"\n# Need this for relative symlinks.\nwhile [ -h \"$PRG\" ] ; do\n    ls=`ls -ld \"$PRG\"`\n    link=`expr \"$ls\" : '.*-> \\(.*\\)$'`\n    if expr \"$link\" : '/.*' > /dev/null; then\n        PRG=\"$link\"\n    else\n        PRG=`dirname \"$PRG\"`\"/$link\"\n    fi\ndone\nSAVED=\"`pwd`\"\ncd \"`dirname \\\"$PRG\\\"`/\" >/dev/null\nAPP_HOME=\"`pwd -P`\"\ncd \"$SAVED\" >/dev/null\n\nCLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar\n\n# Determine the Java command to use to start the JVM.\nif [ -n \"$JAVA_HOME\" ] ; then\n    if [ -x \"$JAVA_HOME/jre/sh/java\" ] ; then\n        # IBM's JDK on AIX uses strange locations for the executables\n        JAVACMD=\"$JAVA_HOME/jre/sh/java\"\n    else\n        JAVACMD=\"$JAVA_HOME/bin/java\"\n    fi\n    if [ ! -x \"$JAVACMD\" ] ; then\n        die \"ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME\n\nPlease set the JAVA_HOME variable in your environment to match the\nlocation of your Java installation.\"\n    fi\nelse\n    JAVACMD=\"java\"\n    which java >/dev/null 2>&1 || die \"ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.\n\nPlease set the JAVA_HOME variable in your environment to match the\nlocation of your Java installation.\"\nfi\n\n# Increase the maximum file descriptors if we can.\nif [ \"$cygwin\" = \"false\" -a \"$darwin\" = \"false\" ] ; then\n    MAX_FD_LIMIT=`ulimit -H -n`\n    if [ $? -eq 0 ] ; then\n        if [ \"$MAX_FD\" = \"maximum\" -o \"$MAX_FD\" = \"max\" ] ; then\n            MAX_FD=\"$MAX_FD_LIMIT\"\n        fi\n        ulimit -n $MAX_FD\n        if [ $? -ne 0 ] ; then\n            warn \"Could not set maximum file descriptor limit: $MAX_FD\"\n        fi\n    else\n        warn \"Could not query maximum file descriptor limit: $MAX_FD_LIMIT\"\n    fi\nfi\n\n# For Darwin, add options to specify how the application appears in the dock\nif $darwin; then\n    GRADLE_OPTS=\"$GRADLE_OPTS \\\"-Xdock:name=$APP_NAME\\\" \\\"-Xdock:icon=$APP_HOME/media/gradle.icns\\\"\"\nfi\n\n# For Cygwin, switch paths to Windows format before running java\nif $cygwin ; then\n    APP_HOME=`cygpath --path --mixed \"$APP_HOME\"`\n    CLASSPATH=`cygpath --path --mixed \"$CLASSPATH\"`\n    JAVACMD=`cygpath --unix \"$JAVACMD\"`\n\n    # We build the pattern for arguments to be converted via cygpath\n    ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`\n    SEP=\"\"\n    for dir in $ROOTDIRSRAW ; do\n        ROOTDIRS=\"$ROOTDIRS$SEP$dir\"\n        SEP=\"|\"\n    done\n    OURCYGPATTERN=\"(^($ROOTDIRS))\"\n    # Add a user-defined pattern to the cygpath arguments\n    if [ \"$GRADLE_CYGPATTERN\" != \"\" ] ; then\n        OURCYGPATTERN=\"$OURCYGPATTERN|($GRADLE_CYGPATTERN)\"\n    fi\n    # Now convert the arguments - kludge to limit ourselves to /bin/sh\n    i=0\n    for arg in \"$@\" ; do\n        CHECK=`echo \"$arg\"|egrep -c \"$OURCYGPATTERN\" -`\n        CHECK2=`echo \"$arg\"|egrep -c \"^-\"`                                 ### Determine if an option\n\n        if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then                    ### Added a condition\n            eval `echo args$i`=`cygpath --path --ignore --mixed \"$arg\"`\n        else\n            eval `echo args$i`=\"\\\"$arg\\\"\"\n        fi\n        i=$((i+1))\n    done\n    case $i in\n        (0) set -- ;;\n        (1) set -- \"$args0\" ;;\n        (2) set -- \"$args0\" \"$args1\" ;;\n        (3) set -- \"$args0\" \"$args1\" \"$args2\" ;;\n        (4) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" ;;\n        (5) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" ;;\n        (6) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" \"$args5\" ;;\n        (7) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" \"$args5\" \"$args6\" ;;\n        (8) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" \"$args5\" \"$args6\" \"$args7\" ;;\n        (9) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" \"$args5\" \"$args6\" \"$args7\" \"$args8\" ;;\n    esac\nfi\n\n# Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules\nfunction splitJvmOpts() {\n    JVM_OPTS=(\"$@\")\n}\neval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS\nJVM_OPTS[${#JVM_OPTS[*]}]=\"-Dorg.gradle.appname=$APP_BASE_NAME\"\n\nexec \"$JAVACMD\" \"${JVM_OPTS[@]}\" -classpath \"$CLASSPATH\" org.gradle.wrapper.GradleWrapperMain \"$@\"\n"
  },
  {
    "path": "graphiql-spring-boot-autoconfigure/gradlew.bat",
    "content": "@if \"%DEBUG%\" == \"\" @echo off\n@rem ##########################################################################\n@rem\n@rem  Gradle startup script for Windows\n@rem\n@rem ##########################################################################\n\n@rem Set local scope for the variables with windows NT shell\nif \"%OS%\"==\"Windows_NT\" setlocal\n\n@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.\nset DEFAULT_JVM_OPTS=\n\nset DIRNAME=%~dp0\nif \"%DIRNAME%\" == \"\" set DIRNAME=.\nset APP_BASE_NAME=%~n0\nset APP_HOME=%DIRNAME%\n\n@rem Find java.exe\nif defined JAVA_HOME goto findJavaFromJavaHome\n\nset JAVA_EXE=java.exe\n%JAVA_EXE% -version >NUL 2>&1\nif \"%ERRORLEVEL%\" == \"0\" goto init\n\necho.\necho ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.\necho.\necho Please set the JAVA_HOME variable in your environment to match the\necho location of your Java installation.\n\ngoto fail\n\n:findJavaFromJavaHome\nset JAVA_HOME=%JAVA_HOME:\"=%\nset JAVA_EXE=%JAVA_HOME%/bin/java.exe\n\nif exist \"%JAVA_EXE%\" goto init\n\necho.\necho ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%\necho.\necho Please set the JAVA_HOME variable in your environment to match the\necho location of your Java installation.\n\ngoto fail\n\n:init\n@rem Get command-line arguments, handling Windowz variants\n\nif not \"%OS%\" == \"Windows_NT\" goto win9xME_args\nif \"%@eval[2+2]\" == \"4\" goto 4NT_args\n\n:win9xME_args\n@rem Slurp the command line arguments.\nset CMD_LINE_ARGS=\nset _SKIP=2\n\n:win9xME_args_slurp\nif \"x%~1\" == \"x\" goto execute\n\nset CMD_LINE_ARGS=%*\ngoto execute\n\n:4NT_args\n@rem Get arguments from the 4NT Shell from JP Software\nset CMD_LINE_ARGS=%$\n\n:execute\n@rem Setup the command line\n\nset CLASSPATH=%APP_HOME%\\gradle\\wrapper\\gradle-wrapper.jar\n\n@rem Execute Gradle\n\"%JAVA_EXE%\" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% \"-Dorg.gradle.appname=%APP_BASE_NAME%\" -classpath \"%CLASSPATH%\" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%\n\n:end\n@rem End local scope for the variables with windows NT shell\nif \"%ERRORLEVEL%\"==\"0\" goto mainEnd\n\n:fail\nrem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of\nrem the _cmd.exe /c_ return code!\nif  not \"\" == \"%GRADLE_EXIT_CONSOLE%\" exit 1\nexit /b 1\n\n:mainEnd\nif \"%OS%\"==\"Windows_NT\" endlocal\n\n:omega\n"
  },
  {
    "path": "graphiql-spring-boot-autoconfigure/settings.gradle",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\n\nrootProject.name = PROJECT_NAME"
  },
  {
    "path": "graphiql-spring-boot-autoconfigure/src/main/resources/META-INF/resources/graphiql-config.js",
    "content": "(function(f){\n   var graphql_server_context = '{{graphql_server_context}}'\n});"
  },
  {
    "path": "graphiql-spring-boot-autoconfigure/src/main/resources/META-INF/resources/index.html",
    "content": "<!DOCTYPE html>\n<html>\n<head>\n    <style>body{height:100%;margin:0;width:100%;overflow:hidden}#graphiql{height:100vh}</style>\n    <link rel=stylesheet href=\"webjars/graphiql/0.6.6/graphiql.min.css\" />\n    <script src=\"webjars/fetch/0.9.0/fetch.min.js\"></script>\n    <script src=\"webjars/react/0.14.7/react.min.js\"></script>\n    <script src=\"webjars/react/0.14.7/react-dom.min.js\"></script>\n    <script src=\"webjars/graphiql/0.6.6/graphiql.min.js\"></script>\n</head>\n<body>\n<div id=graphiql>Loading...</div>\n<script>var search=window.location.search;var parameters={};search.substr(1).split(\"&\").forEach(function(b){var a=b.indexOf(\"=\");if(a>=0){parameters[decodeURIComponent(b.slice(0,a))]=decodeURIComponent(b.slice(a+1))}});if(parameters.variables){try{parameters.variables=JSON.stringify(JSON.parse(parameters.variables),null,2)}catch(e){}}function onEditQuery(a){parameters.query=a;updateURL()}function onEditVariables(a){parameters.variables=a;updateURL()}function onEditOperationName(a){parameters.operationName=a;updateURL()}function updateURL(){var a=\"?\"+Object.keys(parameters).filter(function(b){return Boolean(parameters[b])}).map(function(b){return encodeURIComponent(b)+\"=\"+encodeURIComponent(parameters[b])}).join(\"&\");history.replaceState(null,null,a)}function graphQLFetcher(a){return fetch(window.location.origin+\"/graphql\",{method:\"post\",headers:{Accept:\"application/json\",\"Content-Type\":\"application/json\",},body:JSON.stringify(a),credentials:\"include\",}).then(function(b){return b.text()}).then(function(c){try{return JSON.parse(c)}catch(b){return c}})}ReactDOM.render(React.createElement(GraphiQL,{fetcher:graphQLFetcher,query:parameters.query,variables:parameters.variables,operationName:parameters.operationName,onEditQuery:onEditQuery,onEditVariables:onEditVariables,onEditOperationName:onEditOperationName}),document.getElementById(\"graphiql\"));</script>\n</body>\n</html>"
  },
  {
    "path": "graphiql-spring-boot-starter/LICENSE.md",
    "content": "The MIT License (MIT)\n\nCopyright (c) 2016 Oembedler Inc. and Contributors\n\nPermission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE."
  },
  {
    "path": "graphiql-spring-boot-starter/build.gradle",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\nbuildscript {\n    repositories {\n        maven { url \"https://plugins.gradle.org/m2/\" }\n    }\n    dependencies {\n        classpath \"com.jfrog.bintray.gradle:gradle-bintray-plugin:1.6\"\n    }\n}\n\ndependencies {\n    compile(project(':graphiql-spring-boot-autoconfigure'))\n}"
  },
  {
    "path": "graphiql-spring-boot-starter/gradle/wrapper/gradle-wrapper.properties",
    "content": "#Sun Mar 27 20:34:11 BST 2016\ndistributionBase=GRADLE_USER_HOME\ndistributionPath=wrapper/dists\nzipStoreBase=GRADLE_USER_HOME\nzipStorePath=wrapper/dists\ndistributionUrl=https\\://services.gradle.org/distributions/gradle-2.9-bin.zip\n"
  },
  {
    "path": "graphiql-spring-boot-starter/gradle.properties",
    "content": "#\n# The MIT License (MIT)\n#\n# Copyright (c) 2016 oEmbedler Inc. and Contributors\n#\n# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n#  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n#  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n#  persons to whom the Software is furnished to do so, subject to the following conditions:\n#\n# The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n#\n# THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n# BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n# DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n#\n\nPROJECT_VERSION = 2.1.0\nPROJECT_GROUP = com.embedler.moon.graphql.boot.starter\nPROJECT_NAME = graphiql-spring-boot-starter\nPROJECT_DESC = GraphiQL Spring Framework Boot Starter\nPROJECT_GIT_REPO_URL = https://github.com/oembedler/graphql-spring-boot\nPROJECT_LICENSE = MIT\nPROJECT_LICENSE_URL = https://github.com/oembedler/spring-boot-graphql/blob/master/LICENSE.md\nPROJECT_DEV_ID = oembedler\nPROJECT_DEV_NAME = Embedler Inc.\n\nVCS=Git\n\n###\n\nSOURCE_COMPATIBILITY = 1.8\nTARGET_COMPATIBILITY = 1.8\n\n###\n\nGRADLE_WRAPPER_VER = 2.9\n\n###\n\norg.gradle.daemon=true\n\nbintray.user=USER\nbintray.key=KEY"
  },
  {
    "path": "graphiql-spring-boot-starter/gradlew",
    "content": "#!/usr/bin/env bash\n\n##############################################################################\n##\n##  Gradle start up script for UN*X\n##\n##############################################################################\n\n# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.\nDEFAULT_JVM_OPTS=\"\"\n\nAPP_NAME=\"Gradle\"\nAPP_BASE_NAME=`basename \"$0\"`\n\n# Use the maximum available, or set MAX_FD != -1 to use that value.\nMAX_FD=\"maximum\"\n\nwarn ( ) {\n    echo \"$*\"\n}\n\ndie ( ) {\n    echo\n    echo \"$*\"\n    echo\n    exit 1\n}\n\n# OS specific support (must be 'true' or 'false').\ncygwin=false\nmsys=false\ndarwin=false\ncase \"`uname`\" in\n  CYGWIN* )\n    cygwin=true\n    ;;\n  Darwin* )\n    darwin=true\n    ;;\n  MINGW* )\n    msys=true\n    ;;\nesac\n\n# Attempt to set APP_HOME\n# Resolve links: $0 may be a link\nPRG=\"$0\"\n# Need this for relative symlinks.\nwhile [ -h \"$PRG\" ] ; do\n    ls=`ls -ld \"$PRG\"`\n    link=`expr \"$ls\" : '.*-> \\(.*\\)$'`\n    if expr \"$link\" : '/.*' > /dev/null; then\n        PRG=\"$link\"\n    else\n        PRG=`dirname \"$PRG\"`\"/$link\"\n    fi\ndone\nSAVED=\"`pwd`\"\ncd \"`dirname \\\"$PRG\\\"`/\" >/dev/null\nAPP_HOME=\"`pwd -P`\"\ncd \"$SAVED\" >/dev/null\n\nCLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar\n\n# Determine the Java command to use to start the JVM.\nif [ -n \"$JAVA_HOME\" ] ; then\n    if [ -x \"$JAVA_HOME/jre/sh/java\" ] ; then\n        # IBM's JDK on AIX uses strange locations for the executables\n        JAVACMD=\"$JAVA_HOME/jre/sh/java\"\n    else\n        JAVACMD=\"$JAVA_HOME/bin/java\"\n    fi\n    if [ ! -x \"$JAVACMD\" ] ; then\n        die \"ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME\n\nPlease set the JAVA_HOME variable in your environment to match the\nlocation of your Java installation.\"\n    fi\nelse\n    JAVACMD=\"java\"\n    which java >/dev/null 2>&1 || die \"ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.\n\nPlease set the JAVA_HOME variable in your environment to match the\nlocation of your Java installation.\"\nfi\n\n# Increase the maximum file descriptors if we can.\nif [ \"$cygwin\" = \"false\" -a \"$darwin\" = \"false\" ] ; then\n    MAX_FD_LIMIT=`ulimit -H -n`\n    if [ $? -eq 0 ] ; then\n        if [ \"$MAX_FD\" = \"maximum\" -o \"$MAX_FD\" = \"max\" ] ; then\n            MAX_FD=\"$MAX_FD_LIMIT\"\n        fi\n        ulimit -n $MAX_FD\n        if [ $? -ne 0 ] ; then\n            warn \"Could not set maximum file descriptor limit: $MAX_FD\"\n        fi\n    else\n        warn \"Could not query maximum file descriptor limit: $MAX_FD_LIMIT\"\n    fi\nfi\n\n# For Darwin, add options to specify how the application appears in the dock\nif $darwin; then\n    GRADLE_OPTS=\"$GRADLE_OPTS \\\"-Xdock:name=$APP_NAME\\\" \\\"-Xdock:icon=$APP_HOME/media/gradle.icns\\\"\"\nfi\n\n# For Cygwin, switch paths to Windows format before running java\nif $cygwin ; then\n    APP_HOME=`cygpath --path --mixed \"$APP_HOME\"`\n    CLASSPATH=`cygpath --path --mixed \"$CLASSPATH\"`\n    JAVACMD=`cygpath --unix \"$JAVACMD\"`\n\n    # We build the pattern for arguments to be converted via cygpath\n    ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`\n    SEP=\"\"\n    for dir in $ROOTDIRSRAW ; do\n        ROOTDIRS=\"$ROOTDIRS$SEP$dir\"\n        SEP=\"|\"\n    done\n    OURCYGPATTERN=\"(^($ROOTDIRS))\"\n    # Add a user-defined pattern to the cygpath arguments\n    if [ \"$GRADLE_CYGPATTERN\" != \"\" ] ; then\n        OURCYGPATTERN=\"$OURCYGPATTERN|($GRADLE_CYGPATTERN)\"\n    fi\n    # Now convert the arguments - kludge to limit ourselves to /bin/sh\n    i=0\n    for arg in \"$@\" ; do\n        CHECK=`echo \"$arg\"|egrep -c \"$OURCYGPATTERN\" -`\n        CHECK2=`echo \"$arg\"|egrep -c \"^-\"`                                 ### Determine if an option\n\n        if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then                    ### Added a condition\n            eval `echo args$i`=`cygpath --path --ignore --mixed \"$arg\"`\n        else\n            eval `echo args$i`=\"\\\"$arg\\\"\"\n        fi\n        i=$((i+1))\n    done\n    case $i in\n        (0) set -- ;;\n        (1) set -- \"$args0\" ;;\n        (2) set -- \"$args0\" \"$args1\" ;;\n        (3) set -- \"$args0\" \"$args1\" \"$args2\" ;;\n        (4) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" ;;\n        (5) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" ;;\n        (6) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" \"$args5\" ;;\n        (7) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" \"$args5\" \"$args6\" ;;\n        (8) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" \"$args5\" \"$args6\" \"$args7\" ;;\n        (9) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" \"$args5\" \"$args6\" \"$args7\" \"$args8\" ;;\n    esac\nfi\n\n# Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules\nfunction splitJvmOpts() {\n    JVM_OPTS=(\"$@\")\n}\neval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS\nJVM_OPTS[${#JVM_OPTS[*]}]=\"-Dorg.gradle.appname=$APP_BASE_NAME\"\n\nexec \"$JAVACMD\" \"${JVM_OPTS[@]}\" -classpath \"$CLASSPATH\" org.gradle.wrapper.GradleWrapperMain \"$@\"\n"
  },
  {
    "path": "graphiql-spring-boot-starter/gradlew.bat",
    "content": "@if \"%DEBUG%\" == \"\" @echo off\n@rem ##########################################################################\n@rem\n@rem  Gradle startup script for Windows\n@rem\n@rem ##########################################################################\n\n@rem Set local scope for the variables with windows NT shell\nif \"%OS%\"==\"Windows_NT\" setlocal\n\n@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.\nset DEFAULT_JVM_OPTS=\n\nset DIRNAME=%~dp0\nif \"%DIRNAME%\" == \"\" set DIRNAME=.\nset APP_BASE_NAME=%~n0\nset APP_HOME=%DIRNAME%\n\n@rem Find java.exe\nif defined JAVA_HOME goto findJavaFromJavaHome\n\nset JAVA_EXE=java.exe\n%JAVA_EXE% -version >NUL 2>&1\nif \"%ERRORLEVEL%\" == \"0\" goto init\n\necho.\necho ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.\necho.\necho Please set the JAVA_HOME variable in your environment to match the\necho location of your Java installation.\n\ngoto fail\n\n:findJavaFromJavaHome\nset JAVA_HOME=%JAVA_HOME:\"=%\nset JAVA_EXE=%JAVA_HOME%/bin/java.exe\n\nif exist \"%JAVA_EXE%\" goto init\n\necho.\necho ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%\necho.\necho Please set the JAVA_HOME variable in your environment to match the\necho location of your Java installation.\n\ngoto fail\n\n:init\n@rem Get command-line arguments, handling Windowz variants\n\nif not \"%OS%\" == \"Windows_NT\" goto win9xME_args\nif \"%@eval[2+2]\" == \"4\" goto 4NT_args\n\n:win9xME_args\n@rem Slurp the command line arguments.\nset CMD_LINE_ARGS=\nset _SKIP=2\n\n:win9xME_args_slurp\nif \"x%~1\" == \"x\" goto execute\n\nset CMD_LINE_ARGS=%*\ngoto execute\n\n:4NT_args\n@rem Get arguments from the 4NT Shell from JP Software\nset CMD_LINE_ARGS=%$\n\n:execute\n@rem Setup the command line\n\nset CLASSPATH=%APP_HOME%\\gradle\\wrapper\\gradle-wrapper.jar\n\n@rem Execute Gradle\n\"%JAVA_EXE%\" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% \"-Dorg.gradle.appname=%APP_BASE_NAME%\" -classpath \"%CLASSPATH%\" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%\n\n:end\n@rem End local scope for the variables with windows NT shell\nif \"%ERRORLEVEL%\"==\"0\" goto mainEnd\n\n:fail\nrem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of\nrem the _cmd.exe /c_ return code!\nif  not \"\" == \"%GRADLE_EXIT_CONSOLE%\" exit 1\nexit /b 1\n\n:mainEnd\nif \"%OS%\"==\"Windows_NT\" endlocal\n\n:omega\n"
  },
  {
    "path": "graphiql-spring-boot-starter/settings.gradle",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\n\nrootProject.name = PROJECT_NAME"
  },
  {
    "path": "graphql-sample-app/LICENSE.md",
    "content": "The MIT License (MIT)\n\nCopyright (c) 2016 Oembedler Inc. and Contributors\n\nPermission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE."
  },
  {
    "path": "graphql-sample-app/build.gradle",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\nbuildscript {\n    repositories {\n        maven { url \"https://plugins.gradle.org/m2/\" }\n        maven { url 'http://repo.spring.io/plugins-release' }\n    }\n    dependencies {\n        classpath(\"org.springframework.boot:spring-boot-gradle-plugin:1.3.3.RELEASE\")\n        classpath \"com.jfrog.bintray.gradle:gradle-bintray-plugin:1.6\"\n    }\n}\n\napply plugin: 'java'\napply plugin: 'war'\napply plugin: 'spring-boot'\n\nrepositories {\n    jcenter()\n}\n\ndependencies{\n    compile(project(\":graphql-spring-boot-starter\"))\n    compile(project(\":graphiql-spring-boot-starter\"))\n\n    compile(\"org.springframework.boot:spring-boot-starter-web\")\n    compile(\"org.springframework.boot:spring-boot-starter-actuator\")\n\n    testCompile(\"org.springframework.boot:spring-boot-starter-test\")\n}"
  },
  {
    "path": "graphql-sample-app/gradle/wrapper/gradle-wrapper.properties",
    "content": "#Sun Mar 27 20:34:11 BST 2016\ndistributionBase=GRADLE_USER_HOME\ndistributionPath=wrapper/dists\nzipStoreBase=GRADLE_USER_HOME\nzipStorePath=wrapper/dists\ndistributionUrl=https\\://services.gradle.org/distributions/gradle-2.9-bin.zip\n"
  },
  {
    "path": "graphql-sample-app/gradle.properties",
    "content": "#\n# The MIT License (MIT)\n#\n# Copyright (c) 2016 oEmbedler Inc. and Contributors\n#\n# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n#  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n#  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n#  persons to whom the Software is furnished to do so, subject to the following conditions:\n#\n# The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n#\n# THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n# BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n# DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n#\n\nPROJECT_VERSION = 2.1.0\nPROJECT_GROUP = com.embedler.moon.graphql.boot.sample\nPROJECT_NAME = graphql-sample-app\nPROJECT_DESC = GraphQL Spring Framework Boot Sample App\nPROJECT_GIT_REPO_URL = https://github.com/oembedler/graphql-spring-boot\nPROJECT_LICENSE = MIT\nPROJECT_LICENSE_URL = https://github.com/oembedler/spring-boot-graphql/blob/master/LICENSE.md\nPROJECT_DEV_ID = oembedler\nPROJECT_DEV_NAME = Embedler Inc.\n\nVCS=Git\n\n###\n\nSOURCE_COMPATIBILITY = 1.8\nTARGET_COMPATIBILITY = 1.8\n\n###\n\nGRADLE_WRAPPER_VER = 2.9\n\n###\n\norg.gradle.daemon=true\n\nbintray.user=USER\nbintray.key=KEY"
  },
  {
    "path": "graphql-sample-app/gradlew",
    "content": "#!/usr/bin/env bash\n\n##############################################################################\n##\n##  Gradle start up script for UN*X\n##\n##############################################################################\n\n# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.\nDEFAULT_JVM_OPTS=\"\"\n\nAPP_NAME=\"Gradle\"\nAPP_BASE_NAME=`basename \"$0\"`\n\n# Use the maximum available, or set MAX_FD != -1 to use that value.\nMAX_FD=\"maximum\"\n\nwarn ( ) {\n    echo \"$*\"\n}\n\ndie ( ) {\n    echo\n    echo \"$*\"\n    echo\n    exit 1\n}\n\n# OS specific support (must be 'true' or 'false').\ncygwin=false\nmsys=false\ndarwin=false\ncase \"`uname`\" in\n  CYGWIN* )\n    cygwin=true\n    ;;\n  Darwin* )\n    darwin=true\n    ;;\n  MINGW* )\n    msys=true\n    ;;\nesac\n\n# Attempt to set APP_HOME\n# Resolve links: $0 may be a link\nPRG=\"$0\"\n# Need this for relative symlinks.\nwhile [ -h \"$PRG\" ] ; do\n    ls=`ls -ld \"$PRG\"`\n    link=`expr \"$ls\" : '.*-> \\(.*\\)$'`\n    if expr \"$link\" : '/.*' > /dev/null; then\n        PRG=\"$link\"\n    else\n        PRG=`dirname \"$PRG\"`\"/$link\"\n    fi\ndone\nSAVED=\"`pwd`\"\ncd \"`dirname \\\"$PRG\\\"`/\" >/dev/null\nAPP_HOME=\"`pwd -P`\"\ncd \"$SAVED\" >/dev/null\n\nCLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar\n\n# Determine the Java command to use to start the JVM.\nif [ -n \"$JAVA_HOME\" ] ; then\n    if [ -x \"$JAVA_HOME/jre/sh/java\" ] ; then\n        # IBM's JDK on AIX uses strange locations for the executables\n        JAVACMD=\"$JAVA_HOME/jre/sh/java\"\n    else\n        JAVACMD=\"$JAVA_HOME/bin/java\"\n    fi\n    if [ ! -x \"$JAVACMD\" ] ; then\n        die \"ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME\n\nPlease set the JAVA_HOME variable in your environment to match the\nlocation of your Java installation.\"\n    fi\nelse\n    JAVACMD=\"java\"\n    which java >/dev/null 2>&1 || die \"ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.\n\nPlease set the JAVA_HOME variable in your environment to match the\nlocation of your Java installation.\"\nfi\n\n# Increase the maximum file descriptors if we can.\nif [ \"$cygwin\" = \"false\" -a \"$darwin\" = \"false\" ] ; then\n    MAX_FD_LIMIT=`ulimit -H -n`\n    if [ $? -eq 0 ] ; then\n        if [ \"$MAX_FD\" = \"maximum\" -o \"$MAX_FD\" = \"max\" ] ; then\n            MAX_FD=\"$MAX_FD_LIMIT\"\n        fi\n        ulimit -n $MAX_FD\n        if [ $? -ne 0 ] ; then\n            warn \"Could not set maximum file descriptor limit: $MAX_FD\"\n        fi\n    else\n        warn \"Could not query maximum file descriptor limit: $MAX_FD_LIMIT\"\n    fi\nfi\n\n# For Darwin, add options to specify how the application appears in the dock\nif $darwin; then\n    GRADLE_OPTS=\"$GRADLE_OPTS \\\"-Xdock:name=$APP_NAME\\\" \\\"-Xdock:icon=$APP_HOME/media/gradle.icns\\\"\"\nfi\n\n# For Cygwin, switch paths to Windows format before running java\nif $cygwin ; then\n    APP_HOME=`cygpath --path --mixed \"$APP_HOME\"`\n    CLASSPATH=`cygpath --path --mixed \"$CLASSPATH\"`\n    JAVACMD=`cygpath --unix \"$JAVACMD\"`\n\n    # We build the pattern for arguments to be converted via cygpath\n    ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`\n    SEP=\"\"\n    for dir in $ROOTDIRSRAW ; do\n        ROOTDIRS=\"$ROOTDIRS$SEP$dir\"\n        SEP=\"|\"\n    done\n    OURCYGPATTERN=\"(^($ROOTDIRS))\"\n    # Add a user-defined pattern to the cygpath arguments\n    if [ \"$GRADLE_CYGPATTERN\" != \"\" ] ; then\n        OURCYGPATTERN=\"$OURCYGPATTERN|($GRADLE_CYGPATTERN)\"\n    fi\n    # Now convert the arguments - kludge to limit ourselves to /bin/sh\n    i=0\n    for arg in \"$@\" ; do\n        CHECK=`echo \"$arg\"|egrep -c \"$OURCYGPATTERN\" -`\n        CHECK2=`echo \"$arg\"|egrep -c \"^-\"`                                 ### Determine if an option\n\n        if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then                    ### Added a condition\n            eval `echo args$i`=`cygpath --path --ignore --mixed \"$arg\"`\n        else\n            eval `echo args$i`=\"\\\"$arg\\\"\"\n        fi\n        i=$((i+1))\n    done\n    case $i in\n        (0) set -- ;;\n        (1) set -- \"$args0\" ;;\n        (2) set -- \"$args0\" \"$args1\" ;;\n        (3) set -- \"$args0\" \"$args1\" \"$args2\" ;;\n        (4) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" ;;\n        (5) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" ;;\n        (6) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" \"$args5\" ;;\n        (7) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" \"$args5\" \"$args6\" ;;\n        (8) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" \"$args5\" \"$args6\" \"$args7\" ;;\n        (9) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" \"$args5\" \"$args6\" \"$args7\" \"$args8\" ;;\n    esac\nfi\n\n# Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules\nfunction splitJvmOpts() {\n    JVM_OPTS=(\"$@\")\n}\neval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS\nJVM_OPTS[${#JVM_OPTS[*]}]=\"-Dorg.gradle.appname=$APP_BASE_NAME\"\n\nexec \"$JAVACMD\" \"${JVM_OPTS[@]}\" -classpath \"$CLASSPATH\" org.gradle.wrapper.GradleWrapperMain \"$@\"\n"
  },
  {
    "path": "graphql-sample-app/gradlew.bat",
    "content": "@if \"%DEBUG%\" == \"\" @echo off\n@rem ##########################################################################\n@rem\n@rem  Gradle startup script for Windows\n@rem\n@rem ##########################################################################\n\n@rem Set local scope for the variables with windows NT shell\nif \"%OS%\"==\"Windows_NT\" setlocal\n\n@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.\nset DEFAULT_JVM_OPTS=\n\nset DIRNAME=%~dp0\nif \"%DIRNAME%\" == \"\" set DIRNAME=.\nset APP_BASE_NAME=%~n0\nset APP_HOME=%DIRNAME%\n\n@rem Find java.exe\nif defined JAVA_HOME goto findJavaFromJavaHome\n\nset JAVA_EXE=java.exe\n%JAVA_EXE% -version >NUL 2>&1\nif \"%ERRORLEVEL%\" == \"0\" goto init\n\necho.\necho ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.\necho.\necho Please set the JAVA_HOME variable in your environment to match the\necho location of your Java installation.\n\ngoto fail\n\n:findJavaFromJavaHome\nset JAVA_HOME=%JAVA_HOME:\"=%\nset JAVA_EXE=%JAVA_HOME%/bin/java.exe\n\nif exist \"%JAVA_EXE%\" goto init\n\necho.\necho ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%\necho.\necho Please set the JAVA_HOME variable in your environment to match the\necho location of your Java installation.\n\ngoto fail\n\n:init\n@rem Get command-line arguments, handling Windowz variants\n\nif not \"%OS%\" == \"Windows_NT\" goto win9xME_args\nif \"%@eval[2+2]\" == \"4\" goto 4NT_args\n\n:win9xME_args\n@rem Slurp the command line arguments.\nset CMD_LINE_ARGS=\nset _SKIP=2\n\n:win9xME_args_slurp\nif \"x%~1\" == \"x\" goto execute\n\nset CMD_LINE_ARGS=%*\ngoto execute\n\n:4NT_args\n@rem Get arguments from the 4NT Shell from JP Software\nset CMD_LINE_ARGS=%$\n\n:execute\n@rem Setup the command line\n\nset CLASSPATH=%APP_HOME%\\gradle\\wrapper\\gradle-wrapper.jar\n\n@rem Execute Gradle\n\"%JAVA_EXE%\" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% \"-Dorg.gradle.appname=%APP_BASE_NAME%\" -classpath \"%CLASSPATH%\" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%\n\n:end\n@rem End local scope for the variables with windows NT shell\nif \"%ERRORLEVEL%\"==\"0\" goto mainEnd\n\n:fail\nrem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of\nrem the _cmd.exe /c_ return code!\nif  not \"\" == \"%GRADLE_EXIT_CONSOLE%\" exit 1\nexit /b 1\n\n:mainEnd\nif \"%OS%\"==\"Windows_NT\" endlocal\n\n:omega\n"
  },
  {
    "path": "graphql-sample-app/settings.gradle",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\n\nrootProject.name = PROJECT_NAME"
  },
  {
    "path": "graphql-sample-app/src/main/java/com/embedler/moon/graphql/boot/sample/ApplicationBootConfiguration.java",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\n\npackage com.embedler.moon.graphql.boot.sample;\n\nimport com.oembedler.moon.graphql.boot.EnableGraphQLServer;\nimport org.springframework.boot.SpringApplication;\nimport org.springframework.boot.autoconfigure.SpringBootApplication;\n\n/**\n * @author <a href=\"mailto:java.lang.RuntimeException@gmail.com\">oEmbedler Inc.</a>\n */\n@SpringBootApplication\n@EnableGraphQLServer\npublic class ApplicationBootConfiguration {\n\n    public static void main(String[] args) throws Exception {\n        SpringApplication.run(ApplicationBootConfiguration.class, args);\n    }\n}\n"
  },
  {
    "path": "graphql-sample-app/src/main/java/com/embedler/moon/graphql/boot/sample/SimpleListConnection.java",
    "content": "package com.embedler.moon.graphql.boot.sample;\n\nimport com.oembedler.moon.graphql.engine.relay.ConnectionObjectType;\nimport com.oembedler.moon.graphql.engine.relay.EdgeObjectType;\nimport com.oembedler.moon.graphql.engine.relay.PageInfoObjectType;\nimport graphql.relay.Base64;\nimport graphql.relay.ConnectionCursor;\nimport graphql.schema.DataFetchingEnvironment;\n\nimport java.util.ArrayList;\nimport java.util.List;\n\n/**\n * @author <a href=\"mailto:java.lang.RuntimeException@gmail.com\">oEmbedler Inc.</a>\n */\npublic class SimpleListConnection {\n\n    private static final String DUMMY_CURSOR_PREFIX = \"simple-cursor\";\n    private List<?> data = new ArrayList<Object>();\n\n    public SimpleListConnection(List<?> data) {\n        this.data = data;\n    }\n\n    public <T extends EdgeObjectType> T createEdgeObject() {\n        return (T) new EdgeObjectType();\n    }\n\n    public <T extends ConnectionObjectType> T createConnectionObject() {\n        return (T) new ConnectionObjectType();\n    }\n\n    private List<EdgeObjectType> buildEdges() {\n        List<EdgeObjectType> edges = new ArrayList<>();\n        int ix = 0;\n        for (Object object : data) {\n            EdgeObjectType edge = createEdgeObject();\n            edge.setNode(object);\n            edge.setCursor(createCursor(ix++));\n            edges.add(edge);\n        }\n        return edges;\n    }\n\n    public <T extends ConnectionObjectType> T get(DataFetchingEnvironment environment) {\n\n        List<EdgeObjectType> edges = buildEdges();\n\n        int afterOffset = getOffsetFromCursor(environment.<String>getArgument(\"after\"), -1);\n        int begin = Math.max(afterOffset, -1) + 1;\n        int beforeOffset = getOffsetFromCursor(environment.<String>getArgument(\"before\"), edges.size());\n        int end = Math.min(beforeOffset, edges.size());\n\n        edges = edges.subList(begin, end);\n        if (edges.size() == 0) {\n            return emptyConnection();\n        }\n\n        Integer first = environment.<Integer>getArgument(\"first\");\n        Integer last = environment.<Integer>getArgument(\"last\");\n\n        String firstPresliceCursor = edges.get(0).getCursor();\n        String lastPresliceCursor = edges.get(edges.size() - 1).getCursor();\n\n        if (first != null) {\n            edges = edges.subList(0, first <= edges.size() ? first : edges.size());\n        }\n        if (last != null) {\n            edges = edges.subList(edges.size() - last, edges.size());\n        }\n\n        if (edges.size() == 0) {\n            return emptyConnection();\n        }\n\n        EdgeObjectType firstEdge = edges.get(0);\n        EdgeObjectType lastEdge = edges.get(edges.size() - 1);\n\n        PageInfoObjectType pageInfo = new PageInfoObjectType();\n        pageInfo.setStartCursor(firstEdge.getCursor());\n        pageInfo.setEndCursor(lastEdge.getCursor());\n        pageInfo.setHasPreviousPage(!firstEdge.getCursor().equals(firstPresliceCursor));\n        pageInfo.setHasNextPage(!lastEdge.getCursor().equals(lastPresliceCursor));\n\n        ConnectionObjectType connection = createConnectionObject();\n        connection.setEdges(edges);\n        connection.setPageInfo(pageInfo);\n\n        return (T) connection;\n    }\n\n    private <T extends ConnectionObjectType> T emptyConnection() {\n        ConnectionObjectType connection = createConnectionObject();\n        connection.setPageInfo(new PageInfoObjectType());\n        return (T) connection;\n    }\n\n    public ConnectionCursor cursorForObjectInConnection(Object object) {\n        int index = data.indexOf(object);\n        String cursor = createCursor(index);\n        return new ConnectionCursor(cursor);\n    }\n\n    private int getOffsetFromCursor(String cursor, int defaultValue) {\n        if (cursor == null) return defaultValue;\n        String string = Base64.fromBase64(cursor);\n        return Integer.parseInt(string.substring(DUMMY_CURSOR_PREFIX.length()));\n    }\n\n    private String createCursor(int offset) {\n        String string = Base64.toBase64(DUMMY_CURSOR_PREFIX + Integer.toString(offset));\n        return string;\n    }\n\n}"
  },
  {
    "path": "graphql-sample-app/src/main/java/com/embedler/moon/graphql/boot/sample/TodoSimpleListConnection.java",
    "content": "package com.embedler.moon.graphql.boot.sample;\n\nimport com.embedler.moon.graphql.boot.sample.schema.objecttype.TodoObjectType;\nimport com.oembedler.moon.graphql.engine.relay.ConnectionObjectType;\nimport com.oembedler.moon.graphql.engine.relay.EdgeObjectType;\n\nimport java.util.ArrayList;\nimport java.util.List;\n\n/**\n * @author <a href=\"mailto:java.lang.RuntimeException@gmail.com\">oEmbedler Inc.</a>\n */\npublic class TodoSimpleListConnection extends SimpleListConnection {\n\n    private static final String DUMMY_CURSOR_PREFIX = \"simple-cursor\";\n    private List<?> data = new ArrayList<Object>();\n\n    public TodoSimpleListConnection(List<?> data) {\n        super(data);\n    }\n\n    public <T extends EdgeObjectType> T createEdgeObject() {\n        return (T) new TodoObjectType.TodoEdgeObjectType();\n    }\n\n    public <T extends ConnectionObjectType> T createConnectionObject() {\n        return (T) new TodoObjectType.TodoConnectionObjectType();\n    }\n\n}"
  },
  {
    "path": "graphql-sample-app/src/main/java/com/embedler/moon/graphql/boot/sample/schema/TodoSchema.java",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\n\npackage com.embedler.moon.graphql.boot.sample.schema;\n\nimport com.embedler.moon.graphql.boot.sample.TodoSimpleListConnection;\nimport com.embedler.moon.graphql.boot.sample.schema.objecttype.RootObjectType;\nimport com.embedler.moon.graphql.boot.sample.schema.objecttype.TodoObjectType;\nimport com.embedler.moon.graphql.boot.sample.schema.objecttype.UserObjectType;\nimport com.oembedler.moon.graphql.boot.GraphQLContext;\nimport com.oembedler.moon.graphql.engine.stereotype.*;\n\nimport java.util.ArrayList;\nimport java.util.List;\nimport java.util.stream.Collectors;\n\n@GraphQLSchema\npublic class TodoSchema {\n\n    @GraphQLSchemaQuery\n    private RootObjectType root;\n\n    private UserObjectType theOnlyUser = new UserObjectType();\n    private List<TodoObjectType> todos = new ArrayList<>();\n\n    private TodoSimpleListConnection simpleConnectionTodo;\n    private int nextTodoId = 0;\n\n\n    public TodoSchema() {\n        addTodo(\"Do Something\");\n        addTodo(\"Other todo\");\n\n        simpleConnectionTodo = new TodoSimpleListConnection(todos);\n    }\n\n    public String addTodo(String text) {\n        TodoObjectType newTodo = new TodoObjectType();\n        newTodo.setId(Integer.toString(nextTodoId++));\n        newTodo.setText(text);\n        todos.add(newTodo);\n        return newTodo.getId(newTodo);\n    }\n\n    public void removeTodo(String id) {\n        TodoObjectType del = todos.stream().filter(todo -> todo.getId(todo).equals(id)).findFirst().get();\n        todos.remove(del);\n    }\n\n    public void renameTodo(String id, String text) {\n        TodoObjectType matchedTodo = todos.stream().filter(todo -> todo.getId(todo).equals(id)).findFirst().get();\n        matchedTodo.setText(text);\n    }\n\n    public List<String> removeCompletedTodos() {\n        List<String> toDelete = todos.stream()\n                .filter(TodoObjectType::isComplete)\n                .map(todoObjectType -> todoObjectType.getId(todoObjectType))\n                .collect(Collectors.toList());\n        todos.removeIf(todo -> toDelete.contains(todo.getId(todo)));\n        return toDelete;\n    }\n\n    public List<String> markAllTodos(boolean complete) {\n        List<String> changed = new ArrayList<>();\n        todos.stream().filter(todo -> complete != todo.isComplete()).forEach(todo -> {\n            changed.add(todo.getId(todo));\n            todo.setComplete(complete);\n        });\n\n        return changed;\n    }\n\n    public void changeTodoStatus(String id, boolean complete) {\n        TodoObjectType todo = getTodo(id);\n        todo.setComplete(complete);\n    }\n\n    public TodoObjectType getTodo(String id) {\n        return todos.stream().filter(todo -> todo.getId(todo).equals(id)).findFirst().get();\n    }\n\n    public List<TodoObjectType> getTodos(List<String> ids) {\n        return todos.stream().filter(todo -> ids.contains(todo.getId(todo))).collect(Collectors.toList());\n    }\n\n    public UserObjectType getTheOnlyUser() {\n        return theOnlyUser;\n    }\n\n\n    public TodoSimpleListConnection getSimpleConnectionTodo() {\n        return simpleConnectionTodo;\n    }\n\n    public static class AddTodoIn {\n        private String text;\n\n        public String getText() {\n            return text;\n        }\n\n        public void setText(String text) {\n            this.text = text;\n        }\n    }\n\n    // --- mutations\n\n    @GraphQLMutation\n    @GraphQLDescription(\"Mutation to add new todo item\")\n    public\n    @GraphQLOut(\"todoEdge\")\n    TodoObjectType.TodoEdgeObjectType addTodoMutation(@GraphQLIn(\"addTodoInput\") AddTodoIn addTodoInput) {\n\n        TodoObjectType.TodoEdgeObjectType todoEdgeObjectType = new TodoObjectType.TodoEdgeObjectType();\n        todoEdgeObjectType.setCursor(\"test-cursor\");\n        todoEdgeObjectType.setNode(new TodoObjectType());\n        todoEdgeObjectType.getNode().setId(\"id-12345\");\n        todoEdgeObjectType.getNode().setText(\"simple text\");\n        todoEdgeObjectType.getNode().setComplete(false);\n\n        return todoEdgeObjectType;\n    }\n\n    @GraphQLMutation\n    public\n    @GraphQLOut(\"filename\")\n    String uploadFile(GraphQLContext graphQLContext) {\n        return graphQLContext.getUploadedFile().getName();\n    }\n\n    @GraphQLMutation\n    public String updateTodoMutation(@GraphQLIn(\"updateTodoInput\") String newText) {\n        return \"Simple output string\";\n    }\n\n}\n"
  },
  {
    "path": "graphql-sample-app/src/main/java/com/embedler/moon/graphql/boot/sample/schema/objecttype/BaseObjectType.java",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\n\npackage com.embedler.moon.graphql.boot.sample.schema.objecttype;\n\nimport com.oembedler.moon.graphql.engine.relay.RelayNode;\nimport com.oembedler.moon.graphql.engine.stereotype.GraphQLDescription;\nimport com.oembedler.moon.graphql.engine.stereotype.GraphQLID;\nimport com.oembedler.moon.graphql.engine.stereotype.GraphQLIgnore;\nimport com.oembedler.moon.graphql.engine.stereotype.GraphQLNonNull;\nimport graphql.relay.Relay;\n\n/**\n * @author <a href=\"mailto:java.lang.RuntimeException@gmail.com\">oEmbedler Inc.</a>\n */\npublic class BaseObjectType implements RelayNode {\n\n    @GraphQLIgnore\n    private String id;\n\n    @GraphQLID(\"id\")\n    @GraphQLNonNull\n    @GraphQLDescription(\"Global object unique identifier\")\n    public String getId(RelayNode relayNode) {\n        BaseObjectType baseObjectType = (BaseObjectType) relayNode;\n        return new Relay().toGlobalId(relayNode.getClass().getSimpleName(), baseObjectType.id);\n    }\n\n    public void setId(String id) {\n        this.id = id;\n    }\n}\n"
  },
  {
    "path": "graphql-sample-app/src/main/java/com/embedler/moon/graphql/boot/sample/schema/objecttype/RootObjectType.java",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\n\npackage com.embedler.moon.graphql.boot.sample.schema.objecttype;\n\nimport com.embedler.moon.graphql.boot.sample.schema.TodoSchema;\nimport com.oembedler.moon.graphql.boot.GraphQLContext;\nimport com.oembedler.moon.graphql.engine.relay.RelayNode;\nimport com.oembedler.moon.graphql.engine.stereotype.*;\nimport org.springframework.beans.factory.annotation.Autowired;\n\n/**\n * @author <a href=\"mailto:java.lang.RuntimeException@gmail.com\">oEmbedler Inc.</a>\n */\n@GraphQLObject(\"Root\")\npublic class RootObjectType {\n\n    @GraphQLNonNull\n    @GraphQLField(\"version\")\n    @GraphQLDescription(\"Root query version number\")\n    public static final String VERSION = \"0.9.0.2\";\n\n    @Autowired\n    @GraphQLIgnore\n    private TodoSchema todoSchema;\n\n    @GraphQLField\n    public UserObjectType viewer() {\n        return todoSchema.getTheOnlyUser();\n    }\n\n    @GraphQLField\n    public RelayNode node(@GraphQLID @GraphQLNonNull @GraphQLIn(\"id\") final String id) {\n        return new UserObjectType();\n    }\n}\n"
  },
  {
    "path": "graphql-sample-app/src/main/java/com/embedler/moon/graphql/boot/sample/schema/objecttype/TodoObjectType.java",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\n\npackage com.embedler.moon.graphql.boot.sample.schema.objecttype;\n\nimport com.oembedler.moon.graphql.engine.relay.ConnectionObjectType;\nimport com.oembedler.moon.graphql.engine.relay.EdgeObjectType;\nimport com.oembedler.moon.graphql.engine.relay.PageInfoObjectType;\nimport com.oembedler.moon.graphql.engine.stereotype.GraphQLObject;\n\n/**\n * @author <a href=\"mailto:java.lang.RuntimeException@gmail.com\">oEmbedler Inc.</a>\n */\n@GraphQLObject(\"Todo\")\npublic class TodoObjectType extends BaseObjectType {\n    private String text;\n    private boolean complete;\n\n    public String getText() {\n        return text;\n    }\n\n    public void setText(String text) {\n        this.text = text;\n    }\n\n    public boolean isComplete() {\n        return complete;\n    }\n\n    public void setComplete(boolean complete) {\n        this.complete = complete;\n    }\n\n    @GraphQLObject\n    public static class TodoConnectionObjectType extends ConnectionObjectType<TodoEdgeObjectType, PageInfoObjectType> {\n    }\n\n    @GraphQLObject\n    public static class TodoEdgeObjectType extends EdgeObjectType<TodoObjectType> {\n    }\n\n}\n"
  },
  {
    "path": "graphql-sample-app/src/main/java/com/embedler/moon/graphql/boot/sample/schema/objecttype/UserObjectType.java",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\n\npackage com.embedler.moon.graphql.boot.sample.schema.objecttype;\n\nimport com.embedler.moon.graphql.boot.sample.schema.TodoSchema;\nimport com.oembedler.moon.graphql.engine.stereotype.GraphQLField;\nimport com.oembedler.moon.graphql.engine.stereotype.GraphQLIgnore;\nimport com.oembedler.moon.graphql.engine.stereotype.GraphQLIn;\nimport com.oembedler.moon.graphql.engine.stereotype.GraphQLObject;\nimport graphql.schema.DataFetchingEnvironment;\nimport org.springframework.beans.factory.annotation.Autowired;\n\n/**\n * @author <a href=\"mailto:java.lang.RuntimeException@gmail.com\">oEmbedler Inc.</a>\n */\n@GraphQLObject(\"User\")\npublic class UserObjectType extends BaseObjectType {\n\n    @Autowired\n    @GraphQLIgnore\n    private TodoSchema todoSchema;\n\n    private String name = \"someId\";\n\n    public String getName() {\n        return name;\n    }\n\n    public void setName(String name) {\n        this.name = name;\n    }\n\n    @GraphQLField\n    public TodoObjectType.TodoConnectionObjectType todos(@GraphQLIn(\"before\") String before,\n                                                         @GraphQLIn(\"after\") String after,\n                                                         @GraphQLIn(value = \"first\", defaultSpel = \"1\") Integer first,\n                                                         @GraphQLIn(value = \"last\", defaultProvider = \"1\") Integer last,\n                                                         DataFetchingEnvironment environment) {\n        return todoSchema.getSimpleConnectionTodo().get(environment);\n    }\n\n}\n"
  },
  {
    "path": "graphql-sample-app/src/main/resources/application.yml",
    "content": "spring:\n      application:\n               name: graphql-todo-app\nserver:\n      port: 9000\ngraphql:\n      server:\n               mapping: /graphql\n               corsEnabled: true\n               suppressSpringResponseCodes: true\n               query-key: query\n               variables-key: variables\n               uploadMaxFileSize: 128KB\n               uploadMaxRequestSize: 128KB\n      schema:\n               clientMutationIdName: clientMutationId\n               injectClientMutationId: true\n               allowEmptyClientMutationId: false\n               mutationInputArgumentName: input\n               outputObjectNamePrefix: Payload\n               inputObjectNamePrefix: Input\n               schemaMutationObjectName: Mutation\n"
  },
  {
    "path": "graphql-sample-app/src/test/java/com/embedler/moon/graphql/boot/sample/test/GenericTodoSchemaParserTest.java",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\n\npackage com.embedler.moon.graphql.boot.sample.test;\n\nimport com.embedler.moon.graphql.boot.sample.ApplicationBootConfiguration;\nimport com.fasterxml.jackson.databind.ObjectMapper;\nimport com.oembedler.moon.graphql.boot.GraphQLServerRequest;\nimport com.oembedler.moon.graphql.boot.GraphQLServerResult;\nimport org.junit.Assert;\nimport org.junit.Test;\nimport org.junit.runner.RunWith;\nimport org.slf4j.Logger;\nimport org.slf4j.LoggerFactory;\nimport org.springframework.beans.factory.annotation.Value;\nimport org.springframework.boot.test.IntegrationTest;\nimport org.springframework.boot.test.SpringApplicationConfiguration;\nimport org.springframework.boot.test.TestRestTemplate;\nimport org.springframework.boot.test.WebIntegrationTest;\nimport org.springframework.core.io.ClassPathResource;\nimport org.springframework.http.*;\nimport org.springframework.test.context.junit4.SpringJUnit4ClassRunner;\nimport org.springframework.test.context.web.WebAppConfiguration;\nimport org.springframework.util.CollectionUtils;\nimport org.springframework.util.LinkedMultiValueMap;\nimport org.springframework.web.client.RestTemplate;\n\nimport java.io.IOException;\nimport java.util.HashMap;\nimport java.util.Map;\n\n/**\n * @author <a href=\"mailto:java.lang.RuntimeException@gmail.com\">oEmbedler Inc.</a>\n */\n@RunWith(SpringJUnit4ClassRunner.class)\n@SpringApplicationConfiguration(ApplicationBootConfiguration.class)\n@WebIntegrationTest(\"server.port=0\")\npublic class GenericTodoSchemaParserTest {\n\n    private static final Logger LOGGER = LoggerFactory.getLogger(GenericTodoSchemaParserTest.class);\n\n    @Value(\"${local.server.port}\")\n    private int port;\n\n    private RestTemplate restTemplate = new TestRestTemplate();\n    private ObjectMapper objectMapper = new ObjectMapper();\n\n    @Test\n    public void restViewerByIdTest() throws IOException {\n        HttpHeaders headers = new HttpHeaders();\n        headers.setContentType(MediaType.APPLICATION_JSON_UTF8);\n\n        GraphQLServerRequest qlQuery = new GraphQLServerRequest(\"{viewer{ id }}\");\n\n        HttpEntity<GraphQLServerRequest> httpEntity = new HttpEntity<>(qlQuery, headers);\n        ResponseEntity<GraphQLServerResult> responseEntity = restTemplate.exchange(\"http://localhost:\" + port + \"/graphql\", HttpMethod.POST, httpEntity, GraphQLServerResult.class);\n\n        GraphQLServerResult result = responseEntity.getBody();\n        Assert.assertTrue(CollectionUtils.isEmpty(result.getErrors()));\n        Assert.assertFalse(CollectionUtils.isEmpty(result.getData()));\n        LOGGER.info(objectMapper.writeValueAsString(result.getData()));\n    }\n\n    @Test\n    public void restSchemaDoesNotExistsTest() throws IOException {\n        HttpHeaders headers = new HttpHeaders();\n        headers.setContentType(MediaType.APPLICATION_JSON_UTF8);\n        headers.add(\"graphql-schema\", \"no-such-schema\");\n\n        GraphQLServerRequest qlQuery = new GraphQLServerRequest(\"{viewer{ id }}\");\n\n        HttpEntity<GraphQLServerRequest> httpEntity = new HttpEntity<>(qlQuery, headers);\n        ResponseEntity<GraphQLServerResult> responseEntity = restTemplate.exchange(\"http://localhost:\" + port + \"/graphql\", HttpMethod.POST, httpEntity, GraphQLServerResult.class);\n\n        GraphQLServerResult result = responseEntity.getBody();\n        Assert.assertFalse(CollectionUtils.isEmpty(result.getErrors()));\n        LOGGER.info(objectMapper.writeValueAsString(result));\n    }\n\n    @Test\n    public void restUnsupportedOperationErrorTest() throws IOException {\n        HttpHeaders headers = new HttpHeaders();\n        headers.setContentType(MediaType.APPLICATION_JSON_UTF8);\n        GraphQLServerRequest qlQuery = new GraphQLServerRequest(\"{viewer{ id }}\");\n        HttpEntity<GraphQLServerRequest> httpEntity = new HttpEntity<>(qlQuery, headers);\n\n        ResponseEntity<GraphQLServerResult> responseEntity = restTemplate.exchange(\"http://localhost:\" + port + \"/graphql\", HttpMethod.PUT, httpEntity, GraphQLServerResult.class);\n\n        GraphQLServerResult result = responseEntity.getBody();\n        Assert.assertFalse(CollectionUtils.isEmpty(result.getErrors()));\n        LOGGER.info(objectMapper.writeValueAsString(result));\n    }\n\n    @Test\n    public void restViewerJsonTest() throws IOException {\n        HttpHeaders headers = new HttpHeaders();\n        headers.setContentType(MediaType.APPLICATION_JSON_UTF8);\n\n        String qlQuery = \"{viewer{ id }}\";\n        Map<String, Object> variables = new HashMap<>();\n        variables.put(\"test-key\", \"key-0.9.0\");\n        ResponseEntity<GraphQLServerResult> responseEntity =\n                restTemplate.getForEntity(\"http://localhost:\" + port + \"/graphql?query={0}&variables={1}\",\n                        GraphQLServerResult.class, qlQuery, objectMapper.writeValueAsString(variables));\n\n        GraphQLServerResult result = responseEntity.getBody();\n        Assert.assertTrue(CollectionUtils.isEmpty(result.getErrors()));\n        Assert.assertFalse(CollectionUtils.isEmpty(result.getData()));\n        LOGGER.info(objectMapper.writeValueAsString(result.getData()));\n    }\n\n    @Test\n    public void restUploadFileTest() throws IOException {\n\n        LinkedMultiValueMap<String, Object> map = new LinkedMultiValueMap<>();\n        map.add(\"file\", new ClassPathResource(\"application.yml\"));\n        String qlQuery = \"mutation UploadFileMutation{uploadFile(input: {clientMutationId:\\\"m-123\\\"}){ filename }}\";\n        map.add(\"query\", qlQuery);\n        map.add(\"variables\", \"{}\");\n\n        HttpHeaders headers = new HttpHeaders();\n        headers.setContentType(MediaType.MULTIPART_FORM_DATA);\n        HttpEntity<LinkedMultiValueMap<String, Object>> requestEntity = new HttpEntity<>(map, headers);\n\n        ResponseEntity<GraphQLServerResult> responseEntity =\n                restTemplate.exchange(\"http://localhost:\" + port + \"/graphql\", HttpMethod.POST, requestEntity, GraphQLServerResult.class);\n\n        GraphQLServerResult result = responseEntity.getBody();\n        Assert.assertTrue(CollectionUtils.isEmpty(result.getErrors()));\n        Assert.assertFalse(CollectionUtils.isEmpty(result.getData()));\n        LOGGER.info(objectMapper.writeValueAsString(result.getData()));\n    }\n\n    @Test\n    public void restUploadFileUrlEncodedTest() throws IOException {\n\n        LinkedMultiValueMap<String, Object> map = new LinkedMultiValueMap<>();\n        map.add(\"query\", \"mutation AddTodoMutationMutation{addTodoMutation(input: {clientMutationId:\\\"m-123\\\", addTodoInput:{text: \\\"text\\\"}}){ clientMutationId, todoEdge {cursor, node {text, complete}} }}\");\n        map.add(\"variables\", \"{}\");\n        HttpHeaders headers = new HttpHeaders();\n        headers.setContentType(MediaType.APPLICATION_FORM_URLENCODED);\n        HttpEntity<LinkedMultiValueMap<String, Object>> requestEntity = new HttpEntity<>(map, headers);\n\n        ResponseEntity<GraphQLServerResult> responseEntity =\n                restTemplate.exchange(\"http://localhost:\" + port + \"/graphql\", HttpMethod.POST, requestEntity, GraphQLServerResult.class);\n\n        GraphQLServerResult result = responseEntity.getBody();\n        Assert.assertTrue(CollectionUtils.isEmpty(result.getErrors()));\n        Assert.assertFalse(CollectionUtils.isEmpty(result.getData()));\n        LOGGER.info(objectMapper.writeValueAsString(result.getData()));\n    }\n\n}\n"
  },
  {
    "path": "graphql-spring-boot-autoconfigure/LICENSE.md",
    "content": "The MIT License (MIT)\n\nCopyright (c) 2016 Oembedler Inc. and Contributors\n\nPermission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE."
  },
  {
    "path": "graphql-spring-boot-autoconfigure/build.gradle",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\n\nbuildscript {\n    repositories {\n        maven { url \"https://plugins.gradle.org/m2/\" }\n    }\n    dependencies {\n        classpath \"com.jfrog.bintray.gradle:gradle-bintray-plugin:1.6\"\n    }\n}\n\n\ndependencies {\n    compile \"com.embedler.moon.graphql:spring-graphql-common:$LIB_SPRING_GRAPHQL_COMMON_VER\"\n    compile \"org.springframework.boot:spring-boot-configuration-processor:$LIB_SPRING_BOOT_VER\"\n    compile \"org.springframework.boot:spring-boot-autoconfigure:$LIB_SPRING_BOOT_VER\"\n    provided \"org.springframework.boot:spring-boot-starter-web:$LIB_SPRING_BOOT_VER\"\n    provided \"commons-fileupload:commons-fileupload:$LIB_COMMON_UPLOAD\"\n\n    testCompile \"org.springframework.boot:spring-boot-starter-test:$LIB_SPRING_BOOT_VER\"\n}"
  },
  {
    "path": "graphql-spring-boot-autoconfigure/gradle/wrapper/gradle-wrapper.properties",
    "content": "#Sun Mar 27 20:34:11 BST 2016\ndistributionBase=GRADLE_USER_HOME\ndistributionPath=wrapper/dists\nzipStoreBase=GRADLE_USER_HOME\nzipStorePath=wrapper/dists\ndistributionUrl=https\\://services.gradle.org/distributions/gradle-2.9-bin.zip\n"
  },
  {
    "path": "graphql-spring-boot-autoconfigure/gradle.properties",
    "content": "#\n# The MIT License (MIT)\n#\n# Copyright (c) 2016 oEmbedler Inc. and Contributors\n#\n# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n#  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n#  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n#  persons to whom the Software is furnished to do so, subject to the following conditions:\n#\n# The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n#\n# THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n# BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n# DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n#\n\nPROJECT_VERSION = 2.1.0\nPROJECT_GROUP = com.embedler.moon.graphql.boot.autoconfigure\nPROJECT_NAME = graphql-spring-boot-autoconfigure\nPROJECT_DESC = GraphQL Spring Framework Boot Autoconfigure\nPROJECT_GIT_REPO_URL = https://github.com/oembedler/graphql-spring-boot\nPROJECT_LICENSE = MIT\nPROJECT_LICENSE_URL = https://github.com/oembedler/spring-boot-graphql/blob/master/LICENSE.md\nPROJECT_DEV_ID = oembedler\nPROJECT_DEV_NAME = Embedler Inc.\n\nVCS=Git\n\n###\n\nSOURCE_COMPATIBILITY = 1.8\nTARGET_COMPATIBILITY = 1.8\n\n###\n\nLIB_SPRING_GRAPHQL_COMMON_VER = 2+\nLIB_JUNIT_VER = 4.12\nLIB_SPRING_CORE_VER = 4.2.4.RELEASE\nLIB_SPRING_BOOT_VER = 1.3.2.RELEASE\n\nGRADLE_WRAPPER_VER = 2.9\n\n###\n\norg.gradle.daemon=true\n\nbintray.user=USER\nbintray.key=KEY"
  },
  {
    "path": "graphql-spring-boot-autoconfigure/gradlew",
    "content": "#!/usr/bin/env bash\n\n##############################################################################\n##\n##  Gradle start up script for UN*X\n##\n##############################################################################\n\n# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.\nDEFAULT_JVM_OPTS=\"\"\n\nAPP_NAME=\"Gradle\"\nAPP_BASE_NAME=`basename \"$0\"`\n\n# Use the maximum available, or set MAX_FD != -1 to use that value.\nMAX_FD=\"maximum\"\n\nwarn ( ) {\n    echo \"$*\"\n}\n\ndie ( ) {\n    echo\n    echo \"$*\"\n    echo\n    exit 1\n}\n\n# OS specific support (must be 'true' or 'false').\ncygwin=false\nmsys=false\ndarwin=false\ncase \"`uname`\" in\n  CYGWIN* )\n    cygwin=true\n    ;;\n  Darwin* )\n    darwin=true\n    ;;\n  MINGW* )\n    msys=true\n    ;;\nesac\n\n# Attempt to set APP_HOME\n# Resolve links: $0 may be a link\nPRG=\"$0\"\n# Need this for relative symlinks.\nwhile [ -h \"$PRG\" ] ; do\n    ls=`ls -ld \"$PRG\"`\n    link=`expr \"$ls\" : '.*-> \\(.*\\)$'`\n    if expr \"$link\" : '/.*' > /dev/null; then\n        PRG=\"$link\"\n    else\n        PRG=`dirname \"$PRG\"`\"/$link\"\n    fi\ndone\nSAVED=\"`pwd`\"\ncd \"`dirname \\\"$PRG\\\"`/\" >/dev/null\nAPP_HOME=\"`pwd -P`\"\ncd \"$SAVED\" >/dev/null\n\nCLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar\n\n# Determine the Java command to use to start the JVM.\nif [ -n \"$JAVA_HOME\" ] ; then\n    if [ -x \"$JAVA_HOME/jre/sh/java\" ] ; then\n        # IBM's JDK on AIX uses strange locations for the executables\n        JAVACMD=\"$JAVA_HOME/jre/sh/java\"\n    else\n        JAVACMD=\"$JAVA_HOME/bin/java\"\n    fi\n    if [ ! -x \"$JAVACMD\" ] ; then\n        die \"ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME\n\nPlease set the JAVA_HOME variable in your environment to match the\nlocation of your Java installation.\"\n    fi\nelse\n    JAVACMD=\"java\"\n    which java >/dev/null 2>&1 || die \"ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.\n\nPlease set the JAVA_HOME variable in your environment to match the\nlocation of your Java installation.\"\nfi\n\n# Increase the maximum file descriptors if we can.\nif [ \"$cygwin\" = \"false\" -a \"$darwin\" = \"false\" ] ; then\n    MAX_FD_LIMIT=`ulimit -H -n`\n    if [ $? -eq 0 ] ; then\n        if [ \"$MAX_FD\" = \"maximum\" -o \"$MAX_FD\" = \"max\" ] ; then\n            MAX_FD=\"$MAX_FD_LIMIT\"\n        fi\n        ulimit -n $MAX_FD\n        if [ $? -ne 0 ] ; then\n            warn \"Could not set maximum file descriptor limit: $MAX_FD\"\n        fi\n    else\n        warn \"Could not query maximum file descriptor limit: $MAX_FD_LIMIT\"\n    fi\nfi\n\n# For Darwin, add options to specify how the application appears in the dock\nif $darwin; then\n    GRADLE_OPTS=\"$GRADLE_OPTS \\\"-Xdock:name=$APP_NAME\\\" \\\"-Xdock:icon=$APP_HOME/media/gradle.icns\\\"\"\nfi\n\n# For Cygwin, switch paths to Windows format before running java\nif $cygwin ; then\n    APP_HOME=`cygpath --path --mixed \"$APP_HOME\"`\n    CLASSPATH=`cygpath --path --mixed \"$CLASSPATH\"`\n    JAVACMD=`cygpath --unix \"$JAVACMD\"`\n\n    # We build the pattern for arguments to be converted via cygpath\n    ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`\n    SEP=\"\"\n    for dir in $ROOTDIRSRAW ; do\n        ROOTDIRS=\"$ROOTDIRS$SEP$dir\"\n        SEP=\"|\"\n    done\n    OURCYGPATTERN=\"(^($ROOTDIRS))\"\n    # Add a user-defined pattern to the cygpath arguments\n    if [ \"$GRADLE_CYGPATTERN\" != \"\" ] ; then\n        OURCYGPATTERN=\"$OURCYGPATTERN|($GRADLE_CYGPATTERN)\"\n    fi\n    # Now convert the arguments - kludge to limit ourselves to /bin/sh\n    i=0\n    for arg in \"$@\" ; do\n        CHECK=`echo \"$arg\"|egrep -c \"$OURCYGPATTERN\" -`\n        CHECK2=`echo \"$arg\"|egrep -c \"^-\"`                                 ### Determine if an option\n\n        if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then                    ### Added a condition\n            eval `echo args$i`=`cygpath --path --ignore --mixed \"$arg\"`\n        else\n            eval `echo args$i`=\"\\\"$arg\\\"\"\n        fi\n        i=$((i+1))\n    done\n    case $i in\n        (0) set -- ;;\n        (1) set -- \"$args0\" ;;\n        (2) set -- \"$args0\" \"$args1\" ;;\n        (3) set -- \"$args0\" \"$args1\" \"$args2\" ;;\n        (4) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" ;;\n        (5) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" ;;\n        (6) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" \"$args5\" ;;\n        (7) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" \"$args5\" \"$args6\" ;;\n        (8) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" \"$args5\" \"$args6\" \"$args7\" ;;\n        (9) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" \"$args5\" \"$args6\" \"$args7\" \"$args8\" ;;\n    esac\nfi\n\n# Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules\nfunction splitJvmOpts() {\n    JVM_OPTS=(\"$@\")\n}\neval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS\nJVM_OPTS[${#JVM_OPTS[*]}]=\"-Dorg.gradle.appname=$APP_BASE_NAME\"\n\nexec \"$JAVACMD\" \"${JVM_OPTS[@]}\" -classpath \"$CLASSPATH\" org.gradle.wrapper.GradleWrapperMain \"$@\"\n"
  },
  {
    "path": "graphql-spring-boot-autoconfigure/gradlew.bat",
    "content": "@if \"%DEBUG%\" == \"\" @echo off\n@rem ##########################################################################\n@rem\n@rem  Gradle startup script for Windows\n@rem\n@rem ##########################################################################\n\n@rem Set local scope for the variables with windows NT shell\nif \"%OS%\"==\"Windows_NT\" setlocal\n\n@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.\nset DEFAULT_JVM_OPTS=\n\nset DIRNAME=%~dp0\nif \"%DIRNAME%\" == \"\" set DIRNAME=.\nset APP_BASE_NAME=%~n0\nset APP_HOME=%DIRNAME%\n\n@rem Find java.exe\nif defined JAVA_HOME goto findJavaFromJavaHome\n\nset JAVA_EXE=java.exe\n%JAVA_EXE% -version >NUL 2>&1\nif \"%ERRORLEVEL%\" == \"0\" goto init\n\necho.\necho ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.\necho.\necho Please set the JAVA_HOME variable in your environment to match the\necho location of your Java installation.\n\ngoto fail\n\n:findJavaFromJavaHome\nset JAVA_HOME=%JAVA_HOME:\"=%\nset JAVA_EXE=%JAVA_HOME%/bin/java.exe\n\nif exist \"%JAVA_EXE%\" goto init\n\necho.\necho ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%\necho.\necho Please set the JAVA_HOME variable in your environment to match the\necho location of your Java installation.\n\ngoto fail\n\n:init\n@rem Get command-line arguments, handling Windowz variants\n\nif not \"%OS%\" == \"Windows_NT\" goto win9xME_args\nif \"%@eval[2+2]\" == \"4\" goto 4NT_args\n\n:win9xME_args\n@rem Slurp the command line arguments.\nset CMD_LINE_ARGS=\nset _SKIP=2\n\n:win9xME_args_slurp\nif \"x%~1\" == \"x\" goto execute\n\nset CMD_LINE_ARGS=%*\ngoto execute\n\n:4NT_args\n@rem Get arguments from the 4NT Shell from JP Software\nset CMD_LINE_ARGS=%$\n\n:execute\n@rem Setup the command line\n\nset CLASSPATH=%APP_HOME%\\gradle\\wrapper\\gradle-wrapper.jar\n\n@rem Execute Gradle\n\"%JAVA_EXE%\" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% \"-Dorg.gradle.appname=%APP_BASE_NAME%\" -classpath \"%CLASSPATH%\" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%\n\n:end\n@rem End local scope for the variables with windows NT shell\nif \"%ERRORLEVEL%\"==\"0\" goto mainEnd\n\n:fail\nrem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of\nrem the _cmd.exe /c_ return code!\nif  not \"\" == \"%GRADLE_EXIT_CONSOLE%\" exit 1\nexit /b 1\n\n:mainEnd\nif \"%OS%\"==\"Windows_NT\" endlocal\n\n:omega\n"
  },
  {
    "path": "graphql-spring-boot-autoconfigure/settings.gradle",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\n\nrootProject.name = PROJECT_NAME"
  },
  {
    "path": "graphql-spring-boot-autoconfigure/src/main/java/com/oembedler/moon/graphql/boot/EnableGraphQLServer.java",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\n\npackage com.oembedler.moon.graphql.boot;\n\nimport org.springframework.context.annotation.Import;\n\nimport java.lang.annotation.*;\n\n/**\n * @author <a href=\"mailto:java.lang.RuntimeException@gmail.com\">oEmbedler Inc.</a>\n */\n@Retention(value = RetentionPolicy.RUNTIME)\n@Target(value = {ElementType.TYPE})\n@Documented\n@Import(GraphQLWebAutoConfiguration.class)\npublic @interface EnableGraphQLServer {\n}"
  },
  {
    "path": "graphql-spring-boot-autoconfigure/src/main/java/com/oembedler/moon/graphql/boot/ErrorGraphQLQueryEvaluation.java",
    "content": "package com.oembedler.moon.graphql.boot;\n\nimport graphql.ErrorType;\nimport graphql.GraphQLError;\nimport graphql.language.SourceLocation;\n\nimport java.util.List;\n\n/**\n * @author <a href=\"mailto:java.lang.RuntimeException@gmail.com\">oEmbedler Inc.</a>\n */\npublic class ErrorGraphQLQueryEvaluation implements GraphQLError {\n\n    @Override\n    public String getMessage() {\n        return \"Error evaluating GraphQL schema\";\n    }\n\n    @Override\n    public List<SourceLocation> getLocations() {\n        return null;\n    }\n\n    @Override\n    public ErrorType getErrorType() {\n        return ErrorType.ValidationError;\n    }\n}\n"
  },
  {
    "path": "graphql-spring-boot-autoconfigure/src/main/java/com/oembedler/moon/graphql/boot/ErrorGraphQLSchemaUndefined.java",
    "content": "package com.oembedler.moon.graphql.boot;\n\nimport graphql.ErrorType;\nimport graphql.GraphQLError;\nimport graphql.language.SourceLocation;\n\nimport java.util.List;\n\n/**\n * @author <a href=\"mailto:java.lang.RuntimeException@gmail.com\">oEmbedler Inc.</a>\n */\npublic class ErrorGraphQLSchemaUndefined implements GraphQLError {\n\n    @Override\n    public String getMessage() {\n        return \"No GraphQL schema definition found\";\n    }\n\n    @Override\n    public List<SourceLocation> getLocations() {\n        return null;\n    }\n\n    @Override\n    public ErrorType getErrorType() {\n        return ErrorType.ValidationError;\n    }\n}\n"
  },
  {
    "path": "graphql-spring-boot-autoconfigure/src/main/java/com/oembedler/moon/graphql/boot/ErrorGraphQLServer.java",
    "content": "package com.oembedler.moon.graphql.boot;\n\nimport graphql.ErrorType;\nimport graphql.GraphQLError;\nimport graphql.language.SourceLocation;\n\nimport java.util.List;\n\n/**\n * @author <a href=\"mailto:java.lang.RuntimeException@gmail.com\">oEmbedler Inc.</a>\n */\npublic class ErrorGraphQLServer implements GraphQLError {\n\n    private String message;\n\n    public ErrorGraphQLServer(String message) {\n        this.message = message;\n    }\n\n    @Override\n    public String getMessage() {\n        return message;\n    }\n\n    @Override\n    public List<SourceLocation> getLocations() {\n        return null;\n    }\n\n    @Override\n    public ErrorType getErrorType() {\n        return ErrorType.ValidationError;\n    }\n}\n"
  },
  {
    "path": "graphql-spring-boot-autoconfigure/src/main/java/com/oembedler/moon/graphql/boot/GlobalDefaultExceptionHandler.java",
    "content": "package com.oembedler.moon.graphql.boot;\n\nimport com.google.common.collect.Maps;\nimport graphql.ErrorType;\nimport org.springframework.core.annotation.AnnotationUtils;\nimport org.springframework.http.ResponseEntity;\nimport org.springframework.web.bind.annotation.ControllerAdvice;\nimport org.springframework.web.bind.annotation.ExceptionHandler;\nimport org.springframework.web.bind.annotation.ResponseStatus;\n\nimport javax.servlet.http.HttpServletRequest;\nimport java.util.Arrays;\nimport java.util.Map;\n\n/**\n * @author <a href=\"mailto:java.lang.RuntimeException@gmail.com\">oEmbedler Inc.</a>\n */\n@ControllerAdvice\npublic class GlobalDefaultExceptionHandler {\n\n    public static final String ERROR_MESSAGE = \"message\";\n    public static final String ERROR_TYPE = \"type\";\n\n    @ExceptionHandler(Exception.class)\n    public ResponseEntity<GraphQLServerResult> defaultErrorHandler(HttpServletRequest req, Exception e) throws Exception {\n        // if the exception is annotated with @ResponseStatus rethrow it and let the framework handle it\n        if (AnnotationUtils.findAnnotation(e.getClass(), ResponseStatus.class) != null) {\n            throw e;\n        }\n\n        Map<String, String> map = Maps.newHashMap();\n        map.put(ERROR_MESSAGE, e.getMessage());\n        map.put(ERROR_TYPE, ErrorType.ValidationError.toString());\n\n        return ResponseEntity.ok(new GraphQLServerResult(Arrays.asList(map)));\n    }\n}"
  },
  {
    "path": "graphql-spring-boot-autoconfigure/src/main/java/com/oembedler/moon/graphql/boot/GraphQLAutoConfiguration.java",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\n\npackage com.oembedler.moon.graphql.boot;\n\nimport com.oembedler.moon.graphql.GraphQLSchemaBeanFactory;\nimport com.oembedler.moon.graphql.SpringGraphQLSchemaBeanFactory;\nimport com.oembedler.moon.graphql.engine.GraphQLSchemaBuilder;\nimport com.oembedler.moon.graphql.engine.GraphQLSchemaConfig;\nimport com.oembedler.moon.graphql.engine.GraphQLSchemaHolder;\nimport com.oembedler.moon.graphql.engine.stereotype.GraphQLSchema;\nimport org.springframework.beans.factory.annotation.Autowired;\nimport org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;\nimport org.springframework.boot.context.properties.EnableConfigurationProperties;\nimport org.springframework.context.ApplicationContext;\nimport org.springframework.context.annotation.Bean;\nimport org.springframework.context.annotation.Configuration;\nimport org.springframework.util.StringUtils;\n\nimport java.util.HashMap;\nimport java.util.Map;\nimport java.util.Set;\nimport java.util.stream.Collectors;\n\n/**\n * @author <a href=\"mailto:java.lang.RuntimeException@gmail.com\">oEmbedler Inc.</a>\n */\n@Configuration\n@EnableConfigurationProperties(GraphQLProperties.class)\npublic class GraphQLAutoConfiguration {\n\n    @Autowired\n    private GraphQLProperties graphQLProperties;\n\n    @Autowired\n    private ApplicationContext applicationContext;\n\n    @Bean\n    @ConditionalOnMissingBean\n    public GraphQLSchemaBeanFactory graphQLSchemaBeanFactory() {\n        return new SpringGraphQLSchemaBeanFactory();\n    }\n\n    @Bean\n    @ConditionalOnMissingBean\n    public GraphQLSchemaConfig graphQLSchemaConfig() {\n        GraphQLSchemaConfig graphQLSchemaConfig = new GraphQLSchemaConfig();\n\n        // --- populate schema config based on boot GraphQL properties\n        GraphQLProperties.Schema schema = graphQLProperties.getSchema();\n        if (schema != null) {\n            if (schema.getAllowEmptyClientMutationId() != null)\n                graphQLSchemaConfig.setAllowEmptyClientMutationId(schema.getAllowEmptyClientMutationId());\n            if (schema.getInjectClientMutationId() != null)\n                graphQLSchemaConfig.setInjectClientMutationId(schema.getInjectClientMutationId());\n            if (StringUtils.hasText(schema.getClientMutationIdName()))\n                graphQLSchemaConfig.setClientMutationIdName(schema.getClientMutationIdName());\n            if (StringUtils.hasText(schema.getInputObjectNamePrefix()))\n                graphQLSchemaConfig.setInputObjectNamePrefix(schema.getInputObjectNamePrefix());\n            if (StringUtils.hasText(schema.getMutationInputArgumentName()))\n                graphQLSchemaConfig.setMutationInputArgumentName(schema.getMutationInputArgumentName());\n            if (StringUtils.hasText(schema.getOutputObjectNamePrefix()))\n                graphQLSchemaConfig.setOutputObjectNamePrefix(schema.getOutputObjectNamePrefix());\n            if (StringUtils.hasText(schema.getSchemaMutationObjectName()))\n                graphQLSchemaConfig.setSchemaMutationObjectName(schema.getSchemaMutationObjectName());\n        }\n\n        return graphQLSchemaConfig;\n    }\n\n    @Bean\n    @ConditionalOnMissingBean\n    public GraphQLSchemaBuilder graphQLSchemaBuilder() {\n        return new GraphQLSchemaBuilder(graphQLSchemaConfig(), graphQLSchemaBeanFactory());\n    }\n\n    @Bean\n    @ConditionalOnMissingBean\n    public GraphQLSchemaLocator graphQLSchemaLocator() throws ClassNotFoundException {\n        Map<String, GraphQLSchemaHolder> graphQLSchemaHolders = new HashMap<>();\n        GraphQLSchemaBuilder graphQLSchemaBuilder = graphQLSchemaBuilder();\n        Set<Class<?>> schemaClasses = initialSchemaClassesSet();\n        if (schemaClasses.size() > 0) {\n            for (Class<?> schema : schemaClasses) {\n                GraphQLSchemaHolder schemaHolder = graphQLSchemaBuilder.buildSchema(schema);\n                graphQLSchemaHolders.put(schemaHolder.getSchemaName(), schemaHolder);\n            }\n        }\n        return new GraphQLSchemaLocator(graphQLSchemaHolders);\n    }\n\n    protected Set<Class<?>> initialSchemaClassesSet() {\n        // scans the application context for classes annotated with {@link GraphQLSchema}\n        Map<String, Object> potentialCandidates = applicationContext.getBeansWithAnnotation(GraphQLSchema.class);\n        return potentialCandidates.values().stream().map(x -> x.getClass()).collect(Collectors.toSet());\n    }\n\n}\n"
  },
  {
    "path": "graphql-spring-boot-autoconfigure/src/main/java/com/oembedler/moon/graphql/boot/GraphQLContext.java",
    "content": "package com.oembedler.moon.graphql.boot;\n\nimport org.springframework.web.multipart.MultipartFile;\n\nimport javax.servlet.http.HttpServletRequest;\nimport java.util.HashMap;\n\n/**\n * @author <a href=\"mailto:java.lang.RuntimeException@gmail.com\">oEmbedler Inc.</a>\n */\npublic class GraphQLContext extends HashMap<String, Object> {\n\n    public static final String KEY_FILE_UPLOAD = \"file\";\n    public static final String KEY_HTTP_REQUEST = \"http-request\";\n\n    public HttpServletRequest setHttpRequest(final HttpServletRequest request) {\n        this.put(KEY_HTTP_REQUEST, request);\n        return getHttpRequest();\n    }\n\n    public MultipartFile setUploadedFile(final MultipartFile file) {\n        this.put(KEY_FILE_UPLOAD, file);\n        return getUploadedFile();\n    }\n\n    public MultipartFile getUploadedFile() {\n        return (MultipartFile) this.get(KEY_FILE_UPLOAD);\n    }\n\n    public HttpServletRequest getHttpRequest() {\n        return (HttpServletRequest) this.get(KEY_HTTP_REQUEST);\n    }\n}\n"
  },
  {
    "path": "graphql-spring-boot-autoconfigure/src/main/java/com/oembedler/moon/graphql/boot/GraphQLProperties.java",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\n\npackage com.oembedler.moon.graphql.boot;\n\nimport org.springframework.boot.context.properties.ConfigurationProperties;\nimport org.springframework.boot.context.properties.NestedConfigurationProperty;\nimport org.springframework.context.annotation.Configuration;\n\n/**\n * @author <a href=\"mailto:java.lang.RuntimeException@gmail.com\">oEmbedler Inc.</a>\n */\n@Configuration\n@ConfigurationProperties(prefix = \"graphql\")\npublic class GraphQLProperties {\n\n    @NestedConfigurationProperty\n    private Server server;\n\n    @NestedConfigurationProperty\n    private Schema schema;\n\n    public static class Server {\n        private String mapping;\n        private String queryKey;\n        private String variablesKey;\n        private String uploadMaxFileSize;\n        private String uploadMaxRequestSize;\n        private Boolean suppressSpringResponseCodes;\n\n        public String getMapping() {\n            return mapping;\n        }\n\n        public void setMapping(String mapping) {\n            this.mapping = mapping;\n        }\n\n        public String getQueryKey() {\n            return queryKey;\n        }\n\n        public void setQueryKey(String queryKey) {\n            this.queryKey = queryKey;\n        }\n\n        public String getVariablesKey() {\n            return variablesKey;\n        }\n\n        public void setVariablesKey(String variablesKey) {\n            this.variablesKey = variablesKey;\n        }\n\n        public String getUploadMaxFileSize() {\n            return uploadMaxFileSize;\n        }\n\n        public void setUploadMaxFileSize(String uploadMaxFileSize) {\n            this.uploadMaxFileSize = uploadMaxFileSize;\n        }\n\n        public String getUploadMaxRequestSize() {\n            return uploadMaxRequestSize;\n        }\n\n        public void setUploadMaxRequestSize(String uploadMaxRequestSize) {\n            this.uploadMaxRequestSize = uploadMaxRequestSize;\n        }\n\n        public Boolean getSuppressSpringResponseCodes() {\n            return suppressSpringResponseCodes;\n        }\n\n        public void setSuppressSpringResponseCodes(Boolean suppressSpringResponseCodes) {\n            this.suppressSpringResponseCodes = suppressSpringResponseCodes;\n        }\n    }\n\n    public static class Schema {\n        private String clientMutationIdName;\n        private Boolean injectClientMutationId;\n        private Boolean allowEmptyClientMutationId;\n        private String mutationInputArgumentName;\n        private String outputObjectNamePrefix;\n        private String inputObjectNamePrefix;\n        private String schemaMutationObjectName;\n\n        public String getClientMutationIdName() {\n            return clientMutationIdName;\n        }\n\n        public void setClientMutationIdName(String clientMutationIdName) {\n            this.clientMutationIdName = clientMutationIdName;\n        }\n\n        public Boolean getInjectClientMutationId() {\n            return injectClientMutationId;\n        }\n\n        public void setInjectClientMutationId(Boolean injectClientMutationId) {\n            this.injectClientMutationId = injectClientMutationId;\n        }\n\n        public Boolean getAllowEmptyClientMutationId() {\n            return allowEmptyClientMutationId;\n        }\n\n        public void setAllowEmptyClientMutationId(Boolean allowEmptyClientMutationId) {\n            this.allowEmptyClientMutationId = allowEmptyClientMutationId;\n        }\n\n        public String getMutationInputArgumentName() {\n            return mutationInputArgumentName;\n        }\n\n        public void setMutationInputArgumentName(String mutationInputArgumentName) {\n            this.mutationInputArgumentName = mutationInputArgumentName;\n        }\n\n        public String getOutputObjectNamePrefix() {\n            return outputObjectNamePrefix;\n        }\n\n        public void setOutputObjectNamePrefix(String outputObjectNamePrefix) {\n            this.outputObjectNamePrefix = outputObjectNamePrefix;\n        }\n\n        public String getInputObjectNamePrefix() {\n            return inputObjectNamePrefix;\n        }\n\n        public void setInputObjectNamePrefix(String inputObjectNamePrefix) {\n            this.inputObjectNamePrefix = inputObjectNamePrefix;\n        }\n\n        public String getSchemaMutationObjectName() {\n            return schemaMutationObjectName;\n        }\n\n        public void setSchemaMutationObjectName(String schemaMutationObjectName) {\n            this.schemaMutationObjectName = schemaMutationObjectName;\n        }\n    }\n\n    public Server getServer() {\n        return server;\n    }\n\n    public void setServer(Server server) {\n        this.server = server;\n    }\n\n    public Schema getSchema() {\n        return schema;\n    }\n\n    public void setSchema(Schema schema) {\n        this.schema = schema;\n    }\n}\n"
  },
  {
    "path": "graphql-spring-boot-autoconfigure/src/main/java/com/oembedler/moon/graphql/boot/GraphQLSchemaLocator.java",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\n\npackage com.oembedler.moon.graphql.boot;\n\nimport com.google.common.collect.Maps;\nimport com.oembedler.moon.graphql.engine.GraphQLSchemaHolder;\nimport graphql.Assert;\n\nimport java.util.Map;\n\n/**\n * @author <a href=\"mailto:java.lang.RuntimeException@gmail.com\">oEmbedler Inc.</a>\n */\npublic class GraphQLSchemaLocator {\n\n    private final Map<String, GraphQLSchemaHolder> graphQLSchemaHolders;\n    private final int totalNumberOfSchemas;\n\n    public GraphQLSchemaLocator(Map<String, GraphQLSchemaHolder> graphQLSchemaHolders) {\n        this.graphQLSchemaHolders = Maps.newHashMap();\n        this.graphQLSchemaHolders.putAll(graphQLSchemaHolders);\n        this.totalNumberOfSchemas = this.graphQLSchemaHolders.size();\n    }\n\n    public GraphQLSchemaHolder getGraphQLSchemaHolder(final String schemaName) {\n        Assert.assertNotNull(schemaName, \"Schema name can not be null\");\n        return graphQLSchemaHolders.get(schemaName);\n    }\n\n    public GraphQLSchemaHolder getSingleSchema() {\n        return getTotalNumberOfSchemas() == 1 ?\n                graphQLSchemaHolders.get(graphQLSchemaHolders.keySet().iterator().next()) :\n                null;\n    }\n\n    public int getTotalNumberOfSchemas() {\n        return totalNumberOfSchemas;\n    }\n\n    public boolean containsSchema(final String schemaName) {\n        Assert.assertNotNull(schemaName, \"Schema name can not be null\");\n        return graphQLSchemaHolders.containsKey(schemaName);\n    }\n}\n"
  },
  {
    "path": "graphql-spring-boot-autoconfigure/src/main/java/com/oembedler/moon/graphql/boot/GraphQLServerController.java",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\npackage com.oembedler.moon.graphql.boot;\n\nimport com.fasterxml.jackson.databind.ObjectMapper;\nimport com.google.common.collect.Lists;\nimport com.oembedler.moon.graphql.engine.GraphQLSchemaHolder;\nimport com.oembedler.moon.graphql.engine.execute.GraphQLQueryExecutor;\nimport graphql.ExecutionResult;\nimport graphql.ExecutionResultImpl;\nimport org.slf4j.Logger;\nimport org.slf4j.LoggerFactory;\nimport org.springframework.beans.factory.annotation.Autowired;\nimport org.springframework.http.ResponseEntity;\nimport org.springframework.util.StringUtils;\nimport org.springframework.web.bind.annotation.*;\nimport org.springframework.web.multipart.MultipartFile;\n\nimport javax.servlet.http.HttpServletRequest;\nimport java.io.IOException;\nimport java.util.HashMap;\nimport java.util.LinkedHashMap;\nimport java.util.Map;\n\n/**\n * @author <a href=\"mailto:java.lang.RuntimeException@gmail.com\">oEmbedler Inc.</a>\n */\n@RestController\n@RequestMapping(\"${graphql.server.mapping:/graphql}\")\npublic class GraphQLServerController {\n\n    private static final Logger LOGGER = LoggerFactory.getLogger(GraphQLServerController.class);\n\n    public static final String DEFAULT_QUERY_KEY = \"query\";\n    public static final String DEFAULT_VARIABLES_KEY = \"variables\";\n    public static final String DEFAULT_OPERATION_NAME_KEY = \"operationName\";\n    public static final String DEFAULT_DATA_KEY = \"data\";\n    public static final String DEFAULT_FILENAME_UPLOAD_KEY = \"file\";\n    public static final String DEFAULT_ERRORS_KEY = \"errors\";\n    public static final String HEADER_SCHEMA_NAME = \"graphql-schema\";\n\n    // ---\n\n    @Autowired\n    private GraphQLProperties graphQLProperties;\n    @Autowired\n    private GraphQLSchemaLocator graphQLSchemaLocator;\n\n    private ObjectMapper objectMapper = new ObjectMapper();\n\n    // ---\n\n    @RequestMapping(method = RequestMethod.GET)\n    public ResponseEntity<Map<String, Object>> getJson(@RequestParam(DEFAULT_QUERY_KEY) String query,\n                                                       @RequestParam(value = DEFAULT_VARIABLES_KEY, required = false) String variables,\n                                                       @RequestParam(value = DEFAULT_OPERATION_NAME_KEY, required = false) String operationName,\n                                                       @RequestHeader(value = HEADER_SCHEMA_NAME, required = false) String graphQLSchemaName,\n                                                       HttpServletRequest httpServletRequest) throws IOException {\n\n        final GraphQLContext graphQLContext = new GraphQLContext();\n        graphQLContext.setHttpRequest(httpServletRequest);\n\n        final Map<String, Object> result = evaluateAndBuildResponseMap(query, operationName, graphQLContext, decodeIntoMap(variables), graphQLSchemaName);\n        return ResponseEntity.ok(result);\n    }\n\n    @RequestMapping(method = RequestMethod.POST, consumes = \"application/graphql\")\n    public ResponseEntity<Map<String, Object>> postGraphQL(@RequestBody String query,\n                                                           @RequestParam(value = DEFAULT_OPERATION_NAME_KEY, required = false) String operationName,\n                                                           @RequestHeader(value = HEADER_SCHEMA_NAME, required = false) String graphQLSchemaName,\n                                                           HttpServletRequest httpServletRequest) {\n\n        final GraphQLContext graphQLContext = new GraphQLContext();\n        graphQLContext.setHttpRequest(httpServletRequest);\n\n        final Map<String, Object> result = evaluateAndBuildResponseMap(query, operationName, graphQLContext, new HashMap<>(), graphQLSchemaName);\n        return ResponseEntity.ok(result);\n    }\n\n    @RequestMapping(method = RequestMethod.POST, consumes = \"application/json\")\n    public ResponseEntity<Map<String, Object>> postJson(@RequestBody Map<String, Object> body,\n                                                        @RequestHeader(value = HEADER_SCHEMA_NAME, required = false) String graphQLSchemaName,\n                                                        HttpServletRequest httpServletRequest) {\n\n        final String query = (String) body.get(getQueryKey());\n        final String operationName = (String) body.get(DEFAULT_OPERATION_NAME_KEY);\n\n        Map<String, Object> variables = null;\n        Object variablesObject = body.get(getVariablesKey());\n        if (variablesObject != null && variablesObject instanceof Map)\n            variables = (Map<String, Object>) variablesObject;\n\n        final GraphQLContext graphQLContext = new GraphQLContext();\n        graphQLContext.setHttpRequest(httpServletRequest);\n\n        final Map<String, Object> result = evaluateAndBuildResponseMap(query, operationName, graphQLContext, variables, graphQLSchemaName);\n\n        return ResponseEntity.ok(result);\n    }\n\n    @RequestMapping(method = RequestMethod.POST, consumes = \"multipart/form-data\")\n    public ResponseEntity<Map<String, Object>> uploadFile(@RequestParam(DEFAULT_FILENAME_UPLOAD_KEY) MultipartFile file,\n                                                          @RequestParam(DEFAULT_QUERY_KEY) String query,\n                                                          @RequestParam(value = DEFAULT_VARIABLES_KEY, required = false) String variables,\n                                                          @RequestParam(value = DEFAULT_OPERATION_NAME_KEY, required = false) String operationName,\n                                                          @RequestHeader(value = HEADER_SCHEMA_NAME, required = false) String graphQLSchemaName,\n                                                          HttpServletRequest httpServletRequest) throws IOException {\n\n        final GraphQLContext graphQLContext = new GraphQLContext();\n        graphQLContext.setUploadedFile(file);\n        graphQLContext.setHttpRequest(httpServletRequest);\n\n        final Map<String, Object> result = evaluateAndBuildResponseMap(query, operationName, graphQLContext, decodeIntoMap(variables), graphQLSchemaName);\n        return ResponseEntity.ok(result);\n    }\n\n    @RequestMapping(method = RequestMethod.POST, consumes = \"application/x-www-form-urlencoded\")\n    public ResponseEntity<Map<String, Object>> uploadSmallFile(@RequestParam(DEFAULT_QUERY_KEY) String query,\n                                                               @RequestParam(value = DEFAULT_VARIABLES_KEY, required = false) String variables,\n                                                               @RequestParam(value = DEFAULT_OPERATION_NAME_KEY, required = false) String operationName,\n                                                               @RequestHeader(value = HEADER_SCHEMA_NAME, required = false) String graphQLSchemaName,\n                                                               HttpServletRequest httpServletRequest) throws IOException {\n\n        final GraphQLContext graphQLContext = new GraphQLContext();\n        graphQLContext.setHttpRequest(httpServletRequest);\n\n        final Map<String, Object> result = evaluateAndBuildResponseMap(query, operationName, graphQLContext, decodeIntoMap(variables), graphQLSchemaName);\n        return ResponseEntity.ok(result);\n    }\n\n    private Map<String, Object> decodeIntoMap(final String variablesParam) throws IOException {\n        return objectMapper.readValue(variablesParam, Map.class);\n    }\n\n    private Map<String, Object> evaluateAndBuildResponseMap(final String query,\n                                                            final String operationName,\n                                                            final GraphQLContext graphQLContext,\n                                                            final Map<String, Object> variables,\n                                                            final String graphQLSchemaName) {\n        final Map<String, Object> result = new LinkedHashMap<>();\n        final GraphQLSchemaHolder graphQLSchemaHolder = getGraphQLSchemaContainer(graphQLSchemaName);\n        final ExecutionResult executionResult = evaluate(query, operationName, graphQLContext, variables, graphQLSchemaHolder);\n\n        if (executionResult.getErrors().size() > 0) {\n            result.put(DEFAULT_ERRORS_KEY, executionResult.getErrors());\n            LOGGER.error(\"Errors: {}\", executionResult.getErrors());\n        }\n\n        result.put(DEFAULT_DATA_KEY, executionResult.getData());\n        return result;\n    }\n\n    private ExecutionResult evaluate(final String query,\n                                     final String operationName,\n                                     final GraphQLContext graphQLContext,\n                                     final Map<String, Object> variables,\n                                     final GraphQLSchemaHolder graphQLSchemaHolder) {\n        ExecutionResult executionResult;\n\n        if (graphQLSchemaHolder == null) {\n            executionResult = new ExecutionResultImpl(Lists.newArrayList(new ErrorGraphQLSchemaUndefined()));\n        } else {\n            try {\n                GraphQLQueryExecutor graphQLQueryExecutor = GraphQLQueryExecutor.create(graphQLSchemaHolder)\n                        .query(query).context(graphQLContext);\n\n                if (variables != null)\n                    graphQLQueryExecutor.arguments(variables);\n\n                if (StringUtils.hasText(operationName))\n                    graphQLQueryExecutor.operation(operationName);\n\n                executionResult = graphQLQueryExecutor.execute();\n\n            } catch (Exception e) {\n                LOGGER.error(\"Error occurred evaluating query: {}\", query);\n                executionResult = new ExecutionResultImpl(Lists.newArrayList(new ErrorGraphQLQueryEvaluation()));\n            }\n        }\n\n        return executionResult;\n    }\n\n    private String getQueryKey() {\n        return StringUtils.hasText(graphQLProperties.getServer().getQueryKey()) ?\n                graphQLProperties.getServer().getQueryKey() : DEFAULT_QUERY_KEY;\n    }\n\n    private String getVariablesKey() {\n        return StringUtils.hasText(graphQLProperties.getServer().getVariablesKey()) ?\n                graphQLProperties.getServer().getVariablesKey() : DEFAULT_VARIABLES_KEY;\n    }\n\n    public GraphQLSchemaHolder getGraphQLSchemaContainer(String graphQLSchema) {\n        if (StringUtils.hasText(graphQLSchema))\n            return graphQLSchemaLocator.getGraphQLSchemaHolder(graphQLSchema);\n        else if (graphQLSchemaLocator.getTotalNumberOfSchemas() == 1)\n            return graphQLSchemaLocator.getSingleSchema();\n\n        return null;\n    }\n}\n"
  },
  {
    "path": "graphql-spring-boot-autoconfigure/src/main/java/com/oembedler/moon/graphql/boot/GraphQLServerRequest.java",
    "content": "package com.oembedler.moon.graphql.boot;\n\nimport java.util.HashMap;\nimport java.util.Map;\n\n/**\n * @author <a href=\"mailto:java.lang.RuntimeException@gmail.com\">oEmbedler Inc.</a>\n */\npublic class GraphQLServerRequest {\n    private String query;\n    private Map<String, Object> variables = new HashMap<>();\n\n    public GraphQLServerRequest() {\n    }\n\n    public GraphQLServerRequest(String query) {\n        this.query = query;\n    }\n\n    public GraphQLServerRequest(String query, Map<String, Object> variables) {\n        this.query = query;\n        this.variables = variables;\n    }\n\n    public String getQuery() {\n        return query;\n    }\n\n    public Map<String, Object> getVariables() {\n        return variables;\n    }\n}\n"
  },
  {
    "path": "graphql-spring-boot-autoconfigure/src/main/java/com/oembedler/moon/graphql/boot/GraphQLServerResult.java",
    "content": "package com.oembedler.moon.graphql.boot;\n\nimport java.util.Collections;\nimport java.util.List;\nimport java.util.Map;\n\n/**\n * @author <a href=\"mailto:java.lang.RuntimeException@gmail.com\">oEmbedler Inc.</a>\n */\npublic class GraphQLServerResult {\n    private List<Map<String, String>> errors;\n    private Map<String, Object> data;\n\n    public GraphQLServerResult() {\n    }\n\n    public GraphQLServerResult(Map<String, Object> data) {\n        this(Collections.EMPTY_LIST, data);\n    }\n\n    public GraphQLServerResult(List<Map<String, String>> errors) {\n        this(errors, Collections.EMPTY_MAP);\n    }\n\n    public GraphQLServerResult(List<Map<String, String>> errors, Map<String, Object> data) {\n        this.errors = errors;\n        this.data = data;\n    }\n\n    public List<Map<String, String>> getErrors() {\n        return errors;\n    }\n\n    public void setErrors(List<Map<String, String>> errors) {\n        this.errors = errors;\n    }\n\n    public Map<String, Object> getData() {\n        return data;\n    }\n\n    public void setData(Map<String, Object> data) {\n        this.data = data;\n    }\n}\n"
  },
  {
    "path": "graphql-spring-boot-autoconfigure/src/main/java/com/oembedler/moon/graphql/boot/GraphQLWebAutoConfiguration.java",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\n\npackage com.oembedler.moon.graphql.boot;\n\nimport org.springframework.beans.factory.annotation.Value;\nimport org.springframework.boot.autoconfigure.AutoConfigureAfter;\nimport org.springframework.boot.autoconfigure.condition.ConditionalOnClass;\nimport org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;\nimport org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;\nimport org.springframework.boot.autoconfigure.condition.ConditionalOnWebApplication;\nimport org.springframework.boot.context.embedded.MultipartConfigFactory;\nimport org.springframework.context.annotation.Bean;\nimport org.springframework.context.annotation.Configuration;\nimport org.springframework.util.StringUtils;\nimport org.springframework.web.servlet.DispatcherServlet;\nimport org.springframework.web.servlet.config.annotation.CorsRegistry;\nimport org.springframework.web.servlet.config.annotation.WebMvcConfigurer;\nimport org.springframework.web.servlet.config.annotation.WebMvcConfigurerAdapter;\n\nimport javax.servlet.MultipartConfigElement;\nimport javax.servlet.Servlet;\n\n/**\n * @author <a href=\"mailto:java.lang.RuntimeException@gmail.com\">oEmbedler Inc.</a>\n */\n@Configuration\n@ConditionalOnWebApplication\n@ConditionalOnClass({Servlet.class, DispatcherServlet.class, WebMvcConfigurerAdapter.class})\n@AutoConfigureAfter({GraphQLAutoConfiguration.class, WebMvcConfigurerAdapter.class})\npublic class GraphQLWebAutoConfiguration {\n\n    private static final String DEFAULT_UPLOAD_MAX_FILE_SIZE = \"128KB\";\n    private static final String DEFAULT_UPLOAD_MAX_REQUEST_SIZE = \"128KB\";\n\n    @Value(\"${graphql.server.mapping:/graphql}\")\n    private String graphQLServerMapping;\n\n    @Bean\n    @ConditionalOnProperty(value = \"graphql.server.corsEnabled\", havingValue = \"true\", matchIfMissing = true)\n    public WebMvcConfigurer corsConfigurer() {\n        return new WebMvcConfigurerAdapter() {\n            @Override\n            public void addCorsMappings(CorsRegistry registry) {\n                registry.addMapping(graphQLServerMapping);\n            }\n        };\n    }\n\n    @Bean\n    @ConditionalOnMissingBean(GraphQLServerController.class)\n    public GraphQLServerController basicGraphQLController() {\n        return new GraphQLServerController();\n    }\n\n    @Bean\n    @ConditionalOnMissingBean(GlobalDefaultExceptionHandler.class)\n    @ConditionalOnProperty(value = \"graphql.server.suppressSpringResponseCodes\", havingValue = \"true\", matchIfMissing = true)\n    public GlobalDefaultExceptionHandler globalDefaultExceptionHandler() {\n        return new GlobalDefaultExceptionHandler();\n    }\n\n    @Bean\n    @ConditionalOnMissingBean(MultipartConfigElement.class)\n    public MultipartConfigElement multipartConfigElement(GraphQLProperties graphQLProperties) {\n        MultipartConfigFactory factory = new MultipartConfigFactory();\n        factory.setMaxFileSize(DEFAULT_UPLOAD_MAX_FILE_SIZE);\n        factory.setMaxRequestSize(DEFAULT_UPLOAD_MAX_REQUEST_SIZE);\n\n        String temp = graphQLProperties.getServer().getUploadMaxFileSize();\n        if (StringUtils.hasText(temp))\n            factory.setMaxFileSize(temp);\n\n        temp = graphQLProperties.getServer().getUploadMaxRequestSize();\n        if (StringUtils.hasText(temp))\n            factory.setMaxRequestSize(temp);\n\n        return factory.createMultipartConfig();\n    }\n\n}\n"
  },
  {
    "path": "graphql-spring-boot-autoconfigure/src/main/resources/META-INF/spring.factories",
    "content": "org.springframework.boot.autoconfigure.EnableAutoConfiguration=\\\ncom.oembedler.moon.graphql.boot.GraphQLAutoConfiguration"
  },
  {
    "path": "graphql-spring-boot-autoconfigure/src/test/java/com/oembedler/moon/graphql/boot/test/GraphQLAutoConfigurationTest.java",
    "content": "package com.oembedler.moon.graphql.boot.test;\n\nimport com.oembedler.moon.graphql.GraphQLSchemaBeanFactory;\nimport com.oembedler.moon.graphql.boot.GraphQLAutoConfiguration;\nimport com.oembedler.moon.graphql.boot.GraphQLSchemaLocator;\nimport com.oembedler.moon.graphql.engine.GraphQLSchemaBuilder;\nimport com.oembedler.moon.graphql.engine.GraphQLSchemaConfig;\nimport org.junit.After;\nimport org.junit.Assert;\nimport org.junit.Test;\nimport org.springframework.boot.test.EnvironmentTestUtils;\nimport org.springframework.context.annotation.AnnotationConfigApplicationContext;\nimport org.springframework.context.annotation.ComponentScan;\nimport org.springframework.context.annotation.Configuration;\n\n/**\n * @author <a href=\"mailto:java.lang.RuntimeException@gmail.com\">oEmbedler Inc.</a>\n */\npublic class GraphQLAutoConfigurationTest {\n\n    private static final String BASE_PACKAGE = \"com.oembedler.moon.graphql.boot.test\";\n    private AnnotationConfigApplicationContext context;\n\n    @After\n    public void tearDown() {\n        if (this.context != null) {\n            this.context.close();\n        }\n    }\n\n    @Test\n    public void defaultSettingsLoad() {\n        load(EmptyConfiguration.class, \"\");\n        GraphQLSchemaBeanFactory graphQLSchemaBeanFactory = this.context.getBean(GraphQLSchemaBeanFactory.class);\n        GraphQLSchemaConfig graphQLSchemaConfig = this.context.getBean(GraphQLSchemaConfig.class);\n        GraphQLSchemaBuilder graphQLSchemaBuilder = this.context.getBean(GraphQLSchemaBuilder.class);\n        GraphQLSchemaLocator graphQLSchemaLocator = this.context.getBean(GraphQLSchemaLocator.class);\n\n        Assert.assertTrue(graphQLSchemaBeanFactory.containsBean(GraphQLSchemaBeanFactory.class));\n        Assert.assertEquals(graphQLSchemaBeanFactory, graphQLSchemaBeanFactory.getBeanByType(GraphQLSchemaBeanFactory.class));\n        Assert.assertEquals(graphQLSchemaBeanFactory, graphQLSchemaBuilder.getGraphQLSchemaBeanFactory());\n        Assert.assertEquals(graphQLSchemaConfig, graphQLSchemaBuilder.getGraphQLSchemaConfig());\n        Assert.assertEquals(1, graphQLSchemaLocator.getTotalNumberOfSchemas());\n    }\n\n    private void load(Class<?> config, String... environment) {\n        AnnotationConfigApplicationContext applicationContext = new AnnotationConfigApplicationContext();\n        EnvironmentTestUtils.addEnvironment(applicationContext, environment);\n        applicationContext.register(config);\n        applicationContext.register(GraphQLAutoConfiguration.class);\n        applicationContext.refresh();\n        this.context = applicationContext;\n    }\n\n    @Configuration\n    @ComponentScan(BASE_PACKAGE)\n    static class EmptyConfiguration {\n    }\n\n}\n"
  },
  {
    "path": "graphql-spring-boot-autoconfigure/src/test/java/com/oembedler/moon/graphql/boot/test/schema/EmptySchema.java",
    "content": "package com.oembedler.moon.graphql.boot.test.schema;\n\nimport com.oembedler.moon.graphql.engine.stereotype.GraphQLObject;\nimport com.oembedler.moon.graphql.engine.stereotype.GraphQLSchema;\nimport com.oembedler.moon.graphql.engine.stereotype.GraphQLSchemaQuery;\n\n/**\n * @author <a href=\"mailto:java.lang.RuntimeException@gmail.com\">oEmbedler Inc.</a>\n */\n@GraphQLSchema(\"EmptySchema\")\npublic class EmptySchema {\n\n    @GraphQLSchemaQuery\n    private Root root;\n\n    @GraphQLObject\n    public static class Root {\n\n    }\n}\n"
  },
  {
    "path": "graphql-spring-boot-starter/LICENSE.md",
    "content": "The MIT License (MIT)\n\nCopyright (c) 2015 Oembedler Inc. and Contributors\n\nPermission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE."
  },
  {
    "path": "graphql-spring-boot-starter/build.gradle",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\nbuildscript {\n    repositories {\n        maven { url \"https://plugins.gradle.org/m2/\" }\n    }\n    dependencies {\n        classpath \"com.jfrog.bintray.gradle:gradle-bintray-plugin:1.6\"\n    }\n}\n\ndependencies {\n    compile(project(':graphql-spring-boot-autoconfigure'))\n}"
  },
  {
    "path": "graphql-spring-boot-starter/gradle/wrapper/gradle-wrapper.properties",
    "content": "#Sun Mar 27 20:34:11 BST 2016\ndistributionBase=GRADLE_USER_HOME\ndistributionPath=wrapper/dists\nzipStoreBase=GRADLE_USER_HOME\nzipStorePath=wrapper/dists\ndistributionUrl=https\\://services.gradle.org/distributions/gradle-2.9-bin.zip\n"
  },
  {
    "path": "graphql-spring-boot-starter/gradle.properties",
    "content": "#\n# The MIT License (MIT)\n#\n# Copyright (c) 2016 oEmbedler Inc. and Contributors\n#\n# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n#  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n#  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n#  persons to whom the Software is furnished to do so, subject to the following conditions:\n#\n# The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n#\n# THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n# BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n# DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n#\n\nPROJECT_VERSION = 2.1.0\nPROJECT_GROUP = com.embedler.moon.graphql.boot.starter\nPROJECT_NAME = graphql-spring-boot-starter\nPROJECT_DESC = GraphQL Spring Framework Boot Starter\nPROJECT_GIT_REPO_URL = https://github.com/oembedler/graphql-spring-boot\nPROJECT_LICENSE = MIT\nPROJECT_LICENSE_URL = https://github.com/oembedler/spring-boot-graphql/blob/master/LICENSE.md\nPROJECT_DEV_ID = oembedler\nPROJECT_DEV_NAME = Embedler Inc.\n\nVCS=Git\n\n###\n\nSOURCE_COMPATIBILITY = 1.8\nTARGET_COMPATIBILITY = 1.8\n\n###\n\nLIB_SPRING_GRAPHQL_COMMON_VER = 2+\nLIB_JUNIT_VER = 4.12\nLIB_SPRING_CORE_VER = 4.2.4.RELEASE\nLIB_SPRING_BOOT_VER = 1.3.2.RELEASE\n\nGRADLE_WRAPPER_VER = 2.9\n\n###\n\norg.gradle.daemon=true\n\nbintray.user=USER\nbintray.key=KEY"
  },
  {
    "path": "graphql-spring-boot-starter/gradlew",
    "content": "#!/usr/bin/env bash\n\n##############################################################################\n##\n##  Gradle start up script for UN*X\n##\n##############################################################################\n\n# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.\nDEFAULT_JVM_OPTS=\"\"\n\nAPP_NAME=\"Gradle\"\nAPP_BASE_NAME=`basename \"$0\"`\n\n# Use the maximum available, or set MAX_FD != -1 to use that value.\nMAX_FD=\"maximum\"\n\nwarn ( ) {\n    echo \"$*\"\n}\n\ndie ( ) {\n    echo\n    echo \"$*\"\n    echo\n    exit 1\n}\n\n# OS specific support (must be 'true' or 'false').\ncygwin=false\nmsys=false\ndarwin=false\ncase \"`uname`\" in\n  CYGWIN* )\n    cygwin=true\n    ;;\n  Darwin* )\n    darwin=true\n    ;;\n  MINGW* )\n    msys=true\n    ;;\nesac\n\n# Attempt to set APP_HOME\n# Resolve links: $0 may be a link\nPRG=\"$0\"\n# Need this for relative symlinks.\nwhile [ -h \"$PRG\" ] ; do\n    ls=`ls -ld \"$PRG\"`\n    link=`expr \"$ls\" : '.*-> \\(.*\\)$'`\n    if expr \"$link\" : '/.*' > /dev/null; then\n        PRG=\"$link\"\n    else\n        PRG=`dirname \"$PRG\"`\"/$link\"\n    fi\ndone\nSAVED=\"`pwd`\"\ncd \"`dirname \\\"$PRG\\\"`/\" >/dev/null\nAPP_HOME=\"`pwd -P`\"\ncd \"$SAVED\" >/dev/null\n\nCLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar\n\n# Determine the Java command to use to start the JVM.\nif [ -n \"$JAVA_HOME\" ] ; then\n    if [ -x \"$JAVA_HOME/jre/sh/java\" ] ; then\n        # IBM's JDK on AIX uses strange locations for the executables\n        JAVACMD=\"$JAVA_HOME/jre/sh/java\"\n    else\n        JAVACMD=\"$JAVA_HOME/bin/java\"\n    fi\n    if [ ! -x \"$JAVACMD\" ] ; then\n        die \"ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME\n\nPlease set the JAVA_HOME variable in your environment to match the\nlocation of your Java installation.\"\n    fi\nelse\n    JAVACMD=\"java\"\n    which java >/dev/null 2>&1 || die \"ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.\n\nPlease set the JAVA_HOME variable in your environment to match the\nlocation of your Java installation.\"\nfi\n\n# Increase the maximum file descriptors if we can.\nif [ \"$cygwin\" = \"false\" -a \"$darwin\" = \"false\" ] ; then\n    MAX_FD_LIMIT=`ulimit -H -n`\n    if [ $? -eq 0 ] ; then\n        if [ \"$MAX_FD\" = \"maximum\" -o \"$MAX_FD\" = \"max\" ] ; then\n            MAX_FD=\"$MAX_FD_LIMIT\"\n        fi\n        ulimit -n $MAX_FD\n        if [ $? -ne 0 ] ; then\n            warn \"Could not set maximum file descriptor limit: $MAX_FD\"\n        fi\n    else\n        warn \"Could not query maximum file descriptor limit: $MAX_FD_LIMIT\"\n    fi\nfi\n\n# For Darwin, add options to specify how the application appears in the dock\nif $darwin; then\n    GRADLE_OPTS=\"$GRADLE_OPTS \\\"-Xdock:name=$APP_NAME\\\" \\\"-Xdock:icon=$APP_HOME/media/gradle.icns\\\"\"\nfi\n\n# For Cygwin, switch paths to Windows format before running java\nif $cygwin ; then\n    APP_HOME=`cygpath --path --mixed \"$APP_HOME\"`\n    CLASSPATH=`cygpath --path --mixed \"$CLASSPATH\"`\n    JAVACMD=`cygpath --unix \"$JAVACMD\"`\n\n    # We build the pattern for arguments to be converted via cygpath\n    ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`\n    SEP=\"\"\n    for dir in $ROOTDIRSRAW ; do\n        ROOTDIRS=\"$ROOTDIRS$SEP$dir\"\n        SEP=\"|\"\n    done\n    OURCYGPATTERN=\"(^($ROOTDIRS))\"\n    # Add a user-defined pattern to the cygpath arguments\n    if [ \"$GRADLE_CYGPATTERN\" != \"\" ] ; then\n        OURCYGPATTERN=\"$OURCYGPATTERN|($GRADLE_CYGPATTERN)\"\n    fi\n    # Now convert the arguments - kludge to limit ourselves to /bin/sh\n    i=0\n    for arg in \"$@\" ; do\n        CHECK=`echo \"$arg\"|egrep -c \"$OURCYGPATTERN\" -`\n        CHECK2=`echo \"$arg\"|egrep -c \"^-\"`                                 ### Determine if an option\n\n        if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then                    ### Added a condition\n            eval `echo args$i`=`cygpath --path --ignore --mixed \"$arg\"`\n        else\n            eval `echo args$i`=\"\\\"$arg\\\"\"\n        fi\n        i=$((i+1))\n    done\n    case $i in\n        (0) set -- ;;\n        (1) set -- \"$args0\" ;;\n        (2) set -- \"$args0\" \"$args1\" ;;\n        (3) set -- \"$args0\" \"$args1\" \"$args2\" ;;\n        (4) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" ;;\n        (5) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" ;;\n        (6) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" \"$args5\" ;;\n        (7) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" \"$args5\" \"$args6\" ;;\n        (8) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" \"$args5\" \"$args6\" \"$args7\" ;;\n        (9) set -- \"$args0\" \"$args1\" \"$args2\" \"$args3\" \"$args4\" \"$args5\" \"$args6\" \"$args7\" \"$args8\" ;;\n    esac\nfi\n\n# Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules\nfunction splitJvmOpts() {\n    JVM_OPTS=(\"$@\")\n}\neval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS\nJVM_OPTS[${#JVM_OPTS[*]}]=\"-Dorg.gradle.appname=$APP_BASE_NAME\"\n\nexec \"$JAVACMD\" \"${JVM_OPTS[@]}\" -classpath \"$CLASSPATH\" org.gradle.wrapper.GradleWrapperMain \"$@\"\n"
  },
  {
    "path": "graphql-spring-boot-starter/gradlew.bat",
    "content": "@if \"%DEBUG%\" == \"\" @echo off\n@rem ##########################################################################\n@rem\n@rem  Gradle startup script for Windows\n@rem\n@rem ##########################################################################\n\n@rem Set local scope for the variables with windows NT shell\nif \"%OS%\"==\"Windows_NT\" setlocal\n\n@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.\nset DEFAULT_JVM_OPTS=\n\nset DIRNAME=%~dp0\nif \"%DIRNAME%\" == \"\" set DIRNAME=.\nset APP_BASE_NAME=%~n0\nset APP_HOME=%DIRNAME%\n\n@rem Find java.exe\nif defined JAVA_HOME goto findJavaFromJavaHome\n\nset JAVA_EXE=java.exe\n%JAVA_EXE% -version >NUL 2>&1\nif \"%ERRORLEVEL%\" == \"0\" goto init\n\necho.\necho ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.\necho.\necho Please set the JAVA_HOME variable in your environment to match the\necho location of your Java installation.\n\ngoto fail\n\n:findJavaFromJavaHome\nset JAVA_HOME=%JAVA_HOME:\"=%\nset JAVA_EXE=%JAVA_HOME%/bin/java.exe\n\nif exist \"%JAVA_EXE%\" goto init\n\necho.\necho ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%\necho.\necho Please set the JAVA_HOME variable in your environment to match the\necho location of your Java installation.\n\ngoto fail\n\n:init\n@rem Get command-line arguments, handling Windowz variants\n\nif not \"%OS%\" == \"Windows_NT\" goto win9xME_args\nif \"%@eval[2+2]\" == \"4\" goto 4NT_args\n\n:win9xME_args\n@rem Slurp the command line arguments.\nset CMD_LINE_ARGS=\nset _SKIP=2\n\n:win9xME_args_slurp\nif \"x%~1\" == \"x\" goto execute\n\nset CMD_LINE_ARGS=%*\ngoto execute\n\n:4NT_args\n@rem Get arguments from the 4NT Shell from JP Software\nset CMD_LINE_ARGS=%$\n\n:execute\n@rem Setup the command line\n\nset CLASSPATH=%APP_HOME%\\gradle\\wrapper\\gradle-wrapper.jar\n\n@rem Execute Gradle\n\"%JAVA_EXE%\" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% \"-Dorg.gradle.appname=%APP_BASE_NAME%\" -classpath \"%CLASSPATH%\" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%\n\n:end\n@rem End local scope for the variables with windows NT shell\nif \"%ERRORLEVEL%\"==\"0\" goto mainEnd\n\n:fail\nrem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of\nrem the _cmd.exe /c_ return code!\nif  not \"\" == \"%GRADLE_EXIT_CONSOLE%\" exit 1\nexit /b 1\n\n:mainEnd\nif \"%OS%\"==\"Windows_NT\" endlocal\n\n:omega\n"
  },
  {
    "path": "graphql-spring-boot-starter/settings.gradle",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\n\nrootProject.name = PROJECT_NAME"
  },
  {
    "path": "settings.gradle",
    "content": "/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 oEmbedler Inc. and Contributors\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n *  documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\n *  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\n *  persons to whom the Software is furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING\n * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n */\n\nrootProject.name = PROJECT_NAME\n\ninclude \":graphql-spring-boot-autoconfigure\", \":graphql-spring-boot-starter\"\ninclude \":graphiql-spring-boot-autoconfigure\", \":graphiql-spring-boot-starter\"\ninclude \":graphql-sample-app\""
  }
]