graphql-tools-monorepo / wrap/src / WrapFields
Class: WrapFields<TContext>
wrap/src.WrapFields
Type parameters
Name | Type |
---|---|
TContext | extends Record <string , any > |
Implements
Transform
<WrapFieldsTransformationContext
,TContext
>
Table of contents
Constructors
Methods
Constructors
constructor
• new WrapFields<TContext
>(outerTypeName
, wrappingFieldNames
, wrappingTypeNames
, fieldNames?
, prefix?
): WrapFields
<TContext
>
Type parameters
Name | Type |
---|---|
TContext | extends Record <string , any > |
Parameters
Name | Type | Default value |
---|---|---|
outerTypeName | string | undefined |
wrappingFieldNames | string [] | undefined |
wrappingTypeNames | string [] | undefined |
fieldNames? | string [] | undefined |
prefix | string | 'gqtld' |
Returns
WrapFields
<TContext
>
Defined in
packages/wrap/src/transforms/WrapFields.ts:47
Methods
transformRequest
▸ transformRequest(originalRequest
, delegationContext
, transformationContext
): ExecutionRequest
<any
, any
, any
, Record
<string
, any
>, any
>
Parameters
Name | Type |
---|---|
originalRequest | ExecutionRequest <any , any , any , Record <string , any >, any > |
delegationContext | DelegationContext <TContext > |
transformationContext | WrapFieldsTransformationContext |
Returns
ExecutionRequest
<any
, any
, any
, Record
<string
, any
>, any
>
Implementation of
Transform.transformRequest
Defined in
packages/wrap/src/transforms/WrapFields.ts:188
transformResult
▸ transformResult(originalResult
, delegationContext
, transformationContext
): ExecutionResult
<any
, any
>
Parameters
Name | Type |
---|---|
originalResult | ExecutionResult <any , any > |
delegationContext | DelegationContext <TContext > |
transformationContext | WrapFieldsTransformationContext |
Returns
ExecutionResult
<any
, any
>
Implementation of
Transform.transformResult
Defined in
packages/wrap/src/transforms/WrapFields.ts:202
transformSchema
▸ transformSchema(originalWrappingSchema
, subschemaConfig
): GraphQLSchema
Parameters
Name | Type |
---|---|
originalWrappingSchema | GraphQLSchema |
subschemaConfig | SubschemaConfig <any , any , any , TContext > |
Returns
GraphQLSchema
Implementation of
Transform.transformSchema