From 6a3869707da1ffff7c196fcbcac44c92dcdd5350 Mon Sep 17 00:00:00 2001 From: mokeko Date: Sat, 29 Apr 2023 11:03:00 +0900 Subject: [PATCH 1/4] remove 'foo' above resolver --- plugin/resolvergen/resolver.go | 2 +- plugin/resolvergen/testdata/singlefile/out/resolver.go | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/plugin/resolvergen/resolver.go b/plugin/resolvergen/resolver.go index 2bc714a795c..5826a93c727 100644 --- a/plugin/resolvergen/resolver.go +++ b/plugin/resolvergen/resolver.go @@ -68,7 +68,7 @@ func (m *Plugin) generateSingleFile(data *codegen.Data) error { continue } - resolver := Resolver{o, f, nil, "// foo", `panic("not implemented")`} + resolver := Resolver{o, f, nil, "", `panic("not implemented")`} file.Resolvers = append(file.Resolvers, &resolver) } } diff --git a/plugin/resolvergen/testdata/singlefile/out/resolver.go b/plugin/resolvergen/testdata/singlefile/out/resolver.go index b4bc684e954..54d778636ae 100644 --- a/plugin/resolvergen/testdata/singlefile/out/resolver.go +++ b/plugin/resolvergen/testdata/singlefile/out/resolver.go @@ -8,12 +8,10 @@ import ( type CustomResolverType struct{} -// // foo func (r *queryCustomResolverType) Resolver(ctx context.Context) (*Resolver, error) { panic("not implemented") } -// // foo func (r *resolverCustomResolverType) Name(ctx context.Context, obj *Resolver) (string, error) { panic("not implemented") } From 921442a85234af9295dc582d9ea5e125536b5b66 Mon Sep 17 00:00:00 2001 From: mokeko Date: Sat, 29 Apr 2023 13:21:33 +0900 Subject: [PATCH 2/4] regenerate after 6a3869707da1ffff7c196fcbcac44c92 --- api/testdata/federation2/graph/generated.go | 3 +- codegen/testserver/followschema/resolver.go | 99 --------------------- codegen/testserver/singlefile/resolver.go | 99 --------------------- 3 files changed, 1 insertion(+), 200 deletions(-) diff --git a/api/testdata/federation2/graph/generated.go b/api/testdata/federation2/graph/generated.go index 44ff05d8db3..2a5d2a0559a 100644 --- a/api/testdata/federation2/graph/generated.go +++ b/api/testdata/federation2/graph/generated.go @@ -253,13 +253,12 @@ var sources = []*ast.Source{ {Name: "../federation/directives.graphql", Input: ` scalar _Any scalar _FieldSet - - directive @external on FIELD_DEFINITION directive @requires(fields: _FieldSet!) on FIELD_DEFINITION directive @provides(fields: _FieldSet!) on FIELD_DEFINITION directive @extends on OBJECT | INTERFACE directive @key(fields: _FieldSet!, resolvable: Boolean = true) repeatable on OBJECT | INTERFACE + directive @external on FIELD_DEFINITION | OBJECT directive @link(import: [String!], url: String!) repeatable on SCHEMA directive @shareable on OBJECT | FIELD_DEFINITION directive @tag(name: String!) repeatable on FIELD_DEFINITION | INTERFACE | OBJECT | UNION | ARGUMENT_DEFINITION | SCALAR | ENUM | ENUM_VALUE | INPUT_OBJECT | INPUT_FIELD_DEFINITION diff --git a/codegen/testserver/followschema/resolver.go b/codegen/testserver/followschema/resolver.go index bf3b233c4df..c5f26be3d78 100644 --- a/codegen/testserver/followschema/resolver.go +++ b/codegen/testserver/followschema/resolver.go @@ -12,497 +12,398 @@ import ( type Resolver struct{} -// // foo func (r *backedByInterfaceResolver) ID(ctx context.Context, obj BackedByInterface) (string, error) { panic("not implemented") } -// // foo func (r *errorsResolver) A(ctx context.Context, obj *Errors) (*Error, error) { panic("not implemented") } -// // foo func (r *errorsResolver) B(ctx context.Context, obj *Errors) (*Error, error) { panic("not implemented") } -// // foo func (r *errorsResolver) C(ctx context.Context, obj *Errors) (*Error, error) { panic("not implemented") } -// // foo func (r *errorsResolver) D(ctx context.Context, obj *Errors) (*Error, error) { panic("not implemented") } -// // foo func (r *errorsResolver) E(ctx context.Context, obj *Errors) (*Error, error) { panic("not implemented") } -// // foo func (r *forcedResolverResolver) Field(ctx context.Context, obj *ForcedResolver) (*Circle, error) { panic("not implemented") } -// // foo func (r *modelMethodsResolver) ResolverField(ctx context.Context, obj *ModelMethods) (bool, error) { panic("not implemented") } -// // foo func (r *mutationResolver) DefaultInput(ctx context.Context, input DefaultInput) (*DefaultParametersMirror, error) { panic("not implemented") } -// // foo func (r *mutationResolver) OverrideValueViaInput(ctx context.Context, input FieldsOrderInput) (*FieldsOrderPayload, error) { panic("not implemented") } -// // foo func (r *mutationResolver) UpdateSomething(ctx context.Context, input SpecialInput) (string, error) { panic("not implemented") } -// // foo func (r *mutationResolver) UpdatePtrToPtr(ctx context.Context, input UpdatePtrToPtrOuter) (*PtrToPtrOuter, error) { panic("not implemented") } -// // foo func (r *overlappingFieldsResolver) OldFoo(ctx context.Context, obj *OverlappingFields) (int, error) { panic("not implemented") } -// // foo func (r *panicsResolver) FieldScalarMarshal(ctx context.Context, obj *Panics) ([]MarshalPanic, error) { panic("not implemented") } -// // foo func (r *panicsResolver) ArgUnmarshal(ctx context.Context, obj *Panics, u []MarshalPanic) (bool, error) { panic("not implemented") } -// // foo func (r *petResolver) Friends(ctx context.Context, obj *Pet, limit *int) ([]*Pet, error) { panic("not implemented") } -// // foo func (r *primitiveResolver) Value(ctx context.Context, obj *Primitive) (int, error) { panic("not implemented") } -// // foo func (r *primitiveStringResolver) Value(ctx context.Context, obj *PrimitiveString) (string, error) { panic("not implemented") } -// // foo func (r *primitiveStringResolver) Len(ctx context.Context, obj *PrimitiveString) (int, error) { panic("not implemented") } -// // foo func (r *queryResolver) InvalidIdentifier(ctx context.Context) (*invalid_packagename.InvalidIdentifier, error) { panic("not implemented") } -// // foo func (r *queryResolver) Collision(ctx context.Context) (*introspection1.It, error) { panic("not implemented") } -// // foo func (r *queryResolver) MapInput(ctx context.Context, input map[string]interface{}) (*bool, error) { panic("not implemented") } -// // foo func (r *queryResolver) Recursive(ctx context.Context, input *RecursiveInputSlice) (*bool, error) { panic("not implemented") } -// // foo func (r *queryResolver) NestedInputs(ctx context.Context, input [][]*OuterInput) (*bool, error) { panic("not implemented") } -// // foo func (r *queryResolver) NestedOutputs(ctx context.Context) ([][]*OuterObject, error) { panic("not implemented") } -// // foo func (r *queryResolver) ModelMethods(ctx context.Context) (*ModelMethods, error) { panic("not implemented") } -// // foo func (r *queryResolver) User(ctx context.Context, id int) (*User, error) { panic("not implemented") } -// // foo func (r *queryResolver) NullableArg(ctx context.Context, arg *int) (*string, error) { panic("not implemented") } -// // foo func (r *queryResolver) InputSlice(ctx context.Context, arg []string) (bool, error) { panic("not implemented") } -// // foo func (r *queryResolver) InputNullableSlice(ctx context.Context, arg []string) (bool, error) { panic("not implemented") } -// // foo func (r *queryResolver) InputOmittable(ctx context.Context, arg OmittableInput) (string, error) { panic("not implemented") } -// // foo func (r *queryResolver) ShapeUnion(ctx context.Context) (ShapeUnion, error) { panic("not implemented") } -// // foo func (r *queryResolver) Autobind(ctx context.Context) (*Autobind, error) { panic("not implemented") } -// // foo func (r *queryResolver) DeprecatedField(ctx context.Context) (string, error) { panic("not implemented") } -// // foo func (r *queryResolver) Overlapping(ctx context.Context) (*OverlappingFields, error) { panic("not implemented") } -// // foo func (r *queryResolver) DefaultParameters(ctx context.Context, falsyBoolean *bool, truthyBoolean *bool) (*DefaultParametersMirror, error) { panic("not implemented") } -// // foo func (r *queryResolver) DirectiveArg(ctx context.Context, arg string) (*string, error) { panic("not implemented") } -// // foo func (r *queryResolver) DirectiveNullableArg(ctx context.Context, arg *int, arg2 *int, arg3 *string) (*string, error) { panic("not implemented") } -// // foo func (r *queryResolver) DirectiveInputNullable(ctx context.Context, arg *InputDirectives) (*string, error) { panic("not implemented") } -// // foo func (r *queryResolver) DirectiveInput(ctx context.Context, arg InputDirectives) (*string, error) { panic("not implemented") } -// // foo func (r *queryResolver) DirectiveInputType(ctx context.Context, arg InnerInput) (*string, error) { panic("not implemented") } -// // foo func (r *queryResolver) DirectiveObject(ctx context.Context) (*ObjectDirectives, error) { panic("not implemented") } -// // foo func (r *queryResolver) DirectiveObjectWithCustomGoModel(ctx context.Context) (*ObjectDirectivesWithCustomGoModel, error) { panic("not implemented") } -// // foo func (r *queryResolver) DirectiveFieldDef(ctx context.Context, ret string) (string, error) { panic("not implemented") } -// // foo func (r *queryResolver) DirectiveField(ctx context.Context) (*string, error) { panic("not implemented") } -// // foo func (r *queryResolver) DirectiveDouble(ctx context.Context) (*string, error) { panic("not implemented") } -// // foo func (r *queryResolver) DirectiveUnimplemented(ctx context.Context) (*string, error) { panic("not implemented") } -// // foo func (r *queryResolver) EmbeddedCase1(ctx context.Context) (*EmbeddedCase1, error) { panic("not implemented") } -// // foo func (r *queryResolver) EmbeddedCase2(ctx context.Context) (*EmbeddedCase2, error) { panic("not implemented") } -// // foo func (r *queryResolver) EmbeddedCase3(ctx context.Context) (*EmbeddedCase3, error) { panic("not implemented") } -// // foo func (r *queryResolver) EnumInInput(ctx context.Context, input *InputWithEnumValue) (EnumTest, error) { panic("not implemented") } -// // foo func (r *queryResolver) Shapes(ctx context.Context) ([]Shape, error) { panic("not implemented") } -// // foo func (r *queryResolver) NoShape(ctx context.Context) (Shape, error) { panic("not implemented") } -// // foo func (r *queryResolver) Node(ctx context.Context) (Node, error) { panic("not implemented") } -// // foo func (r *queryResolver) NoShapeTypedNil(ctx context.Context) (Shape, error) { panic("not implemented") } -// // foo func (r *queryResolver) Animal(ctx context.Context) (Animal, error) { panic("not implemented") } -// // foo func (r *queryResolver) NotAnInterface(ctx context.Context) (BackedByInterface, error) { panic("not implemented") } -// // foo func (r *queryResolver) Dog(ctx context.Context) (*Dog, error) { panic("not implemented") } -// // foo func (r *queryResolver) Issue896a(ctx context.Context) ([]*CheckIssue896, error) { panic("not implemented") } -// // foo func (r *queryResolver) MapStringInterface(ctx context.Context, in map[string]interface{}) (map[string]interface{}, error) { panic("not implemented") } -// // foo func (r *queryResolver) MapNestedStringInterface(ctx context.Context, in *NestedMapInput) (map[string]interface{}, error) { panic("not implemented") } -// // foo func (r *queryResolver) ErrorBubble(ctx context.Context) (*Error, error) { panic("not implemented") } -// // foo func (r *queryResolver) ErrorBubbleList(ctx context.Context) ([]*Error, error) { panic("not implemented") } -// // foo func (r *queryResolver) ErrorList(ctx context.Context) ([]*Error, error) { panic("not implemented") } -// // foo func (r *queryResolver) Errors(ctx context.Context) (*Errors, error) { panic("not implemented") } -// // foo func (r *queryResolver) Valid(ctx context.Context) (string, error) { panic("not implemented") } -// // foo func (r *queryResolver) Invalid(ctx context.Context) (string, error) { panic("not implemented") } -// // foo func (r *queryResolver) Panics(ctx context.Context) (*Panics, error) { panic("not implemented") } -// // foo func (r *queryResolver) PrimitiveObject(ctx context.Context) ([]Primitive, error) { panic("not implemented") } -// // foo func (r *queryResolver) PrimitiveStringObject(ctx context.Context) ([]PrimitiveString, error) { panic("not implemented") } -// // foo func (r *queryResolver) PtrToSliceContainer(ctx context.Context) (*PtrToSliceContainer, error) { panic("not implemented") } -// // foo func (r *queryResolver) Infinity(ctx context.Context) (float64, error) { panic("not implemented") } -// // foo func (r *queryResolver) StringFromContextInterface(ctx context.Context) (*StringFromContextInterface, error) { panic("not implemented") } -// // foo func (r *queryResolver) StringFromContextFunction(ctx context.Context) (string, error) { panic("not implemented") } -// // foo func (r *queryResolver) DefaultScalar(ctx context.Context, arg string) (string, error) { panic("not implemented") } -// // foo func (r *queryResolver) Slices(ctx context.Context) (*Slices, error) { panic("not implemented") } -// // foo func (r *queryResolver) ScalarSlice(ctx context.Context) ([]byte, error) { panic("not implemented") } -// // foo func (r *queryResolver) Fallback(ctx context.Context, arg FallbackToStringEncoding) (FallbackToStringEncoding, error) { panic("not implemented") } -// // foo func (r *queryResolver) OptionalUnion(ctx context.Context) (TestUnion, error) { panic("not implemented") } -// // foo func (r *queryResolver) VOkCaseValue(ctx context.Context) (*VOkCaseValue, error) { panic("not implemented") } -// // foo func (r *queryResolver) VOkCaseNil(ctx context.Context) (*VOkCaseNil, error) { panic("not implemented") } -// // foo func (r *queryResolver) ValidType(ctx context.Context) (*ValidType, error) { panic("not implemented") } -// // foo func (r *queryResolver) VariadicModel(ctx context.Context) (*VariadicModel, error) { panic("not implemented") } -// // foo func (r *queryResolver) WrappedStruct(ctx context.Context) (*WrappedStruct, error) { panic("not implemented") } -// // foo func (r *queryResolver) WrappedScalar(ctx context.Context) (otherpkg.Scalar, error) { panic("not implemented") } -// // foo func (r *queryResolver) WrappedMap(ctx context.Context) (WrappedMap, error) { panic("not implemented") } -// // foo func (r *queryResolver) WrappedSlice(ctx context.Context) (WrappedSlice, error) { panic("not implemented") } -// // foo func (r *subscriptionResolver) Updated(ctx context.Context) (<-chan string, error) { panic("not implemented") } -// // foo func (r *subscriptionResolver) InitPayload(ctx context.Context) (<-chan string, error) { panic("not implemented") } -// // foo func (r *subscriptionResolver) DirectiveArg(ctx context.Context, arg string) (<-chan *string, error) { panic("not implemented") } -// // foo func (r *subscriptionResolver) DirectiveNullableArg(ctx context.Context, arg *int, arg2 *int, arg3 *string) (<-chan *string, error) { panic("not implemented") } -// // foo func (r *subscriptionResolver) DirectiveDouble(ctx context.Context) (<-chan *string, error) { panic("not implemented") } -// // foo func (r *subscriptionResolver) DirectiveUnimplemented(ctx context.Context) (<-chan *string, error) { panic("not implemented") } -// // foo func (r *subscriptionResolver) Issue896b(ctx context.Context) (<-chan []*CheckIssue896, error) { panic("not implemented") } -// // foo func (r *subscriptionResolver) ErrorRequired(ctx context.Context) (<-chan *Error, error) { panic("not implemented") } -// // foo func (r *userResolver) Friends(ctx context.Context, obj *User) ([]*User, error) { panic("not implemented") } -// // foo func (r *userResolver) Pets(ctx context.Context, obj *User, limit *int) ([]*Pet, error) { panic("not implemented") } -// // foo func (r *wrappedMapResolver) Get(ctx context.Context, obj WrappedMap, key string) (string, error) { panic("not implemented") } -// // foo func (r *wrappedSliceResolver) Get(ctx context.Context, obj WrappedSlice, idx int) (string, error) { panic("not implemented") } diff --git a/codegen/testserver/singlefile/resolver.go b/codegen/testserver/singlefile/resolver.go index 56352c6b160..cd0db6db56b 100644 --- a/codegen/testserver/singlefile/resolver.go +++ b/codegen/testserver/singlefile/resolver.go @@ -12,497 +12,398 @@ import ( type Resolver struct{} -// // foo func (r *backedByInterfaceResolver) ID(ctx context.Context, obj BackedByInterface) (string, error) { panic("not implemented") } -// // foo func (r *errorsResolver) A(ctx context.Context, obj *Errors) (*Error, error) { panic("not implemented") } -// // foo func (r *errorsResolver) B(ctx context.Context, obj *Errors) (*Error, error) { panic("not implemented") } -// // foo func (r *errorsResolver) C(ctx context.Context, obj *Errors) (*Error, error) { panic("not implemented") } -// // foo func (r *errorsResolver) D(ctx context.Context, obj *Errors) (*Error, error) { panic("not implemented") } -// // foo func (r *errorsResolver) E(ctx context.Context, obj *Errors) (*Error, error) { panic("not implemented") } -// // foo func (r *forcedResolverResolver) Field(ctx context.Context, obj *ForcedResolver) (*Circle, error) { panic("not implemented") } -// // foo func (r *modelMethodsResolver) ResolverField(ctx context.Context, obj *ModelMethods) (bool, error) { panic("not implemented") } -// // foo func (r *mutationResolver) DefaultInput(ctx context.Context, input DefaultInput) (*DefaultParametersMirror, error) { panic("not implemented") } -// // foo func (r *mutationResolver) OverrideValueViaInput(ctx context.Context, input FieldsOrderInput) (*FieldsOrderPayload, error) { panic("not implemented") } -// // foo func (r *mutationResolver) UpdateSomething(ctx context.Context, input SpecialInput) (string, error) { panic("not implemented") } -// // foo func (r *mutationResolver) UpdatePtrToPtr(ctx context.Context, input UpdatePtrToPtrOuter) (*PtrToPtrOuter, error) { panic("not implemented") } -// // foo func (r *overlappingFieldsResolver) OldFoo(ctx context.Context, obj *OverlappingFields) (int, error) { panic("not implemented") } -// // foo func (r *panicsResolver) FieldScalarMarshal(ctx context.Context, obj *Panics) ([]MarshalPanic, error) { panic("not implemented") } -// // foo func (r *panicsResolver) ArgUnmarshal(ctx context.Context, obj *Panics, u []MarshalPanic) (bool, error) { panic("not implemented") } -// // foo func (r *petResolver) Friends(ctx context.Context, obj *Pet, limit *int) ([]*Pet, error) { panic("not implemented") } -// // foo func (r *primitiveResolver) Value(ctx context.Context, obj *Primitive) (int, error) { panic("not implemented") } -// // foo func (r *primitiveStringResolver) Value(ctx context.Context, obj *PrimitiveString) (string, error) { panic("not implemented") } -// // foo func (r *primitiveStringResolver) Len(ctx context.Context, obj *PrimitiveString) (int, error) { panic("not implemented") } -// // foo func (r *queryResolver) InvalidIdentifier(ctx context.Context) (*invalid_packagename.InvalidIdentifier, error) { panic("not implemented") } -// // foo func (r *queryResolver) Collision(ctx context.Context) (*introspection1.It, error) { panic("not implemented") } -// // foo func (r *queryResolver) MapInput(ctx context.Context, input map[string]interface{}) (*bool, error) { panic("not implemented") } -// // foo func (r *queryResolver) Recursive(ctx context.Context, input *RecursiveInputSlice) (*bool, error) { panic("not implemented") } -// // foo func (r *queryResolver) NestedInputs(ctx context.Context, input [][]*OuterInput) (*bool, error) { panic("not implemented") } -// // foo func (r *queryResolver) NestedOutputs(ctx context.Context) ([][]*OuterObject, error) { panic("not implemented") } -// // foo func (r *queryResolver) ModelMethods(ctx context.Context) (*ModelMethods, error) { panic("not implemented") } -// // foo func (r *queryResolver) User(ctx context.Context, id int) (*User, error) { panic("not implemented") } -// // foo func (r *queryResolver) NullableArg(ctx context.Context, arg *int) (*string, error) { panic("not implemented") } -// // foo func (r *queryResolver) InputSlice(ctx context.Context, arg []string) (bool, error) { panic("not implemented") } -// // foo func (r *queryResolver) InputNullableSlice(ctx context.Context, arg []string) (bool, error) { panic("not implemented") } -// // foo func (r *queryResolver) InputOmittable(ctx context.Context, arg OmittableInput) (string, error) { panic("not implemented") } -// // foo func (r *queryResolver) ShapeUnion(ctx context.Context) (ShapeUnion, error) { panic("not implemented") } -// // foo func (r *queryResolver) Autobind(ctx context.Context) (*Autobind, error) { panic("not implemented") } -// // foo func (r *queryResolver) DeprecatedField(ctx context.Context) (string, error) { panic("not implemented") } -// // foo func (r *queryResolver) Overlapping(ctx context.Context) (*OverlappingFields, error) { panic("not implemented") } -// // foo func (r *queryResolver) DefaultParameters(ctx context.Context, falsyBoolean *bool, truthyBoolean *bool) (*DefaultParametersMirror, error) { panic("not implemented") } -// // foo func (r *queryResolver) DirectiveArg(ctx context.Context, arg string) (*string, error) { panic("not implemented") } -// // foo func (r *queryResolver) DirectiveNullableArg(ctx context.Context, arg *int, arg2 *int, arg3 *string) (*string, error) { panic("not implemented") } -// // foo func (r *queryResolver) DirectiveInputNullable(ctx context.Context, arg *InputDirectives) (*string, error) { panic("not implemented") } -// // foo func (r *queryResolver) DirectiveInput(ctx context.Context, arg InputDirectives) (*string, error) { panic("not implemented") } -// // foo func (r *queryResolver) DirectiveInputType(ctx context.Context, arg InnerInput) (*string, error) { panic("not implemented") } -// // foo func (r *queryResolver) DirectiveObject(ctx context.Context) (*ObjectDirectives, error) { panic("not implemented") } -// // foo func (r *queryResolver) DirectiveObjectWithCustomGoModel(ctx context.Context) (*ObjectDirectivesWithCustomGoModel, error) { panic("not implemented") } -// // foo func (r *queryResolver) DirectiveFieldDef(ctx context.Context, ret string) (string, error) { panic("not implemented") } -// // foo func (r *queryResolver) DirectiveField(ctx context.Context) (*string, error) { panic("not implemented") } -// // foo func (r *queryResolver) DirectiveDouble(ctx context.Context) (*string, error) { panic("not implemented") } -// // foo func (r *queryResolver) DirectiveUnimplemented(ctx context.Context) (*string, error) { panic("not implemented") } -// // foo func (r *queryResolver) EmbeddedCase1(ctx context.Context) (*EmbeddedCase1, error) { panic("not implemented") } -// // foo func (r *queryResolver) EmbeddedCase2(ctx context.Context) (*EmbeddedCase2, error) { panic("not implemented") } -// // foo func (r *queryResolver) EmbeddedCase3(ctx context.Context) (*EmbeddedCase3, error) { panic("not implemented") } -// // foo func (r *queryResolver) EnumInInput(ctx context.Context, input *InputWithEnumValue) (EnumTest, error) { panic("not implemented") } -// // foo func (r *queryResolver) Shapes(ctx context.Context) ([]Shape, error) { panic("not implemented") } -// // foo func (r *queryResolver) NoShape(ctx context.Context) (Shape, error) { panic("not implemented") } -// // foo func (r *queryResolver) Node(ctx context.Context) (Node, error) { panic("not implemented") } -// // foo func (r *queryResolver) NoShapeTypedNil(ctx context.Context) (Shape, error) { panic("not implemented") } -// // foo func (r *queryResolver) Animal(ctx context.Context) (Animal, error) { panic("not implemented") } -// // foo func (r *queryResolver) NotAnInterface(ctx context.Context) (BackedByInterface, error) { panic("not implemented") } -// // foo func (r *queryResolver) Dog(ctx context.Context) (*Dog, error) { panic("not implemented") } -// // foo func (r *queryResolver) Issue896a(ctx context.Context) ([]*CheckIssue896, error) { panic("not implemented") } -// // foo func (r *queryResolver) MapStringInterface(ctx context.Context, in map[string]interface{}) (map[string]interface{}, error) { panic("not implemented") } -// // foo func (r *queryResolver) MapNestedStringInterface(ctx context.Context, in *NestedMapInput) (map[string]interface{}, error) { panic("not implemented") } -// // foo func (r *queryResolver) ErrorBubble(ctx context.Context) (*Error, error) { panic("not implemented") } -// // foo func (r *queryResolver) ErrorBubbleList(ctx context.Context) ([]*Error, error) { panic("not implemented") } -// // foo func (r *queryResolver) ErrorList(ctx context.Context) ([]*Error, error) { panic("not implemented") } -// // foo func (r *queryResolver) Errors(ctx context.Context) (*Errors, error) { panic("not implemented") } -// // foo func (r *queryResolver) Valid(ctx context.Context) (string, error) { panic("not implemented") } -// // foo func (r *queryResolver) Invalid(ctx context.Context) (string, error) { panic("not implemented") } -// // foo func (r *queryResolver) Panics(ctx context.Context) (*Panics, error) { panic("not implemented") } -// // foo func (r *queryResolver) PrimitiveObject(ctx context.Context) ([]Primitive, error) { panic("not implemented") } -// // foo func (r *queryResolver) PrimitiveStringObject(ctx context.Context) ([]PrimitiveString, error) { panic("not implemented") } -// // foo func (r *queryResolver) PtrToSliceContainer(ctx context.Context) (*PtrToSliceContainer, error) { panic("not implemented") } -// // foo func (r *queryResolver) Infinity(ctx context.Context) (float64, error) { panic("not implemented") } -// // foo func (r *queryResolver) StringFromContextInterface(ctx context.Context) (*StringFromContextInterface, error) { panic("not implemented") } -// // foo func (r *queryResolver) StringFromContextFunction(ctx context.Context) (string, error) { panic("not implemented") } -// // foo func (r *queryResolver) DefaultScalar(ctx context.Context, arg string) (string, error) { panic("not implemented") } -// // foo func (r *queryResolver) Slices(ctx context.Context) (*Slices, error) { panic("not implemented") } -// // foo func (r *queryResolver) ScalarSlice(ctx context.Context) ([]byte, error) { panic("not implemented") } -// // foo func (r *queryResolver) Fallback(ctx context.Context, arg FallbackToStringEncoding) (FallbackToStringEncoding, error) { panic("not implemented") } -// // foo func (r *queryResolver) OptionalUnion(ctx context.Context) (TestUnion, error) { panic("not implemented") } -// // foo func (r *queryResolver) VOkCaseValue(ctx context.Context) (*VOkCaseValue, error) { panic("not implemented") } -// // foo func (r *queryResolver) VOkCaseNil(ctx context.Context) (*VOkCaseNil, error) { panic("not implemented") } -// // foo func (r *queryResolver) ValidType(ctx context.Context) (*ValidType, error) { panic("not implemented") } -// // foo func (r *queryResolver) VariadicModel(ctx context.Context) (*VariadicModel, error) { panic("not implemented") } -// // foo func (r *queryResolver) WrappedStruct(ctx context.Context) (*WrappedStruct, error) { panic("not implemented") } -// // foo func (r *queryResolver) WrappedScalar(ctx context.Context) (otherpkg.Scalar, error) { panic("not implemented") } -// // foo func (r *queryResolver) WrappedMap(ctx context.Context) (WrappedMap, error) { panic("not implemented") } -// // foo func (r *queryResolver) WrappedSlice(ctx context.Context) (WrappedSlice, error) { panic("not implemented") } -// // foo func (r *subscriptionResolver) Updated(ctx context.Context) (<-chan string, error) { panic("not implemented") } -// // foo func (r *subscriptionResolver) InitPayload(ctx context.Context) (<-chan string, error) { panic("not implemented") } -// // foo func (r *subscriptionResolver) DirectiveArg(ctx context.Context, arg string) (<-chan *string, error) { panic("not implemented") } -// // foo func (r *subscriptionResolver) DirectiveNullableArg(ctx context.Context, arg *int, arg2 *int, arg3 *string) (<-chan *string, error) { panic("not implemented") } -// // foo func (r *subscriptionResolver) DirectiveDouble(ctx context.Context) (<-chan *string, error) { panic("not implemented") } -// // foo func (r *subscriptionResolver) DirectiveUnimplemented(ctx context.Context) (<-chan *string, error) { panic("not implemented") } -// // foo func (r *subscriptionResolver) Issue896b(ctx context.Context) (<-chan []*CheckIssue896, error) { panic("not implemented") } -// // foo func (r *subscriptionResolver) ErrorRequired(ctx context.Context) (<-chan *Error, error) { panic("not implemented") } -// // foo func (r *userResolver) Friends(ctx context.Context, obj *User) ([]*User, error) { panic("not implemented") } -// // foo func (r *userResolver) Pets(ctx context.Context, obj *User, limit *int) ([]*Pet, error) { panic("not implemented") } -// // foo func (r *wrappedMapResolver) Get(ctx context.Context, obj WrappedMap, key string) (string, error) { panic("not implemented") } -// // foo func (r *wrappedSliceResolver) Get(ctx context.Context, obj WrappedSlice, idx int) (string, error) { panic("not implemented") } From 9fd8abc581b218e252c5daecfd77857de5c31ee2 Mon Sep 17 00:00:00 2001 From: mokeko Date: Sat, 29 Apr 2023 14:52:03 +0900 Subject: [PATCH 3/4] omit resolver template comment --- codegen/config/resolver.go | 13 ++++---- docs/content/config.md | 2 ++ init-templates/gqlgen.yml.gotmpl | 2 ++ plugin/resolvergen/resolver.go | 26 ++++++++-------- plugin/resolvergen/resolver.gotpl | 10 +++++-- plugin/resolvergen/resolver_test.go | 18 +++++++++++ .../filetemplate/out/schema.custom.go | 2 +- .../followschema/out/schema.resolvers.go | 2 +- .../testdata/omit_template_comment/gqlgen.yml | 16 ++++++++++ .../omit_template_comment/out/resolver.go | 7 +++++ .../out/schema.resolvers.go | 30 +++++++++++++++++++ .../testdata/singlefile/out/resolver.go | 2 ++ 12 files changed, 107 insertions(+), 23 deletions(-) create mode 100644 plugin/resolvergen/testdata/omit_template_comment/gqlgen.yml create mode 100644 plugin/resolvergen/testdata/omit_template_comment/out/resolver.go create mode 100644 plugin/resolvergen/testdata/omit_template_comment/out/schema.resolvers.go diff --git a/codegen/config/resolver.go b/codegen/config/resolver.go index cd03f188729..a3ec38f8e20 100644 --- a/codegen/config/resolver.go +++ b/codegen/config/resolver.go @@ -10,12 +10,13 @@ import ( ) type ResolverConfig struct { - Filename string `yaml:"filename,omitempty"` - FilenameTemplate string `yaml:"filename_template,omitempty"` - Package string `yaml:"package,omitempty"` - Type string `yaml:"type,omitempty"` - Layout ResolverLayout `yaml:"layout,omitempty"` - DirName string `yaml:"dir"` + Filename string `yaml:"filename,omitempty"` + FilenameTemplate string `yaml:"filename_template,omitempty"` + Package string `yaml:"package,omitempty"` + Type string `yaml:"type,omitempty"` + Layout ResolverLayout `yaml:"layout,omitempty"` + DirName string `yaml:"dir"` + OmitTemplateComment bool `yaml:"omit_template_comment,omitempty"` } type ResolverLayout string diff --git a/docs/content/config.md b/docs/content/config.md index 2b59c3322a7..aa8c8a3ba3d 100644 --- a/docs/content/config.md +++ b/docs/content/config.md @@ -37,6 +37,8 @@ resolver: dir: graph package: graph filename_template: "{name}.resolvers.go" + # Optional: turn on to not generate template comments above resolvers + # omit_template_comment: false # Optional: turn on use ` + "`" + `gqlgen:"fieldName"` + "`" + ` tags in your models # struct_tag: json diff --git a/init-templates/gqlgen.yml.gotmpl b/init-templates/gqlgen.yml.gotmpl index 79e8b8b07d0..4e0ecf8a5d2 100644 --- a/init-templates/gqlgen.yml.gotmpl +++ b/init-templates/gqlgen.yml.gotmpl @@ -23,6 +23,8 @@ resolver: dir: graph package: graph filename_template: "{name}.resolvers.go" + # Optional: turn on to not generate template comments above resolvers + # omit_template_comment: false # Optional: turn on use ` + "`" + `gqlgen:"fieldName"` + "`" + ` tags in your models # struct_tag: json diff --git a/plugin/resolvergen/resolver.go b/plugin/resolvergen/resolver.go index 5826a93c727..09cfbab63bb 100644 --- a/plugin/resolvergen/resolver.go +++ b/plugin/resolvergen/resolver.go @@ -74,10 +74,11 @@ func (m *Plugin) generateSingleFile(data *codegen.Data) error { } resolverBuild := &ResolverBuild{ - File: &file, - PackageName: data.Config.Resolver.Package, - ResolverType: data.Config.Resolver.Type, - HasRoot: true, + File: &file, + PackageName: data.Config.Resolver.Package, + ResolverType: data.Config.Resolver.Type, + HasRoot: true, + OmitTemplateComment: data.Config.Resolver.OmitTemplateComment, } return templates.Render(templates.Options{ @@ -122,9 +123,6 @@ func (m *Plugin) generatePerSchema(data *codegen.Data) error { structName := templates.LcFirst(o.Name) + templates.UcFirst(data.Config.Resolver.Type) comment := strings.TrimSpace(strings.TrimLeft(rewriter.GetMethodComment(structName, f.GoFieldName), `\`)) - if comment == "" { - comment = fmt.Sprintf("%v is the resolver for the %v field.", f.GoFieldName, f.Name) - } implementation := strings.TrimSpace(rewriter.GetMethodBody(structName, f.GoFieldName)) if implementation == "" { // Check for Implementer Plugin @@ -163,9 +161,10 @@ func (m *Plugin) generatePerSchema(data *codegen.Data) error { for filename, file := range files { resolverBuild := &ResolverBuild{ - File: file, - PackageName: data.Config.Resolver.Package, - ResolverType: data.Config.Resolver.Type, + File: file, + PackageName: data.Config.Resolver.Package, + ResolverType: data.Config.Resolver.Type, + OmitTemplateComment: data.Config.Resolver.OmitTemplateComment, } var fileNotice strings.Builder @@ -215,9 +214,10 @@ func (m *Plugin) generatePerSchema(data *codegen.Data) error { type ResolverBuild struct { *File - HasRoot bool - PackageName string - ResolverType string + HasRoot bool + PackageName string + ResolverType string + OmitTemplateComment bool } type File struct { diff --git a/plugin/resolvergen/resolver.gotpl b/plugin/resolvergen/resolver.gotpl index 920617608e6..c25bd1d5627 100644 --- a/plugin/resolvergen/resolver.gotpl +++ b/plugin/resolvergen/resolver.gotpl @@ -19,7 +19,11 @@ {{ end }} {{ range $resolver := .Resolvers -}} - // {{ $resolver.Comment }} + {{ if $resolver.Comment -}} + // {{ $resolver.Comment }} + {{- else if not $.OmitTemplateComment -}} + // {{ $resolver.Field.GoFieldName }} is the resolver for the {{ $resolver.Field.Name }} field. + {{- end }} func (r *{{lcFirst $resolver.Object.Name}}{{ucFirst $.ResolverType}}) {{$resolver.Field.GoFieldName}}{{ with $resolver.PrevDecl }}{{ $resolver.Field.ShortResolverSignature .Type }}{{ else }}{{ $resolver.Field.ShortResolverDeclaration }}{{ end }}{ {{ $resolver.Implementation }} } @@ -27,7 +31,9 @@ {{ end }} {{ range $object := .Objects -}} - // {{ucFirst $object.Name}} returns {{ $object.ResolverInterface | ref }} implementation. + {{ if not $.OmitTemplateComment -}} + // {{ucFirst $object.Name}} returns {{ $object.ResolverInterface | ref }} implementation. + {{- end }} func (r *{{$.ResolverType}}) {{ucFirst $object.Name}}() {{ $object.ResolverInterface | ref }} { return &{{lcFirst $object.Name}}{{ucFirst $.ResolverType}}{r} } {{ end }} diff --git a/plugin/resolvergen/resolver_test.go b/plugin/resolvergen/resolver_test.go index ea66e50567f..5a1300113ce 100644 --- a/plugin/resolvergen/resolver_test.go +++ b/plugin/resolvergen/resolver_test.go @@ -65,6 +65,24 @@ func TestLayoutInvalidModelPath(t *testing.T) { require.Error(t, err) } +func TestOmitTemplateComment(t *testing.T) { + _ = syscall.Unlink("testdata/omit_template_comment/resolver.go") + + cfg, err := config.LoadConfig("testdata/omit_template_comment/gqlgen.yml") + require.NoError(t, err) + p := Plugin{} + + require.NoError(t, cfg.Init()) + + data, err := codegen.BuildData(cfg) + if err != nil { + panic(err) + } + + require.NoError(t, p.GenerateCode(data)) + assertNoErrors(t, "github.com/99designs/gqlgen/plugin/resolvergen/testdata/omit_template_comment/out") +} + func testFollowSchemaPersistence(t *testing.T, dir string) { _ = syscall.Unlink(dir + "/out/resolver.go") diff --git a/plugin/resolvergen/testdata/filetemplate/out/schema.custom.go b/plugin/resolvergen/testdata/filetemplate/out/schema.custom.go index 89f44a10a14..a4da064b24b 100644 --- a/plugin/resolvergen/testdata/filetemplate/out/schema.custom.go +++ b/plugin/resolvergen/testdata/filetemplate/out/schema.custom.go @@ -2,7 +2,7 @@ package customresolver // This file will be automatically regenerated based on the schema, any resolver implementations // will be copied through when generating and any unknown code will be moved to the end. -// Code generated by github.com/99designs/gqlgen version v0.17.26-dev +// Code generated by github.com/99designs/gqlgen version v0.17.30-dev import ( "context" diff --git a/plugin/resolvergen/testdata/followschema/out/schema.resolvers.go b/plugin/resolvergen/testdata/followschema/out/schema.resolvers.go index 3819d559143..5ba2bb3ad55 100644 --- a/plugin/resolvergen/testdata/followschema/out/schema.resolvers.go +++ b/plugin/resolvergen/testdata/followschema/out/schema.resolvers.go @@ -2,7 +2,7 @@ package customresolver // This file will be automatically regenerated based on the schema, any resolver implementations // will be copied through when generating and any unknown code will be moved to the end. -// Code generated by github.com/99designs/gqlgen version v0.17.26-dev +// Code generated by github.com/99designs/gqlgen version v0.17.30-dev import ( "context" diff --git a/plugin/resolvergen/testdata/omit_template_comment/gqlgen.yml b/plugin/resolvergen/testdata/omit_template_comment/gqlgen.yml new file mode 100644 index 00000000000..68c4cacc06a --- /dev/null +++ b/plugin/resolvergen/testdata/omit_template_comment/gqlgen.yml @@ -0,0 +1,16 @@ +schema: + - "testdata/schema.graphql" + +exec: + filename: testdata/singlefile/out/ignored.go +model: + filename: testdata/singlefile/out/generated.go +resolver: + type: CustomResolverType + layout: follow-schema + dir: testdata/omit_template_comment/out + omit_template_comment: true + +models: + Resolver: + model: github.com/99designs/gqlgen/plugin/resolvergen/testdata/singlefile/out.Resolver diff --git a/plugin/resolvergen/testdata/omit_template_comment/out/resolver.go b/plugin/resolvergen/testdata/omit_template_comment/out/resolver.go new file mode 100644 index 00000000000..640b3c53ff5 --- /dev/null +++ b/plugin/resolvergen/testdata/omit_template_comment/out/resolver.go @@ -0,0 +1,7 @@ +package out + +// This file will not be regenerated automatically. +// +// It serves as dependency injection for your app, add any dependencies you require here. + +type CustomResolverType struct{} diff --git a/plugin/resolvergen/testdata/omit_template_comment/out/schema.resolvers.go b/plugin/resolvergen/testdata/omit_template_comment/out/schema.resolvers.go new file mode 100644 index 00000000000..d854d564be2 --- /dev/null +++ b/plugin/resolvergen/testdata/omit_template_comment/out/schema.resolvers.go @@ -0,0 +1,30 @@ +package out + +// This file will be automatically regenerated based on the schema, any resolver implementations +// will be copied through when generating and any unknown code will be moved to the end. +// Code generated by github.com/99designs/gqlgen version v0.17.30-dev + +import ( + "context" + "fmt" + + customresolver "github.com/99designs/gqlgen/plugin/resolvergen/testdata/singlefile/out" +) + +func (r *queryCustomResolverType) Resolver(ctx context.Context) (*customresolver.Resolver, error) { + panic(fmt.Errorf("not implemented: Resolver - resolver")) +} + +// This comment was added manually after code generation. It will remain after re-generation. +func (r *resolverCustomResolverType) Name(ctx context.Context, obj *customresolver.Resolver) (string, error) { + panic(fmt.Errorf("not implemented: Name - name")) +} + +func (r *CustomResolverType) Query() customresolver.QueryResolver { return &queryCustomResolverType{r} } + +func (r *CustomResolverType) Resolver() customresolver.ResolverResolver { + return &resolverCustomResolverType{r} +} + +type queryCustomResolverType struct{ *CustomResolverType } +type resolverCustomResolverType struct{ *CustomResolverType } diff --git a/plugin/resolvergen/testdata/singlefile/out/resolver.go b/plugin/resolvergen/testdata/singlefile/out/resolver.go index 54d778636ae..844b077c4ac 100644 --- a/plugin/resolvergen/testdata/singlefile/out/resolver.go +++ b/plugin/resolvergen/testdata/singlefile/out/resolver.go @@ -8,10 +8,12 @@ import ( type CustomResolverType struct{} +// Resolver is the resolver for the resolver field. func (r *queryCustomResolverType) Resolver(ctx context.Context) (*Resolver, error) { panic("not implemented") } +// Name is the resolver for the name field. func (r *resolverCustomResolverType) Name(ctx context.Context, obj *Resolver) (string, error) { panic("not implemented") } From a6993032a6a5a541a27b7ab4101d71b710e754b9 Mon Sep 17 00:00:00 2001 From: mokeko Date: Sat, 29 Apr 2023 14:55:30 +0900 Subject: [PATCH 4/4] re-generate --- codegen/testserver/followschema/resolver.go | 99 +++++++++++++++++++++ codegen/testserver/singlefile/resolver.go | 99 +++++++++++++++++++++ 2 files changed, 198 insertions(+) diff --git a/codegen/testserver/followschema/resolver.go b/codegen/testserver/followschema/resolver.go index c5f26be3d78..7efd695ec8f 100644 --- a/codegen/testserver/followschema/resolver.go +++ b/codegen/testserver/followschema/resolver.go @@ -12,398 +12,497 @@ import ( type Resolver struct{} +// ID is the resolver for the id field. func (r *backedByInterfaceResolver) ID(ctx context.Context, obj BackedByInterface) (string, error) { panic("not implemented") } +// A is the resolver for the a field. func (r *errorsResolver) A(ctx context.Context, obj *Errors) (*Error, error) { panic("not implemented") } +// B is the resolver for the b field. func (r *errorsResolver) B(ctx context.Context, obj *Errors) (*Error, error) { panic("not implemented") } +// C is the resolver for the c field. func (r *errorsResolver) C(ctx context.Context, obj *Errors) (*Error, error) { panic("not implemented") } +// D is the resolver for the d field. func (r *errorsResolver) D(ctx context.Context, obj *Errors) (*Error, error) { panic("not implemented") } +// E is the resolver for the e field. func (r *errorsResolver) E(ctx context.Context, obj *Errors) (*Error, error) { panic("not implemented") } +// Field is the resolver for the field field. func (r *forcedResolverResolver) Field(ctx context.Context, obj *ForcedResolver) (*Circle, error) { panic("not implemented") } +// ResolverField is the resolver for the resolverField field. func (r *modelMethodsResolver) ResolverField(ctx context.Context, obj *ModelMethods) (bool, error) { panic("not implemented") } +// DefaultInput is the resolver for the defaultInput field. func (r *mutationResolver) DefaultInput(ctx context.Context, input DefaultInput) (*DefaultParametersMirror, error) { panic("not implemented") } +// OverrideValueViaInput is the resolver for the overrideValueViaInput field. func (r *mutationResolver) OverrideValueViaInput(ctx context.Context, input FieldsOrderInput) (*FieldsOrderPayload, error) { panic("not implemented") } +// UpdateSomething is the resolver for the updateSomething field. func (r *mutationResolver) UpdateSomething(ctx context.Context, input SpecialInput) (string, error) { panic("not implemented") } +// UpdatePtrToPtr is the resolver for the updatePtrToPtr field. func (r *mutationResolver) UpdatePtrToPtr(ctx context.Context, input UpdatePtrToPtrOuter) (*PtrToPtrOuter, error) { panic("not implemented") } +// OldFoo is the resolver for the oldFoo field. func (r *overlappingFieldsResolver) OldFoo(ctx context.Context, obj *OverlappingFields) (int, error) { panic("not implemented") } +// FieldScalarMarshal is the resolver for the fieldScalarMarshal field. func (r *panicsResolver) FieldScalarMarshal(ctx context.Context, obj *Panics) ([]MarshalPanic, error) { panic("not implemented") } +// ArgUnmarshal is the resolver for the argUnmarshal field. func (r *panicsResolver) ArgUnmarshal(ctx context.Context, obj *Panics, u []MarshalPanic) (bool, error) { panic("not implemented") } +// Friends is the resolver for the friends field. func (r *petResolver) Friends(ctx context.Context, obj *Pet, limit *int) ([]*Pet, error) { panic("not implemented") } +// Value is the resolver for the value field. func (r *primitiveResolver) Value(ctx context.Context, obj *Primitive) (int, error) { panic("not implemented") } +// Value is the resolver for the value field. func (r *primitiveStringResolver) Value(ctx context.Context, obj *PrimitiveString) (string, error) { panic("not implemented") } +// Len is the resolver for the len field. func (r *primitiveStringResolver) Len(ctx context.Context, obj *PrimitiveString) (int, error) { panic("not implemented") } +// InvalidIdentifier is the resolver for the invalidIdentifier field. func (r *queryResolver) InvalidIdentifier(ctx context.Context) (*invalid_packagename.InvalidIdentifier, error) { panic("not implemented") } +// Collision is the resolver for the collision field. func (r *queryResolver) Collision(ctx context.Context) (*introspection1.It, error) { panic("not implemented") } +// MapInput is the resolver for the mapInput field. func (r *queryResolver) MapInput(ctx context.Context, input map[string]interface{}) (*bool, error) { panic("not implemented") } +// Recursive is the resolver for the recursive field. func (r *queryResolver) Recursive(ctx context.Context, input *RecursiveInputSlice) (*bool, error) { panic("not implemented") } +// NestedInputs is the resolver for the nestedInputs field. func (r *queryResolver) NestedInputs(ctx context.Context, input [][]*OuterInput) (*bool, error) { panic("not implemented") } +// NestedOutputs is the resolver for the nestedOutputs field. func (r *queryResolver) NestedOutputs(ctx context.Context) ([][]*OuterObject, error) { panic("not implemented") } +// ModelMethods is the resolver for the modelMethods field. func (r *queryResolver) ModelMethods(ctx context.Context) (*ModelMethods, error) { panic("not implemented") } +// User is the resolver for the user field. func (r *queryResolver) User(ctx context.Context, id int) (*User, error) { panic("not implemented") } +// NullableArg is the resolver for the nullableArg field. func (r *queryResolver) NullableArg(ctx context.Context, arg *int) (*string, error) { panic("not implemented") } +// InputSlice is the resolver for the inputSlice field. func (r *queryResolver) InputSlice(ctx context.Context, arg []string) (bool, error) { panic("not implemented") } +// InputNullableSlice is the resolver for the inputNullableSlice field. func (r *queryResolver) InputNullableSlice(ctx context.Context, arg []string) (bool, error) { panic("not implemented") } +// InputOmittable is the resolver for the inputOmittable field. func (r *queryResolver) InputOmittable(ctx context.Context, arg OmittableInput) (string, error) { panic("not implemented") } +// ShapeUnion is the resolver for the shapeUnion field. func (r *queryResolver) ShapeUnion(ctx context.Context) (ShapeUnion, error) { panic("not implemented") } +// Autobind is the resolver for the autobind field. func (r *queryResolver) Autobind(ctx context.Context) (*Autobind, error) { panic("not implemented") } +// DeprecatedField is the resolver for the deprecatedField field. func (r *queryResolver) DeprecatedField(ctx context.Context) (string, error) { panic("not implemented") } +// Overlapping is the resolver for the overlapping field. func (r *queryResolver) Overlapping(ctx context.Context) (*OverlappingFields, error) { panic("not implemented") } +// DefaultParameters is the resolver for the defaultParameters field. func (r *queryResolver) DefaultParameters(ctx context.Context, falsyBoolean *bool, truthyBoolean *bool) (*DefaultParametersMirror, error) { panic("not implemented") } +// DirectiveArg is the resolver for the directiveArg field. func (r *queryResolver) DirectiveArg(ctx context.Context, arg string) (*string, error) { panic("not implemented") } +// DirectiveNullableArg is the resolver for the directiveNullableArg field. func (r *queryResolver) DirectiveNullableArg(ctx context.Context, arg *int, arg2 *int, arg3 *string) (*string, error) { panic("not implemented") } +// DirectiveInputNullable is the resolver for the directiveInputNullable field. func (r *queryResolver) DirectiveInputNullable(ctx context.Context, arg *InputDirectives) (*string, error) { panic("not implemented") } +// DirectiveInput is the resolver for the directiveInput field. func (r *queryResolver) DirectiveInput(ctx context.Context, arg InputDirectives) (*string, error) { panic("not implemented") } +// DirectiveInputType is the resolver for the directiveInputType field. func (r *queryResolver) DirectiveInputType(ctx context.Context, arg InnerInput) (*string, error) { panic("not implemented") } +// DirectiveObject is the resolver for the directiveObject field. func (r *queryResolver) DirectiveObject(ctx context.Context) (*ObjectDirectives, error) { panic("not implemented") } +// DirectiveObjectWithCustomGoModel is the resolver for the directiveObjectWithCustomGoModel field. func (r *queryResolver) DirectiveObjectWithCustomGoModel(ctx context.Context) (*ObjectDirectivesWithCustomGoModel, error) { panic("not implemented") } +// DirectiveFieldDef is the resolver for the directiveFieldDef field. func (r *queryResolver) DirectiveFieldDef(ctx context.Context, ret string) (string, error) { panic("not implemented") } +// DirectiveField is the resolver for the directiveField field. func (r *queryResolver) DirectiveField(ctx context.Context) (*string, error) { panic("not implemented") } +// DirectiveDouble is the resolver for the directiveDouble field. func (r *queryResolver) DirectiveDouble(ctx context.Context) (*string, error) { panic("not implemented") } +// DirectiveUnimplemented is the resolver for the directiveUnimplemented field. func (r *queryResolver) DirectiveUnimplemented(ctx context.Context) (*string, error) { panic("not implemented") } +// EmbeddedCase1 is the resolver for the embeddedCase1 field. func (r *queryResolver) EmbeddedCase1(ctx context.Context) (*EmbeddedCase1, error) { panic("not implemented") } +// EmbeddedCase2 is the resolver for the embeddedCase2 field. func (r *queryResolver) EmbeddedCase2(ctx context.Context) (*EmbeddedCase2, error) { panic("not implemented") } +// EmbeddedCase3 is the resolver for the embeddedCase3 field. func (r *queryResolver) EmbeddedCase3(ctx context.Context) (*EmbeddedCase3, error) { panic("not implemented") } +// EnumInInput is the resolver for the enumInInput field. func (r *queryResolver) EnumInInput(ctx context.Context, input *InputWithEnumValue) (EnumTest, error) { panic("not implemented") } +// Shapes is the resolver for the shapes field. func (r *queryResolver) Shapes(ctx context.Context) ([]Shape, error) { panic("not implemented") } +// NoShape is the resolver for the noShape field. func (r *queryResolver) NoShape(ctx context.Context) (Shape, error) { panic("not implemented") } +// Node is the resolver for the node field. func (r *queryResolver) Node(ctx context.Context) (Node, error) { panic("not implemented") } +// NoShapeTypedNil is the resolver for the noShapeTypedNil field. func (r *queryResolver) NoShapeTypedNil(ctx context.Context) (Shape, error) { panic("not implemented") } +// Animal is the resolver for the animal field. func (r *queryResolver) Animal(ctx context.Context) (Animal, error) { panic("not implemented") } +// NotAnInterface is the resolver for the notAnInterface field. func (r *queryResolver) NotAnInterface(ctx context.Context) (BackedByInterface, error) { panic("not implemented") } +// Dog is the resolver for the dog field. func (r *queryResolver) Dog(ctx context.Context) (*Dog, error) { panic("not implemented") } +// Issue896a is the resolver for the issue896a field. func (r *queryResolver) Issue896a(ctx context.Context) ([]*CheckIssue896, error) { panic("not implemented") } +// MapStringInterface is the resolver for the mapStringInterface field. func (r *queryResolver) MapStringInterface(ctx context.Context, in map[string]interface{}) (map[string]interface{}, error) { panic("not implemented") } +// MapNestedStringInterface is the resolver for the mapNestedStringInterface field. func (r *queryResolver) MapNestedStringInterface(ctx context.Context, in *NestedMapInput) (map[string]interface{}, error) { panic("not implemented") } +// ErrorBubble is the resolver for the errorBubble field. func (r *queryResolver) ErrorBubble(ctx context.Context) (*Error, error) { panic("not implemented") } +// ErrorBubbleList is the resolver for the errorBubbleList field. func (r *queryResolver) ErrorBubbleList(ctx context.Context) ([]*Error, error) { panic("not implemented") } +// ErrorList is the resolver for the errorList field. func (r *queryResolver) ErrorList(ctx context.Context) ([]*Error, error) { panic("not implemented") } +// Errors is the resolver for the errors field. func (r *queryResolver) Errors(ctx context.Context) (*Errors, error) { panic("not implemented") } +// Valid is the resolver for the valid field. func (r *queryResolver) Valid(ctx context.Context) (string, error) { panic("not implemented") } +// Invalid is the resolver for the invalid field. func (r *queryResolver) Invalid(ctx context.Context) (string, error) { panic("not implemented") } +// Panics is the resolver for the panics field. func (r *queryResolver) Panics(ctx context.Context) (*Panics, error) { panic("not implemented") } +// PrimitiveObject is the resolver for the primitiveObject field. func (r *queryResolver) PrimitiveObject(ctx context.Context) ([]Primitive, error) { panic("not implemented") } +// PrimitiveStringObject is the resolver for the primitiveStringObject field. func (r *queryResolver) PrimitiveStringObject(ctx context.Context) ([]PrimitiveString, error) { panic("not implemented") } +// PtrToSliceContainer is the resolver for the ptrToSliceContainer field. func (r *queryResolver) PtrToSliceContainer(ctx context.Context) (*PtrToSliceContainer, error) { panic("not implemented") } +// Infinity is the resolver for the infinity field. func (r *queryResolver) Infinity(ctx context.Context) (float64, error) { panic("not implemented") } +// StringFromContextInterface is the resolver for the stringFromContextInterface field. func (r *queryResolver) StringFromContextInterface(ctx context.Context) (*StringFromContextInterface, error) { panic("not implemented") } +// StringFromContextFunction is the resolver for the stringFromContextFunction field. func (r *queryResolver) StringFromContextFunction(ctx context.Context) (string, error) { panic("not implemented") } +// DefaultScalar is the resolver for the defaultScalar field. func (r *queryResolver) DefaultScalar(ctx context.Context, arg string) (string, error) { panic("not implemented") } +// Slices is the resolver for the slices field. func (r *queryResolver) Slices(ctx context.Context) (*Slices, error) { panic("not implemented") } +// ScalarSlice is the resolver for the scalarSlice field. func (r *queryResolver) ScalarSlice(ctx context.Context) ([]byte, error) { panic("not implemented") } +// Fallback is the resolver for the fallback field. func (r *queryResolver) Fallback(ctx context.Context, arg FallbackToStringEncoding) (FallbackToStringEncoding, error) { panic("not implemented") } +// OptionalUnion is the resolver for the optionalUnion field. func (r *queryResolver) OptionalUnion(ctx context.Context) (TestUnion, error) { panic("not implemented") } +// VOkCaseValue is the resolver for the vOkCaseValue field. func (r *queryResolver) VOkCaseValue(ctx context.Context) (*VOkCaseValue, error) { panic("not implemented") } +// VOkCaseNil is the resolver for the vOkCaseNil field. func (r *queryResolver) VOkCaseNil(ctx context.Context) (*VOkCaseNil, error) { panic("not implemented") } +// ValidType is the resolver for the validType field. func (r *queryResolver) ValidType(ctx context.Context) (*ValidType, error) { panic("not implemented") } +// VariadicModel is the resolver for the variadicModel field. func (r *queryResolver) VariadicModel(ctx context.Context) (*VariadicModel, error) { panic("not implemented") } +// WrappedStruct is the resolver for the wrappedStruct field. func (r *queryResolver) WrappedStruct(ctx context.Context) (*WrappedStruct, error) { panic("not implemented") } +// WrappedScalar is the resolver for the wrappedScalar field. func (r *queryResolver) WrappedScalar(ctx context.Context) (otherpkg.Scalar, error) { panic("not implemented") } +// WrappedMap is the resolver for the wrappedMap field. func (r *queryResolver) WrappedMap(ctx context.Context) (WrappedMap, error) { panic("not implemented") } +// WrappedSlice is the resolver for the wrappedSlice field. func (r *queryResolver) WrappedSlice(ctx context.Context) (WrappedSlice, error) { panic("not implemented") } +// Updated is the resolver for the updated field. func (r *subscriptionResolver) Updated(ctx context.Context) (<-chan string, error) { panic("not implemented") } +// InitPayload is the resolver for the initPayload field. func (r *subscriptionResolver) InitPayload(ctx context.Context) (<-chan string, error) { panic("not implemented") } +// DirectiveArg is the resolver for the directiveArg field. func (r *subscriptionResolver) DirectiveArg(ctx context.Context, arg string) (<-chan *string, error) { panic("not implemented") } +// DirectiveNullableArg is the resolver for the directiveNullableArg field. func (r *subscriptionResolver) DirectiveNullableArg(ctx context.Context, arg *int, arg2 *int, arg3 *string) (<-chan *string, error) { panic("not implemented") } +// DirectiveDouble is the resolver for the directiveDouble field. func (r *subscriptionResolver) DirectiveDouble(ctx context.Context) (<-chan *string, error) { panic("not implemented") } +// DirectiveUnimplemented is the resolver for the directiveUnimplemented field. func (r *subscriptionResolver) DirectiveUnimplemented(ctx context.Context) (<-chan *string, error) { panic("not implemented") } +// Issue896b is the resolver for the issue896b field. func (r *subscriptionResolver) Issue896b(ctx context.Context) (<-chan []*CheckIssue896, error) { panic("not implemented") } +// ErrorRequired is the resolver for the errorRequired field. func (r *subscriptionResolver) ErrorRequired(ctx context.Context) (<-chan *Error, error) { panic("not implemented") } +// Friends is the resolver for the friends field. func (r *userResolver) Friends(ctx context.Context, obj *User) ([]*User, error) { panic("not implemented") } +// Pets is the resolver for the pets field. func (r *userResolver) Pets(ctx context.Context, obj *User, limit *int) ([]*Pet, error) { panic("not implemented") } +// Get is the resolver for the get field. func (r *wrappedMapResolver) Get(ctx context.Context, obj WrappedMap, key string) (string, error) { panic("not implemented") } +// Get is the resolver for the get field. func (r *wrappedSliceResolver) Get(ctx context.Context, obj WrappedSlice, idx int) (string, error) { panic("not implemented") } diff --git a/codegen/testserver/singlefile/resolver.go b/codegen/testserver/singlefile/resolver.go index cd0db6db56b..219c6ce774c 100644 --- a/codegen/testserver/singlefile/resolver.go +++ b/codegen/testserver/singlefile/resolver.go @@ -12,398 +12,497 @@ import ( type Resolver struct{} +// ID is the resolver for the id field. func (r *backedByInterfaceResolver) ID(ctx context.Context, obj BackedByInterface) (string, error) { panic("not implemented") } +// A is the resolver for the a field. func (r *errorsResolver) A(ctx context.Context, obj *Errors) (*Error, error) { panic("not implemented") } +// B is the resolver for the b field. func (r *errorsResolver) B(ctx context.Context, obj *Errors) (*Error, error) { panic("not implemented") } +// C is the resolver for the c field. func (r *errorsResolver) C(ctx context.Context, obj *Errors) (*Error, error) { panic("not implemented") } +// D is the resolver for the d field. func (r *errorsResolver) D(ctx context.Context, obj *Errors) (*Error, error) { panic("not implemented") } +// E is the resolver for the e field. func (r *errorsResolver) E(ctx context.Context, obj *Errors) (*Error, error) { panic("not implemented") } +// Field is the resolver for the field field. func (r *forcedResolverResolver) Field(ctx context.Context, obj *ForcedResolver) (*Circle, error) { panic("not implemented") } +// ResolverField is the resolver for the resolverField field. func (r *modelMethodsResolver) ResolverField(ctx context.Context, obj *ModelMethods) (bool, error) { panic("not implemented") } +// DefaultInput is the resolver for the defaultInput field. func (r *mutationResolver) DefaultInput(ctx context.Context, input DefaultInput) (*DefaultParametersMirror, error) { panic("not implemented") } +// OverrideValueViaInput is the resolver for the overrideValueViaInput field. func (r *mutationResolver) OverrideValueViaInput(ctx context.Context, input FieldsOrderInput) (*FieldsOrderPayload, error) { panic("not implemented") } +// UpdateSomething is the resolver for the updateSomething field. func (r *mutationResolver) UpdateSomething(ctx context.Context, input SpecialInput) (string, error) { panic("not implemented") } +// UpdatePtrToPtr is the resolver for the updatePtrToPtr field. func (r *mutationResolver) UpdatePtrToPtr(ctx context.Context, input UpdatePtrToPtrOuter) (*PtrToPtrOuter, error) { panic("not implemented") } +// OldFoo is the resolver for the oldFoo field. func (r *overlappingFieldsResolver) OldFoo(ctx context.Context, obj *OverlappingFields) (int, error) { panic("not implemented") } +// FieldScalarMarshal is the resolver for the fieldScalarMarshal field. func (r *panicsResolver) FieldScalarMarshal(ctx context.Context, obj *Panics) ([]MarshalPanic, error) { panic("not implemented") } +// ArgUnmarshal is the resolver for the argUnmarshal field. func (r *panicsResolver) ArgUnmarshal(ctx context.Context, obj *Panics, u []MarshalPanic) (bool, error) { panic("not implemented") } +// Friends is the resolver for the friends field. func (r *petResolver) Friends(ctx context.Context, obj *Pet, limit *int) ([]*Pet, error) { panic("not implemented") } +// Value is the resolver for the value field. func (r *primitiveResolver) Value(ctx context.Context, obj *Primitive) (int, error) { panic("not implemented") } +// Value is the resolver for the value field. func (r *primitiveStringResolver) Value(ctx context.Context, obj *PrimitiveString) (string, error) { panic("not implemented") } +// Len is the resolver for the len field. func (r *primitiveStringResolver) Len(ctx context.Context, obj *PrimitiveString) (int, error) { panic("not implemented") } +// InvalidIdentifier is the resolver for the invalidIdentifier field. func (r *queryResolver) InvalidIdentifier(ctx context.Context) (*invalid_packagename.InvalidIdentifier, error) { panic("not implemented") } +// Collision is the resolver for the collision field. func (r *queryResolver) Collision(ctx context.Context) (*introspection1.It, error) { panic("not implemented") } +// MapInput is the resolver for the mapInput field. func (r *queryResolver) MapInput(ctx context.Context, input map[string]interface{}) (*bool, error) { panic("not implemented") } +// Recursive is the resolver for the recursive field. func (r *queryResolver) Recursive(ctx context.Context, input *RecursiveInputSlice) (*bool, error) { panic("not implemented") } +// NestedInputs is the resolver for the nestedInputs field. func (r *queryResolver) NestedInputs(ctx context.Context, input [][]*OuterInput) (*bool, error) { panic("not implemented") } +// NestedOutputs is the resolver for the nestedOutputs field. func (r *queryResolver) NestedOutputs(ctx context.Context) ([][]*OuterObject, error) { panic("not implemented") } +// ModelMethods is the resolver for the modelMethods field. func (r *queryResolver) ModelMethods(ctx context.Context) (*ModelMethods, error) { panic("not implemented") } +// User is the resolver for the user field. func (r *queryResolver) User(ctx context.Context, id int) (*User, error) { panic("not implemented") } +// NullableArg is the resolver for the nullableArg field. func (r *queryResolver) NullableArg(ctx context.Context, arg *int) (*string, error) { panic("not implemented") } +// InputSlice is the resolver for the inputSlice field. func (r *queryResolver) InputSlice(ctx context.Context, arg []string) (bool, error) { panic("not implemented") } +// InputNullableSlice is the resolver for the inputNullableSlice field. func (r *queryResolver) InputNullableSlice(ctx context.Context, arg []string) (bool, error) { panic("not implemented") } +// InputOmittable is the resolver for the inputOmittable field. func (r *queryResolver) InputOmittable(ctx context.Context, arg OmittableInput) (string, error) { panic("not implemented") } +// ShapeUnion is the resolver for the shapeUnion field. func (r *queryResolver) ShapeUnion(ctx context.Context) (ShapeUnion, error) { panic("not implemented") } +// Autobind is the resolver for the autobind field. func (r *queryResolver) Autobind(ctx context.Context) (*Autobind, error) { panic("not implemented") } +// DeprecatedField is the resolver for the deprecatedField field. func (r *queryResolver) DeprecatedField(ctx context.Context) (string, error) { panic("not implemented") } +// Overlapping is the resolver for the overlapping field. func (r *queryResolver) Overlapping(ctx context.Context) (*OverlappingFields, error) { panic("not implemented") } +// DefaultParameters is the resolver for the defaultParameters field. func (r *queryResolver) DefaultParameters(ctx context.Context, falsyBoolean *bool, truthyBoolean *bool) (*DefaultParametersMirror, error) { panic("not implemented") } +// DirectiveArg is the resolver for the directiveArg field. func (r *queryResolver) DirectiveArg(ctx context.Context, arg string) (*string, error) { panic("not implemented") } +// DirectiveNullableArg is the resolver for the directiveNullableArg field. func (r *queryResolver) DirectiveNullableArg(ctx context.Context, arg *int, arg2 *int, arg3 *string) (*string, error) { panic("not implemented") } +// DirectiveInputNullable is the resolver for the directiveInputNullable field. func (r *queryResolver) DirectiveInputNullable(ctx context.Context, arg *InputDirectives) (*string, error) { panic("not implemented") } +// DirectiveInput is the resolver for the directiveInput field. func (r *queryResolver) DirectiveInput(ctx context.Context, arg InputDirectives) (*string, error) { panic("not implemented") } +// DirectiveInputType is the resolver for the directiveInputType field. func (r *queryResolver) DirectiveInputType(ctx context.Context, arg InnerInput) (*string, error) { panic("not implemented") } +// DirectiveObject is the resolver for the directiveObject field. func (r *queryResolver) DirectiveObject(ctx context.Context) (*ObjectDirectives, error) { panic("not implemented") } +// DirectiveObjectWithCustomGoModel is the resolver for the directiveObjectWithCustomGoModel field. func (r *queryResolver) DirectiveObjectWithCustomGoModel(ctx context.Context) (*ObjectDirectivesWithCustomGoModel, error) { panic("not implemented") } +// DirectiveFieldDef is the resolver for the directiveFieldDef field. func (r *queryResolver) DirectiveFieldDef(ctx context.Context, ret string) (string, error) { panic("not implemented") } +// DirectiveField is the resolver for the directiveField field. func (r *queryResolver) DirectiveField(ctx context.Context) (*string, error) { panic("not implemented") } +// DirectiveDouble is the resolver for the directiveDouble field. func (r *queryResolver) DirectiveDouble(ctx context.Context) (*string, error) { panic("not implemented") } +// DirectiveUnimplemented is the resolver for the directiveUnimplemented field. func (r *queryResolver) DirectiveUnimplemented(ctx context.Context) (*string, error) { panic("not implemented") } +// EmbeddedCase1 is the resolver for the embeddedCase1 field. func (r *queryResolver) EmbeddedCase1(ctx context.Context) (*EmbeddedCase1, error) { panic("not implemented") } +// EmbeddedCase2 is the resolver for the embeddedCase2 field. func (r *queryResolver) EmbeddedCase2(ctx context.Context) (*EmbeddedCase2, error) { panic("not implemented") } +// EmbeddedCase3 is the resolver for the embeddedCase3 field. func (r *queryResolver) EmbeddedCase3(ctx context.Context) (*EmbeddedCase3, error) { panic("not implemented") } +// EnumInInput is the resolver for the enumInInput field. func (r *queryResolver) EnumInInput(ctx context.Context, input *InputWithEnumValue) (EnumTest, error) { panic("not implemented") } +// Shapes is the resolver for the shapes field. func (r *queryResolver) Shapes(ctx context.Context) ([]Shape, error) { panic("not implemented") } +// NoShape is the resolver for the noShape field. func (r *queryResolver) NoShape(ctx context.Context) (Shape, error) { panic("not implemented") } +// Node is the resolver for the node field. func (r *queryResolver) Node(ctx context.Context) (Node, error) { panic("not implemented") } +// NoShapeTypedNil is the resolver for the noShapeTypedNil field. func (r *queryResolver) NoShapeTypedNil(ctx context.Context) (Shape, error) { panic("not implemented") } +// Animal is the resolver for the animal field. func (r *queryResolver) Animal(ctx context.Context) (Animal, error) { panic("not implemented") } +// NotAnInterface is the resolver for the notAnInterface field. func (r *queryResolver) NotAnInterface(ctx context.Context) (BackedByInterface, error) { panic("not implemented") } +// Dog is the resolver for the dog field. func (r *queryResolver) Dog(ctx context.Context) (*Dog, error) { panic("not implemented") } +// Issue896a is the resolver for the issue896a field. func (r *queryResolver) Issue896a(ctx context.Context) ([]*CheckIssue896, error) { panic("not implemented") } +// MapStringInterface is the resolver for the mapStringInterface field. func (r *queryResolver) MapStringInterface(ctx context.Context, in map[string]interface{}) (map[string]interface{}, error) { panic("not implemented") } +// MapNestedStringInterface is the resolver for the mapNestedStringInterface field. func (r *queryResolver) MapNestedStringInterface(ctx context.Context, in *NestedMapInput) (map[string]interface{}, error) { panic("not implemented") } +// ErrorBubble is the resolver for the errorBubble field. func (r *queryResolver) ErrorBubble(ctx context.Context) (*Error, error) { panic("not implemented") } +// ErrorBubbleList is the resolver for the errorBubbleList field. func (r *queryResolver) ErrorBubbleList(ctx context.Context) ([]*Error, error) { panic("not implemented") } +// ErrorList is the resolver for the errorList field. func (r *queryResolver) ErrorList(ctx context.Context) ([]*Error, error) { panic("not implemented") } +// Errors is the resolver for the errors field. func (r *queryResolver) Errors(ctx context.Context) (*Errors, error) { panic("not implemented") } +// Valid is the resolver for the valid field. func (r *queryResolver) Valid(ctx context.Context) (string, error) { panic("not implemented") } +// Invalid is the resolver for the invalid field. func (r *queryResolver) Invalid(ctx context.Context) (string, error) { panic("not implemented") } +// Panics is the resolver for the panics field. func (r *queryResolver) Panics(ctx context.Context) (*Panics, error) { panic("not implemented") } +// PrimitiveObject is the resolver for the primitiveObject field. func (r *queryResolver) PrimitiveObject(ctx context.Context) ([]Primitive, error) { panic("not implemented") } +// PrimitiveStringObject is the resolver for the primitiveStringObject field. func (r *queryResolver) PrimitiveStringObject(ctx context.Context) ([]PrimitiveString, error) { panic("not implemented") } +// PtrToSliceContainer is the resolver for the ptrToSliceContainer field. func (r *queryResolver) PtrToSliceContainer(ctx context.Context) (*PtrToSliceContainer, error) { panic("not implemented") } +// Infinity is the resolver for the infinity field. func (r *queryResolver) Infinity(ctx context.Context) (float64, error) { panic("not implemented") } +// StringFromContextInterface is the resolver for the stringFromContextInterface field. func (r *queryResolver) StringFromContextInterface(ctx context.Context) (*StringFromContextInterface, error) { panic("not implemented") } +// StringFromContextFunction is the resolver for the stringFromContextFunction field. func (r *queryResolver) StringFromContextFunction(ctx context.Context) (string, error) { panic("not implemented") } +// DefaultScalar is the resolver for the defaultScalar field. func (r *queryResolver) DefaultScalar(ctx context.Context, arg string) (string, error) { panic("not implemented") } +// Slices is the resolver for the slices field. func (r *queryResolver) Slices(ctx context.Context) (*Slices, error) { panic("not implemented") } +// ScalarSlice is the resolver for the scalarSlice field. func (r *queryResolver) ScalarSlice(ctx context.Context) ([]byte, error) { panic("not implemented") } +// Fallback is the resolver for the fallback field. func (r *queryResolver) Fallback(ctx context.Context, arg FallbackToStringEncoding) (FallbackToStringEncoding, error) { panic("not implemented") } +// OptionalUnion is the resolver for the optionalUnion field. func (r *queryResolver) OptionalUnion(ctx context.Context) (TestUnion, error) { panic("not implemented") } +// VOkCaseValue is the resolver for the vOkCaseValue field. func (r *queryResolver) VOkCaseValue(ctx context.Context) (*VOkCaseValue, error) { panic("not implemented") } +// VOkCaseNil is the resolver for the vOkCaseNil field. func (r *queryResolver) VOkCaseNil(ctx context.Context) (*VOkCaseNil, error) { panic("not implemented") } +// ValidType is the resolver for the validType field. func (r *queryResolver) ValidType(ctx context.Context) (*ValidType, error) { panic("not implemented") } +// VariadicModel is the resolver for the variadicModel field. func (r *queryResolver) VariadicModel(ctx context.Context) (*VariadicModel, error) { panic("not implemented") } +// WrappedStruct is the resolver for the wrappedStruct field. func (r *queryResolver) WrappedStruct(ctx context.Context) (*WrappedStruct, error) { panic("not implemented") } +// WrappedScalar is the resolver for the wrappedScalar field. func (r *queryResolver) WrappedScalar(ctx context.Context) (otherpkg.Scalar, error) { panic("not implemented") } +// WrappedMap is the resolver for the wrappedMap field. func (r *queryResolver) WrappedMap(ctx context.Context) (WrappedMap, error) { panic("not implemented") } +// WrappedSlice is the resolver for the wrappedSlice field. func (r *queryResolver) WrappedSlice(ctx context.Context) (WrappedSlice, error) { panic("not implemented") } +// Updated is the resolver for the updated field. func (r *subscriptionResolver) Updated(ctx context.Context) (<-chan string, error) { panic("not implemented") } +// InitPayload is the resolver for the initPayload field. func (r *subscriptionResolver) InitPayload(ctx context.Context) (<-chan string, error) { panic("not implemented") } +// DirectiveArg is the resolver for the directiveArg field. func (r *subscriptionResolver) DirectiveArg(ctx context.Context, arg string) (<-chan *string, error) { panic("not implemented") } +// DirectiveNullableArg is the resolver for the directiveNullableArg field. func (r *subscriptionResolver) DirectiveNullableArg(ctx context.Context, arg *int, arg2 *int, arg3 *string) (<-chan *string, error) { panic("not implemented") } +// DirectiveDouble is the resolver for the directiveDouble field. func (r *subscriptionResolver) DirectiveDouble(ctx context.Context) (<-chan *string, error) { panic("not implemented") } +// DirectiveUnimplemented is the resolver for the directiveUnimplemented field. func (r *subscriptionResolver) DirectiveUnimplemented(ctx context.Context) (<-chan *string, error) { panic("not implemented") } +// Issue896b is the resolver for the issue896b field. func (r *subscriptionResolver) Issue896b(ctx context.Context) (<-chan []*CheckIssue896, error) { panic("not implemented") } +// ErrorRequired is the resolver for the errorRequired field. func (r *subscriptionResolver) ErrorRequired(ctx context.Context) (<-chan *Error, error) { panic("not implemented") } +// Friends is the resolver for the friends field. func (r *userResolver) Friends(ctx context.Context, obj *User) ([]*User, error) { panic("not implemented") } +// Pets is the resolver for the pets field. func (r *userResolver) Pets(ctx context.Context, obj *User, limit *int) ([]*Pet, error) { panic("not implemented") } +// Get is the resolver for the get field. func (r *wrappedMapResolver) Get(ctx context.Context, obj WrappedMap, key string) (string, error) { panic("not implemented") } +// Get is the resolver for the get field. func (r *wrappedSliceResolver) Get(ctx context.Context, obj WrappedSlice, idx int) (string, error) { panic("not implemented") }