All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.github.graphglue.data.execution.NodeExtensionField.kt Maven / Gradle / Ivy

Go to download

A library to develop annotation-based code-first GraphQL servers using GraphQL Kotlin, Spring Boot and Neo4j - excluding Spring GraphQL server dependencies

The newest version!
package io.github.graphglue.data.execution

import graphql.schema.DataFetchingEnvironment
import graphql.schema.SelectedField
import io.github.graphglue.definition.ExtensionFieldDefinition
import io.github.graphglue.definition.NodeDefinition

/**
 * Defines an extension field which should be loaded with a NodeQuery
 *
 * @param definition defines the extension field and provides the generator for the expression
 * @param dfe the data fetching environment required to generate the expression
 * @param field the selected field
 * @param onlyOnTypes a list of parent types on which this should be evaluated
 * @param resultKey used to identify the result
 */
class NodeExtensionField(
    val definition: ExtensionFieldDefinition,
    val dfe: DataFetchingEnvironment,
    val field: SelectedField,
    onlyOnTypes: List,
    resultKey: String,
) : NodeQueryPartEntry(onlyOnTypes, resultKey) {

    override val cost: Int get() = definition.cost

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy