Package graphql.schema.idl
Class RuntimeWiring
java.lang.Object
graphql.schema.idl.RuntimeWiring
A runtime wiring is a specification of data fetchers, type resolvers and custom scalars that are needed
to wire together a functional
GraphQLSchema
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final RuntimeWiring
This is a Runtime wiring which provides mocked types resolver and scalars. -
Method Summary
Modifier and TypeMethodDescriptiongetDataFetcherForType
(String typeName) Deprecated.getDataFetchersForType
(String typeName) This returns a map of the data fetchers per field on that named type.getDefaultDataFetcherForType
(String typeName) static RuntimeWiring.Builder
static RuntimeWiring.Builder
newRuntimeWiring
(RuntimeWiring originalRuntimeWiring) transform
(Consumer<RuntimeWiring.Builder> builderConsumer) This helps you transform the current RuntimeWiring object into another one by starting a builder with all the current values and allows you to transform it how you want.
-
Field Details
-
MOCKED_WIRING
This is a Runtime wiring which provides mocked types resolver and scalars. It is useful for testing only, for example for creating schemas that can be inspected but not executed on.
-
-
Method Details
-
newRuntimeWiring
- Returns:
- a builder of Runtime Wiring
-
newRuntimeWiring
- Parameters:
originalRuntimeWiring
- the runtime wiring to start from- Returns:
- a builder of Runtime Wiring based on the provided one
-
transform
This helps you transform the current RuntimeWiring object into another one by starting a builder with all the current values and allows you to transform it how you want.- Parameters:
builderConsumer
- the consumer code that will be given a builder to transform- Returns:
- a new RuntimeWiring object based on calling build on that builder
-
getCodeRegistry
-
getScalars
-
getDataFetchers
-
getDataFetcherForType
@Deprecated(since="2024-04-28") public Map<String,DataFetcher> getDataFetcherForType(String typeName) Deprecated.This is deprecated because the name has the wrong plural case.- Parameters:
typeName
- the type for fetch a map of per field data fetchers for- Returns:
- a map of field data fetchers for a type
-
getDataFetchersForType
This returns a map of the data fetchers per field on that named type.- Parameters:
typeName
- the type for fetch a map of per field data fetchers for- Returns:
- a map of field data fetchers for a type
-
getDefaultDataFetcherForType
-
getTypeResolvers
-
getEnumValuesProviders
-
getWiringFactory
-
getFieldVisibility
-
getRegisteredDirectiveWiring
-
getDirectiveWiring
-
getComparatorRegistry
-
getDataFetchersForType(String)