Interface DataFetchersDelegate
- All Known Implementing Classes:
DataFetchersDelegateImpl
public interface DataFetchersDelegate
This class represents a GraphQL Data Fetcher Delegate. A DataFetchersDelegate aggregates all
Thus there are two kinds of
The arguments for the data fetcher delegates are the arguments of its field.
DataFetcher for
a GraphQL type. It is only used when in server mode, the GraphQL maven plugin generates on data fetcher delegate for
each object whose fields need at least one data fetcher. This helps to limit the impact on the specific code, when
the GraphQL schema changes. Thus there are two kinds of
DataFetchersDelegate:
- The
DataFetchersDelegatefor regular GraphQL objects. TheseDataFetchers are used to read non scalar fields, that is: fields that are subjects, like friends of the human types, in the StarWars schema. - The
DataFetchersDelegatefor queries, mutations and subscriptions type. TheseDataFetchersDelegateare actually the entry points of the GraphQL server. For suchDataFetchersDelegates, each field is actually aDataFetcher.
The arguments for the data fetcher delegates are the arguments of its field.
- Author:
- etienne-sf
-
Method Summary
Modifier and TypeMethodDescriptionRetrieves theBatchLoaders that are to be implemented by this Data Fetcher Delegate.default StringThe name of the DataFetcher, in camelCase.Retrieves theDataFetchers that are to be implemented by this Data Fetcher Delegate.getName()The name of the DataFetcher.default StringThe name of the DataFetcher, in PascalCase.getType()Returns theType, for which the DataFetchersDelegate aggregates the access methods.
-
Method Details
-
getName
String getName()The name of the DataFetcher. This name is a valid java classname identifier, and is the name to use as a method name.- Returns:
-
getType
Type getType()Returns theType, for which the DataFetchersDelegate aggregates the access methods.- Returns:
-
getCamelCaseName
The name of the DataFetcher, in camelCase. This name is a valid for a java variable identifier, and is the name to use as a method name.- Returns:
-
getPascalCaseName
The name of the DataFetcher, in PascalCase. This name is a valid for a java type identifier.- Returns:
-
getDataFetchers
List<DataFetcher> getDataFetchers()Retrieves theDataFetchers that are to be implemented by this Data Fetcher Delegate.- Returns:
-
getBatchLoaders
List<BatchLoader> getBatchLoaders()Retrieves theBatchLoaders that are to be implemented by this Data Fetcher Delegate.- Returns:
-