github.com/spread-ai/gqlgen@v0.0.0-20221124102857-a6c8ef538a1d/plugin/resolvergen/testdata/followschema/out/schema.resolvers.go (about) 1 package customresolver 2 3 // This file will be automatically regenerated based on the schema, any resolver implementations 4 // will be copied through when generating and any unknown code will be moved to the end. 5 6 import ( 7 "context" 8 9 customresolver "github.com/spread-ai/gqlgen/plugin/resolvergen/testdata/singlefile/out" 10 ) 11 12 // Resolver is the resolver for the resolver field. 13 func (r *queryCustomResolverType) Resolver(ctx context.Context) (*customresolver.Resolver, error) { 14 // CustomerResolverType.Resolver implementation 15 return nil, nil 16 } 17 18 // Name is the resolver for the name field. 19 func (r *resolverCustomResolverType) Name(ctx context.Context, obj *customresolver.Resolver) (string, error) { 20 // CustomerResolverType.Name implementation 21 return "", nil 22 } 23 24 // Query returns customresolver.QueryResolver implementation. 25 func (r *CustomResolverType) Query() customresolver.QueryResolver { return &queryCustomResolverType{r} } 26 27 // Resolver returns customresolver.ResolverResolver implementation. 28 func (r *CustomResolverType) Resolver() customresolver.ResolverResolver { 29 return &resolverCustomResolverType{r} 30 } 31 32 type queryCustomResolverType struct{ *CustomResolverType } 33 type resolverCustomResolverType struct{ *CustomResolverType } 34 35 // !!! WARNING !!! 36 // The code below was going to be deleted when updating resolvers. It has been copied here so you have 37 // one last chance to move it out of harms way if you want. There are two reasons this happens: 38 // - When renaming or deleting a resolver the old code will be put in here. You can safely delete 39 // it when you're done. 40 // - You have helper methods in this file. Move them out to keep these resolver files clean. 41 func AUserHelperFunction() { 42 // AUserHelperFunction implementation 43 }