github.com/luciferinlove/gqlgen@v0.17.16-bzc.1/codegen/testserver/singlefile/generated.go (about) 1 // Code generated by github.com/luciferinlove/gqlgen, DO NOT EDIT. 2 3 package singlefile 4 5 import ( 6 "bytes" 7 "context" 8 "embed" 9 "errors" 10 "fmt" 11 "io" 12 "strconv" 13 "sync" 14 "sync/atomic" 15 "time" 16 17 introspection1 "github.com/luciferinlove/gqlgen/codegen/testserver/singlefile/introspection" 18 invalid_packagename "github.com/luciferinlove/gqlgen/codegen/testserver/singlefile/invalid-packagename" 19 "github.com/luciferinlove/gqlgen/codegen/testserver/singlefile/otherpkg" 20 "github.com/luciferinlove/gqlgen/graphql" 21 "github.com/luciferinlove/gqlgen/graphql/introspection" 22 gqlparser "github.com/vektah/gqlparser/v2" 23 "github.com/vektah/gqlparser/v2/ast" 24 ) 25 26 // region ************************** generated!.gotpl ************************** 27 28 // NewExecutableSchema creates an ExecutableSchema from the ResolverRoot interface. 29 func NewExecutableSchema(cfg Config) graphql.ExecutableSchema { 30 return &executableSchema{ 31 resolvers: cfg.Resolvers, 32 directives: cfg.Directives, 33 complexity: cfg.Complexity, 34 } 35 } 36 37 type Config struct { 38 Resolvers ResolverRoot 39 Directives DirectiveRoot 40 Complexity ComplexityRoot 41 } 42 43 type ResolverRoot interface { 44 BackedByInterface() BackedByInterfaceResolver 45 Errors() ErrorsResolver 46 ForcedResolver() ForcedResolverResolver 47 ModelMethods() ModelMethodsResolver 48 Mutation() MutationResolver 49 OverlappingFields() OverlappingFieldsResolver 50 Panics() PanicsResolver 51 Pet() PetResolver 52 Primitive() PrimitiveResolver 53 PrimitiveString() PrimitiveStringResolver 54 Query() QueryResolver 55 Subscription() SubscriptionResolver 56 User() UserResolver 57 WrappedMap() WrappedMapResolver 58 WrappedSlice() WrappedSliceResolver 59 FieldsOrderInput() FieldsOrderInputResolver 60 } 61 62 type DirectiveRoot struct { 63 Custom func(ctx context.Context, obj interface{}, next graphql.Resolver) (res interface{}, err error) 64 Directive1 func(ctx context.Context, obj interface{}, next graphql.Resolver) (res interface{}, err error) 65 Directive2 func(ctx context.Context, obj interface{}, next graphql.Resolver) (res interface{}, err error) 66 Directive3 func(ctx context.Context, obj interface{}, next graphql.Resolver) (res interface{}, err error) 67 Length func(ctx context.Context, obj interface{}, next graphql.Resolver, min int, max *int, message *string) (res interface{}, err error) 68 Logged func(ctx context.Context, obj interface{}, next graphql.Resolver, id string) (res interface{}, err error) 69 MakeNil func(ctx context.Context, obj interface{}, next graphql.Resolver) (res interface{}, err error) 70 MakeTypedNil func(ctx context.Context, obj interface{}, next graphql.Resolver) (res interface{}, err error) 71 Order1 func(ctx context.Context, obj interface{}, next graphql.Resolver, location string) (res interface{}, err error) 72 Order2 func(ctx context.Context, obj interface{}, next graphql.Resolver, location string) (res interface{}, err error) 73 Range func(ctx context.Context, obj interface{}, next graphql.Resolver, min *int, max *int) (res interface{}, err error) 74 ToNull func(ctx context.Context, obj interface{}, next graphql.Resolver) (res interface{}, err error) 75 Unimplemented func(ctx context.Context, obj interface{}, next graphql.Resolver) (res interface{}, err error) 76 } 77 78 type ComplexityRoot struct { 79 A struct { 80 ID func(childComplexity int) int 81 } 82 83 AIt struct { 84 ID func(childComplexity int) int 85 } 86 87 AbIt struct { 88 ID func(childComplexity int) int 89 } 90 91 Autobind struct { 92 IdInt func(childComplexity int) int 93 IdStr func(childComplexity int) int 94 Int func(childComplexity int) int 95 Int32 func(childComplexity int) int 96 Int64 func(childComplexity int) int 97 } 98 99 B struct { 100 ID func(childComplexity int) int 101 } 102 103 BackedByInterface struct { 104 ID func(childComplexity int) int 105 ThisShouldBind func(childComplexity int) int 106 ThisShouldBindWithError func(childComplexity int) int 107 } 108 109 Cat struct { 110 CatBreed func(childComplexity int) int 111 Species func(childComplexity int) int 112 } 113 114 CheckIssue896 struct { 115 ID func(childComplexity int) int 116 } 117 118 Circle struct { 119 Area func(childComplexity int) int 120 Coordinates func(childComplexity int) int 121 Radius func(childComplexity int) int 122 } 123 124 ConcreteNodeA struct { 125 Child func(childComplexity int) int 126 ID func(childComplexity int) int 127 Name func(childComplexity int) int 128 } 129 130 ConcreteNodeInterface struct { 131 Child func(childComplexity int) int 132 ID func(childComplexity int) int 133 } 134 135 Content_Post struct { 136 Foo func(childComplexity int) int 137 } 138 139 Content_User struct { 140 Foo func(childComplexity int) int 141 } 142 143 Coordinates struct { 144 X func(childComplexity int) int 145 Y func(childComplexity int) int 146 } 147 148 DefaultParametersMirror struct { 149 FalsyBoolean func(childComplexity int) int 150 TruthyBoolean func(childComplexity int) int 151 } 152 153 Dog struct { 154 DogBreed func(childComplexity int) int 155 Species func(childComplexity int) int 156 } 157 158 EmbeddedCase1 struct { 159 ExportedEmbeddedPointerExportedMethod func(childComplexity int) int 160 } 161 162 EmbeddedCase2 struct { 163 UnexportedEmbeddedPointerExportedMethod func(childComplexity int) int 164 } 165 166 EmbeddedCase3 struct { 167 UnexportedEmbeddedInterfaceExportedMethod func(childComplexity int) int 168 } 169 170 EmbeddedDefaultScalar struct { 171 Value func(childComplexity int) int 172 } 173 174 EmbeddedPointer struct { 175 ID func(childComplexity int) int 176 Title func(childComplexity int) int 177 } 178 179 Error struct { 180 ErrorOnNonRequiredField func(childComplexity int) int 181 ErrorOnRequiredField func(childComplexity int) int 182 ID func(childComplexity int) int 183 NilOnRequiredField func(childComplexity int) int 184 } 185 186 Errors struct { 187 A func(childComplexity int) int 188 B func(childComplexity int) int 189 C func(childComplexity int) int 190 D func(childComplexity int) int 191 E func(childComplexity int) int 192 } 193 194 FieldsOrderPayload struct { 195 FirstFieldValue func(childComplexity int) int 196 } 197 198 ForcedResolver struct { 199 Field func(childComplexity int) int 200 } 201 202 InnerObject struct { 203 ID func(childComplexity int) int 204 } 205 206 InvalidIdentifier struct { 207 ID func(childComplexity int) int 208 } 209 210 It struct { 211 ID func(childComplexity int) int 212 } 213 214 LoopA struct { 215 B func(childComplexity int) int 216 } 217 218 LoopB struct { 219 A func(childComplexity int) int 220 } 221 222 Map struct { 223 ID func(childComplexity int) int 224 } 225 226 MapStringInterfaceType struct { 227 A func(childComplexity int) int 228 B func(childComplexity int) int 229 } 230 231 ModelMethods struct { 232 NoContext func(childComplexity int) int 233 ResolverField func(childComplexity int) int 234 WithContext func(childComplexity int) int 235 } 236 237 Mutation struct { 238 DefaultInput func(childComplexity int, input DefaultInput) int 239 OverrideValueViaInput func(childComplexity int, input FieldsOrderInput) int 240 UpdatePtrToPtr func(childComplexity int, input UpdatePtrToPtrOuter) int 241 UpdateSomething func(childComplexity int, input SpecialInput) int 242 } 243 244 ObjectDirectives struct { 245 NullableText func(childComplexity int) int 246 Order func(childComplexity int) int 247 Text func(childComplexity int) int 248 } 249 250 ObjectDirectivesWithCustomGoModel struct { 251 NullableText func(childComplexity int) int 252 } 253 254 OuterObject struct { 255 Inner func(childComplexity int) int 256 } 257 258 OverlappingFields struct { 259 Foo func(childComplexity int) int 260 NewFoo func(childComplexity int) int 261 OldFoo func(childComplexity int) int 262 } 263 264 Panics struct { 265 ArgUnmarshal func(childComplexity int, u []MarshalPanic) int 266 FieldFuncMarshal func(childComplexity int, u []MarshalPanic) int 267 FieldScalarMarshal func(childComplexity int) int 268 } 269 270 Pet struct { 271 Friends func(childComplexity int, limit *int) int 272 ID func(childComplexity int) int 273 } 274 275 Primitive struct { 276 Squared func(childComplexity int) int 277 Value func(childComplexity int) int 278 } 279 280 PrimitiveString struct { 281 Doubled func(childComplexity int) int 282 Len func(childComplexity int) int 283 Value func(childComplexity int) int 284 } 285 286 PtrToPtrInner struct { 287 Key func(childComplexity int) int 288 Value func(childComplexity int) int 289 } 290 291 PtrToPtrOuter struct { 292 Inner func(childComplexity int) int 293 Name func(childComplexity int) int 294 StupidInner func(childComplexity int) int 295 } 296 297 PtrToSliceContainer struct { 298 PtrToSlice func(childComplexity int) int 299 } 300 301 Query struct { 302 Animal func(childComplexity int) int 303 Autobind func(childComplexity int) int 304 Collision func(childComplexity int) int 305 DefaultParameters func(childComplexity int, falsyBoolean *bool, truthyBoolean *bool) int 306 DefaultScalar func(childComplexity int, arg string) int 307 DeprecatedField func(childComplexity int) int 308 DirectiveArg func(childComplexity int, arg string) int 309 DirectiveDouble func(childComplexity int) int 310 DirectiveField func(childComplexity int) int 311 DirectiveFieldDef func(childComplexity int, ret string) int 312 DirectiveInput func(childComplexity int, arg InputDirectives) int 313 DirectiveInputNullable func(childComplexity int, arg *InputDirectives) int 314 DirectiveInputType func(childComplexity int, arg InnerInput) int 315 DirectiveNullableArg func(childComplexity int, arg *int, arg2 *int, arg3 *string) int 316 DirectiveObject func(childComplexity int) int 317 DirectiveObjectWithCustomGoModel func(childComplexity int) int 318 DirectiveUnimplemented func(childComplexity int) int 319 EmbeddedCase1 func(childComplexity int) int 320 EmbeddedCase2 func(childComplexity int) int 321 EmbeddedCase3 func(childComplexity int) int 322 EnumInInput func(childComplexity int, input *InputWithEnumValue) int 323 ErrorBubble func(childComplexity int) int 324 ErrorBubbleList func(childComplexity int) int 325 ErrorList func(childComplexity int) int 326 Errors func(childComplexity int) int 327 Fallback func(childComplexity int, arg FallbackToStringEncoding) int 328 Infinity func(childComplexity int) int 329 InputNullableSlice func(childComplexity int, arg []string) int 330 InputSlice func(childComplexity int, arg []string) int 331 InvalidIdentifier func(childComplexity int) int 332 Issue896a func(childComplexity int) int 333 MapInput func(childComplexity int, input map[string]interface{}) int 334 MapNestedStringInterface func(childComplexity int, in *NestedMapInput) int 335 MapStringInterface func(childComplexity int, in map[string]interface{}) int 336 ModelMethods func(childComplexity int) int 337 NestedInputs func(childComplexity int, input [][]*OuterInput) int 338 NestedOutputs func(childComplexity int) int 339 NoShape func(childComplexity int) int 340 NoShapeTypedNil func(childComplexity int) int 341 Node func(childComplexity int) int 342 NotAnInterface func(childComplexity int) int 343 NullableArg func(childComplexity int, arg *int) int 344 OptionalUnion func(childComplexity int) int 345 Overlapping func(childComplexity int) int 346 Panics func(childComplexity int) int 347 PrimitiveObject func(childComplexity int) int 348 PrimitiveStringObject func(childComplexity int) int 349 PtrToSliceContainer func(childComplexity int) int 350 Recursive func(childComplexity int, input *RecursiveInputSlice) int 351 ScalarSlice func(childComplexity int) int 352 ShapeUnion func(childComplexity int) int 353 Shapes func(childComplexity int) int 354 Slices func(childComplexity int) int 355 StringFromContextFunction func(childComplexity int) int 356 StringFromContextInterface func(childComplexity int) int 357 User func(childComplexity int, id int) int 358 VOkCaseNil func(childComplexity int) int 359 VOkCaseValue func(childComplexity int) int 360 Valid func(childComplexity int) int 361 ValidType func(childComplexity int) int 362 VariadicModel func(childComplexity int) int 363 WrappedMap func(childComplexity int) int 364 WrappedScalar func(childComplexity int) int 365 WrappedSlice func(childComplexity int) int 366 WrappedStruct func(childComplexity int) int 367 } 368 369 Rectangle struct { 370 Area func(childComplexity int) int 371 Coordinates func(childComplexity int) int 372 Length func(childComplexity int) int 373 Width func(childComplexity int) int 374 } 375 376 Slices struct { 377 Test1 func(childComplexity int) int 378 Test2 func(childComplexity int) int 379 Test3 func(childComplexity int) int 380 Test4 func(childComplexity int) int 381 } 382 383 Subscription struct { 384 DirectiveArg func(childComplexity int, arg string) int 385 DirectiveDouble func(childComplexity int) int 386 DirectiveNullableArg func(childComplexity int, arg *int, arg2 *int, arg3 *string) int 387 DirectiveUnimplemented func(childComplexity int) int 388 ErrorRequired func(childComplexity int) int 389 InitPayload func(childComplexity int) int 390 Issue896b func(childComplexity int) int 391 Updated func(childComplexity int) int 392 } 393 394 User struct { 395 Created func(childComplexity int) int 396 Friends func(childComplexity int) int 397 ID func(childComplexity int) int 398 Pets func(childComplexity int, limit *int) int 399 Updated func(childComplexity int) int 400 } 401 402 VOkCaseNil struct { 403 Value func(childComplexity int) int 404 } 405 406 VOkCaseValue struct { 407 Value func(childComplexity int) int 408 } 409 410 ValidType struct { 411 DifferentCase func(childComplexity int) int 412 DifferentCaseOld func(childComplexity int) int 413 ValidArgs func(childComplexity int, breakArg string, defaultArg string, funcArg string, interfaceArg string, selectArg string, caseArg string, deferArg string, goArg string, mapArg string, structArg string, chanArg string, elseArg string, gotoArg string, packageArg string, switchArg string, constArg string, fallthroughArg string, ifArg string, rangeArg string, typeArg string, continueArg string, forArg string, importArg string, returnArg string, varArg string, _ string) int 414 ValidInputKeywords func(childComplexity int, input *ValidInput) int 415 } 416 417 VariadicModel struct { 418 Value func(childComplexity int, rank int) int 419 } 420 421 WrappedMap struct { 422 Get func(childComplexity int, key string) int 423 } 424 425 WrappedSlice struct { 426 Get func(childComplexity int, idx int) int 427 } 428 429 WrappedStruct struct { 430 Desc func(childComplexity int) int 431 Name func(childComplexity int) int 432 } 433 434 XXIt struct { 435 ID func(childComplexity int) int 436 } 437 438 XxIt struct { 439 ID func(childComplexity int) int 440 } 441 442 AsdfIt struct { 443 ID func(childComplexity int) int 444 } 445 446 IIt struct { 447 ID func(childComplexity int) int 448 } 449 } 450 451 type BackedByInterfaceResolver interface { 452 ID(ctx context.Context, obj BackedByInterface) (string, error) 453 } 454 type ErrorsResolver interface { 455 A(ctx context.Context, obj *Errors) (*Error, error) 456 B(ctx context.Context, obj *Errors) (*Error, error) 457 C(ctx context.Context, obj *Errors) (*Error, error) 458 D(ctx context.Context, obj *Errors) (*Error, error) 459 E(ctx context.Context, obj *Errors) (*Error, error) 460 } 461 type ForcedResolverResolver interface { 462 Field(ctx context.Context, obj *ForcedResolver) (*Circle, error) 463 } 464 type ModelMethodsResolver interface { 465 ResolverField(ctx context.Context, obj *ModelMethods) (bool, error) 466 } 467 type MutationResolver interface { 468 DefaultInput(ctx context.Context, input DefaultInput) (*DefaultParametersMirror, error) 469 OverrideValueViaInput(ctx context.Context, input FieldsOrderInput) (*FieldsOrderPayload, error) 470 UpdateSomething(ctx context.Context, input SpecialInput) (string, error) 471 UpdatePtrToPtr(ctx context.Context, input UpdatePtrToPtrOuter) (*PtrToPtrOuter, error) 472 } 473 type OverlappingFieldsResolver interface { 474 OldFoo(ctx context.Context, obj *OverlappingFields) (int, error) 475 } 476 type PanicsResolver interface { 477 FieldScalarMarshal(ctx context.Context, obj *Panics) ([]MarshalPanic, error) 478 479 ArgUnmarshal(ctx context.Context, obj *Panics, u []MarshalPanic) (bool, error) 480 } 481 type PetResolver interface { 482 Friends(ctx context.Context, obj *Pet, limit *int) ([]*Pet, error) 483 } 484 type PrimitiveResolver interface { 485 Value(ctx context.Context, obj *Primitive) (int, error) 486 } 487 type PrimitiveStringResolver interface { 488 Value(ctx context.Context, obj *PrimitiveString) (string, error) 489 490 Len(ctx context.Context, obj *PrimitiveString) (int, error) 491 } 492 type QueryResolver interface { 493 InvalidIdentifier(ctx context.Context) (*invalid_packagename.InvalidIdentifier, error) 494 Collision(ctx context.Context) (*introspection1.It, error) 495 MapInput(ctx context.Context, input map[string]interface{}) (*bool, error) 496 Recursive(ctx context.Context, input *RecursiveInputSlice) (*bool, error) 497 NestedInputs(ctx context.Context, input [][]*OuterInput) (*bool, error) 498 NestedOutputs(ctx context.Context) ([][]*OuterObject, error) 499 ModelMethods(ctx context.Context) (*ModelMethods, error) 500 User(ctx context.Context, id int) (*User, error) 501 NullableArg(ctx context.Context, arg *int) (*string, error) 502 InputSlice(ctx context.Context, arg []string) (bool, error) 503 InputNullableSlice(ctx context.Context, arg []string) (bool, error) 504 ShapeUnion(ctx context.Context) (ShapeUnion, error) 505 Autobind(ctx context.Context) (*Autobind, error) 506 DeprecatedField(ctx context.Context) (string, error) 507 Overlapping(ctx context.Context) (*OverlappingFields, error) 508 DefaultParameters(ctx context.Context, falsyBoolean *bool, truthyBoolean *bool) (*DefaultParametersMirror, error) 509 DirectiveArg(ctx context.Context, arg string) (*string, error) 510 DirectiveNullableArg(ctx context.Context, arg *int, arg2 *int, arg3 *string) (*string, error) 511 DirectiveInputNullable(ctx context.Context, arg *InputDirectives) (*string, error) 512 DirectiveInput(ctx context.Context, arg InputDirectives) (*string, error) 513 DirectiveInputType(ctx context.Context, arg InnerInput) (*string, error) 514 DirectiveObject(ctx context.Context) (*ObjectDirectives, error) 515 DirectiveObjectWithCustomGoModel(ctx context.Context) (*ObjectDirectivesWithCustomGoModel, error) 516 DirectiveFieldDef(ctx context.Context, ret string) (string, error) 517 DirectiveField(ctx context.Context) (*string, error) 518 DirectiveDouble(ctx context.Context) (*string, error) 519 DirectiveUnimplemented(ctx context.Context) (*string, error) 520 EmbeddedCase1(ctx context.Context) (*EmbeddedCase1, error) 521 EmbeddedCase2(ctx context.Context) (*EmbeddedCase2, error) 522 EmbeddedCase3(ctx context.Context) (*EmbeddedCase3, error) 523 EnumInInput(ctx context.Context, input *InputWithEnumValue) (EnumTest, error) 524 Shapes(ctx context.Context) ([]Shape, error) 525 NoShape(ctx context.Context) (Shape, error) 526 Node(ctx context.Context) (Node, error) 527 NoShapeTypedNil(ctx context.Context) (Shape, error) 528 Animal(ctx context.Context) (Animal, error) 529 NotAnInterface(ctx context.Context) (BackedByInterface, error) 530 Issue896a(ctx context.Context) ([]*CheckIssue896, error) 531 MapStringInterface(ctx context.Context, in map[string]interface{}) (map[string]interface{}, error) 532 MapNestedStringInterface(ctx context.Context, in *NestedMapInput) (map[string]interface{}, error) 533 ErrorBubble(ctx context.Context) (*Error, error) 534 ErrorBubbleList(ctx context.Context) ([]*Error, error) 535 ErrorList(ctx context.Context) ([]*Error, error) 536 Errors(ctx context.Context) (*Errors, error) 537 Valid(ctx context.Context) (string, error) 538 Panics(ctx context.Context) (*Panics, error) 539 PrimitiveObject(ctx context.Context) ([]Primitive, error) 540 PrimitiveStringObject(ctx context.Context) ([]PrimitiveString, error) 541 PtrToSliceContainer(ctx context.Context) (*PtrToSliceContainer, error) 542 Infinity(ctx context.Context) (float64, error) 543 StringFromContextInterface(ctx context.Context) (*StringFromContextInterface, error) 544 StringFromContextFunction(ctx context.Context) (string, error) 545 DefaultScalar(ctx context.Context, arg string) (string, error) 546 Slices(ctx context.Context) (*Slices, error) 547 ScalarSlice(ctx context.Context) ([]byte, error) 548 Fallback(ctx context.Context, arg FallbackToStringEncoding) (FallbackToStringEncoding, error) 549 OptionalUnion(ctx context.Context) (TestUnion, error) 550 VOkCaseValue(ctx context.Context) (*VOkCaseValue, error) 551 VOkCaseNil(ctx context.Context) (*VOkCaseNil, error) 552 ValidType(ctx context.Context) (*ValidType, error) 553 VariadicModel(ctx context.Context) (*VariadicModel, error) 554 WrappedStruct(ctx context.Context) (*WrappedStruct, error) 555 WrappedScalar(ctx context.Context) (otherpkg.Scalar, error) 556 WrappedMap(ctx context.Context) (WrappedMap, error) 557 WrappedSlice(ctx context.Context) (WrappedSlice, error) 558 } 559 type SubscriptionResolver interface { 560 Updated(ctx context.Context) (<-chan string, error) 561 InitPayload(ctx context.Context) (<-chan string, error) 562 DirectiveArg(ctx context.Context, arg string) (<-chan *string, error) 563 DirectiveNullableArg(ctx context.Context, arg *int, arg2 *int, arg3 *string) (<-chan *string, error) 564 DirectiveDouble(ctx context.Context) (<-chan *string, error) 565 DirectiveUnimplemented(ctx context.Context) (<-chan *string, error) 566 Issue896b(ctx context.Context) (<-chan []*CheckIssue896, error) 567 ErrorRequired(ctx context.Context) (<-chan *Error, error) 568 } 569 type UserResolver interface { 570 Friends(ctx context.Context, obj *User) ([]*User, error) 571 572 Pets(ctx context.Context, obj *User, limit *int) ([]*Pet, error) 573 } 574 type WrappedMapResolver interface { 575 Get(ctx context.Context, obj WrappedMap, key string) (string, error) 576 } 577 type WrappedSliceResolver interface { 578 Get(ctx context.Context, obj WrappedSlice, idx int) (string, error) 579 } 580 581 type FieldsOrderInputResolver interface { 582 OverrideFirstField(ctx context.Context, obj *FieldsOrderInput, data *string) error 583 } 584 585 type executableSchema struct { 586 resolvers ResolverRoot 587 directives DirectiveRoot 588 complexity ComplexityRoot 589 } 590 591 func (e *executableSchema) Schema() *ast.Schema { 592 return parsedSchema 593 } 594 595 func (e *executableSchema) Complexity(typeName, field string, childComplexity int, rawArgs map[string]interface{}) (int, bool) { 596 ec := executionContext{nil, e} 597 _ = ec 598 switch typeName + "." + field { 599 600 case "A.id": 601 if e.complexity.A.ID == nil { 602 break 603 } 604 605 return e.complexity.A.ID(childComplexity), true 606 607 case "AIt.id": 608 if e.complexity.AIt.ID == nil { 609 break 610 } 611 612 return e.complexity.AIt.ID(childComplexity), true 613 614 case "AbIt.id": 615 if e.complexity.AbIt.ID == nil { 616 break 617 } 618 619 return e.complexity.AbIt.ID(childComplexity), true 620 621 case "Autobind.idInt": 622 if e.complexity.Autobind.IdInt == nil { 623 break 624 } 625 626 return e.complexity.Autobind.IdInt(childComplexity), true 627 628 case "Autobind.idStr": 629 if e.complexity.Autobind.IdStr == nil { 630 break 631 } 632 633 return e.complexity.Autobind.IdStr(childComplexity), true 634 635 case "Autobind.int": 636 if e.complexity.Autobind.Int == nil { 637 break 638 } 639 640 return e.complexity.Autobind.Int(childComplexity), true 641 642 case "Autobind.int32": 643 if e.complexity.Autobind.Int32 == nil { 644 break 645 } 646 647 return e.complexity.Autobind.Int32(childComplexity), true 648 649 case "Autobind.int64": 650 if e.complexity.Autobind.Int64 == nil { 651 break 652 } 653 654 return e.complexity.Autobind.Int64(childComplexity), true 655 656 case "B.id": 657 if e.complexity.B.ID == nil { 658 break 659 } 660 661 return e.complexity.B.ID(childComplexity), true 662 663 case "BackedByInterface.id": 664 if e.complexity.BackedByInterface.ID == nil { 665 break 666 } 667 668 return e.complexity.BackedByInterface.ID(childComplexity), true 669 670 case "BackedByInterface.thisShouldBind": 671 if e.complexity.BackedByInterface.ThisShouldBind == nil { 672 break 673 } 674 675 return e.complexity.BackedByInterface.ThisShouldBind(childComplexity), true 676 677 case "BackedByInterface.thisShouldBindWithError": 678 if e.complexity.BackedByInterface.ThisShouldBindWithError == nil { 679 break 680 } 681 682 return e.complexity.BackedByInterface.ThisShouldBindWithError(childComplexity), true 683 684 case "Cat.catBreed": 685 if e.complexity.Cat.CatBreed == nil { 686 break 687 } 688 689 return e.complexity.Cat.CatBreed(childComplexity), true 690 691 case "Cat.species": 692 if e.complexity.Cat.Species == nil { 693 break 694 } 695 696 return e.complexity.Cat.Species(childComplexity), true 697 698 case "CheckIssue896.id": 699 if e.complexity.CheckIssue896.ID == nil { 700 break 701 } 702 703 return e.complexity.CheckIssue896.ID(childComplexity), true 704 705 case "Circle.area": 706 if e.complexity.Circle.Area == nil { 707 break 708 } 709 710 return e.complexity.Circle.Area(childComplexity), true 711 712 case "Circle.coordinates": 713 if e.complexity.Circle.Coordinates == nil { 714 break 715 } 716 717 return e.complexity.Circle.Coordinates(childComplexity), true 718 719 case "Circle.radius": 720 if e.complexity.Circle.Radius == nil { 721 break 722 } 723 724 return e.complexity.Circle.Radius(childComplexity), true 725 726 case "ConcreteNodeA.child": 727 if e.complexity.ConcreteNodeA.Child == nil { 728 break 729 } 730 731 return e.complexity.ConcreteNodeA.Child(childComplexity), true 732 733 case "ConcreteNodeA.id": 734 if e.complexity.ConcreteNodeA.ID == nil { 735 break 736 } 737 738 return e.complexity.ConcreteNodeA.ID(childComplexity), true 739 740 case "ConcreteNodeA.name": 741 if e.complexity.ConcreteNodeA.Name == nil { 742 break 743 } 744 745 return e.complexity.ConcreteNodeA.Name(childComplexity), true 746 747 case "ConcreteNodeInterface.child": 748 if e.complexity.ConcreteNodeInterface.Child == nil { 749 break 750 } 751 752 return e.complexity.ConcreteNodeInterface.Child(childComplexity), true 753 754 case "ConcreteNodeInterface.id": 755 if e.complexity.ConcreteNodeInterface.ID == nil { 756 break 757 } 758 759 return e.complexity.ConcreteNodeInterface.ID(childComplexity), true 760 761 case "Content_Post.foo": 762 if e.complexity.Content_Post.Foo == nil { 763 break 764 } 765 766 return e.complexity.Content_Post.Foo(childComplexity), true 767 768 case "Content_User.foo": 769 if e.complexity.Content_User.Foo == nil { 770 break 771 } 772 773 return e.complexity.Content_User.Foo(childComplexity), true 774 775 case "Coordinates.x": 776 if e.complexity.Coordinates.X == nil { 777 break 778 } 779 780 return e.complexity.Coordinates.X(childComplexity), true 781 782 case "Coordinates.y": 783 if e.complexity.Coordinates.Y == nil { 784 break 785 } 786 787 return e.complexity.Coordinates.Y(childComplexity), true 788 789 case "DefaultParametersMirror.falsyBoolean": 790 if e.complexity.DefaultParametersMirror.FalsyBoolean == nil { 791 break 792 } 793 794 return e.complexity.DefaultParametersMirror.FalsyBoolean(childComplexity), true 795 796 case "DefaultParametersMirror.truthyBoolean": 797 if e.complexity.DefaultParametersMirror.TruthyBoolean == nil { 798 break 799 } 800 801 return e.complexity.DefaultParametersMirror.TruthyBoolean(childComplexity), true 802 803 case "Dog.dogBreed": 804 if e.complexity.Dog.DogBreed == nil { 805 break 806 } 807 808 return e.complexity.Dog.DogBreed(childComplexity), true 809 810 case "Dog.species": 811 if e.complexity.Dog.Species == nil { 812 break 813 } 814 815 return e.complexity.Dog.Species(childComplexity), true 816 817 case "EmbeddedCase1.exportedEmbeddedPointerExportedMethod": 818 if e.complexity.EmbeddedCase1.ExportedEmbeddedPointerExportedMethod == nil { 819 break 820 } 821 822 return e.complexity.EmbeddedCase1.ExportedEmbeddedPointerExportedMethod(childComplexity), true 823 824 case "EmbeddedCase2.unexportedEmbeddedPointerExportedMethod": 825 if e.complexity.EmbeddedCase2.UnexportedEmbeddedPointerExportedMethod == nil { 826 break 827 } 828 829 return e.complexity.EmbeddedCase2.UnexportedEmbeddedPointerExportedMethod(childComplexity), true 830 831 case "EmbeddedCase3.unexportedEmbeddedInterfaceExportedMethod": 832 if e.complexity.EmbeddedCase3.UnexportedEmbeddedInterfaceExportedMethod == nil { 833 break 834 } 835 836 return e.complexity.EmbeddedCase3.UnexportedEmbeddedInterfaceExportedMethod(childComplexity), true 837 838 case "EmbeddedDefaultScalar.value": 839 if e.complexity.EmbeddedDefaultScalar.Value == nil { 840 break 841 } 842 843 return e.complexity.EmbeddedDefaultScalar.Value(childComplexity), true 844 845 case "EmbeddedPointer.ID": 846 if e.complexity.EmbeddedPointer.ID == nil { 847 break 848 } 849 850 return e.complexity.EmbeddedPointer.ID(childComplexity), true 851 852 case "EmbeddedPointer.Title": 853 if e.complexity.EmbeddedPointer.Title == nil { 854 break 855 } 856 857 return e.complexity.EmbeddedPointer.Title(childComplexity), true 858 859 case "Error.errorOnNonRequiredField": 860 if e.complexity.Error.ErrorOnNonRequiredField == nil { 861 break 862 } 863 864 return e.complexity.Error.ErrorOnNonRequiredField(childComplexity), true 865 866 case "Error.errorOnRequiredField": 867 if e.complexity.Error.ErrorOnRequiredField == nil { 868 break 869 } 870 871 return e.complexity.Error.ErrorOnRequiredField(childComplexity), true 872 873 case "Error.id": 874 if e.complexity.Error.ID == nil { 875 break 876 } 877 878 return e.complexity.Error.ID(childComplexity), true 879 880 case "Error.nilOnRequiredField": 881 if e.complexity.Error.NilOnRequiredField == nil { 882 break 883 } 884 885 return e.complexity.Error.NilOnRequiredField(childComplexity), true 886 887 case "Errors.a": 888 if e.complexity.Errors.A == nil { 889 break 890 } 891 892 return e.complexity.Errors.A(childComplexity), true 893 894 case "Errors.b": 895 if e.complexity.Errors.B == nil { 896 break 897 } 898 899 return e.complexity.Errors.B(childComplexity), true 900 901 case "Errors.c": 902 if e.complexity.Errors.C == nil { 903 break 904 } 905 906 return e.complexity.Errors.C(childComplexity), true 907 908 case "Errors.d": 909 if e.complexity.Errors.D == nil { 910 break 911 } 912 913 return e.complexity.Errors.D(childComplexity), true 914 915 case "Errors.e": 916 if e.complexity.Errors.E == nil { 917 break 918 } 919 920 return e.complexity.Errors.E(childComplexity), true 921 922 case "FieldsOrderPayload.firstFieldValue": 923 if e.complexity.FieldsOrderPayload.FirstFieldValue == nil { 924 break 925 } 926 927 return e.complexity.FieldsOrderPayload.FirstFieldValue(childComplexity), true 928 929 case "ForcedResolver.field": 930 if e.complexity.ForcedResolver.Field == nil { 931 break 932 } 933 934 return e.complexity.ForcedResolver.Field(childComplexity), true 935 936 case "InnerObject.id": 937 if e.complexity.InnerObject.ID == nil { 938 break 939 } 940 941 return e.complexity.InnerObject.ID(childComplexity), true 942 943 case "InvalidIdentifier.id": 944 if e.complexity.InvalidIdentifier.ID == nil { 945 break 946 } 947 948 return e.complexity.InvalidIdentifier.ID(childComplexity), true 949 950 case "It.id": 951 if e.complexity.It.ID == nil { 952 break 953 } 954 955 return e.complexity.It.ID(childComplexity), true 956 957 case "LoopA.b": 958 if e.complexity.LoopA.B == nil { 959 break 960 } 961 962 return e.complexity.LoopA.B(childComplexity), true 963 964 case "LoopB.a": 965 if e.complexity.LoopB.A == nil { 966 break 967 } 968 969 return e.complexity.LoopB.A(childComplexity), true 970 971 case "Map.id": 972 if e.complexity.Map.ID == nil { 973 break 974 } 975 976 return e.complexity.Map.ID(childComplexity), true 977 978 case "MapStringInterfaceType.a": 979 if e.complexity.MapStringInterfaceType.A == nil { 980 break 981 } 982 983 return e.complexity.MapStringInterfaceType.A(childComplexity), true 984 985 case "MapStringInterfaceType.b": 986 if e.complexity.MapStringInterfaceType.B == nil { 987 break 988 } 989 990 return e.complexity.MapStringInterfaceType.B(childComplexity), true 991 992 case "ModelMethods.noContext": 993 if e.complexity.ModelMethods.NoContext == nil { 994 break 995 } 996 997 return e.complexity.ModelMethods.NoContext(childComplexity), true 998 999 case "ModelMethods.resolverField": 1000 if e.complexity.ModelMethods.ResolverField == nil { 1001 break 1002 } 1003 1004 return e.complexity.ModelMethods.ResolverField(childComplexity), true 1005 1006 case "ModelMethods.withContext": 1007 if e.complexity.ModelMethods.WithContext == nil { 1008 break 1009 } 1010 1011 return e.complexity.ModelMethods.WithContext(childComplexity), true 1012 1013 case "Mutation.defaultInput": 1014 if e.complexity.Mutation.DefaultInput == nil { 1015 break 1016 } 1017 1018 args, err := ec.field_Mutation_defaultInput_args(context.TODO(), rawArgs) 1019 if err != nil { 1020 return 0, false 1021 } 1022 1023 return e.complexity.Mutation.DefaultInput(childComplexity, args["input"].(DefaultInput)), true 1024 1025 case "Mutation.overrideValueViaInput": 1026 if e.complexity.Mutation.OverrideValueViaInput == nil { 1027 break 1028 } 1029 1030 args, err := ec.field_Mutation_overrideValueViaInput_args(context.TODO(), rawArgs) 1031 if err != nil { 1032 return 0, false 1033 } 1034 1035 return e.complexity.Mutation.OverrideValueViaInput(childComplexity, args["input"].(FieldsOrderInput)), true 1036 1037 case "Mutation.updatePtrToPtr": 1038 if e.complexity.Mutation.UpdatePtrToPtr == nil { 1039 break 1040 } 1041 1042 args, err := ec.field_Mutation_updatePtrToPtr_args(context.TODO(), rawArgs) 1043 if err != nil { 1044 return 0, false 1045 } 1046 1047 return e.complexity.Mutation.UpdatePtrToPtr(childComplexity, args["input"].(UpdatePtrToPtrOuter)), true 1048 1049 case "Mutation.updateSomething": 1050 if e.complexity.Mutation.UpdateSomething == nil { 1051 break 1052 } 1053 1054 args, err := ec.field_Mutation_updateSomething_args(context.TODO(), rawArgs) 1055 if err != nil { 1056 return 0, false 1057 } 1058 1059 return e.complexity.Mutation.UpdateSomething(childComplexity, args["input"].(SpecialInput)), true 1060 1061 case "ObjectDirectives.nullableText": 1062 if e.complexity.ObjectDirectives.NullableText == nil { 1063 break 1064 } 1065 1066 return e.complexity.ObjectDirectives.NullableText(childComplexity), true 1067 1068 case "ObjectDirectives.order": 1069 if e.complexity.ObjectDirectives.Order == nil { 1070 break 1071 } 1072 1073 return e.complexity.ObjectDirectives.Order(childComplexity), true 1074 1075 case "ObjectDirectives.text": 1076 if e.complexity.ObjectDirectives.Text == nil { 1077 break 1078 } 1079 1080 return e.complexity.ObjectDirectives.Text(childComplexity), true 1081 1082 case "ObjectDirectivesWithCustomGoModel.nullableText": 1083 if e.complexity.ObjectDirectivesWithCustomGoModel.NullableText == nil { 1084 break 1085 } 1086 1087 return e.complexity.ObjectDirectivesWithCustomGoModel.NullableText(childComplexity), true 1088 1089 case "OuterObject.inner": 1090 if e.complexity.OuterObject.Inner == nil { 1091 break 1092 } 1093 1094 return e.complexity.OuterObject.Inner(childComplexity), true 1095 1096 case "OverlappingFields.oneFoo", "OverlappingFields.twoFoo": 1097 if e.complexity.OverlappingFields.Foo == nil { 1098 break 1099 } 1100 1101 return e.complexity.OverlappingFields.Foo(childComplexity), true 1102 1103 case "OverlappingFields.newFoo", "OverlappingFields.new_foo": 1104 if e.complexity.OverlappingFields.NewFoo == nil { 1105 break 1106 } 1107 1108 return e.complexity.OverlappingFields.NewFoo(childComplexity), true 1109 1110 case "OverlappingFields.oldFoo": 1111 if e.complexity.OverlappingFields.OldFoo == nil { 1112 break 1113 } 1114 1115 return e.complexity.OverlappingFields.OldFoo(childComplexity), true 1116 1117 case "Panics.argUnmarshal": 1118 if e.complexity.Panics.ArgUnmarshal == nil { 1119 break 1120 } 1121 1122 args, err := ec.field_Panics_argUnmarshal_args(context.TODO(), rawArgs) 1123 if err != nil { 1124 return 0, false 1125 } 1126 1127 return e.complexity.Panics.ArgUnmarshal(childComplexity, args["u"].([]MarshalPanic)), true 1128 1129 case "Panics.fieldFuncMarshal": 1130 if e.complexity.Panics.FieldFuncMarshal == nil { 1131 break 1132 } 1133 1134 args, err := ec.field_Panics_fieldFuncMarshal_args(context.TODO(), rawArgs) 1135 if err != nil { 1136 return 0, false 1137 } 1138 1139 return e.complexity.Panics.FieldFuncMarshal(childComplexity, args["u"].([]MarshalPanic)), true 1140 1141 case "Panics.fieldScalarMarshal": 1142 if e.complexity.Panics.FieldScalarMarshal == nil { 1143 break 1144 } 1145 1146 return e.complexity.Panics.FieldScalarMarshal(childComplexity), true 1147 1148 case "Pet.friends": 1149 if e.complexity.Pet.Friends == nil { 1150 break 1151 } 1152 1153 args, err := ec.field_Pet_friends_args(context.TODO(), rawArgs) 1154 if err != nil { 1155 return 0, false 1156 } 1157 1158 return e.complexity.Pet.Friends(childComplexity, args["limit"].(*int)), true 1159 1160 case "Pet.id": 1161 if e.complexity.Pet.ID == nil { 1162 break 1163 } 1164 1165 return e.complexity.Pet.ID(childComplexity), true 1166 1167 case "Primitive.squared": 1168 if e.complexity.Primitive.Squared == nil { 1169 break 1170 } 1171 1172 return e.complexity.Primitive.Squared(childComplexity), true 1173 1174 case "Primitive.value": 1175 if e.complexity.Primitive.Value == nil { 1176 break 1177 } 1178 1179 return e.complexity.Primitive.Value(childComplexity), true 1180 1181 case "PrimitiveString.doubled": 1182 if e.complexity.PrimitiveString.Doubled == nil { 1183 break 1184 } 1185 1186 return e.complexity.PrimitiveString.Doubled(childComplexity), true 1187 1188 case "PrimitiveString.len": 1189 if e.complexity.PrimitiveString.Len == nil { 1190 break 1191 } 1192 1193 return e.complexity.PrimitiveString.Len(childComplexity), true 1194 1195 case "PrimitiveString.value": 1196 if e.complexity.PrimitiveString.Value == nil { 1197 break 1198 } 1199 1200 return e.complexity.PrimitiveString.Value(childComplexity), true 1201 1202 case "PtrToPtrInner.key": 1203 if e.complexity.PtrToPtrInner.Key == nil { 1204 break 1205 } 1206 1207 return e.complexity.PtrToPtrInner.Key(childComplexity), true 1208 1209 case "PtrToPtrInner.value": 1210 if e.complexity.PtrToPtrInner.Value == nil { 1211 break 1212 } 1213 1214 return e.complexity.PtrToPtrInner.Value(childComplexity), true 1215 1216 case "PtrToPtrOuter.inner": 1217 if e.complexity.PtrToPtrOuter.Inner == nil { 1218 break 1219 } 1220 1221 return e.complexity.PtrToPtrOuter.Inner(childComplexity), true 1222 1223 case "PtrToPtrOuter.name": 1224 if e.complexity.PtrToPtrOuter.Name == nil { 1225 break 1226 } 1227 1228 return e.complexity.PtrToPtrOuter.Name(childComplexity), true 1229 1230 case "PtrToPtrOuter.stupidInner": 1231 if e.complexity.PtrToPtrOuter.StupidInner == nil { 1232 break 1233 } 1234 1235 return e.complexity.PtrToPtrOuter.StupidInner(childComplexity), true 1236 1237 case "PtrToSliceContainer.ptrToSlice": 1238 if e.complexity.PtrToSliceContainer.PtrToSlice == nil { 1239 break 1240 } 1241 1242 return e.complexity.PtrToSliceContainer.PtrToSlice(childComplexity), true 1243 1244 case "Query.animal": 1245 if e.complexity.Query.Animal == nil { 1246 break 1247 } 1248 1249 return e.complexity.Query.Animal(childComplexity), true 1250 1251 case "Query.autobind": 1252 if e.complexity.Query.Autobind == nil { 1253 break 1254 } 1255 1256 return e.complexity.Query.Autobind(childComplexity), true 1257 1258 case "Query.collision": 1259 if e.complexity.Query.Collision == nil { 1260 break 1261 } 1262 1263 return e.complexity.Query.Collision(childComplexity), true 1264 1265 case "Query.defaultParameters": 1266 if e.complexity.Query.DefaultParameters == nil { 1267 break 1268 } 1269 1270 args, err := ec.field_Query_defaultParameters_args(context.TODO(), rawArgs) 1271 if err != nil { 1272 return 0, false 1273 } 1274 1275 return e.complexity.Query.DefaultParameters(childComplexity, args["falsyBoolean"].(*bool), args["truthyBoolean"].(*bool)), true 1276 1277 case "Query.defaultScalar": 1278 if e.complexity.Query.DefaultScalar == nil { 1279 break 1280 } 1281 1282 args, err := ec.field_Query_defaultScalar_args(context.TODO(), rawArgs) 1283 if err != nil { 1284 return 0, false 1285 } 1286 1287 return e.complexity.Query.DefaultScalar(childComplexity, args["arg"].(string)), true 1288 1289 case "Query.deprecatedField": 1290 if e.complexity.Query.DeprecatedField == nil { 1291 break 1292 } 1293 1294 return e.complexity.Query.DeprecatedField(childComplexity), true 1295 1296 case "Query.directiveArg": 1297 if e.complexity.Query.DirectiveArg == nil { 1298 break 1299 } 1300 1301 args, err := ec.field_Query_directiveArg_args(context.TODO(), rawArgs) 1302 if err != nil { 1303 return 0, false 1304 } 1305 1306 return e.complexity.Query.DirectiveArg(childComplexity, args["arg"].(string)), true 1307 1308 case "Query.directiveDouble": 1309 if e.complexity.Query.DirectiveDouble == nil { 1310 break 1311 } 1312 1313 return e.complexity.Query.DirectiveDouble(childComplexity), true 1314 1315 case "Query.directiveField": 1316 if e.complexity.Query.DirectiveField == nil { 1317 break 1318 } 1319 1320 return e.complexity.Query.DirectiveField(childComplexity), true 1321 1322 case "Query.directiveFieldDef": 1323 if e.complexity.Query.DirectiveFieldDef == nil { 1324 break 1325 } 1326 1327 args, err := ec.field_Query_directiveFieldDef_args(context.TODO(), rawArgs) 1328 if err != nil { 1329 return 0, false 1330 } 1331 1332 return e.complexity.Query.DirectiveFieldDef(childComplexity, args["ret"].(string)), true 1333 1334 case "Query.directiveInput": 1335 if e.complexity.Query.DirectiveInput == nil { 1336 break 1337 } 1338 1339 args, err := ec.field_Query_directiveInput_args(context.TODO(), rawArgs) 1340 if err != nil { 1341 return 0, false 1342 } 1343 1344 return e.complexity.Query.DirectiveInput(childComplexity, args["arg"].(InputDirectives)), true 1345 1346 case "Query.directiveInputNullable": 1347 if e.complexity.Query.DirectiveInputNullable == nil { 1348 break 1349 } 1350 1351 args, err := ec.field_Query_directiveInputNullable_args(context.TODO(), rawArgs) 1352 if err != nil { 1353 return 0, false 1354 } 1355 1356 return e.complexity.Query.DirectiveInputNullable(childComplexity, args["arg"].(*InputDirectives)), true 1357 1358 case "Query.directiveInputType": 1359 if e.complexity.Query.DirectiveInputType == nil { 1360 break 1361 } 1362 1363 args, err := ec.field_Query_directiveInputType_args(context.TODO(), rawArgs) 1364 if err != nil { 1365 return 0, false 1366 } 1367 1368 return e.complexity.Query.DirectiveInputType(childComplexity, args["arg"].(InnerInput)), true 1369 1370 case "Query.directiveNullableArg": 1371 if e.complexity.Query.DirectiveNullableArg == nil { 1372 break 1373 } 1374 1375 args, err := ec.field_Query_directiveNullableArg_args(context.TODO(), rawArgs) 1376 if err != nil { 1377 return 0, false 1378 } 1379 1380 return e.complexity.Query.DirectiveNullableArg(childComplexity, args["arg"].(*int), args["arg2"].(*int), args["arg3"].(*string)), true 1381 1382 case "Query.directiveObject": 1383 if e.complexity.Query.DirectiveObject == nil { 1384 break 1385 } 1386 1387 return e.complexity.Query.DirectiveObject(childComplexity), true 1388 1389 case "Query.directiveObjectWithCustomGoModel": 1390 if e.complexity.Query.DirectiveObjectWithCustomGoModel == nil { 1391 break 1392 } 1393 1394 return e.complexity.Query.DirectiveObjectWithCustomGoModel(childComplexity), true 1395 1396 case "Query.directiveUnimplemented": 1397 if e.complexity.Query.DirectiveUnimplemented == nil { 1398 break 1399 } 1400 1401 return e.complexity.Query.DirectiveUnimplemented(childComplexity), true 1402 1403 case "Query.embeddedCase1": 1404 if e.complexity.Query.EmbeddedCase1 == nil { 1405 break 1406 } 1407 1408 return e.complexity.Query.EmbeddedCase1(childComplexity), true 1409 1410 case "Query.embeddedCase2": 1411 if e.complexity.Query.EmbeddedCase2 == nil { 1412 break 1413 } 1414 1415 return e.complexity.Query.EmbeddedCase2(childComplexity), true 1416 1417 case "Query.embeddedCase3": 1418 if e.complexity.Query.EmbeddedCase3 == nil { 1419 break 1420 } 1421 1422 return e.complexity.Query.EmbeddedCase3(childComplexity), true 1423 1424 case "Query.enumInInput": 1425 if e.complexity.Query.EnumInInput == nil { 1426 break 1427 } 1428 1429 args, err := ec.field_Query_enumInInput_args(context.TODO(), rawArgs) 1430 if err != nil { 1431 return 0, false 1432 } 1433 1434 return e.complexity.Query.EnumInInput(childComplexity, args["input"].(*InputWithEnumValue)), true 1435 1436 case "Query.errorBubble": 1437 if e.complexity.Query.ErrorBubble == nil { 1438 break 1439 } 1440 1441 return e.complexity.Query.ErrorBubble(childComplexity), true 1442 1443 case "Query.errorBubbleList": 1444 if e.complexity.Query.ErrorBubbleList == nil { 1445 break 1446 } 1447 1448 return e.complexity.Query.ErrorBubbleList(childComplexity), true 1449 1450 case "Query.errorList": 1451 if e.complexity.Query.ErrorList == nil { 1452 break 1453 } 1454 1455 return e.complexity.Query.ErrorList(childComplexity), true 1456 1457 case "Query.errors": 1458 if e.complexity.Query.Errors == nil { 1459 break 1460 } 1461 1462 return e.complexity.Query.Errors(childComplexity), true 1463 1464 case "Query.fallback": 1465 if e.complexity.Query.Fallback == nil { 1466 break 1467 } 1468 1469 args, err := ec.field_Query_fallback_args(context.TODO(), rawArgs) 1470 if err != nil { 1471 return 0, false 1472 } 1473 1474 return e.complexity.Query.Fallback(childComplexity, args["arg"].(FallbackToStringEncoding)), true 1475 1476 case "Query.infinity": 1477 if e.complexity.Query.Infinity == nil { 1478 break 1479 } 1480 1481 return e.complexity.Query.Infinity(childComplexity), true 1482 1483 case "Query.inputNullableSlice": 1484 if e.complexity.Query.InputNullableSlice == nil { 1485 break 1486 } 1487 1488 args, err := ec.field_Query_inputNullableSlice_args(context.TODO(), rawArgs) 1489 if err != nil { 1490 return 0, false 1491 } 1492 1493 return e.complexity.Query.InputNullableSlice(childComplexity, args["arg"].([]string)), true 1494 1495 case "Query.inputSlice": 1496 if e.complexity.Query.InputSlice == nil { 1497 break 1498 } 1499 1500 args, err := ec.field_Query_inputSlice_args(context.TODO(), rawArgs) 1501 if err != nil { 1502 return 0, false 1503 } 1504 1505 return e.complexity.Query.InputSlice(childComplexity, args["arg"].([]string)), true 1506 1507 case "Query.invalidIdentifier": 1508 if e.complexity.Query.InvalidIdentifier == nil { 1509 break 1510 } 1511 1512 return e.complexity.Query.InvalidIdentifier(childComplexity), true 1513 1514 case "Query.issue896a": 1515 if e.complexity.Query.Issue896a == nil { 1516 break 1517 } 1518 1519 return e.complexity.Query.Issue896a(childComplexity), true 1520 1521 case "Query.mapInput": 1522 if e.complexity.Query.MapInput == nil { 1523 break 1524 } 1525 1526 args, err := ec.field_Query_mapInput_args(context.TODO(), rawArgs) 1527 if err != nil { 1528 return 0, false 1529 } 1530 1531 return e.complexity.Query.MapInput(childComplexity, args["input"].(map[string]interface{})), true 1532 1533 case "Query.mapNestedStringInterface": 1534 if e.complexity.Query.MapNestedStringInterface == nil { 1535 break 1536 } 1537 1538 args, err := ec.field_Query_mapNestedStringInterface_args(context.TODO(), rawArgs) 1539 if err != nil { 1540 return 0, false 1541 } 1542 1543 return e.complexity.Query.MapNestedStringInterface(childComplexity, args["in"].(*NestedMapInput)), true 1544 1545 case "Query.mapStringInterface": 1546 if e.complexity.Query.MapStringInterface == nil { 1547 break 1548 } 1549 1550 args, err := ec.field_Query_mapStringInterface_args(context.TODO(), rawArgs) 1551 if err != nil { 1552 return 0, false 1553 } 1554 1555 return e.complexity.Query.MapStringInterface(childComplexity, args["in"].(map[string]interface{})), true 1556 1557 case "Query.modelMethods": 1558 if e.complexity.Query.ModelMethods == nil { 1559 break 1560 } 1561 1562 return e.complexity.Query.ModelMethods(childComplexity), true 1563 1564 case "Query.nestedInputs": 1565 if e.complexity.Query.NestedInputs == nil { 1566 break 1567 } 1568 1569 args, err := ec.field_Query_nestedInputs_args(context.TODO(), rawArgs) 1570 if err != nil { 1571 return 0, false 1572 } 1573 1574 return e.complexity.Query.NestedInputs(childComplexity, args["input"].([][]*OuterInput)), true 1575 1576 case "Query.nestedOutputs": 1577 if e.complexity.Query.NestedOutputs == nil { 1578 break 1579 } 1580 1581 return e.complexity.Query.NestedOutputs(childComplexity), true 1582 1583 case "Query.noShape": 1584 if e.complexity.Query.NoShape == nil { 1585 break 1586 } 1587 1588 return e.complexity.Query.NoShape(childComplexity), true 1589 1590 case "Query.noShapeTypedNil": 1591 if e.complexity.Query.NoShapeTypedNil == nil { 1592 break 1593 } 1594 1595 return e.complexity.Query.NoShapeTypedNil(childComplexity), true 1596 1597 case "Query.node": 1598 if e.complexity.Query.Node == nil { 1599 break 1600 } 1601 1602 return e.complexity.Query.Node(childComplexity), true 1603 1604 case "Query.notAnInterface": 1605 if e.complexity.Query.NotAnInterface == nil { 1606 break 1607 } 1608 1609 return e.complexity.Query.NotAnInterface(childComplexity), true 1610 1611 case "Query.nullableArg": 1612 if e.complexity.Query.NullableArg == nil { 1613 break 1614 } 1615 1616 args, err := ec.field_Query_nullableArg_args(context.TODO(), rawArgs) 1617 if err != nil { 1618 return 0, false 1619 } 1620 1621 return e.complexity.Query.NullableArg(childComplexity, args["arg"].(*int)), true 1622 1623 case "Query.optionalUnion": 1624 if e.complexity.Query.OptionalUnion == nil { 1625 break 1626 } 1627 1628 return e.complexity.Query.OptionalUnion(childComplexity), true 1629 1630 case "Query.overlapping": 1631 if e.complexity.Query.Overlapping == nil { 1632 break 1633 } 1634 1635 return e.complexity.Query.Overlapping(childComplexity), true 1636 1637 case "Query.panics": 1638 if e.complexity.Query.Panics == nil { 1639 break 1640 } 1641 1642 return e.complexity.Query.Panics(childComplexity), true 1643 1644 case "Query.primitiveObject": 1645 if e.complexity.Query.PrimitiveObject == nil { 1646 break 1647 } 1648 1649 return e.complexity.Query.PrimitiveObject(childComplexity), true 1650 1651 case "Query.primitiveStringObject": 1652 if e.complexity.Query.PrimitiveStringObject == nil { 1653 break 1654 } 1655 1656 return e.complexity.Query.PrimitiveStringObject(childComplexity), true 1657 1658 case "Query.ptrToSliceContainer": 1659 if e.complexity.Query.PtrToSliceContainer == nil { 1660 break 1661 } 1662 1663 return e.complexity.Query.PtrToSliceContainer(childComplexity), true 1664 1665 case "Query.recursive": 1666 if e.complexity.Query.Recursive == nil { 1667 break 1668 } 1669 1670 args, err := ec.field_Query_recursive_args(context.TODO(), rawArgs) 1671 if err != nil { 1672 return 0, false 1673 } 1674 1675 return e.complexity.Query.Recursive(childComplexity, args["input"].(*RecursiveInputSlice)), true 1676 1677 case "Query.scalarSlice": 1678 if e.complexity.Query.ScalarSlice == nil { 1679 break 1680 } 1681 1682 return e.complexity.Query.ScalarSlice(childComplexity), true 1683 1684 case "Query.shapeUnion": 1685 if e.complexity.Query.ShapeUnion == nil { 1686 break 1687 } 1688 1689 return e.complexity.Query.ShapeUnion(childComplexity), true 1690 1691 case "Query.shapes": 1692 if e.complexity.Query.Shapes == nil { 1693 break 1694 } 1695 1696 return e.complexity.Query.Shapes(childComplexity), true 1697 1698 case "Query.slices": 1699 if e.complexity.Query.Slices == nil { 1700 break 1701 } 1702 1703 return e.complexity.Query.Slices(childComplexity), true 1704 1705 case "Query.stringFromContextFunction": 1706 if e.complexity.Query.StringFromContextFunction == nil { 1707 break 1708 } 1709 1710 return e.complexity.Query.StringFromContextFunction(childComplexity), true 1711 1712 case "Query.stringFromContextInterface": 1713 if e.complexity.Query.StringFromContextInterface == nil { 1714 break 1715 } 1716 1717 return e.complexity.Query.StringFromContextInterface(childComplexity), true 1718 1719 case "Query.user": 1720 if e.complexity.Query.User == nil { 1721 break 1722 } 1723 1724 args, err := ec.field_Query_user_args(context.TODO(), rawArgs) 1725 if err != nil { 1726 return 0, false 1727 } 1728 1729 return e.complexity.Query.User(childComplexity, args["id"].(int)), true 1730 1731 case "Query.vOkCaseNil": 1732 if e.complexity.Query.VOkCaseNil == nil { 1733 break 1734 } 1735 1736 return e.complexity.Query.VOkCaseNil(childComplexity), true 1737 1738 case "Query.vOkCaseValue": 1739 if e.complexity.Query.VOkCaseValue == nil { 1740 break 1741 } 1742 1743 return e.complexity.Query.VOkCaseValue(childComplexity), true 1744 1745 case "Query.valid": 1746 if e.complexity.Query.Valid == nil { 1747 break 1748 } 1749 1750 return e.complexity.Query.Valid(childComplexity), true 1751 1752 case "Query.validType": 1753 if e.complexity.Query.ValidType == nil { 1754 break 1755 } 1756 1757 return e.complexity.Query.ValidType(childComplexity), true 1758 1759 case "Query.variadicModel": 1760 if e.complexity.Query.VariadicModel == nil { 1761 break 1762 } 1763 1764 return e.complexity.Query.VariadicModel(childComplexity), true 1765 1766 case "Query.wrappedMap": 1767 if e.complexity.Query.WrappedMap == nil { 1768 break 1769 } 1770 1771 return e.complexity.Query.WrappedMap(childComplexity), true 1772 1773 case "Query.wrappedScalar": 1774 if e.complexity.Query.WrappedScalar == nil { 1775 break 1776 } 1777 1778 return e.complexity.Query.WrappedScalar(childComplexity), true 1779 1780 case "Query.wrappedSlice": 1781 if e.complexity.Query.WrappedSlice == nil { 1782 break 1783 } 1784 1785 return e.complexity.Query.WrappedSlice(childComplexity), true 1786 1787 case "Query.wrappedStruct": 1788 if e.complexity.Query.WrappedStruct == nil { 1789 break 1790 } 1791 1792 return e.complexity.Query.WrappedStruct(childComplexity), true 1793 1794 case "Rectangle.area": 1795 if e.complexity.Rectangle.Area == nil { 1796 break 1797 } 1798 1799 return e.complexity.Rectangle.Area(childComplexity), true 1800 1801 case "Rectangle.coordinates": 1802 if e.complexity.Rectangle.Coordinates == nil { 1803 break 1804 } 1805 1806 return e.complexity.Rectangle.Coordinates(childComplexity), true 1807 1808 case "Rectangle.length": 1809 if e.complexity.Rectangle.Length == nil { 1810 break 1811 } 1812 1813 return e.complexity.Rectangle.Length(childComplexity), true 1814 1815 case "Rectangle.width": 1816 if e.complexity.Rectangle.Width == nil { 1817 break 1818 } 1819 1820 return e.complexity.Rectangle.Width(childComplexity), true 1821 1822 case "Slices.test1": 1823 if e.complexity.Slices.Test1 == nil { 1824 break 1825 } 1826 1827 return e.complexity.Slices.Test1(childComplexity), true 1828 1829 case "Slices.test2": 1830 if e.complexity.Slices.Test2 == nil { 1831 break 1832 } 1833 1834 return e.complexity.Slices.Test2(childComplexity), true 1835 1836 case "Slices.test3": 1837 if e.complexity.Slices.Test3 == nil { 1838 break 1839 } 1840 1841 return e.complexity.Slices.Test3(childComplexity), true 1842 1843 case "Slices.test4": 1844 if e.complexity.Slices.Test4 == nil { 1845 break 1846 } 1847 1848 return e.complexity.Slices.Test4(childComplexity), true 1849 1850 case "Subscription.directiveArg": 1851 if e.complexity.Subscription.DirectiveArg == nil { 1852 break 1853 } 1854 1855 args, err := ec.field_Subscription_directiveArg_args(context.TODO(), rawArgs) 1856 if err != nil { 1857 return 0, false 1858 } 1859 1860 return e.complexity.Subscription.DirectiveArg(childComplexity, args["arg"].(string)), true 1861 1862 case "Subscription.directiveDouble": 1863 if e.complexity.Subscription.DirectiveDouble == nil { 1864 break 1865 } 1866 1867 return e.complexity.Subscription.DirectiveDouble(childComplexity), true 1868 1869 case "Subscription.directiveNullableArg": 1870 if e.complexity.Subscription.DirectiveNullableArg == nil { 1871 break 1872 } 1873 1874 args, err := ec.field_Subscription_directiveNullableArg_args(context.TODO(), rawArgs) 1875 if err != nil { 1876 return 0, false 1877 } 1878 1879 return e.complexity.Subscription.DirectiveNullableArg(childComplexity, args["arg"].(*int), args["arg2"].(*int), args["arg3"].(*string)), true 1880 1881 case "Subscription.directiveUnimplemented": 1882 if e.complexity.Subscription.DirectiveUnimplemented == nil { 1883 break 1884 } 1885 1886 return e.complexity.Subscription.DirectiveUnimplemented(childComplexity), true 1887 1888 case "Subscription.errorRequired": 1889 if e.complexity.Subscription.ErrorRequired == nil { 1890 break 1891 } 1892 1893 return e.complexity.Subscription.ErrorRequired(childComplexity), true 1894 1895 case "Subscription.initPayload": 1896 if e.complexity.Subscription.InitPayload == nil { 1897 break 1898 } 1899 1900 return e.complexity.Subscription.InitPayload(childComplexity), true 1901 1902 case "Subscription.issue896b": 1903 if e.complexity.Subscription.Issue896b == nil { 1904 break 1905 } 1906 1907 return e.complexity.Subscription.Issue896b(childComplexity), true 1908 1909 case "Subscription.updated": 1910 if e.complexity.Subscription.Updated == nil { 1911 break 1912 } 1913 1914 return e.complexity.Subscription.Updated(childComplexity), true 1915 1916 case "User.created": 1917 if e.complexity.User.Created == nil { 1918 break 1919 } 1920 1921 return e.complexity.User.Created(childComplexity), true 1922 1923 case "User.friends": 1924 if e.complexity.User.Friends == nil { 1925 break 1926 } 1927 1928 return e.complexity.User.Friends(childComplexity), true 1929 1930 case "User.id": 1931 if e.complexity.User.ID == nil { 1932 break 1933 } 1934 1935 return e.complexity.User.ID(childComplexity), true 1936 1937 case "User.pets": 1938 if e.complexity.User.Pets == nil { 1939 break 1940 } 1941 1942 args, err := ec.field_User_pets_args(context.TODO(), rawArgs) 1943 if err != nil { 1944 return 0, false 1945 } 1946 1947 return e.complexity.User.Pets(childComplexity, args["limit"].(*int)), true 1948 1949 case "User.updated": 1950 if e.complexity.User.Updated == nil { 1951 break 1952 } 1953 1954 return e.complexity.User.Updated(childComplexity), true 1955 1956 case "VOkCaseNil.value": 1957 if e.complexity.VOkCaseNil.Value == nil { 1958 break 1959 } 1960 1961 return e.complexity.VOkCaseNil.Value(childComplexity), true 1962 1963 case "VOkCaseValue.value": 1964 if e.complexity.VOkCaseValue.Value == nil { 1965 break 1966 } 1967 1968 return e.complexity.VOkCaseValue.Value(childComplexity), true 1969 1970 case "ValidType.differentCase": 1971 if e.complexity.ValidType.DifferentCase == nil { 1972 break 1973 } 1974 1975 return e.complexity.ValidType.DifferentCase(childComplexity), true 1976 1977 case "ValidType.different_case": 1978 if e.complexity.ValidType.DifferentCaseOld == nil { 1979 break 1980 } 1981 1982 return e.complexity.ValidType.DifferentCaseOld(childComplexity), true 1983 1984 case "ValidType.validArgs": 1985 if e.complexity.ValidType.ValidArgs == nil { 1986 break 1987 } 1988 1989 args, err := ec.field_ValidType_validArgs_args(context.TODO(), rawArgs) 1990 if err != nil { 1991 return 0, false 1992 } 1993 1994 return e.complexity.ValidType.ValidArgs(childComplexity, args["break"].(string), args["default"].(string), args["func"].(string), args["interface"].(string), args["select"].(string), args["case"].(string), args["defer"].(string), args["go"].(string), args["map"].(string), args["struct"].(string), args["chan"].(string), args["else"].(string), args["goto"].(string), args["package"].(string), args["switch"].(string), args["const"].(string), args["fallthrough"].(string), args["if"].(string), args["range"].(string), args["type"].(string), args["continue"].(string), args["for"].(string), args["import"].(string), args["return"].(string), args["var"].(string), args["_"].(string)), true 1995 1996 case "ValidType.validInputKeywords": 1997 if e.complexity.ValidType.ValidInputKeywords == nil { 1998 break 1999 } 2000 2001 args, err := ec.field_ValidType_validInputKeywords_args(context.TODO(), rawArgs) 2002 if err != nil { 2003 return 0, false 2004 } 2005 2006 return e.complexity.ValidType.ValidInputKeywords(childComplexity, args["input"].(*ValidInput)), true 2007 2008 case "VariadicModel.value": 2009 if e.complexity.VariadicModel.Value == nil { 2010 break 2011 } 2012 2013 args, err := ec.field_VariadicModel_value_args(context.TODO(), rawArgs) 2014 if err != nil { 2015 return 0, false 2016 } 2017 2018 return e.complexity.VariadicModel.Value(childComplexity, args["rank"].(int)), true 2019 2020 case "WrappedMap.get": 2021 if e.complexity.WrappedMap.Get == nil { 2022 break 2023 } 2024 2025 args, err := ec.field_WrappedMap_get_args(context.TODO(), rawArgs) 2026 if err != nil { 2027 return 0, false 2028 } 2029 2030 return e.complexity.WrappedMap.Get(childComplexity, args["key"].(string)), true 2031 2032 case "WrappedSlice.get": 2033 if e.complexity.WrappedSlice.Get == nil { 2034 break 2035 } 2036 2037 args, err := ec.field_WrappedSlice_get_args(context.TODO(), rawArgs) 2038 if err != nil { 2039 return 0, false 2040 } 2041 2042 return e.complexity.WrappedSlice.Get(childComplexity, args["idx"].(int)), true 2043 2044 case "WrappedStruct.desc": 2045 if e.complexity.WrappedStruct.Desc == nil { 2046 break 2047 } 2048 2049 return e.complexity.WrappedStruct.Desc(childComplexity), true 2050 2051 case "WrappedStruct.name": 2052 if e.complexity.WrappedStruct.Name == nil { 2053 break 2054 } 2055 2056 return e.complexity.WrappedStruct.Name(childComplexity), true 2057 2058 case "XXIt.id": 2059 if e.complexity.XXIt.ID == nil { 2060 break 2061 } 2062 2063 return e.complexity.XXIt.ID(childComplexity), true 2064 2065 case "XxIt.id": 2066 if e.complexity.XxIt.ID == nil { 2067 break 2068 } 2069 2070 return e.complexity.XxIt.ID(childComplexity), true 2071 2072 case "asdfIt.id": 2073 if e.complexity.AsdfIt.ID == nil { 2074 break 2075 } 2076 2077 return e.complexity.AsdfIt.ID(childComplexity), true 2078 2079 case "iIt.id": 2080 if e.complexity.IIt.ID == nil { 2081 break 2082 } 2083 2084 return e.complexity.IIt.ID(childComplexity), true 2085 2086 } 2087 return 0, false 2088 } 2089 2090 func (e *executableSchema) Exec(ctx context.Context) graphql.ResponseHandler { 2091 rc := graphql.GetOperationContext(ctx) 2092 ec := executionContext{rc, e} 2093 inputUnmarshalMap := graphql.BuildUnmarshalerMap( 2094 ec.unmarshalInputDefaultInput, 2095 ec.unmarshalInputFieldsOrderInput, 2096 ec.unmarshalInputInnerDirectives, 2097 ec.unmarshalInputInnerInput, 2098 ec.unmarshalInputInputDirectives, 2099 ec.unmarshalInputInputWithEnumValue, 2100 ec.unmarshalInputNestedInput, 2101 ec.unmarshalInputNestedMapInput, 2102 ec.unmarshalInputOuterInput, 2103 ec.unmarshalInputRecursiveInputSlice, 2104 ec.unmarshalInputSpecialInput, 2105 ec.unmarshalInputUpdatePtrToPtrInner, 2106 ec.unmarshalInputUpdatePtrToPtrOuter, 2107 ec.unmarshalInputValidInput, 2108 ) 2109 first := true 2110 2111 switch rc.Operation.Operation { 2112 case ast.Query: 2113 return func(ctx context.Context) *graphql.Response { 2114 if !first { 2115 return nil 2116 } 2117 first = false 2118 ctx = graphql.WithUnmarshalerMap(ctx, inputUnmarshalMap) 2119 data := ec._Query(ctx, rc.Operation.SelectionSet) 2120 var buf bytes.Buffer 2121 data.MarshalGQL(&buf) 2122 2123 return &graphql.Response{ 2124 Data: buf.Bytes(), 2125 } 2126 } 2127 case ast.Mutation: 2128 return func(ctx context.Context) *graphql.Response { 2129 if !first { 2130 return nil 2131 } 2132 first = false 2133 ctx = graphql.WithUnmarshalerMap(ctx, inputUnmarshalMap) 2134 data := ec._Mutation(ctx, rc.Operation.SelectionSet) 2135 var buf bytes.Buffer 2136 data.MarshalGQL(&buf) 2137 2138 return &graphql.Response{ 2139 Data: buf.Bytes(), 2140 } 2141 } 2142 case ast.Subscription: 2143 next := ec._Subscription(ctx, rc.Operation.SelectionSet) 2144 2145 var buf bytes.Buffer 2146 return func(ctx context.Context) *graphql.Response { 2147 buf.Reset() 2148 data := next(ctx) 2149 2150 if data == nil { 2151 return nil 2152 } 2153 data.MarshalGQL(&buf) 2154 2155 return &graphql.Response{ 2156 Data: buf.Bytes(), 2157 } 2158 } 2159 2160 default: 2161 return graphql.OneShot(graphql.ErrorResponse(ctx, "unsupported GraphQL operation")) 2162 } 2163 } 2164 2165 type executionContext struct { 2166 *graphql.OperationContext 2167 *executableSchema 2168 } 2169 2170 func (ec *executionContext) introspectSchema() (*introspection.Schema, error) { 2171 if ec.DisableIntrospection { 2172 return nil, errors.New("introspection disabled") 2173 } 2174 return introspection.WrapSchema(parsedSchema), nil 2175 } 2176 2177 func (ec *executionContext) introspectType(name string) (*introspection.Type, error) { 2178 if ec.DisableIntrospection { 2179 return nil, errors.New("introspection disabled") 2180 } 2181 return introspection.WrapTypeFromDef(parsedSchema, parsedSchema.Types[name]), nil 2182 } 2183 2184 //go:embed "builtinscalar.graphql" "complexity.graphql" "defaults.graphql" "directive.graphql" "embedded.graphql" "enum.graphql" "fields_order.graphql" "interfaces.graphql" "issue896.graphql" "loops.graphql" "maps.graphql" "mutation_with_custom_scalar.graphql" "nulls.graphql" "panics.graphql" "primitive_objects.graphql" "ptr_to_ptr_input.graphql" "ptr_to_slice.graphql" "scalar_context.graphql" "scalar_default.graphql" "schema.graphql" "slices.graphql" "typefallback.graphql" "useptr.graphql" "v-ok.graphql" "validtypes.graphql" "variadic.graphql" "weird_type_cases.graphql" "wrapped_type.graphql" 2185 var sourcesFS embed.FS 2186 2187 func sourceData(filename string) string { 2188 data, err := sourcesFS.ReadFile(filename) 2189 if err != nil { 2190 panic(fmt.Sprintf("codegen problem: %s not available", filename)) 2191 } 2192 return string(data) 2193 } 2194 2195 var sources = []*ast.Source{ 2196 {Name: "builtinscalar.graphql", Input: sourceData("builtinscalar.graphql"), BuiltIn: false}, 2197 {Name: "complexity.graphql", Input: sourceData("complexity.graphql"), BuiltIn: false}, 2198 {Name: "defaults.graphql", Input: sourceData("defaults.graphql"), BuiltIn: false}, 2199 {Name: "directive.graphql", Input: sourceData("directive.graphql"), BuiltIn: false}, 2200 {Name: "embedded.graphql", Input: sourceData("embedded.graphql"), BuiltIn: false}, 2201 {Name: "enum.graphql", Input: sourceData("enum.graphql"), BuiltIn: false}, 2202 {Name: "fields_order.graphql", Input: sourceData("fields_order.graphql"), BuiltIn: false}, 2203 {Name: "interfaces.graphql", Input: sourceData("interfaces.graphql"), BuiltIn: false}, 2204 {Name: "issue896.graphql", Input: sourceData("issue896.graphql"), BuiltIn: false}, 2205 {Name: "loops.graphql", Input: sourceData("loops.graphql"), BuiltIn: false}, 2206 {Name: "maps.graphql", Input: sourceData("maps.graphql"), BuiltIn: false}, 2207 {Name: "mutation_with_custom_scalar.graphql", Input: sourceData("mutation_with_custom_scalar.graphql"), BuiltIn: false}, 2208 {Name: "nulls.graphql", Input: sourceData("nulls.graphql"), BuiltIn: false}, 2209 {Name: "panics.graphql", Input: sourceData("panics.graphql"), BuiltIn: false}, 2210 {Name: "primitive_objects.graphql", Input: sourceData("primitive_objects.graphql"), BuiltIn: false}, 2211 {Name: "ptr_to_ptr_input.graphql", Input: sourceData("ptr_to_ptr_input.graphql"), BuiltIn: false}, 2212 {Name: "ptr_to_slice.graphql", Input: sourceData("ptr_to_slice.graphql"), BuiltIn: false}, 2213 {Name: "scalar_context.graphql", Input: sourceData("scalar_context.graphql"), BuiltIn: false}, 2214 {Name: "scalar_default.graphql", Input: sourceData("scalar_default.graphql"), BuiltIn: false}, 2215 {Name: "schema.graphql", Input: sourceData("schema.graphql"), BuiltIn: false}, 2216 {Name: "slices.graphql", Input: sourceData("slices.graphql"), BuiltIn: false}, 2217 {Name: "typefallback.graphql", Input: sourceData("typefallback.graphql"), BuiltIn: false}, 2218 {Name: "useptr.graphql", Input: sourceData("useptr.graphql"), BuiltIn: false}, 2219 {Name: "v-ok.graphql", Input: sourceData("v-ok.graphql"), BuiltIn: false}, 2220 {Name: "validtypes.graphql", Input: sourceData("validtypes.graphql"), BuiltIn: false}, 2221 {Name: "variadic.graphql", Input: sourceData("variadic.graphql"), BuiltIn: false}, 2222 {Name: "weird_type_cases.graphql", Input: sourceData("weird_type_cases.graphql"), BuiltIn: false}, 2223 {Name: "wrapped_type.graphql", Input: sourceData("wrapped_type.graphql"), BuiltIn: false}, 2224 } 2225 var parsedSchema = gqlparser.MustLoadSchema(sources...) 2226 2227 // endregion ************************** generated!.gotpl ************************** 2228 2229 // region ***************************** args.gotpl ***************************** 2230 2231 func (ec *executionContext) dir_length_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2232 var err error 2233 args := map[string]interface{}{} 2234 var arg0 int 2235 if tmp, ok := rawArgs["min"]; ok { 2236 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("min")) 2237 arg0, err = ec.unmarshalNInt2int(ctx, tmp) 2238 if err != nil { 2239 return nil, err 2240 } 2241 } 2242 args["min"] = arg0 2243 var arg1 *int 2244 if tmp, ok := rawArgs["max"]; ok { 2245 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("max")) 2246 arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) 2247 if err != nil { 2248 return nil, err 2249 } 2250 } 2251 args["max"] = arg1 2252 var arg2 *string 2253 if tmp, ok := rawArgs["message"]; ok { 2254 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("message")) 2255 arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) 2256 if err != nil { 2257 return nil, err 2258 } 2259 } 2260 args["message"] = arg2 2261 return args, nil 2262 } 2263 2264 func (ec *executionContext) dir_logged_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2265 var err error 2266 args := map[string]interface{}{} 2267 var arg0 string 2268 if tmp, ok := rawArgs["id"]; ok { 2269 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) 2270 arg0, err = ec.unmarshalNUUID2string(ctx, tmp) 2271 if err != nil { 2272 return nil, err 2273 } 2274 } 2275 args["id"] = arg0 2276 return args, nil 2277 } 2278 2279 func (ec *executionContext) dir_order1_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2280 var err error 2281 args := map[string]interface{}{} 2282 var arg0 string 2283 if tmp, ok := rawArgs["location"]; ok { 2284 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("location")) 2285 arg0, err = ec.unmarshalNString2string(ctx, tmp) 2286 if err != nil { 2287 return nil, err 2288 } 2289 } 2290 args["location"] = arg0 2291 return args, nil 2292 } 2293 2294 func (ec *executionContext) dir_order2_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2295 var err error 2296 args := map[string]interface{}{} 2297 var arg0 string 2298 if tmp, ok := rawArgs["location"]; ok { 2299 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("location")) 2300 arg0, err = ec.unmarshalNString2string(ctx, tmp) 2301 if err != nil { 2302 return nil, err 2303 } 2304 } 2305 args["location"] = arg0 2306 return args, nil 2307 } 2308 2309 func (ec *executionContext) dir_range_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2310 var err error 2311 args := map[string]interface{}{} 2312 var arg0 *int 2313 if tmp, ok := rawArgs["min"]; ok { 2314 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("min")) 2315 arg0, err = ec.unmarshalOInt2ᚖint(ctx, tmp) 2316 if err != nil { 2317 return nil, err 2318 } 2319 } 2320 args["min"] = arg0 2321 var arg1 *int 2322 if tmp, ok := rawArgs["max"]; ok { 2323 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("max")) 2324 arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) 2325 if err != nil { 2326 return nil, err 2327 } 2328 } 2329 args["max"] = arg1 2330 return args, nil 2331 } 2332 2333 func (ec *executionContext) field_Mutation_defaultInput_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2334 var err error 2335 args := map[string]interface{}{} 2336 var arg0 DefaultInput 2337 if tmp, ok := rawArgs["input"]; ok { 2338 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) 2339 arg0, err = ec.unmarshalNDefaultInput2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐDefaultInput(ctx, tmp) 2340 if err != nil { 2341 return nil, err 2342 } 2343 } 2344 args["input"] = arg0 2345 return args, nil 2346 } 2347 2348 func (ec *executionContext) field_Mutation_overrideValueViaInput_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2349 var err error 2350 args := map[string]interface{}{} 2351 var arg0 FieldsOrderInput 2352 if tmp, ok := rawArgs["input"]; ok { 2353 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) 2354 arg0, err = ec.unmarshalNFieldsOrderInput2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐFieldsOrderInput(ctx, tmp) 2355 if err != nil { 2356 return nil, err 2357 } 2358 } 2359 args["input"] = arg0 2360 return args, nil 2361 } 2362 2363 func (ec *executionContext) field_Mutation_updatePtrToPtr_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2364 var err error 2365 args := map[string]interface{}{} 2366 var arg0 UpdatePtrToPtrOuter 2367 if tmp, ok := rawArgs["input"]; ok { 2368 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) 2369 arg0, err = ec.unmarshalNUpdatePtrToPtrOuter2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUpdatePtrToPtrOuter(ctx, tmp) 2370 if err != nil { 2371 return nil, err 2372 } 2373 } 2374 args["input"] = arg0 2375 return args, nil 2376 } 2377 2378 func (ec *executionContext) field_Mutation_updateSomething_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2379 var err error 2380 args := map[string]interface{}{} 2381 var arg0 SpecialInput 2382 if tmp, ok := rawArgs["input"]; ok { 2383 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) 2384 arg0, err = ec.unmarshalNSpecialInput2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐSpecialInput(ctx, tmp) 2385 if err != nil { 2386 return nil, err 2387 } 2388 } 2389 args["input"] = arg0 2390 return args, nil 2391 } 2392 2393 func (ec *executionContext) field_Panics_argUnmarshal_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2394 var err error 2395 args := map[string]interface{}{} 2396 var arg0 []MarshalPanic 2397 if tmp, ok := rawArgs["u"]; ok { 2398 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("u")) 2399 arg0, err = ec.unmarshalNMarshalPanic2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐMarshalPanicᚄ(ctx, tmp) 2400 if err != nil { 2401 return nil, err 2402 } 2403 } 2404 args["u"] = arg0 2405 return args, nil 2406 } 2407 2408 func (ec *executionContext) field_Panics_fieldFuncMarshal_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2409 var err error 2410 args := map[string]interface{}{} 2411 var arg0 []MarshalPanic 2412 if tmp, ok := rawArgs["u"]; ok { 2413 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("u")) 2414 arg0, err = ec.unmarshalNMarshalPanic2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐMarshalPanicᚄ(ctx, tmp) 2415 if err != nil { 2416 return nil, err 2417 } 2418 } 2419 args["u"] = arg0 2420 return args, nil 2421 } 2422 2423 func (ec *executionContext) field_Pet_friends_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2424 var err error 2425 args := map[string]interface{}{} 2426 var arg0 *int 2427 if tmp, ok := rawArgs["limit"]; ok { 2428 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("limit")) 2429 arg0, err = ec.unmarshalOInt2ᚖint(ctx, tmp) 2430 if err != nil { 2431 return nil, err 2432 } 2433 } 2434 args["limit"] = arg0 2435 return args, nil 2436 } 2437 2438 func (ec *executionContext) field_Query___type_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2439 var err error 2440 args := map[string]interface{}{} 2441 var arg0 string 2442 if tmp, ok := rawArgs["name"]; ok { 2443 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("name")) 2444 arg0, err = ec.unmarshalNString2string(ctx, tmp) 2445 if err != nil { 2446 return nil, err 2447 } 2448 } 2449 args["name"] = arg0 2450 return args, nil 2451 } 2452 2453 func (ec *executionContext) field_Query_defaultParameters_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2454 var err error 2455 args := map[string]interface{}{} 2456 var arg0 *bool 2457 if tmp, ok := rawArgs["falsyBoolean"]; ok { 2458 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("falsyBoolean")) 2459 arg0, err = ec.unmarshalOBoolean2ᚖbool(ctx, tmp) 2460 if err != nil { 2461 return nil, err 2462 } 2463 } 2464 args["falsyBoolean"] = arg0 2465 var arg1 *bool 2466 if tmp, ok := rawArgs["truthyBoolean"]; ok { 2467 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("truthyBoolean")) 2468 arg1, err = ec.unmarshalOBoolean2ᚖbool(ctx, tmp) 2469 if err != nil { 2470 return nil, err 2471 } 2472 } 2473 args["truthyBoolean"] = arg1 2474 return args, nil 2475 } 2476 2477 func (ec *executionContext) field_Query_defaultScalar_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2478 var err error 2479 args := map[string]interface{}{} 2480 var arg0 string 2481 if tmp, ok := rawArgs["arg"]; ok { 2482 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("arg")) 2483 arg0, err = ec.unmarshalNDefaultScalarImplementation2string(ctx, tmp) 2484 if err != nil { 2485 return nil, err 2486 } 2487 } 2488 args["arg"] = arg0 2489 return args, nil 2490 } 2491 2492 func (ec *executionContext) field_Query_directiveArg_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2493 var err error 2494 args := map[string]interface{}{} 2495 var arg0 string 2496 if tmp, ok := rawArgs["arg"]; ok { 2497 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("arg")) 2498 directive0 := func(ctx context.Context) (interface{}, error) { return ec.unmarshalNString2string(ctx, tmp) } 2499 directive1 := func(ctx context.Context) (interface{}, error) { 2500 min, err := ec.unmarshalNInt2int(ctx, 1) 2501 if err != nil { 2502 return nil, err 2503 } 2504 max, err := ec.unmarshalOInt2ᚖint(ctx, 255) 2505 if err != nil { 2506 return nil, err 2507 } 2508 message, err := ec.unmarshalOString2ᚖstring(ctx, "invalid length") 2509 if err != nil { 2510 return nil, err 2511 } 2512 if ec.directives.Length == nil { 2513 return nil, errors.New("directive length is not implemented") 2514 } 2515 return ec.directives.Length(ctx, rawArgs, directive0, min, max, message) 2516 } 2517 2518 tmp, err = directive1(ctx) 2519 if err != nil { 2520 return nil, graphql.ErrorOnPath(ctx, err) 2521 } 2522 if data, ok := tmp.(string); ok { 2523 arg0 = data 2524 } else { 2525 return nil, graphql.ErrorOnPath(ctx, fmt.Errorf(`unexpected type %T from directive, should be string`, tmp)) 2526 } 2527 } 2528 args["arg"] = arg0 2529 return args, nil 2530 } 2531 2532 func (ec *executionContext) field_Query_directiveFieldDef_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2533 var err error 2534 args := map[string]interface{}{} 2535 var arg0 string 2536 if tmp, ok := rawArgs["ret"]; ok { 2537 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("ret")) 2538 arg0, err = ec.unmarshalNString2string(ctx, tmp) 2539 if err != nil { 2540 return nil, err 2541 } 2542 } 2543 args["ret"] = arg0 2544 return args, nil 2545 } 2546 2547 func (ec *executionContext) field_Query_directiveInputNullable_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2548 var err error 2549 args := map[string]interface{}{} 2550 var arg0 *InputDirectives 2551 if tmp, ok := rawArgs["arg"]; ok { 2552 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("arg")) 2553 arg0, err = ec.unmarshalOInputDirectives2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐInputDirectives(ctx, tmp) 2554 if err != nil { 2555 return nil, err 2556 } 2557 } 2558 args["arg"] = arg0 2559 return args, nil 2560 } 2561 2562 func (ec *executionContext) field_Query_directiveInputType_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2563 var err error 2564 args := map[string]interface{}{} 2565 var arg0 InnerInput 2566 if tmp, ok := rawArgs["arg"]; ok { 2567 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("arg")) 2568 directive0 := func(ctx context.Context) (interface{}, error) { 2569 return ec.unmarshalNInnerInput2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐInnerInput(ctx, tmp) 2570 } 2571 directive1 := func(ctx context.Context) (interface{}, error) { 2572 if ec.directives.Custom == nil { 2573 return nil, errors.New("directive custom is not implemented") 2574 } 2575 return ec.directives.Custom(ctx, rawArgs, directive0) 2576 } 2577 2578 tmp, err = directive1(ctx) 2579 if err != nil { 2580 return nil, graphql.ErrorOnPath(ctx, err) 2581 } 2582 if data, ok := tmp.(InnerInput); ok { 2583 arg0 = data 2584 } else { 2585 return nil, graphql.ErrorOnPath(ctx, fmt.Errorf(`unexpected type %T from directive, should be github.com/luciferinlove/gqlgen/codegen/testserver/singlefile.InnerInput`, tmp)) 2586 } 2587 } 2588 args["arg"] = arg0 2589 return args, nil 2590 } 2591 2592 func (ec *executionContext) field_Query_directiveInput_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2593 var err error 2594 args := map[string]interface{}{} 2595 var arg0 InputDirectives 2596 if tmp, ok := rawArgs["arg"]; ok { 2597 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("arg")) 2598 arg0, err = ec.unmarshalNInputDirectives2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐInputDirectives(ctx, tmp) 2599 if err != nil { 2600 return nil, err 2601 } 2602 } 2603 args["arg"] = arg0 2604 return args, nil 2605 } 2606 2607 func (ec *executionContext) field_Query_directiveNullableArg_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2608 var err error 2609 args := map[string]interface{}{} 2610 var arg0 *int 2611 if tmp, ok := rawArgs["arg"]; ok { 2612 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("arg")) 2613 directive0 := func(ctx context.Context) (interface{}, error) { return ec.unmarshalOInt2ᚖint(ctx, tmp) } 2614 directive1 := func(ctx context.Context) (interface{}, error) { 2615 min, err := ec.unmarshalOInt2ᚖint(ctx, 0) 2616 if err != nil { 2617 return nil, err 2618 } 2619 if ec.directives.Range == nil { 2620 return nil, errors.New("directive range is not implemented") 2621 } 2622 return ec.directives.Range(ctx, rawArgs, directive0, min, nil) 2623 } 2624 2625 tmp, err = directive1(ctx) 2626 if err != nil { 2627 return nil, graphql.ErrorOnPath(ctx, err) 2628 } 2629 if data, ok := tmp.(*int); ok { 2630 arg0 = data 2631 } else if tmp == nil { 2632 arg0 = nil 2633 } else { 2634 return nil, graphql.ErrorOnPath(ctx, fmt.Errorf(`unexpected type %T from directive, should be *int`, tmp)) 2635 } 2636 } 2637 args["arg"] = arg0 2638 var arg1 *int 2639 if tmp, ok := rawArgs["arg2"]; ok { 2640 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("arg2")) 2641 directive0 := func(ctx context.Context) (interface{}, error) { return ec.unmarshalOInt2ᚖint(ctx, tmp) } 2642 directive1 := func(ctx context.Context) (interface{}, error) { 2643 min, err := ec.unmarshalOInt2ᚖint(ctx, 0) 2644 if err != nil { 2645 return nil, err 2646 } 2647 if ec.directives.Range == nil { 2648 return nil, errors.New("directive range is not implemented") 2649 } 2650 return ec.directives.Range(ctx, rawArgs, directive0, min, nil) 2651 } 2652 2653 tmp, err = directive1(ctx) 2654 if err != nil { 2655 return nil, graphql.ErrorOnPath(ctx, err) 2656 } 2657 if data, ok := tmp.(*int); ok { 2658 arg1 = data 2659 } else if tmp == nil { 2660 arg1 = nil 2661 } else { 2662 return nil, graphql.ErrorOnPath(ctx, fmt.Errorf(`unexpected type %T from directive, should be *int`, tmp)) 2663 } 2664 } 2665 args["arg2"] = arg1 2666 var arg2 *string 2667 if tmp, ok := rawArgs["arg3"]; ok { 2668 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("arg3")) 2669 directive0 := func(ctx context.Context) (interface{}, error) { return ec.unmarshalOString2ᚖstring(ctx, tmp) } 2670 directive1 := func(ctx context.Context) (interface{}, error) { 2671 if ec.directives.ToNull == nil { 2672 return nil, errors.New("directive toNull is not implemented") 2673 } 2674 return ec.directives.ToNull(ctx, rawArgs, directive0) 2675 } 2676 2677 tmp, err = directive1(ctx) 2678 if err != nil { 2679 return nil, graphql.ErrorOnPath(ctx, err) 2680 } 2681 if data, ok := tmp.(*string); ok { 2682 arg2 = data 2683 } else if tmp == nil { 2684 arg2 = nil 2685 } else { 2686 return nil, graphql.ErrorOnPath(ctx, fmt.Errorf(`unexpected type %T from directive, should be *string`, tmp)) 2687 } 2688 } 2689 args["arg3"] = arg2 2690 return args, nil 2691 } 2692 2693 func (ec *executionContext) field_Query_enumInInput_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2694 var err error 2695 args := map[string]interface{}{} 2696 var arg0 *InputWithEnumValue 2697 if tmp, ok := rawArgs["input"]; ok { 2698 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) 2699 arg0, err = ec.unmarshalOInputWithEnumValue2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐInputWithEnumValue(ctx, tmp) 2700 if err != nil { 2701 return nil, err 2702 } 2703 } 2704 args["input"] = arg0 2705 return args, nil 2706 } 2707 2708 func (ec *executionContext) field_Query_fallback_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2709 var err error 2710 args := map[string]interface{}{} 2711 var arg0 FallbackToStringEncoding 2712 if tmp, ok := rawArgs["arg"]; ok { 2713 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("arg")) 2714 arg0, err = ec.unmarshalNFallbackToStringEncoding2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐFallbackToStringEncoding(ctx, tmp) 2715 if err != nil { 2716 return nil, err 2717 } 2718 } 2719 args["arg"] = arg0 2720 return args, nil 2721 } 2722 2723 func (ec *executionContext) field_Query_inputNullableSlice_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2724 var err error 2725 args := map[string]interface{}{} 2726 var arg0 []string 2727 if tmp, ok := rawArgs["arg"]; ok { 2728 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("arg")) 2729 arg0, err = ec.unmarshalOString2ᚕstringᚄ(ctx, tmp) 2730 if err != nil { 2731 return nil, err 2732 } 2733 } 2734 args["arg"] = arg0 2735 return args, nil 2736 } 2737 2738 func (ec *executionContext) field_Query_inputSlice_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2739 var err error 2740 args := map[string]interface{}{} 2741 var arg0 []string 2742 if tmp, ok := rawArgs["arg"]; ok { 2743 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("arg")) 2744 arg0, err = ec.unmarshalNString2ᚕstringᚄ(ctx, tmp) 2745 if err != nil { 2746 return nil, err 2747 } 2748 } 2749 args["arg"] = arg0 2750 return args, nil 2751 } 2752 2753 func (ec *executionContext) field_Query_mapInput_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2754 var err error 2755 args := map[string]interface{}{} 2756 var arg0 map[string]interface{} 2757 if tmp, ok := rawArgs["input"]; ok { 2758 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) 2759 arg0, err = ec.unmarshalOChanges2map(ctx, tmp) 2760 if err != nil { 2761 return nil, err 2762 } 2763 } 2764 args["input"] = arg0 2765 return args, nil 2766 } 2767 2768 func (ec *executionContext) field_Query_mapNestedStringInterface_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2769 var err error 2770 args := map[string]interface{}{} 2771 var arg0 *NestedMapInput 2772 if tmp, ok := rawArgs["in"]; ok { 2773 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("in")) 2774 arg0, err = ec.unmarshalONestedMapInput2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐNestedMapInput(ctx, tmp) 2775 if err != nil { 2776 return nil, err 2777 } 2778 } 2779 args["in"] = arg0 2780 return args, nil 2781 } 2782 2783 func (ec *executionContext) field_Query_mapStringInterface_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2784 var err error 2785 args := map[string]interface{}{} 2786 var arg0 map[string]interface{} 2787 if tmp, ok := rawArgs["in"]; ok { 2788 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("in")) 2789 arg0, err = ec.unmarshalOMapStringInterfaceInput2map(ctx, tmp) 2790 if err != nil { 2791 return nil, err 2792 } 2793 } 2794 args["in"] = arg0 2795 return args, nil 2796 } 2797 2798 func (ec *executionContext) field_Query_nestedInputs_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2799 var err error 2800 args := map[string]interface{}{} 2801 var arg0 [][]*OuterInput 2802 if tmp, ok := rawArgs["input"]; ok { 2803 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) 2804 arg0, err = ec.unmarshalOOuterInput2ᚕᚕᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐOuterInput(ctx, tmp) 2805 if err != nil { 2806 return nil, err 2807 } 2808 } 2809 args["input"] = arg0 2810 return args, nil 2811 } 2812 2813 func (ec *executionContext) field_Query_nullableArg_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2814 var err error 2815 args := map[string]interface{}{} 2816 var arg0 *int 2817 if tmp, ok := rawArgs["arg"]; ok { 2818 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("arg")) 2819 arg0, err = ec.unmarshalOInt2ᚖint(ctx, tmp) 2820 if err != nil { 2821 return nil, err 2822 } 2823 } 2824 args["arg"] = arg0 2825 return args, nil 2826 } 2827 2828 func (ec *executionContext) field_Query_recursive_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2829 var err error 2830 args := map[string]interface{}{} 2831 var arg0 *RecursiveInputSlice 2832 if tmp, ok := rawArgs["input"]; ok { 2833 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) 2834 arg0, err = ec.unmarshalORecursiveInputSlice2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐRecursiveInputSlice(ctx, tmp) 2835 if err != nil { 2836 return nil, err 2837 } 2838 } 2839 args["input"] = arg0 2840 return args, nil 2841 } 2842 2843 func (ec *executionContext) field_Query_user_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2844 var err error 2845 args := map[string]interface{}{} 2846 var arg0 int 2847 if tmp, ok := rawArgs["id"]; ok { 2848 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) 2849 arg0, err = ec.unmarshalNInt2int(ctx, tmp) 2850 if err != nil { 2851 return nil, err 2852 } 2853 } 2854 args["id"] = arg0 2855 return args, nil 2856 } 2857 2858 func (ec *executionContext) field_Subscription_directiveArg_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2859 var err error 2860 args := map[string]interface{}{} 2861 var arg0 string 2862 if tmp, ok := rawArgs["arg"]; ok { 2863 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("arg")) 2864 directive0 := func(ctx context.Context) (interface{}, error) { return ec.unmarshalNString2string(ctx, tmp) } 2865 directive1 := func(ctx context.Context) (interface{}, error) { 2866 min, err := ec.unmarshalNInt2int(ctx, 1) 2867 if err != nil { 2868 return nil, err 2869 } 2870 max, err := ec.unmarshalOInt2ᚖint(ctx, 255) 2871 if err != nil { 2872 return nil, err 2873 } 2874 message, err := ec.unmarshalOString2ᚖstring(ctx, "invalid length") 2875 if err != nil { 2876 return nil, err 2877 } 2878 if ec.directives.Length == nil { 2879 return nil, errors.New("directive length is not implemented") 2880 } 2881 return ec.directives.Length(ctx, rawArgs, directive0, min, max, message) 2882 } 2883 2884 tmp, err = directive1(ctx) 2885 if err != nil { 2886 return nil, graphql.ErrorOnPath(ctx, err) 2887 } 2888 if data, ok := tmp.(string); ok { 2889 arg0 = data 2890 } else { 2891 return nil, graphql.ErrorOnPath(ctx, fmt.Errorf(`unexpected type %T from directive, should be string`, tmp)) 2892 } 2893 } 2894 args["arg"] = arg0 2895 return args, nil 2896 } 2897 2898 func (ec *executionContext) field_Subscription_directiveNullableArg_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2899 var err error 2900 args := map[string]interface{}{} 2901 var arg0 *int 2902 if tmp, ok := rawArgs["arg"]; ok { 2903 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("arg")) 2904 directive0 := func(ctx context.Context) (interface{}, error) { return ec.unmarshalOInt2ᚖint(ctx, tmp) } 2905 directive1 := func(ctx context.Context) (interface{}, error) { 2906 min, err := ec.unmarshalOInt2ᚖint(ctx, 0) 2907 if err != nil { 2908 return nil, err 2909 } 2910 if ec.directives.Range == nil { 2911 return nil, errors.New("directive range is not implemented") 2912 } 2913 return ec.directives.Range(ctx, rawArgs, directive0, min, nil) 2914 } 2915 2916 tmp, err = directive1(ctx) 2917 if err != nil { 2918 return nil, graphql.ErrorOnPath(ctx, err) 2919 } 2920 if data, ok := tmp.(*int); ok { 2921 arg0 = data 2922 } else if tmp == nil { 2923 arg0 = nil 2924 } else { 2925 return nil, graphql.ErrorOnPath(ctx, fmt.Errorf(`unexpected type %T from directive, should be *int`, tmp)) 2926 } 2927 } 2928 args["arg"] = arg0 2929 var arg1 *int 2930 if tmp, ok := rawArgs["arg2"]; ok { 2931 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("arg2")) 2932 directive0 := func(ctx context.Context) (interface{}, error) { return ec.unmarshalOInt2ᚖint(ctx, tmp) } 2933 directive1 := func(ctx context.Context) (interface{}, error) { 2934 min, err := ec.unmarshalOInt2ᚖint(ctx, 0) 2935 if err != nil { 2936 return nil, err 2937 } 2938 if ec.directives.Range == nil { 2939 return nil, errors.New("directive range is not implemented") 2940 } 2941 return ec.directives.Range(ctx, rawArgs, directive0, min, nil) 2942 } 2943 2944 tmp, err = directive1(ctx) 2945 if err != nil { 2946 return nil, graphql.ErrorOnPath(ctx, err) 2947 } 2948 if data, ok := tmp.(*int); ok { 2949 arg1 = data 2950 } else if tmp == nil { 2951 arg1 = nil 2952 } else { 2953 return nil, graphql.ErrorOnPath(ctx, fmt.Errorf(`unexpected type %T from directive, should be *int`, tmp)) 2954 } 2955 } 2956 args["arg2"] = arg1 2957 var arg2 *string 2958 if tmp, ok := rawArgs["arg3"]; ok { 2959 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("arg3")) 2960 directive0 := func(ctx context.Context) (interface{}, error) { return ec.unmarshalOString2ᚖstring(ctx, tmp) } 2961 directive1 := func(ctx context.Context) (interface{}, error) { 2962 if ec.directives.ToNull == nil { 2963 return nil, errors.New("directive toNull is not implemented") 2964 } 2965 return ec.directives.ToNull(ctx, rawArgs, directive0) 2966 } 2967 2968 tmp, err = directive1(ctx) 2969 if err != nil { 2970 return nil, graphql.ErrorOnPath(ctx, err) 2971 } 2972 if data, ok := tmp.(*string); ok { 2973 arg2 = data 2974 } else if tmp == nil { 2975 arg2 = nil 2976 } else { 2977 return nil, graphql.ErrorOnPath(ctx, fmt.Errorf(`unexpected type %T from directive, should be *string`, tmp)) 2978 } 2979 } 2980 args["arg3"] = arg2 2981 return args, nil 2982 } 2983 2984 func (ec *executionContext) field_User_pets_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 2985 var err error 2986 args := map[string]interface{}{} 2987 var arg0 *int 2988 if tmp, ok := rawArgs["limit"]; ok { 2989 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("limit")) 2990 arg0, err = ec.unmarshalOInt2ᚖint(ctx, tmp) 2991 if err != nil { 2992 return nil, err 2993 } 2994 } 2995 args["limit"] = arg0 2996 return args, nil 2997 } 2998 2999 func (ec *executionContext) field_ValidType_validArgs_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 3000 var err error 3001 args := map[string]interface{}{} 3002 var arg0 string 3003 if tmp, ok := rawArgs["break"]; ok { 3004 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("break")) 3005 arg0, err = ec.unmarshalNString2string(ctx, tmp) 3006 if err != nil { 3007 return nil, err 3008 } 3009 } 3010 args["break"] = arg0 3011 var arg1 string 3012 if tmp, ok := rawArgs["default"]; ok { 3013 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("default")) 3014 arg1, err = ec.unmarshalNString2string(ctx, tmp) 3015 if err != nil { 3016 return nil, err 3017 } 3018 } 3019 args["default"] = arg1 3020 var arg2 string 3021 if tmp, ok := rawArgs["func"]; ok { 3022 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("func")) 3023 arg2, err = ec.unmarshalNString2string(ctx, tmp) 3024 if err != nil { 3025 return nil, err 3026 } 3027 } 3028 args["func"] = arg2 3029 var arg3 string 3030 if tmp, ok := rawArgs["interface"]; ok { 3031 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("interface")) 3032 arg3, err = ec.unmarshalNString2string(ctx, tmp) 3033 if err != nil { 3034 return nil, err 3035 } 3036 } 3037 args["interface"] = arg3 3038 var arg4 string 3039 if tmp, ok := rawArgs["select"]; ok { 3040 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("select")) 3041 arg4, err = ec.unmarshalNString2string(ctx, tmp) 3042 if err != nil { 3043 return nil, err 3044 } 3045 } 3046 args["select"] = arg4 3047 var arg5 string 3048 if tmp, ok := rawArgs["case"]; ok { 3049 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("case")) 3050 arg5, err = ec.unmarshalNString2string(ctx, tmp) 3051 if err != nil { 3052 return nil, err 3053 } 3054 } 3055 args["case"] = arg5 3056 var arg6 string 3057 if tmp, ok := rawArgs["defer"]; ok { 3058 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("defer")) 3059 arg6, err = ec.unmarshalNString2string(ctx, tmp) 3060 if err != nil { 3061 return nil, err 3062 } 3063 } 3064 args["defer"] = arg6 3065 var arg7 string 3066 if tmp, ok := rawArgs["go"]; ok { 3067 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("go")) 3068 arg7, err = ec.unmarshalNString2string(ctx, tmp) 3069 if err != nil { 3070 return nil, err 3071 } 3072 } 3073 args["go"] = arg7 3074 var arg8 string 3075 if tmp, ok := rawArgs["map"]; ok { 3076 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("map")) 3077 arg8, err = ec.unmarshalNString2string(ctx, tmp) 3078 if err != nil { 3079 return nil, err 3080 } 3081 } 3082 args["map"] = arg8 3083 var arg9 string 3084 if tmp, ok := rawArgs["struct"]; ok { 3085 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("struct")) 3086 arg9, err = ec.unmarshalNString2string(ctx, tmp) 3087 if err != nil { 3088 return nil, err 3089 } 3090 } 3091 args["struct"] = arg9 3092 var arg10 string 3093 if tmp, ok := rawArgs["chan"]; ok { 3094 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("chan")) 3095 arg10, err = ec.unmarshalNString2string(ctx, tmp) 3096 if err != nil { 3097 return nil, err 3098 } 3099 } 3100 args["chan"] = arg10 3101 var arg11 string 3102 if tmp, ok := rawArgs["else"]; ok { 3103 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("else")) 3104 arg11, err = ec.unmarshalNString2string(ctx, tmp) 3105 if err != nil { 3106 return nil, err 3107 } 3108 } 3109 args["else"] = arg11 3110 var arg12 string 3111 if tmp, ok := rawArgs["goto"]; ok { 3112 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("goto")) 3113 arg12, err = ec.unmarshalNString2string(ctx, tmp) 3114 if err != nil { 3115 return nil, err 3116 } 3117 } 3118 args["goto"] = arg12 3119 var arg13 string 3120 if tmp, ok := rawArgs["package"]; ok { 3121 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("package")) 3122 arg13, err = ec.unmarshalNString2string(ctx, tmp) 3123 if err != nil { 3124 return nil, err 3125 } 3126 } 3127 args["package"] = arg13 3128 var arg14 string 3129 if tmp, ok := rawArgs["switch"]; ok { 3130 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("switch")) 3131 arg14, err = ec.unmarshalNString2string(ctx, tmp) 3132 if err != nil { 3133 return nil, err 3134 } 3135 } 3136 args["switch"] = arg14 3137 var arg15 string 3138 if tmp, ok := rawArgs["const"]; ok { 3139 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("const")) 3140 arg15, err = ec.unmarshalNString2string(ctx, tmp) 3141 if err != nil { 3142 return nil, err 3143 } 3144 } 3145 args["const"] = arg15 3146 var arg16 string 3147 if tmp, ok := rawArgs["fallthrough"]; ok { 3148 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("fallthrough")) 3149 arg16, err = ec.unmarshalNString2string(ctx, tmp) 3150 if err != nil { 3151 return nil, err 3152 } 3153 } 3154 args["fallthrough"] = arg16 3155 var arg17 string 3156 if tmp, ok := rawArgs["if"]; ok { 3157 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("if")) 3158 arg17, err = ec.unmarshalNString2string(ctx, tmp) 3159 if err != nil { 3160 return nil, err 3161 } 3162 } 3163 args["if"] = arg17 3164 var arg18 string 3165 if tmp, ok := rawArgs["range"]; ok { 3166 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("range")) 3167 arg18, err = ec.unmarshalNString2string(ctx, tmp) 3168 if err != nil { 3169 return nil, err 3170 } 3171 } 3172 args["range"] = arg18 3173 var arg19 string 3174 if tmp, ok := rawArgs["type"]; ok { 3175 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("type")) 3176 arg19, err = ec.unmarshalNString2string(ctx, tmp) 3177 if err != nil { 3178 return nil, err 3179 } 3180 } 3181 args["type"] = arg19 3182 var arg20 string 3183 if tmp, ok := rawArgs["continue"]; ok { 3184 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("continue")) 3185 arg20, err = ec.unmarshalNString2string(ctx, tmp) 3186 if err != nil { 3187 return nil, err 3188 } 3189 } 3190 args["continue"] = arg20 3191 var arg21 string 3192 if tmp, ok := rawArgs["for"]; ok { 3193 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("for")) 3194 arg21, err = ec.unmarshalNString2string(ctx, tmp) 3195 if err != nil { 3196 return nil, err 3197 } 3198 } 3199 args["for"] = arg21 3200 var arg22 string 3201 if tmp, ok := rawArgs["import"]; ok { 3202 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("import")) 3203 arg22, err = ec.unmarshalNString2string(ctx, tmp) 3204 if err != nil { 3205 return nil, err 3206 } 3207 } 3208 args["import"] = arg22 3209 var arg23 string 3210 if tmp, ok := rawArgs["return"]; ok { 3211 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("return")) 3212 arg23, err = ec.unmarshalNString2string(ctx, tmp) 3213 if err != nil { 3214 return nil, err 3215 } 3216 } 3217 args["return"] = arg23 3218 var arg24 string 3219 if tmp, ok := rawArgs["var"]; ok { 3220 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("var")) 3221 arg24, err = ec.unmarshalNString2string(ctx, tmp) 3222 if err != nil { 3223 return nil, err 3224 } 3225 } 3226 args["var"] = arg24 3227 var arg25 string 3228 if tmp, ok := rawArgs["_"]; ok { 3229 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("_")) 3230 arg25, err = ec.unmarshalNString2string(ctx, tmp) 3231 if err != nil { 3232 return nil, err 3233 } 3234 } 3235 args["_"] = arg25 3236 return args, nil 3237 } 3238 3239 func (ec *executionContext) field_ValidType_validInputKeywords_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 3240 var err error 3241 args := map[string]interface{}{} 3242 var arg0 *ValidInput 3243 if tmp, ok := rawArgs["input"]; ok { 3244 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) 3245 arg0, err = ec.unmarshalOValidInput2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐValidInput(ctx, tmp) 3246 if err != nil { 3247 return nil, err 3248 } 3249 } 3250 args["input"] = arg0 3251 return args, nil 3252 } 3253 3254 func (ec *executionContext) field_VariadicModel_value_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 3255 var err error 3256 args := map[string]interface{}{} 3257 var arg0 int 3258 if tmp, ok := rawArgs["rank"]; ok { 3259 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("rank")) 3260 arg0, err = ec.unmarshalNInt2int(ctx, tmp) 3261 if err != nil { 3262 return nil, err 3263 } 3264 } 3265 args["rank"] = arg0 3266 return args, nil 3267 } 3268 3269 func (ec *executionContext) field_WrappedMap_get_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 3270 var err error 3271 args := map[string]interface{}{} 3272 var arg0 string 3273 if tmp, ok := rawArgs["key"]; ok { 3274 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("key")) 3275 arg0, err = ec.unmarshalNString2string(ctx, tmp) 3276 if err != nil { 3277 return nil, err 3278 } 3279 } 3280 args["key"] = arg0 3281 return args, nil 3282 } 3283 3284 func (ec *executionContext) field_WrappedSlice_get_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 3285 var err error 3286 args := map[string]interface{}{} 3287 var arg0 int 3288 if tmp, ok := rawArgs["idx"]; ok { 3289 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("idx")) 3290 arg0, err = ec.unmarshalNInt2int(ctx, tmp) 3291 if err != nil { 3292 return nil, err 3293 } 3294 } 3295 args["idx"] = arg0 3296 return args, nil 3297 } 3298 3299 func (ec *executionContext) field___Type_enumValues_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 3300 var err error 3301 args := map[string]interface{}{} 3302 var arg0 bool 3303 if tmp, ok := rawArgs["includeDeprecated"]; ok { 3304 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("includeDeprecated")) 3305 arg0, err = ec.unmarshalOBoolean2bool(ctx, tmp) 3306 if err != nil { 3307 return nil, err 3308 } 3309 } 3310 args["includeDeprecated"] = arg0 3311 return args, nil 3312 } 3313 3314 func (ec *executionContext) field___Type_fields_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 3315 var err error 3316 args := map[string]interface{}{} 3317 var arg0 bool 3318 if tmp, ok := rawArgs["includeDeprecated"]; ok { 3319 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("includeDeprecated")) 3320 arg0, err = ec.unmarshalOBoolean2bool(ctx, tmp) 3321 if err != nil { 3322 return nil, err 3323 } 3324 } 3325 args["includeDeprecated"] = arg0 3326 return args, nil 3327 } 3328 3329 // endregion ***************************** args.gotpl ***************************** 3330 3331 // region ************************** directives.gotpl ************************** 3332 3333 func (ec *executionContext) _fieldMiddleware(ctx context.Context, obj interface{}, next graphql.Resolver) interface{} { 3334 fc := graphql.GetFieldContext(ctx) 3335 for _, d := range fc.Field.Directives { 3336 switch d.Name { 3337 case "logged": 3338 rawArgs := d.ArgumentMap(ec.Variables) 3339 args, err := ec.dir_logged_args(ctx, rawArgs) 3340 if err != nil { 3341 ec.Error(ctx, err) 3342 return nil 3343 } 3344 n := next 3345 next = func(ctx context.Context) (interface{}, error) { 3346 if ec.directives.Logged == nil { 3347 return nil, errors.New("directive logged is not implemented") 3348 } 3349 return ec.directives.Logged(ctx, obj, n, args["id"].(string)) 3350 } 3351 } 3352 } 3353 res, err := ec.ResolverMiddleware(ctx, next) 3354 if err != nil { 3355 ec.Error(ctx, err) 3356 return nil 3357 } 3358 return res 3359 } 3360 3361 // endregion ************************** directives.gotpl ************************** 3362 3363 // region **************************** field.gotpl ***************************** 3364 3365 func (ec *executionContext) _A_id(ctx context.Context, field graphql.CollectedField, obj *A) (ret graphql.Marshaler) { 3366 fc, err := ec.fieldContext_A_id(ctx, field) 3367 if err != nil { 3368 return graphql.Null 3369 } 3370 ctx = graphql.WithFieldContext(ctx, fc) 3371 defer func() { 3372 if r := recover(); r != nil { 3373 ec.Error(ctx, ec.Recover(ctx, r)) 3374 ret = graphql.Null 3375 } 3376 }() 3377 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 3378 ctx = rctx // use context from middleware stack in children 3379 return obj.ID, nil 3380 }) 3381 3382 if resTmp == nil { 3383 if !graphql.HasFieldError(ctx, fc) { 3384 ec.Errorf(ctx, "must not be null") 3385 } 3386 return graphql.Null 3387 } 3388 res := resTmp.(string) 3389 fc.Result = res 3390 return ec.marshalNID2string(ctx, field.Selections, res) 3391 } 3392 3393 func (ec *executionContext) fieldContext_A_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 3394 fc = &graphql.FieldContext{ 3395 Object: "A", 3396 Field: field, 3397 IsMethod: false, 3398 IsResolver: false, 3399 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 3400 return nil, errors.New("field of type ID does not have child fields") 3401 }, 3402 } 3403 return fc, nil 3404 } 3405 3406 func (ec *executionContext) _AIt_id(ctx context.Context, field graphql.CollectedField, obj *AIt) (ret graphql.Marshaler) { 3407 fc, err := ec.fieldContext_AIt_id(ctx, field) 3408 if err != nil { 3409 return graphql.Null 3410 } 3411 ctx = graphql.WithFieldContext(ctx, fc) 3412 defer func() { 3413 if r := recover(); r != nil { 3414 ec.Error(ctx, ec.Recover(ctx, r)) 3415 ret = graphql.Null 3416 } 3417 }() 3418 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 3419 ctx = rctx // use context from middleware stack in children 3420 return obj.ID, nil 3421 }) 3422 3423 if resTmp == nil { 3424 if !graphql.HasFieldError(ctx, fc) { 3425 ec.Errorf(ctx, "must not be null") 3426 } 3427 return graphql.Null 3428 } 3429 res := resTmp.(string) 3430 fc.Result = res 3431 return ec.marshalNID2string(ctx, field.Selections, res) 3432 } 3433 3434 func (ec *executionContext) fieldContext_AIt_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 3435 fc = &graphql.FieldContext{ 3436 Object: "AIt", 3437 Field: field, 3438 IsMethod: false, 3439 IsResolver: false, 3440 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 3441 return nil, errors.New("field of type ID does not have child fields") 3442 }, 3443 } 3444 return fc, nil 3445 } 3446 3447 func (ec *executionContext) _AbIt_id(ctx context.Context, field graphql.CollectedField, obj *AbIt) (ret graphql.Marshaler) { 3448 fc, err := ec.fieldContext_AbIt_id(ctx, field) 3449 if err != nil { 3450 return graphql.Null 3451 } 3452 ctx = graphql.WithFieldContext(ctx, fc) 3453 defer func() { 3454 if r := recover(); r != nil { 3455 ec.Error(ctx, ec.Recover(ctx, r)) 3456 ret = graphql.Null 3457 } 3458 }() 3459 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 3460 ctx = rctx // use context from middleware stack in children 3461 return obj.ID, nil 3462 }) 3463 3464 if resTmp == nil { 3465 if !graphql.HasFieldError(ctx, fc) { 3466 ec.Errorf(ctx, "must not be null") 3467 } 3468 return graphql.Null 3469 } 3470 res := resTmp.(string) 3471 fc.Result = res 3472 return ec.marshalNID2string(ctx, field.Selections, res) 3473 } 3474 3475 func (ec *executionContext) fieldContext_AbIt_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 3476 fc = &graphql.FieldContext{ 3477 Object: "AbIt", 3478 Field: field, 3479 IsMethod: false, 3480 IsResolver: false, 3481 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 3482 return nil, errors.New("field of type ID does not have child fields") 3483 }, 3484 } 3485 return fc, nil 3486 } 3487 3488 func (ec *executionContext) _Autobind_int(ctx context.Context, field graphql.CollectedField, obj *Autobind) (ret graphql.Marshaler) { 3489 fc, err := ec.fieldContext_Autobind_int(ctx, field) 3490 if err != nil { 3491 return graphql.Null 3492 } 3493 ctx = graphql.WithFieldContext(ctx, fc) 3494 defer func() { 3495 if r := recover(); r != nil { 3496 ec.Error(ctx, ec.Recover(ctx, r)) 3497 ret = graphql.Null 3498 } 3499 }() 3500 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 3501 ctx = rctx // use context from middleware stack in children 3502 return obj.Int, nil 3503 }) 3504 3505 if resTmp == nil { 3506 if !graphql.HasFieldError(ctx, fc) { 3507 ec.Errorf(ctx, "must not be null") 3508 } 3509 return graphql.Null 3510 } 3511 res := resTmp.(int) 3512 fc.Result = res 3513 return ec.marshalNInt2int(ctx, field.Selections, res) 3514 } 3515 3516 func (ec *executionContext) fieldContext_Autobind_int(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 3517 fc = &graphql.FieldContext{ 3518 Object: "Autobind", 3519 Field: field, 3520 IsMethod: false, 3521 IsResolver: false, 3522 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 3523 return nil, errors.New("field of type Int does not have child fields") 3524 }, 3525 } 3526 return fc, nil 3527 } 3528 3529 func (ec *executionContext) _Autobind_int32(ctx context.Context, field graphql.CollectedField, obj *Autobind) (ret graphql.Marshaler) { 3530 fc, err := ec.fieldContext_Autobind_int32(ctx, field) 3531 if err != nil { 3532 return graphql.Null 3533 } 3534 ctx = graphql.WithFieldContext(ctx, fc) 3535 defer func() { 3536 if r := recover(); r != nil { 3537 ec.Error(ctx, ec.Recover(ctx, r)) 3538 ret = graphql.Null 3539 } 3540 }() 3541 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 3542 ctx = rctx // use context from middleware stack in children 3543 return obj.Int32, nil 3544 }) 3545 3546 if resTmp == nil { 3547 if !graphql.HasFieldError(ctx, fc) { 3548 ec.Errorf(ctx, "must not be null") 3549 } 3550 return graphql.Null 3551 } 3552 res := resTmp.(int32) 3553 fc.Result = res 3554 return ec.marshalNInt2int32(ctx, field.Selections, res) 3555 } 3556 3557 func (ec *executionContext) fieldContext_Autobind_int32(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 3558 fc = &graphql.FieldContext{ 3559 Object: "Autobind", 3560 Field: field, 3561 IsMethod: false, 3562 IsResolver: false, 3563 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 3564 return nil, errors.New("field of type Int does not have child fields") 3565 }, 3566 } 3567 return fc, nil 3568 } 3569 3570 func (ec *executionContext) _Autobind_int64(ctx context.Context, field graphql.CollectedField, obj *Autobind) (ret graphql.Marshaler) { 3571 fc, err := ec.fieldContext_Autobind_int64(ctx, field) 3572 if err != nil { 3573 return graphql.Null 3574 } 3575 ctx = graphql.WithFieldContext(ctx, fc) 3576 defer func() { 3577 if r := recover(); r != nil { 3578 ec.Error(ctx, ec.Recover(ctx, r)) 3579 ret = graphql.Null 3580 } 3581 }() 3582 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 3583 ctx = rctx // use context from middleware stack in children 3584 return obj.Int64, nil 3585 }) 3586 3587 if resTmp == nil { 3588 if !graphql.HasFieldError(ctx, fc) { 3589 ec.Errorf(ctx, "must not be null") 3590 } 3591 return graphql.Null 3592 } 3593 res := resTmp.(int64) 3594 fc.Result = res 3595 return ec.marshalNInt2int64(ctx, field.Selections, res) 3596 } 3597 3598 func (ec *executionContext) fieldContext_Autobind_int64(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 3599 fc = &graphql.FieldContext{ 3600 Object: "Autobind", 3601 Field: field, 3602 IsMethod: false, 3603 IsResolver: false, 3604 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 3605 return nil, errors.New("field of type Int does not have child fields") 3606 }, 3607 } 3608 return fc, nil 3609 } 3610 3611 func (ec *executionContext) _Autobind_idStr(ctx context.Context, field graphql.CollectedField, obj *Autobind) (ret graphql.Marshaler) { 3612 fc, err := ec.fieldContext_Autobind_idStr(ctx, field) 3613 if err != nil { 3614 return graphql.Null 3615 } 3616 ctx = graphql.WithFieldContext(ctx, fc) 3617 defer func() { 3618 if r := recover(); r != nil { 3619 ec.Error(ctx, ec.Recover(ctx, r)) 3620 ret = graphql.Null 3621 } 3622 }() 3623 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 3624 ctx = rctx // use context from middleware stack in children 3625 return obj.IdStr, nil 3626 }) 3627 3628 if resTmp == nil { 3629 if !graphql.HasFieldError(ctx, fc) { 3630 ec.Errorf(ctx, "must not be null") 3631 } 3632 return graphql.Null 3633 } 3634 res := resTmp.(string) 3635 fc.Result = res 3636 return ec.marshalNID2string(ctx, field.Selections, res) 3637 } 3638 3639 func (ec *executionContext) fieldContext_Autobind_idStr(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 3640 fc = &graphql.FieldContext{ 3641 Object: "Autobind", 3642 Field: field, 3643 IsMethod: false, 3644 IsResolver: false, 3645 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 3646 return nil, errors.New("field of type ID does not have child fields") 3647 }, 3648 } 3649 return fc, nil 3650 } 3651 3652 func (ec *executionContext) _Autobind_idInt(ctx context.Context, field graphql.CollectedField, obj *Autobind) (ret graphql.Marshaler) { 3653 fc, err := ec.fieldContext_Autobind_idInt(ctx, field) 3654 if err != nil { 3655 return graphql.Null 3656 } 3657 ctx = graphql.WithFieldContext(ctx, fc) 3658 defer func() { 3659 if r := recover(); r != nil { 3660 ec.Error(ctx, ec.Recover(ctx, r)) 3661 ret = graphql.Null 3662 } 3663 }() 3664 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 3665 ctx = rctx // use context from middleware stack in children 3666 return obj.IdInt, nil 3667 }) 3668 3669 if resTmp == nil { 3670 if !graphql.HasFieldError(ctx, fc) { 3671 ec.Errorf(ctx, "must not be null") 3672 } 3673 return graphql.Null 3674 } 3675 res := resTmp.(int) 3676 fc.Result = res 3677 return ec.marshalNID2int(ctx, field.Selections, res) 3678 } 3679 3680 func (ec *executionContext) fieldContext_Autobind_idInt(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 3681 fc = &graphql.FieldContext{ 3682 Object: "Autobind", 3683 Field: field, 3684 IsMethod: false, 3685 IsResolver: false, 3686 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 3687 return nil, errors.New("field of type ID does not have child fields") 3688 }, 3689 } 3690 return fc, nil 3691 } 3692 3693 func (ec *executionContext) _B_id(ctx context.Context, field graphql.CollectedField, obj *B) (ret graphql.Marshaler) { 3694 fc, err := ec.fieldContext_B_id(ctx, field) 3695 if err != nil { 3696 return graphql.Null 3697 } 3698 ctx = graphql.WithFieldContext(ctx, fc) 3699 defer func() { 3700 if r := recover(); r != nil { 3701 ec.Error(ctx, ec.Recover(ctx, r)) 3702 ret = graphql.Null 3703 } 3704 }() 3705 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 3706 ctx = rctx // use context from middleware stack in children 3707 return obj.ID, nil 3708 }) 3709 3710 if resTmp == nil { 3711 if !graphql.HasFieldError(ctx, fc) { 3712 ec.Errorf(ctx, "must not be null") 3713 } 3714 return graphql.Null 3715 } 3716 res := resTmp.(string) 3717 fc.Result = res 3718 return ec.marshalNID2string(ctx, field.Selections, res) 3719 } 3720 3721 func (ec *executionContext) fieldContext_B_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 3722 fc = &graphql.FieldContext{ 3723 Object: "B", 3724 Field: field, 3725 IsMethod: false, 3726 IsResolver: false, 3727 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 3728 return nil, errors.New("field of type ID does not have child fields") 3729 }, 3730 } 3731 return fc, nil 3732 } 3733 3734 func (ec *executionContext) _BackedByInterface_id(ctx context.Context, field graphql.CollectedField, obj BackedByInterface) (ret graphql.Marshaler) { 3735 fc, err := ec.fieldContext_BackedByInterface_id(ctx, field) 3736 if err != nil { 3737 return graphql.Null 3738 } 3739 ctx = graphql.WithFieldContext(ctx, fc) 3740 defer func() { 3741 if r := recover(); r != nil { 3742 ec.Error(ctx, ec.Recover(ctx, r)) 3743 ret = graphql.Null 3744 } 3745 }() 3746 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 3747 ctx = rctx // use context from middleware stack in children 3748 return ec.resolvers.BackedByInterface().ID(rctx, obj) 3749 }) 3750 3751 if resTmp == nil { 3752 if !graphql.HasFieldError(ctx, fc) { 3753 ec.Errorf(ctx, "must not be null") 3754 } 3755 return graphql.Null 3756 } 3757 res := resTmp.(string) 3758 fc.Result = res 3759 return ec.marshalNString2string(ctx, field.Selections, res) 3760 } 3761 3762 func (ec *executionContext) fieldContext_BackedByInterface_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 3763 fc = &graphql.FieldContext{ 3764 Object: "BackedByInterface", 3765 Field: field, 3766 IsMethod: true, 3767 IsResolver: true, 3768 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 3769 return nil, errors.New("field of type String does not have child fields") 3770 }, 3771 } 3772 return fc, nil 3773 } 3774 3775 func (ec *executionContext) _BackedByInterface_thisShouldBind(ctx context.Context, field graphql.CollectedField, obj BackedByInterface) (ret graphql.Marshaler) { 3776 fc, err := ec.fieldContext_BackedByInterface_thisShouldBind(ctx, field) 3777 if err != nil { 3778 return graphql.Null 3779 } 3780 ctx = graphql.WithFieldContext(ctx, fc) 3781 defer func() { 3782 if r := recover(); r != nil { 3783 ec.Error(ctx, ec.Recover(ctx, r)) 3784 ret = graphql.Null 3785 } 3786 }() 3787 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 3788 ctx = rctx // use context from middleware stack in children 3789 return obj.ThisShouldBind(), nil 3790 }) 3791 3792 if resTmp == nil { 3793 if !graphql.HasFieldError(ctx, fc) { 3794 ec.Errorf(ctx, "must not be null") 3795 } 3796 return graphql.Null 3797 } 3798 res := resTmp.(string) 3799 fc.Result = res 3800 return ec.marshalNString2string(ctx, field.Selections, res) 3801 } 3802 3803 func (ec *executionContext) fieldContext_BackedByInterface_thisShouldBind(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 3804 fc = &graphql.FieldContext{ 3805 Object: "BackedByInterface", 3806 Field: field, 3807 IsMethod: true, 3808 IsResolver: false, 3809 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 3810 return nil, errors.New("field of type String does not have child fields") 3811 }, 3812 } 3813 return fc, nil 3814 } 3815 3816 func (ec *executionContext) _BackedByInterface_thisShouldBindWithError(ctx context.Context, field graphql.CollectedField, obj BackedByInterface) (ret graphql.Marshaler) { 3817 fc, err := ec.fieldContext_BackedByInterface_thisShouldBindWithError(ctx, field) 3818 if err != nil { 3819 return graphql.Null 3820 } 3821 ctx = graphql.WithFieldContext(ctx, fc) 3822 defer func() { 3823 if r := recover(); r != nil { 3824 ec.Error(ctx, ec.Recover(ctx, r)) 3825 ret = graphql.Null 3826 } 3827 }() 3828 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 3829 ctx = rctx // use context from middleware stack in children 3830 return obj.ThisShouldBindWithError() 3831 }) 3832 3833 if resTmp == nil { 3834 if !graphql.HasFieldError(ctx, fc) { 3835 ec.Errorf(ctx, "must not be null") 3836 } 3837 return graphql.Null 3838 } 3839 res := resTmp.(string) 3840 fc.Result = res 3841 return ec.marshalNString2string(ctx, field.Selections, res) 3842 } 3843 3844 func (ec *executionContext) fieldContext_BackedByInterface_thisShouldBindWithError(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 3845 fc = &graphql.FieldContext{ 3846 Object: "BackedByInterface", 3847 Field: field, 3848 IsMethod: true, 3849 IsResolver: false, 3850 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 3851 return nil, errors.New("field of type String does not have child fields") 3852 }, 3853 } 3854 return fc, nil 3855 } 3856 3857 func (ec *executionContext) _Cat_species(ctx context.Context, field graphql.CollectedField, obj *Cat) (ret graphql.Marshaler) { 3858 fc, err := ec.fieldContext_Cat_species(ctx, field) 3859 if err != nil { 3860 return graphql.Null 3861 } 3862 ctx = graphql.WithFieldContext(ctx, fc) 3863 defer func() { 3864 if r := recover(); r != nil { 3865 ec.Error(ctx, ec.Recover(ctx, r)) 3866 ret = graphql.Null 3867 } 3868 }() 3869 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 3870 ctx = rctx // use context from middleware stack in children 3871 return obj.Species, nil 3872 }) 3873 3874 if resTmp == nil { 3875 if !graphql.HasFieldError(ctx, fc) { 3876 ec.Errorf(ctx, "must not be null") 3877 } 3878 return graphql.Null 3879 } 3880 res := resTmp.(string) 3881 fc.Result = res 3882 return ec.marshalNString2string(ctx, field.Selections, res) 3883 } 3884 3885 func (ec *executionContext) fieldContext_Cat_species(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 3886 fc = &graphql.FieldContext{ 3887 Object: "Cat", 3888 Field: field, 3889 IsMethod: false, 3890 IsResolver: false, 3891 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 3892 return nil, errors.New("field of type String does not have child fields") 3893 }, 3894 } 3895 return fc, nil 3896 } 3897 3898 func (ec *executionContext) _Cat_catBreed(ctx context.Context, field graphql.CollectedField, obj *Cat) (ret graphql.Marshaler) { 3899 fc, err := ec.fieldContext_Cat_catBreed(ctx, field) 3900 if err != nil { 3901 return graphql.Null 3902 } 3903 ctx = graphql.WithFieldContext(ctx, fc) 3904 defer func() { 3905 if r := recover(); r != nil { 3906 ec.Error(ctx, ec.Recover(ctx, r)) 3907 ret = graphql.Null 3908 } 3909 }() 3910 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 3911 ctx = rctx // use context from middleware stack in children 3912 return obj.CatBreed, nil 3913 }) 3914 3915 if resTmp == nil { 3916 if !graphql.HasFieldError(ctx, fc) { 3917 ec.Errorf(ctx, "must not be null") 3918 } 3919 return graphql.Null 3920 } 3921 res := resTmp.(string) 3922 fc.Result = res 3923 return ec.marshalNString2string(ctx, field.Selections, res) 3924 } 3925 3926 func (ec *executionContext) fieldContext_Cat_catBreed(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 3927 fc = &graphql.FieldContext{ 3928 Object: "Cat", 3929 Field: field, 3930 IsMethod: false, 3931 IsResolver: false, 3932 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 3933 return nil, errors.New("field of type String does not have child fields") 3934 }, 3935 } 3936 return fc, nil 3937 } 3938 3939 func (ec *executionContext) _CheckIssue896_id(ctx context.Context, field graphql.CollectedField, obj *CheckIssue896) (ret graphql.Marshaler) { 3940 fc, err := ec.fieldContext_CheckIssue896_id(ctx, field) 3941 if err != nil { 3942 return graphql.Null 3943 } 3944 ctx = graphql.WithFieldContext(ctx, fc) 3945 defer func() { 3946 if r := recover(); r != nil { 3947 ec.Error(ctx, ec.Recover(ctx, r)) 3948 ret = graphql.Null 3949 } 3950 }() 3951 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 3952 ctx = rctx // use context from middleware stack in children 3953 return obj.ID, nil 3954 }) 3955 3956 if resTmp == nil { 3957 return graphql.Null 3958 } 3959 res := resTmp.(*int) 3960 fc.Result = res 3961 return ec.marshalOInt2ᚖint(ctx, field.Selections, res) 3962 } 3963 3964 func (ec *executionContext) fieldContext_CheckIssue896_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 3965 fc = &graphql.FieldContext{ 3966 Object: "CheckIssue896", 3967 Field: field, 3968 IsMethod: false, 3969 IsResolver: false, 3970 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 3971 return nil, errors.New("field of type Int does not have child fields") 3972 }, 3973 } 3974 return fc, nil 3975 } 3976 3977 func (ec *executionContext) _Circle_radius(ctx context.Context, field graphql.CollectedField, obj *Circle) (ret graphql.Marshaler) { 3978 fc, err := ec.fieldContext_Circle_radius(ctx, field) 3979 if err != nil { 3980 return graphql.Null 3981 } 3982 ctx = graphql.WithFieldContext(ctx, fc) 3983 defer func() { 3984 if r := recover(); r != nil { 3985 ec.Error(ctx, ec.Recover(ctx, r)) 3986 ret = graphql.Null 3987 } 3988 }() 3989 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 3990 ctx = rctx // use context from middleware stack in children 3991 return obj.Radius, nil 3992 }) 3993 3994 if resTmp == nil { 3995 return graphql.Null 3996 } 3997 res := resTmp.(float64) 3998 fc.Result = res 3999 return ec.marshalOFloat2float64(ctx, field.Selections, res) 4000 } 4001 4002 func (ec *executionContext) fieldContext_Circle_radius(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4003 fc = &graphql.FieldContext{ 4004 Object: "Circle", 4005 Field: field, 4006 IsMethod: false, 4007 IsResolver: false, 4008 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4009 return nil, errors.New("field of type Float does not have child fields") 4010 }, 4011 } 4012 return fc, nil 4013 } 4014 4015 func (ec *executionContext) _Circle_area(ctx context.Context, field graphql.CollectedField, obj *Circle) (ret graphql.Marshaler) { 4016 fc, err := ec.fieldContext_Circle_area(ctx, field) 4017 if err != nil { 4018 return graphql.Null 4019 } 4020 ctx = graphql.WithFieldContext(ctx, fc) 4021 defer func() { 4022 if r := recover(); r != nil { 4023 ec.Error(ctx, ec.Recover(ctx, r)) 4024 ret = graphql.Null 4025 } 4026 }() 4027 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4028 ctx = rctx // use context from middleware stack in children 4029 return obj.Area(), nil 4030 }) 4031 4032 if resTmp == nil { 4033 return graphql.Null 4034 } 4035 res := resTmp.(float64) 4036 fc.Result = res 4037 return ec.marshalOFloat2float64(ctx, field.Selections, res) 4038 } 4039 4040 func (ec *executionContext) fieldContext_Circle_area(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4041 fc = &graphql.FieldContext{ 4042 Object: "Circle", 4043 Field: field, 4044 IsMethod: true, 4045 IsResolver: false, 4046 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4047 return nil, errors.New("field of type Float does not have child fields") 4048 }, 4049 } 4050 return fc, nil 4051 } 4052 4053 func (ec *executionContext) _Circle_coordinates(ctx context.Context, field graphql.CollectedField, obj *Circle) (ret graphql.Marshaler) { 4054 fc, err := ec.fieldContext_Circle_coordinates(ctx, field) 4055 if err != nil { 4056 return graphql.Null 4057 } 4058 ctx = graphql.WithFieldContext(ctx, fc) 4059 defer func() { 4060 if r := recover(); r != nil { 4061 ec.Error(ctx, ec.Recover(ctx, r)) 4062 ret = graphql.Null 4063 } 4064 }() 4065 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4066 ctx = rctx // use context from middleware stack in children 4067 return obj.Coordinates, nil 4068 }) 4069 4070 if resTmp == nil { 4071 return graphql.Null 4072 } 4073 res := resTmp.(Coordinates) 4074 fc.Result = res 4075 return ec.marshalOCoordinates2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐCoordinates(ctx, field.Selections, res) 4076 } 4077 4078 func (ec *executionContext) fieldContext_Circle_coordinates(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4079 fc = &graphql.FieldContext{ 4080 Object: "Circle", 4081 Field: field, 4082 IsMethod: false, 4083 IsResolver: false, 4084 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4085 switch field.Name { 4086 case "x": 4087 return ec.fieldContext_Coordinates_x(ctx, field) 4088 case "y": 4089 return ec.fieldContext_Coordinates_y(ctx, field) 4090 } 4091 return nil, fmt.Errorf("no field named %q was found under type Coordinates", field.Name) 4092 }, 4093 } 4094 return fc, nil 4095 } 4096 4097 func (ec *executionContext) _ConcreteNodeA_id(ctx context.Context, field graphql.CollectedField, obj *ConcreteNodeA) (ret graphql.Marshaler) { 4098 fc, err := ec.fieldContext_ConcreteNodeA_id(ctx, field) 4099 if err != nil { 4100 return graphql.Null 4101 } 4102 ctx = graphql.WithFieldContext(ctx, fc) 4103 defer func() { 4104 if r := recover(); r != nil { 4105 ec.Error(ctx, ec.Recover(ctx, r)) 4106 ret = graphql.Null 4107 } 4108 }() 4109 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4110 ctx = rctx // use context from middleware stack in children 4111 return obj.ID, nil 4112 }) 4113 4114 if resTmp == nil { 4115 if !graphql.HasFieldError(ctx, fc) { 4116 ec.Errorf(ctx, "must not be null") 4117 } 4118 return graphql.Null 4119 } 4120 res := resTmp.(string) 4121 fc.Result = res 4122 return ec.marshalNID2string(ctx, field.Selections, res) 4123 } 4124 4125 func (ec *executionContext) fieldContext_ConcreteNodeA_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4126 fc = &graphql.FieldContext{ 4127 Object: "ConcreteNodeA", 4128 Field: field, 4129 IsMethod: false, 4130 IsResolver: false, 4131 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4132 return nil, errors.New("field of type ID does not have child fields") 4133 }, 4134 } 4135 return fc, nil 4136 } 4137 4138 func (ec *executionContext) _ConcreteNodeA_child(ctx context.Context, field graphql.CollectedField, obj *ConcreteNodeA) (ret graphql.Marshaler) { 4139 fc, err := ec.fieldContext_ConcreteNodeA_child(ctx, field) 4140 if err != nil { 4141 return graphql.Null 4142 } 4143 ctx = graphql.WithFieldContext(ctx, fc) 4144 defer func() { 4145 if r := recover(); r != nil { 4146 ec.Error(ctx, ec.Recover(ctx, r)) 4147 ret = graphql.Null 4148 } 4149 }() 4150 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4151 ctx = rctx // use context from middleware stack in children 4152 return obj.Child() 4153 }) 4154 4155 if resTmp == nil { 4156 if !graphql.HasFieldError(ctx, fc) { 4157 ec.Errorf(ctx, "must not be null") 4158 } 4159 return graphql.Null 4160 } 4161 res := resTmp.(Node) 4162 fc.Result = res 4163 return ec.marshalNNode2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐNode(ctx, field.Selections, res) 4164 } 4165 4166 func (ec *executionContext) fieldContext_ConcreteNodeA_child(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4167 fc = &graphql.FieldContext{ 4168 Object: "ConcreteNodeA", 4169 Field: field, 4170 IsMethod: true, 4171 IsResolver: false, 4172 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4173 return nil, errors.New("FieldContext.Child cannot be called on type INTERFACE") 4174 }, 4175 } 4176 return fc, nil 4177 } 4178 4179 func (ec *executionContext) _ConcreteNodeA_name(ctx context.Context, field graphql.CollectedField, obj *ConcreteNodeA) (ret graphql.Marshaler) { 4180 fc, err := ec.fieldContext_ConcreteNodeA_name(ctx, field) 4181 if err != nil { 4182 return graphql.Null 4183 } 4184 ctx = graphql.WithFieldContext(ctx, fc) 4185 defer func() { 4186 if r := recover(); r != nil { 4187 ec.Error(ctx, ec.Recover(ctx, r)) 4188 ret = graphql.Null 4189 } 4190 }() 4191 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4192 ctx = rctx // use context from middleware stack in children 4193 return obj.Name, nil 4194 }) 4195 4196 if resTmp == nil { 4197 if !graphql.HasFieldError(ctx, fc) { 4198 ec.Errorf(ctx, "must not be null") 4199 } 4200 return graphql.Null 4201 } 4202 res := resTmp.(string) 4203 fc.Result = res 4204 return ec.marshalNString2string(ctx, field.Selections, res) 4205 } 4206 4207 func (ec *executionContext) fieldContext_ConcreteNodeA_name(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4208 fc = &graphql.FieldContext{ 4209 Object: "ConcreteNodeA", 4210 Field: field, 4211 IsMethod: false, 4212 IsResolver: false, 4213 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4214 return nil, errors.New("field of type String does not have child fields") 4215 }, 4216 } 4217 return fc, nil 4218 } 4219 4220 func (ec *executionContext) _ConcreteNodeInterface_id(ctx context.Context, field graphql.CollectedField, obj ConcreteNodeInterface) (ret graphql.Marshaler) { 4221 fc, err := ec.fieldContext_ConcreteNodeInterface_id(ctx, field) 4222 if err != nil { 4223 return graphql.Null 4224 } 4225 ctx = graphql.WithFieldContext(ctx, fc) 4226 defer func() { 4227 if r := recover(); r != nil { 4228 ec.Error(ctx, ec.Recover(ctx, r)) 4229 ret = graphql.Null 4230 } 4231 }() 4232 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4233 ctx = rctx // use context from middleware stack in children 4234 return obj.ID(), nil 4235 }) 4236 4237 if resTmp == nil { 4238 if !graphql.HasFieldError(ctx, fc) { 4239 ec.Errorf(ctx, "must not be null") 4240 } 4241 return graphql.Null 4242 } 4243 res := resTmp.(string) 4244 fc.Result = res 4245 return ec.marshalNID2string(ctx, field.Selections, res) 4246 } 4247 4248 func (ec *executionContext) fieldContext_ConcreteNodeInterface_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4249 fc = &graphql.FieldContext{ 4250 Object: "ConcreteNodeInterface", 4251 Field: field, 4252 IsMethod: true, 4253 IsResolver: false, 4254 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4255 return nil, errors.New("field of type ID does not have child fields") 4256 }, 4257 } 4258 return fc, nil 4259 } 4260 4261 func (ec *executionContext) _ConcreteNodeInterface_child(ctx context.Context, field graphql.CollectedField, obj ConcreteNodeInterface) (ret graphql.Marshaler) { 4262 fc, err := ec.fieldContext_ConcreteNodeInterface_child(ctx, field) 4263 if err != nil { 4264 return graphql.Null 4265 } 4266 ctx = graphql.WithFieldContext(ctx, fc) 4267 defer func() { 4268 if r := recover(); r != nil { 4269 ec.Error(ctx, ec.Recover(ctx, r)) 4270 ret = graphql.Null 4271 } 4272 }() 4273 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4274 ctx = rctx // use context from middleware stack in children 4275 return obj.Child() 4276 }) 4277 4278 if resTmp == nil { 4279 if !graphql.HasFieldError(ctx, fc) { 4280 ec.Errorf(ctx, "must not be null") 4281 } 4282 return graphql.Null 4283 } 4284 res := resTmp.(Node) 4285 fc.Result = res 4286 return ec.marshalNNode2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐNode(ctx, field.Selections, res) 4287 } 4288 4289 func (ec *executionContext) fieldContext_ConcreteNodeInterface_child(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4290 fc = &graphql.FieldContext{ 4291 Object: "ConcreteNodeInterface", 4292 Field: field, 4293 IsMethod: true, 4294 IsResolver: false, 4295 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4296 return nil, errors.New("FieldContext.Child cannot be called on type INTERFACE") 4297 }, 4298 } 4299 return fc, nil 4300 } 4301 4302 func (ec *executionContext) _Content_Post_foo(ctx context.Context, field graphql.CollectedField, obj *ContentPost) (ret graphql.Marshaler) { 4303 fc, err := ec.fieldContext_Content_Post_foo(ctx, field) 4304 if err != nil { 4305 return graphql.Null 4306 } 4307 ctx = graphql.WithFieldContext(ctx, fc) 4308 defer func() { 4309 if r := recover(); r != nil { 4310 ec.Error(ctx, ec.Recover(ctx, r)) 4311 ret = graphql.Null 4312 } 4313 }() 4314 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4315 ctx = rctx // use context from middleware stack in children 4316 return obj.Foo, nil 4317 }) 4318 4319 if resTmp == nil { 4320 return graphql.Null 4321 } 4322 res := resTmp.(*string) 4323 fc.Result = res 4324 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 4325 } 4326 4327 func (ec *executionContext) fieldContext_Content_Post_foo(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4328 fc = &graphql.FieldContext{ 4329 Object: "Content_Post", 4330 Field: field, 4331 IsMethod: false, 4332 IsResolver: false, 4333 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4334 return nil, errors.New("field of type String does not have child fields") 4335 }, 4336 } 4337 return fc, nil 4338 } 4339 4340 func (ec *executionContext) _Content_User_foo(ctx context.Context, field graphql.CollectedField, obj *ContentUser) (ret graphql.Marshaler) { 4341 fc, err := ec.fieldContext_Content_User_foo(ctx, field) 4342 if err != nil { 4343 return graphql.Null 4344 } 4345 ctx = graphql.WithFieldContext(ctx, fc) 4346 defer func() { 4347 if r := recover(); r != nil { 4348 ec.Error(ctx, ec.Recover(ctx, r)) 4349 ret = graphql.Null 4350 } 4351 }() 4352 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4353 ctx = rctx // use context from middleware stack in children 4354 return obj.Foo, nil 4355 }) 4356 4357 if resTmp == nil { 4358 return graphql.Null 4359 } 4360 res := resTmp.(*string) 4361 fc.Result = res 4362 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 4363 } 4364 4365 func (ec *executionContext) fieldContext_Content_User_foo(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4366 fc = &graphql.FieldContext{ 4367 Object: "Content_User", 4368 Field: field, 4369 IsMethod: false, 4370 IsResolver: false, 4371 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4372 return nil, errors.New("field of type String does not have child fields") 4373 }, 4374 } 4375 return fc, nil 4376 } 4377 4378 func (ec *executionContext) _Coordinates_x(ctx context.Context, field graphql.CollectedField, obj *Coordinates) (ret graphql.Marshaler) { 4379 fc, err := ec.fieldContext_Coordinates_x(ctx, field) 4380 if err != nil { 4381 return graphql.Null 4382 } 4383 ctx = graphql.WithFieldContext(ctx, fc) 4384 defer func() { 4385 if r := recover(); r != nil { 4386 ec.Error(ctx, ec.Recover(ctx, r)) 4387 ret = graphql.Null 4388 } 4389 }() 4390 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4391 ctx = rctx // use context from middleware stack in children 4392 return obj.X, nil 4393 }) 4394 4395 if resTmp == nil { 4396 if !graphql.HasFieldError(ctx, fc) { 4397 ec.Errorf(ctx, "must not be null") 4398 } 4399 return graphql.Null 4400 } 4401 res := resTmp.(float64) 4402 fc.Result = res 4403 return ec.marshalNFloat2float64(ctx, field.Selections, res) 4404 } 4405 4406 func (ec *executionContext) fieldContext_Coordinates_x(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4407 fc = &graphql.FieldContext{ 4408 Object: "Coordinates", 4409 Field: field, 4410 IsMethod: false, 4411 IsResolver: false, 4412 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4413 return nil, errors.New("field of type Float does not have child fields") 4414 }, 4415 } 4416 return fc, nil 4417 } 4418 4419 func (ec *executionContext) _Coordinates_y(ctx context.Context, field graphql.CollectedField, obj *Coordinates) (ret graphql.Marshaler) { 4420 fc, err := ec.fieldContext_Coordinates_y(ctx, field) 4421 if err != nil { 4422 return graphql.Null 4423 } 4424 ctx = graphql.WithFieldContext(ctx, fc) 4425 defer func() { 4426 if r := recover(); r != nil { 4427 ec.Error(ctx, ec.Recover(ctx, r)) 4428 ret = graphql.Null 4429 } 4430 }() 4431 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4432 ctx = rctx // use context from middleware stack in children 4433 return obj.Y, nil 4434 }) 4435 4436 if resTmp == nil { 4437 if !graphql.HasFieldError(ctx, fc) { 4438 ec.Errorf(ctx, "must not be null") 4439 } 4440 return graphql.Null 4441 } 4442 res := resTmp.(float64) 4443 fc.Result = res 4444 return ec.marshalNFloat2float64(ctx, field.Selections, res) 4445 } 4446 4447 func (ec *executionContext) fieldContext_Coordinates_y(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4448 fc = &graphql.FieldContext{ 4449 Object: "Coordinates", 4450 Field: field, 4451 IsMethod: false, 4452 IsResolver: false, 4453 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4454 return nil, errors.New("field of type Float does not have child fields") 4455 }, 4456 } 4457 return fc, nil 4458 } 4459 4460 func (ec *executionContext) _DefaultParametersMirror_falsyBoolean(ctx context.Context, field graphql.CollectedField, obj *DefaultParametersMirror) (ret graphql.Marshaler) { 4461 fc, err := ec.fieldContext_DefaultParametersMirror_falsyBoolean(ctx, field) 4462 if err != nil { 4463 return graphql.Null 4464 } 4465 ctx = graphql.WithFieldContext(ctx, fc) 4466 defer func() { 4467 if r := recover(); r != nil { 4468 ec.Error(ctx, ec.Recover(ctx, r)) 4469 ret = graphql.Null 4470 } 4471 }() 4472 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4473 ctx = rctx // use context from middleware stack in children 4474 return obj.FalsyBoolean, nil 4475 }) 4476 4477 if resTmp == nil { 4478 return graphql.Null 4479 } 4480 res := resTmp.(*bool) 4481 fc.Result = res 4482 return ec.marshalOBoolean2ᚖbool(ctx, field.Selections, res) 4483 } 4484 4485 func (ec *executionContext) fieldContext_DefaultParametersMirror_falsyBoolean(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4486 fc = &graphql.FieldContext{ 4487 Object: "DefaultParametersMirror", 4488 Field: field, 4489 IsMethod: false, 4490 IsResolver: false, 4491 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4492 return nil, errors.New("field of type Boolean does not have child fields") 4493 }, 4494 } 4495 return fc, nil 4496 } 4497 4498 func (ec *executionContext) _DefaultParametersMirror_truthyBoolean(ctx context.Context, field graphql.CollectedField, obj *DefaultParametersMirror) (ret graphql.Marshaler) { 4499 fc, err := ec.fieldContext_DefaultParametersMirror_truthyBoolean(ctx, field) 4500 if err != nil { 4501 return graphql.Null 4502 } 4503 ctx = graphql.WithFieldContext(ctx, fc) 4504 defer func() { 4505 if r := recover(); r != nil { 4506 ec.Error(ctx, ec.Recover(ctx, r)) 4507 ret = graphql.Null 4508 } 4509 }() 4510 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4511 ctx = rctx // use context from middleware stack in children 4512 return obj.TruthyBoolean, nil 4513 }) 4514 4515 if resTmp == nil { 4516 return graphql.Null 4517 } 4518 res := resTmp.(*bool) 4519 fc.Result = res 4520 return ec.marshalOBoolean2ᚖbool(ctx, field.Selections, res) 4521 } 4522 4523 func (ec *executionContext) fieldContext_DefaultParametersMirror_truthyBoolean(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4524 fc = &graphql.FieldContext{ 4525 Object: "DefaultParametersMirror", 4526 Field: field, 4527 IsMethod: false, 4528 IsResolver: false, 4529 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4530 return nil, errors.New("field of type Boolean does not have child fields") 4531 }, 4532 } 4533 return fc, nil 4534 } 4535 4536 func (ec *executionContext) _Dog_species(ctx context.Context, field graphql.CollectedField, obj *Dog) (ret graphql.Marshaler) { 4537 fc, err := ec.fieldContext_Dog_species(ctx, field) 4538 if err != nil { 4539 return graphql.Null 4540 } 4541 ctx = graphql.WithFieldContext(ctx, fc) 4542 defer func() { 4543 if r := recover(); r != nil { 4544 ec.Error(ctx, ec.Recover(ctx, r)) 4545 ret = graphql.Null 4546 } 4547 }() 4548 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4549 ctx = rctx // use context from middleware stack in children 4550 return obj.Species, nil 4551 }) 4552 4553 if resTmp == nil { 4554 if !graphql.HasFieldError(ctx, fc) { 4555 ec.Errorf(ctx, "must not be null") 4556 } 4557 return graphql.Null 4558 } 4559 res := resTmp.(string) 4560 fc.Result = res 4561 return ec.marshalNString2string(ctx, field.Selections, res) 4562 } 4563 4564 func (ec *executionContext) fieldContext_Dog_species(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4565 fc = &graphql.FieldContext{ 4566 Object: "Dog", 4567 Field: field, 4568 IsMethod: false, 4569 IsResolver: false, 4570 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4571 return nil, errors.New("field of type String does not have child fields") 4572 }, 4573 } 4574 return fc, nil 4575 } 4576 4577 func (ec *executionContext) _Dog_dogBreed(ctx context.Context, field graphql.CollectedField, obj *Dog) (ret graphql.Marshaler) { 4578 fc, err := ec.fieldContext_Dog_dogBreed(ctx, field) 4579 if err != nil { 4580 return graphql.Null 4581 } 4582 ctx = graphql.WithFieldContext(ctx, fc) 4583 defer func() { 4584 if r := recover(); r != nil { 4585 ec.Error(ctx, ec.Recover(ctx, r)) 4586 ret = graphql.Null 4587 } 4588 }() 4589 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4590 ctx = rctx // use context from middleware stack in children 4591 return obj.DogBreed, nil 4592 }) 4593 4594 if resTmp == nil { 4595 if !graphql.HasFieldError(ctx, fc) { 4596 ec.Errorf(ctx, "must not be null") 4597 } 4598 return graphql.Null 4599 } 4600 res := resTmp.(string) 4601 fc.Result = res 4602 return ec.marshalNString2string(ctx, field.Selections, res) 4603 } 4604 4605 func (ec *executionContext) fieldContext_Dog_dogBreed(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4606 fc = &graphql.FieldContext{ 4607 Object: "Dog", 4608 Field: field, 4609 IsMethod: false, 4610 IsResolver: false, 4611 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4612 return nil, errors.New("field of type String does not have child fields") 4613 }, 4614 } 4615 return fc, nil 4616 } 4617 4618 func (ec *executionContext) _EmbeddedCase1_exportedEmbeddedPointerExportedMethod(ctx context.Context, field graphql.CollectedField, obj *EmbeddedCase1) (ret graphql.Marshaler) { 4619 fc, err := ec.fieldContext_EmbeddedCase1_exportedEmbeddedPointerExportedMethod(ctx, field) 4620 if err != nil { 4621 return graphql.Null 4622 } 4623 ctx = graphql.WithFieldContext(ctx, fc) 4624 defer func() { 4625 if r := recover(); r != nil { 4626 ec.Error(ctx, ec.Recover(ctx, r)) 4627 ret = graphql.Null 4628 } 4629 }() 4630 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4631 ctx = rctx // use context from middleware stack in children 4632 return obj.ExportedEmbeddedPointerExportedMethod(), nil 4633 }) 4634 4635 if resTmp == nil { 4636 if !graphql.HasFieldError(ctx, fc) { 4637 ec.Errorf(ctx, "must not be null") 4638 } 4639 return graphql.Null 4640 } 4641 res := resTmp.(string) 4642 fc.Result = res 4643 return ec.marshalNString2string(ctx, field.Selections, res) 4644 } 4645 4646 func (ec *executionContext) fieldContext_EmbeddedCase1_exportedEmbeddedPointerExportedMethod(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4647 fc = &graphql.FieldContext{ 4648 Object: "EmbeddedCase1", 4649 Field: field, 4650 IsMethod: true, 4651 IsResolver: false, 4652 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4653 return nil, errors.New("field of type String does not have child fields") 4654 }, 4655 } 4656 return fc, nil 4657 } 4658 4659 func (ec *executionContext) _EmbeddedCase2_unexportedEmbeddedPointerExportedMethod(ctx context.Context, field graphql.CollectedField, obj *EmbeddedCase2) (ret graphql.Marshaler) { 4660 fc, err := ec.fieldContext_EmbeddedCase2_unexportedEmbeddedPointerExportedMethod(ctx, field) 4661 if err != nil { 4662 return graphql.Null 4663 } 4664 ctx = graphql.WithFieldContext(ctx, fc) 4665 defer func() { 4666 if r := recover(); r != nil { 4667 ec.Error(ctx, ec.Recover(ctx, r)) 4668 ret = graphql.Null 4669 } 4670 }() 4671 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4672 ctx = rctx // use context from middleware stack in children 4673 return obj.UnexportedEmbeddedPointerExportedMethod(), nil 4674 }) 4675 4676 if resTmp == nil { 4677 if !graphql.HasFieldError(ctx, fc) { 4678 ec.Errorf(ctx, "must not be null") 4679 } 4680 return graphql.Null 4681 } 4682 res := resTmp.(string) 4683 fc.Result = res 4684 return ec.marshalNString2string(ctx, field.Selections, res) 4685 } 4686 4687 func (ec *executionContext) fieldContext_EmbeddedCase2_unexportedEmbeddedPointerExportedMethod(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4688 fc = &graphql.FieldContext{ 4689 Object: "EmbeddedCase2", 4690 Field: field, 4691 IsMethod: true, 4692 IsResolver: false, 4693 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4694 return nil, errors.New("field of type String does not have child fields") 4695 }, 4696 } 4697 return fc, nil 4698 } 4699 4700 func (ec *executionContext) _EmbeddedCase3_unexportedEmbeddedInterfaceExportedMethod(ctx context.Context, field graphql.CollectedField, obj *EmbeddedCase3) (ret graphql.Marshaler) { 4701 fc, err := ec.fieldContext_EmbeddedCase3_unexportedEmbeddedInterfaceExportedMethod(ctx, field) 4702 if err != nil { 4703 return graphql.Null 4704 } 4705 ctx = graphql.WithFieldContext(ctx, fc) 4706 defer func() { 4707 if r := recover(); r != nil { 4708 ec.Error(ctx, ec.Recover(ctx, r)) 4709 ret = graphql.Null 4710 } 4711 }() 4712 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4713 ctx = rctx // use context from middleware stack in children 4714 return obj.UnexportedEmbeddedInterfaceExportedMethod(), nil 4715 }) 4716 4717 if resTmp == nil { 4718 if !graphql.HasFieldError(ctx, fc) { 4719 ec.Errorf(ctx, "must not be null") 4720 } 4721 return graphql.Null 4722 } 4723 res := resTmp.(string) 4724 fc.Result = res 4725 return ec.marshalNString2string(ctx, field.Selections, res) 4726 } 4727 4728 func (ec *executionContext) fieldContext_EmbeddedCase3_unexportedEmbeddedInterfaceExportedMethod(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4729 fc = &graphql.FieldContext{ 4730 Object: "EmbeddedCase3", 4731 Field: field, 4732 IsMethod: true, 4733 IsResolver: false, 4734 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4735 return nil, errors.New("field of type String does not have child fields") 4736 }, 4737 } 4738 return fc, nil 4739 } 4740 4741 func (ec *executionContext) _EmbeddedDefaultScalar_value(ctx context.Context, field graphql.CollectedField, obj *EmbeddedDefaultScalar) (ret graphql.Marshaler) { 4742 fc, err := ec.fieldContext_EmbeddedDefaultScalar_value(ctx, field) 4743 if err != nil { 4744 return graphql.Null 4745 } 4746 ctx = graphql.WithFieldContext(ctx, fc) 4747 defer func() { 4748 if r := recover(); r != nil { 4749 ec.Error(ctx, ec.Recover(ctx, r)) 4750 ret = graphql.Null 4751 } 4752 }() 4753 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4754 ctx = rctx // use context from middleware stack in children 4755 return obj.Value, nil 4756 }) 4757 4758 if resTmp == nil { 4759 return graphql.Null 4760 } 4761 res := resTmp.(*string) 4762 fc.Result = res 4763 return ec.marshalODefaultScalarImplementation2ᚖstring(ctx, field.Selections, res) 4764 } 4765 4766 func (ec *executionContext) fieldContext_EmbeddedDefaultScalar_value(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4767 fc = &graphql.FieldContext{ 4768 Object: "EmbeddedDefaultScalar", 4769 Field: field, 4770 IsMethod: false, 4771 IsResolver: false, 4772 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4773 return nil, errors.New("field of type DefaultScalarImplementation does not have child fields") 4774 }, 4775 } 4776 return fc, nil 4777 } 4778 4779 func (ec *executionContext) _EmbeddedPointer_ID(ctx context.Context, field graphql.CollectedField, obj *EmbeddedPointerModel) (ret graphql.Marshaler) { 4780 fc, err := ec.fieldContext_EmbeddedPointer_ID(ctx, field) 4781 if err != nil { 4782 return graphql.Null 4783 } 4784 ctx = graphql.WithFieldContext(ctx, fc) 4785 defer func() { 4786 if r := recover(); r != nil { 4787 ec.Error(ctx, ec.Recover(ctx, r)) 4788 ret = graphql.Null 4789 } 4790 }() 4791 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4792 ctx = rctx // use context from middleware stack in children 4793 return obj.ID, nil 4794 }) 4795 4796 if resTmp == nil { 4797 return graphql.Null 4798 } 4799 res := resTmp.(string) 4800 fc.Result = res 4801 return ec.marshalOString2string(ctx, field.Selections, res) 4802 } 4803 4804 func (ec *executionContext) fieldContext_EmbeddedPointer_ID(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4805 fc = &graphql.FieldContext{ 4806 Object: "EmbeddedPointer", 4807 Field: field, 4808 IsMethod: false, 4809 IsResolver: false, 4810 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4811 return nil, errors.New("field of type String does not have child fields") 4812 }, 4813 } 4814 return fc, nil 4815 } 4816 4817 func (ec *executionContext) _EmbeddedPointer_Title(ctx context.Context, field graphql.CollectedField, obj *EmbeddedPointerModel) (ret graphql.Marshaler) { 4818 fc, err := ec.fieldContext_EmbeddedPointer_Title(ctx, field) 4819 if err != nil { 4820 return graphql.Null 4821 } 4822 ctx = graphql.WithFieldContext(ctx, fc) 4823 defer func() { 4824 if r := recover(); r != nil { 4825 ec.Error(ctx, ec.Recover(ctx, r)) 4826 ret = graphql.Null 4827 } 4828 }() 4829 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4830 ctx = rctx // use context from middleware stack in children 4831 return obj.Title, nil 4832 }) 4833 4834 if resTmp == nil { 4835 return graphql.Null 4836 } 4837 res := resTmp.(string) 4838 fc.Result = res 4839 return ec.marshalOString2string(ctx, field.Selections, res) 4840 } 4841 4842 func (ec *executionContext) fieldContext_EmbeddedPointer_Title(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4843 fc = &graphql.FieldContext{ 4844 Object: "EmbeddedPointer", 4845 Field: field, 4846 IsMethod: false, 4847 IsResolver: false, 4848 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4849 return nil, errors.New("field of type String does not have child fields") 4850 }, 4851 } 4852 return fc, nil 4853 } 4854 4855 func (ec *executionContext) _Error_id(ctx context.Context, field graphql.CollectedField, obj *Error) (ret graphql.Marshaler) { 4856 fc, err := ec.fieldContext_Error_id(ctx, field) 4857 if err != nil { 4858 return graphql.Null 4859 } 4860 ctx = graphql.WithFieldContext(ctx, fc) 4861 defer func() { 4862 if r := recover(); r != nil { 4863 ec.Error(ctx, ec.Recover(ctx, r)) 4864 ret = graphql.Null 4865 } 4866 }() 4867 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4868 ctx = rctx // use context from middleware stack in children 4869 return obj.ID, nil 4870 }) 4871 4872 if resTmp == nil { 4873 if !graphql.HasFieldError(ctx, fc) { 4874 ec.Errorf(ctx, "must not be null") 4875 } 4876 return graphql.Null 4877 } 4878 res := resTmp.(string) 4879 fc.Result = res 4880 return ec.marshalNID2string(ctx, field.Selections, res) 4881 } 4882 4883 func (ec *executionContext) fieldContext_Error_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4884 fc = &graphql.FieldContext{ 4885 Object: "Error", 4886 Field: field, 4887 IsMethod: false, 4888 IsResolver: false, 4889 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4890 return nil, errors.New("field of type ID does not have child fields") 4891 }, 4892 } 4893 return fc, nil 4894 } 4895 4896 func (ec *executionContext) _Error_errorOnNonRequiredField(ctx context.Context, field graphql.CollectedField, obj *Error) (ret graphql.Marshaler) { 4897 fc, err := ec.fieldContext_Error_errorOnNonRequiredField(ctx, field) 4898 if err != nil { 4899 return graphql.Null 4900 } 4901 ctx = graphql.WithFieldContext(ctx, fc) 4902 defer func() { 4903 if r := recover(); r != nil { 4904 ec.Error(ctx, ec.Recover(ctx, r)) 4905 ret = graphql.Null 4906 } 4907 }() 4908 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4909 ctx = rctx // use context from middleware stack in children 4910 return obj.ErrorOnNonRequiredField() 4911 }) 4912 4913 if resTmp == nil { 4914 return graphql.Null 4915 } 4916 res := resTmp.(string) 4917 fc.Result = res 4918 return ec.marshalOString2string(ctx, field.Selections, res) 4919 } 4920 4921 func (ec *executionContext) fieldContext_Error_errorOnNonRequiredField(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4922 fc = &graphql.FieldContext{ 4923 Object: "Error", 4924 Field: field, 4925 IsMethod: true, 4926 IsResolver: false, 4927 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4928 return nil, errors.New("field of type String does not have child fields") 4929 }, 4930 } 4931 return fc, nil 4932 } 4933 4934 func (ec *executionContext) _Error_errorOnRequiredField(ctx context.Context, field graphql.CollectedField, obj *Error) (ret graphql.Marshaler) { 4935 fc, err := ec.fieldContext_Error_errorOnRequiredField(ctx, field) 4936 if err != nil { 4937 return graphql.Null 4938 } 4939 ctx = graphql.WithFieldContext(ctx, fc) 4940 defer func() { 4941 if r := recover(); r != nil { 4942 ec.Error(ctx, ec.Recover(ctx, r)) 4943 ret = graphql.Null 4944 } 4945 }() 4946 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4947 ctx = rctx // use context from middleware stack in children 4948 return obj.ErrorOnRequiredField() 4949 }) 4950 4951 if resTmp == nil { 4952 if !graphql.HasFieldError(ctx, fc) { 4953 ec.Errorf(ctx, "must not be null") 4954 } 4955 return graphql.Null 4956 } 4957 res := resTmp.(string) 4958 fc.Result = res 4959 return ec.marshalNString2string(ctx, field.Selections, res) 4960 } 4961 4962 func (ec *executionContext) fieldContext_Error_errorOnRequiredField(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 4963 fc = &graphql.FieldContext{ 4964 Object: "Error", 4965 Field: field, 4966 IsMethod: true, 4967 IsResolver: false, 4968 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 4969 return nil, errors.New("field of type String does not have child fields") 4970 }, 4971 } 4972 return fc, nil 4973 } 4974 4975 func (ec *executionContext) _Error_nilOnRequiredField(ctx context.Context, field graphql.CollectedField, obj *Error) (ret graphql.Marshaler) { 4976 fc, err := ec.fieldContext_Error_nilOnRequiredField(ctx, field) 4977 if err != nil { 4978 return graphql.Null 4979 } 4980 ctx = graphql.WithFieldContext(ctx, fc) 4981 defer func() { 4982 if r := recover(); r != nil { 4983 ec.Error(ctx, ec.Recover(ctx, r)) 4984 ret = graphql.Null 4985 } 4986 }() 4987 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 4988 ctx = rctx // use context from middleware stack in children 4989 return obj.NilOnRequiredField(), nil 4990 }) 4991 4992 if resTmp == nil { 4993 if !graphql.HasFieldError(ctx, fc) { 4994 ec.Errorf(ctx, "must not be null") 4995 } 4996 return graphql.Null 4997 } 4998 res := resTmp.(*string) 4999 fc.Result = res 5000 return ec.marshalNString2ᚖstring(ctx, field.Selections, res) 5001 } 5002 5003 func (ec *executionContext) fieldContext_Error_nilOnRequiredField(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 5004 fc = &graphql.FieldContext{ 5005 Object: "Error", 5006 Field: field, 5007 IsMethod: true, 5008 IsResolver: false, 5009 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 5010 return nil, errors.New("field of type String does not have child fields") 5011 }, 5012 } 5013 return fc, nil 5014 } 5015 5016 func (ec *executionContext) _Errors_a(ctx context.Context, field graphql.CollectedField, obj *Errors) (ret graphql.Marshaler) { 5017 fc, err := ec.fieldContext_Errors_a(ctx, field) 5018 if err != nil { 5019 return graphql.Null 5020 } 5021 ctx = graphql.WithFieldContext(ctx, fc) 5022 defer func() { 5023 if r := recover(); r != nil { 5024 ec.Error(ctx, ec.Recover(ctx, r)) 5025 ret = graphql.Null 5026 } 5027 }() 5028 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 5029 ctx = rctx // use context from middleware stack in children 5030 return ec.resolvers.Errors().A(rctx, obj) 5031 }) 5032 5033 if resTmp == nil { 5034 if !graphql.HasFieldError(ctx, fc) { 5035 ec.Errorf(ctx, "must not be null") 5036 } 5037 return graphql.Null 5038 } 5039 res := resTmp.(*Error) 5040 fc.Result = res 5041 return ec.marshalNError2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐError(ctx, field.Selections, res) 5042 } 5043 5044 func (ec *executionContext) fieldContext_Errors_a(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 5045 fc = &graphql.FieldContext{ 5046 Object: "Errors", 5047 Field: field, 5048 IsMethod: true, 5049 IsResolver: true, 5050 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 5051 switch field.Name { 5052 case "id": 5053 return ec.fieldContext_Error_id(ctx, field) 5054 case "errorOnNonRequiredField": 5055 return ec.fieldContext_Error_errorOnNonRequiredField(ctx, field) 5056 case "errorOnRequiredField": 5057 return ec.fieldContext_Error_errorOnRequiredField(ctx, field) 5058 case "nilOnRequiredField": 5059 return ec.fieldContext_Error_nilOnRequiredField(ctx, field) 5060 } 5061 return nil, fmt.Errorf("no field named %q was found under type Error", field.Name) 5062 }, 5063 } 5064 return fc, nil 5065 } 5066 5067 func (ec *executionContext) _Errors_b(ctx context.Context, field graphql.CollectedField, obj *Errors) (ret graphql.Marshaler) { 5068 fc, err := ec.fieldContext_Errors_b(ctx, field) 5069 if err != nil { 5070 return graphql.Null 5071 } 5072 ctx = graphql.WithFieldContext(ctx, fc) 5073 defer func() { 5074 if r := recover(); r != nil { 5075 ec.Error(ctx, ec.Recover(ctx, r)) 5076 ret = graphql.Null 5077 } 5078 }() 5079 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 5080 ctx = rctx // use context from middleware stack in children 5081 return ec.resolvers.Errors().B(rctx, obj) 5082 }) 5083 5084 if resTmp == nil { 5085 if !graphql.HasFieldError(ctx, fc) { 5086 ec.Errorf(ctx, "must not be null") 5087 } 5088 return graphql.Null 5089 } 5090 res := resTmp.(*Error) 5091 fc.Result = res 5092 return ec.marshalNError2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐError(ctx, field.Selections, res) 5093 } 5094 5095 func (ec *executionContext) fieldContext_Errors_b(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 5096 fc = &graphql.FieldContext{ 5097 Object: "Errors", 5098 Field: field, 5099 IsMethod: true, 5100 IsResolver: true, 5101 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 5102 switch field.Name { 5103 case "id": 5104 return ec.fieldContext_Error_id(ctx, field) 5105 case "errorOnNonRequiredField": 5106 return ec.fieldContext_Error_errorOnNonRequiredField(ctx, field) 5107 case "errorOnRequiredField": 5108 return ec.fieldContext_Error_errorOnRequiredField(ctx, field) 5109 case "nilOnRequiredField": 5110 return ec.fieldContext_Error_nilOnRequiredField(ctx, field) 5111 } 5112 return nil, fmt.Errorf("no field named %q was found under type Error", field.Name) 5113 }, 5114 } 5115 return fc, nil 5116 } 5117 5118 func (ec *executionContext) _Errors_c(ctx context.Context, field graphql.CollectedField, obj *Errors) (ret graphql.Marshaler) { 5119 fc, err := ec.fieldContext_Errors_c(ctx, field) 5120 if err != nil { 5121 return graphql.Null 5122 } 5123 ctx = graphql.WithFieldContext(ctx, fc) 5124 defer func() { 5125 if r := recover(); r != nil { 5126 ec.Error(ctx, ec.Recover(ctx, r)) 5127 ret = graphql.Null 5128 } 5129 }() 5130 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 5131 ctx = rctx // use context from middleware stack in children 5132 return ec.resolvers.Errors().C(rctx, obj) 5133 }) 5134 5135 if resTmp == nil { 5136 if !graphql.HasFieldError(ctx, fc) { 5137 ec.Errorf(ctx, "must not be null") 5138 } 5139 return graphql.Null 5140 } 5141 res := resTmp.(*Error) 5142 fc.Result = res 5143 return ec.marshalNError2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐError(ctx, field.Selections, res) 5144 } 5145 5146 func (ec *executionContext) fieldContext_Errors_c(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 5147 fc = &graphql.FieldContext{ 5148 Object: "Errors", 5149 Field: field, 5150 IsMethod: true, 5151 IsResolver: true, 5152 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 5153 switch field.Name { 5154 case "id": 5155 return ec.fieldContext_Error_id(ctx, field) 5156 case "errorOnNonRequiredField": 5157 return ec.fieldContext_Error_errorOnNonRequiredField(ctx, field) 5158 case "errorOnRequiredField": 5159 return ec.fieldContext_Error_errorOnRequiredField(ctx, field) 5160 case "nilOnRequiredField": 5161 return ec.fieldContext_Error_nilOnRequiredField(ctx, field) 5162 } 5163 return nil, fmt.Errorf("no field named %q was found under type Error", field.Name) 5164 }, 5165 } 5166 return fc, nil 5167 } 5168 5169 func (ec *executionContext) _Errors_d(ctx context.Context, field graphql.CollectedField, obj *Errors) (ret graphql.Marshaler) { 5170 fc, err := ec.fieldContext_Errors_d(ctx, field) 5171 if err != nil { 5172 return graphql.Null 5173 } 5174 ctx = graphql.WithFieldContext(ctx, fc) 5175 defer func() { 5176 if r := recover(); r != nil { 5177 ec.Error(ctx, ec.Recover(ctx, r)) 5178 ret = graphql.Null 5179 } 5180 }() 5181 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 5182 ctx = rctx // use context from middleware stack in children 5183 return ec.resolvers.Errors().D(rctx, obj) 5184 }) 5185 5186 if resTmp == nil { 5187 if !graphql.HasFieldError(ctx, fc) { 5188 ec.Errorf(ctx, "must not be null") 5189 } 5190 return graphql.Null 5191 } 5192 res := resTmp.(*Error) 5193 fc.Result = res 5194 return ec.marshalNError2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐError(ctx, field.Selections, res) 5195 } 5196 5197 func (ec *executionContext) fieldContext_Errors_d(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 5198 fc = &graphql.FieldContext{ 5199 Object: "Errors", 5200 Field: field, 5201 IsMethod: true, 5202 IsResolver: true, 5203 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 5204 switch field.Name { 5205 case "id": 5206 return ec.fieldContext_Error_id(ctx, field) 5207 case "errorOnNonRequiredField": 5208 return ec.fieldContext_Error_errorOnNonRequiredField(ctx, field) 5209 case "errorOnRequiredField": 5210 return ec.fieldContext_Error_errorOnRequiredField(ctx, field) 5211 case "nilOnRequiredField": 5212 return ec.fieldContext_Error_nilOnRequiredField(ctx, field) 5213 } 5214 return nil, fmt.Errorf("no field named %q was found under type Error", field.Name) 5215 }, 5216 } 5217 return fc, nil 5218 } 5219 5220 func (ec *executionContext) _Errors_e(ctx context.Context, field graphql.CollectedField, obj *Errors) (ret graphql.Marshaler) { 5221 fc, err := ec.fieldContext_Errors_e(ctx, field) 5222 if err != nil { 5223 return graphql.Null 5224 } 5225 ctx = graphql.WithFieldContext(ctx, fc) 5226 defer func() { 5227 if r := recover(); r != nil { 5228 ec.Error(ctx, ec.Recover(ctx, r)) 5229 ret = graphql.Null 5230 } 5231 }() 5232 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 5233 ctx = rctx // use context from middleware stack in children 5234 return ec.resolvers.Errors().E(rctx, obj) 5235 }) 5236 5237 if resTmp == nil { 5238 if !graphql.HasFieldError(ctx, fc) { 5239 ec.Errorf(ctx, "must not be null") 5240 } 5241 return graphql.Null 5242 } 5243 res := resTmp.(*Error) 5244 fc.Result = res 5245 return ec.marshalNError2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐError(ctx, field.Selections, res) 5246 } 5247 5248 func (ec *executionContext) fieldContext_Errors_e(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 5249 fc = &graphql.FieldContext{ 5250 Object: "Errors", 5251 Field: field, 5252 IsMethod: true, 5253 IsResolver: true, 5254 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 5255 switch field.Name { 5256 case "id": 5257 return ec.fieldContext_Error_id(ctx, field) 5258 case "errorOnNonRequiredField": 5259 return ec.fieldContext_Error_errorOnNonRequiredField(ctx, field) 5260 case "errorOnRequiredField": 5261 return ec.fieldContext_Error_errorOnRequiredField(ctx, field) 5262 case "nilOnRequiredField": 5263 return ec.fieldContext_Error_nilOnRequiredField(ctx, field) 5264 } 5265 return nil, fmt.Errorf("no field named %q was found under type Error", field.Name) 5266 }, 5267 } 5268 return fc, nil 5269 } 5270 5271 func (ec *executionContext) _FieldsOrderPayload_firstFieldValue(ctx context.Context, field graphql.CollectedField, obj *FieldsOrderPayload) (ret graphql.Marshaler) { 5272 fc, err := ec.fieldContext_FieldsOrderPayload_firstFieldValue(ctx, field) 5273 if err != nil { 5274 return graphql.Null 5275 } 5276 ctx = graphql.WithFieldContext(ctx, fc) 5277 defer func() { 5278 if r := recover(); r != nil { 5279 ec.Error(ctx, ec.Recover(ctx, r)) 5280 ret = graphql.Null 5281 } 5282 }() 5283 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 5284 ctx = rctx // use context from middleware stack in children 5285 return obj.FirstFieldValue, nil 5286 }) 5287 5288 if resTmp == nil { 5289 return graphql.Null 5290 } 5291 res := resTmp.(*string) 5292 fc.Result = res 5293 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 5294 } 5295 5296 func (ec *executionContext) fieldContext_FieldsOrderPayload_firstFieldValue(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 5297 fc = &graphql.FieldContext{ 5298 Object: "FieldsOrderPayload", 5299 Field: field, 5300 IsMethod: false, 5301 IsResolver: false, 5302 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 5303 return nil, errors.New("field of type String does not have child fields") 5304 }, 5305 } 5306 return fc, nil 5307 } 5308 5309 func (ec *executionContext) _ForcedResolver_field(ctx context.Context, field graphql.CollectedField, obj *ForcedResolver) (ret graphql.Marshaler) { 5310 fc, err := ec.fieldContext_ForcedResolver_field(ctx, field) 5311 if err != nil { 5312 return graphql.Null 5313 } 5314 ctx = graphql.WithFieldContext(ctx, fc) 5315 defer func() { 5316 if r := recover(); r != nil { 5317 ec.Error(ctx, ec.Recover(ctx, r)) 5318 ret = graphql.Null 5319 } 5320 }() 5321 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 5322 ctx = rctx // use context from middleware stack in children 5323 return ec.resolvers.ForcedResolver().Field(rctx, obj) 5324 }) 5325 5326 if resTmp == nil { 5327 return graphql.Null 5328 } 5329 res := resTmp.(*Circle) 5330 fc.Result = res 5331 return ec.marshalOCircle2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐCircle(ctx, field.Selections, res) 5332 } 5333 5334 func (ec *executionContext) fieldContext_ForcedResolver_field(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 5335 fc = &graphql.FieldContext{ 5336 Object: "ForcedResolver", 5337 Field: field, 5338 IsMethod: true, 5339 IsResolver: true, 5340 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 5341 switch field.Name { 5342 case "radius": 5343 return ec.fieldContext_Circle_radius(ctx, field) 5344 case "area": 5345 return ec.fieldContext_Circle_area(ctx, field) 5346 case "coordinates": 5347 return ec.fieldContext_Circle_coordinates(ctx, field) 5348 } 5349 return nil, fmt.Errorf("no field named %q was found under type Circle", field.Name) 5350 }, 5351 } 5352 return fc, nil 5353 } 5354 5355 func (ec *executionContext) _InnerObject_id(ctx context.Context, field graphql.CollectedField, obj *InnerObject) (ret graphql.Marshaler) { 5356 fc, err := ec.fieldContext_InnerObject_id(ctx, field) 5357 if err != nil { 5358 return graphql.Null 5359 } 5360 ctx = graphql.WithFieldContext(ctx, fc) 5361 defer func() { 5362 if r := recover(); r != nil { 5363 ec.Error(ctx, ec.Recover(ctx, r)) 5364 ret = graphql.Null 5365 } 5366 }() 5367 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 5368 ctx = rctx // use context from middleware stack in children 5369 return obj.ID, nil 5370 }) 5371 5372 if resTmp == nil { 5373 if !graphql.HasFieldError(ctx, fc) { 5374 ec.Errorf(ctx, "must not be null") 5375 } 5376 return graphql.Null 5377 } 5378 res := resTmp.(int) 5379 fc.Result = res 5380 return ec.marshalNInt2int(ctx, field.Selections, res) 5381 } 5382 5383 func (ec *executionContext) fieldContext_InnerObject_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 5384 fc = &graphql.FieldContext{ 5385 Object: "InnerObject", 5386 Field: field, 5387 IsMethod: false, 5388 IsResolver: false, 5389 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 5390 return nil, errors.New("field of type Int does not have child fields") 5391 }, 5392 } 5393 return fc, nil 5394 } 5395 5396 func (ec *executionContext) _InvalidIdentifier_id(ctx context.Context, field graphql.CollectedField, obj *invalid_packagename.InvalidIdentifier) (ret graphql.Marshaler) { 5397 fc, err := ec.fieldContext_InvalidIdentifier_id(ctx, field) 5398 if err != nil { 5399 return graphql.Null 5400 } 5401 ctx = graphql.WithFieldContext(ctx, fc) 5402 defer func() { 5403 if r := recover(); r != nil { 5404 ec.Error(ctx, ec.Recover(ctx, r)) 5405 ret = graphql.Null 5406 } 5407 }() 5408 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 5409 ctx = rctx // use context from middleware stack in children 5410 return obj.ID, nil 5411 }) 5412 5413 if resTmp == nil { 5414 if !graphql.HasFieldError(ctx, fc) { 5415 ec.Errorf(ctx, "must not be null") 5416 } 5417 return graphql.Null 5418 } 5419 res := resTmp.(int) 5420 fc.Result = res 5421 return ec.marshalNInt2int(ctx, field.Selections, res) 5422 } 5423 5424 func (ec *executionContext) fieldContext_InvalidIdentifier_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 5425 fc = &graphql.FieldContext{ 5426 Object: "InvalidIdentifier", 5427 Field: field, 5428 IsMethod: false, 5429 IsResolver: false, 5430 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 5431 return nil, errors.New("field of type Int does not have child fields") 5432 }, 5433 } 5434 return fc, nil 5435 } 5436 5437 func (ec *executionContext) _It_id(ctx context.Context, field graphql.CollectedField, obj *introspection1.It) (ret graphql.Marshaler) { 5438 fc, err := ec.fieldContext_It_id(ctx, field) 5439 if err != nil { 5440 return graphql.Null 5441 } 5442 ctx = graphql.WithFieldContext(ctx, fc) 5443 defer func() { 5444 if r := recover(); r != nil { 5445 ec.Error(ctx, ec.Recover(ctx, r)) 5446 ret = graphql.Null 5447 } 5448 }() 5449 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 5450 ctx = rctx // use context from middleware stack in children 5451 return obj.ID, nil 5452 }) 5453 5454 if resTmp == nil { 5455 if !graphql.HasFieldError(ctx, fc) { 5456 ec.Errorf(ctx, "must not be null") 5457 } 5458 return graphql.Null 5459 } 5460 res := resTmp.(string) 5461 fc.Result = res 5462 return ec.marshalNID2string(ctx, field.Selections, res) 5463 } 5464 5465 func (ec *executionContext) fieldContext_It_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 5466 fc = &graphql.FieldContext{ 5467 Object: "It", 5468 Field: field, 5469 IsMethod: false, 5470 IsResolver: false, 5471 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 5472 return nil, errors.New("field of type ID does not have child fields") 5473 }, 5474 } 5475 return fc, nil 5476 } 5477 5478 func (ec *executionContext) _LoopA_b(ctx context.Context, field graphql.CollectedField, obj *LoopA) (ret graphql.Marshaler) { 5479 fc, err := ec.fieldContext_LoopA_b(ctx, field) 5480 if err != nil { 5481 return graphql.Null 5482 } 5483 ctx = graphql.WithFieldContext(ctx, fc) 5484 defer func() { 5485 if r := recover(); r != nil { 5486 ec.Error(ctx, ec.Recover(ctx, r)) 5487 ret = graphql.Null 5488 } 5489 }() 5490 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 5491 ctx = rctx // use context from middleware stack in children 5492 return obj.B, nil 5493 }) 5494 5495 if resTmp == nil { 5496 if !graphql.HasFieldError(ctx, fc) { 5497 ec.Errorf(ctx, "must not be null") 5498 } 5499 return graphql.Null 5500 } 5501 res := resTmp.(*LoopB) 5502 fc.Result = res 5503 return ec.marshalNLoopB2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐLoopB(ctx, field.Selections, res) 5504 } 5505 5506 func (ec *executionContext) fieldContext_LoopA_b(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 5507 fc = &graphql.FieldContext{ 5508 Object: "LoopA", 5509 Field: field, 5510 IsMethod: false, 5511 IsResolver: false, 5512 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 5513 switch field.Name { 5514 case "a": 5515 return ec.fieldContext_LoopB_a(ctx, field) 5516 } 5517 return nil, fmt.Errorf("no field named %q was found under type LoopB", field.Name) 5518 }, 5519 } 5520 return fc, nil 5521 } 5522 5523 func (ec *executionContext) _LoopB_a(ctx context.Context, field graphql.CollectedField, obj *LoopB) (ret graphql.Marshaler) { 5524 fc, err := ec.fieldContext_LoopB_a(ctx, field) 5525 if err != nil { 5526 return graphql.Null 5527 } 5528 ctx = graphql.WithFieldContext(ctx, fc) 5529 defer func() { 5530 if r := recover(); r != nil { 5531 ec.Error(ctx, ec.Recover(ctx, r)) 5532 ret = graphql.Null 5533 } 5534 }() 5535 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 5536 ctx = rctx // use context from middleware stack in children 5537 return obj.A, nil 5538 }) 5539 5540 if resTmp == nil { 5541 if !graphql.HasFieldError(ctx, fc) { 5542 ec.Errorf(ctx, "must not be null") 5543 } 5544 return graphql.Null 5545 } 5546 res := resTmp.(*LoopA) 5547 fc.Result = res 5548 return ec.marshalNLoopA2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐLoopA(ctx, field.Selections, res) 5549 } 5550 5551 func (ec *executionContext) fieldContext_LoopB_a(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 5552 fc = &graphql.FieldContext{ 5553 Object: "LoopB", 5554 Field: field, 5555 IsMethod: false, 5556 IsResolver: false, 5557 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 5558 switch field.Name { 5559 case "b": 5560 return ec.fieldContext_LoopA_b(ctx, field) 5561 } 5562 return nil, fmt.Errorf("no field named %q was found under type LoopA", field.Name) 5563 }, 5564 } 5565 return fc, nil 5566 } 5567 5568 func (ec *executionContext) _Map_id(ctx context.Context, field graphql.CollectedField, obj *Map) (ret graphql.Marshaler) { 5569 fc, err := ec.fieldContext_Map_id(ctx, field) 5570 if err != nil { 5571 return graphql.Null 5572 } 5573 ctx = graphql.WithFieldContext(ctx, fc) 5574 defer func() { 5575 if r := recover(); r != nil { 5576 ec.Error(ctx, ec.Recover(ctx, r)) 5577 ret = graphql.Null 5578 } 5579 }() 5580 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 5581 ctx = rctx // use context from middleware stack in children 5582 return obj.ID, nil 5583 }) 5584 5585 if resTmp == nil { 5586 if !graphql.HasFieldError(ctx, fc) { 5587 ec.Errorf(ctx, "must not be null") 5588 } 5589 return graphql.Null 5590 } 5591 res := resTmp.(string) 5592 fc.Result = res 5593 return ec.marshalNID2string(ctx, field.Selections, res) 5594 } 5595 5596 func (ec *executionContext) fieldContext_Map_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 5597 fc = &graphql.FieldContext{ 5598 Object: "Map", 5599 Field: field, 5600 IsMethod: false, 5601 IsResolver: false, 5602 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 5603 return nil, errors.New("field of type ID does not have child fields") 5604 }, 5605 } 5606 return fc, nil 5607 } 5608 5609 func (ec *executionContext) _MapStringInterfaceType_a(ctx context.Context, field graphql.CollectedField, obj map[string]interface{}) (ret graphql.Marshaler) { 5610 fc, err := ec.fieldContext_MapStringInterfaceType_a(ctx, field) 5611 if err != nil { 5612 return graphql.Null 5613 } 5614 ctx = graphql.WithFieldContext(ctx, fc) 5615 defer func() { 5616 if r := recover(); r != nil { 5617 ec.Error(ctx, ec.Recover(ctx, r)) 5618 ret = graphql.Null 5619 } 5620 }() 5621 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 5622 ctx = rctx // use context from middleware stack in children 5623 switch v := obj["a"].(type) { 5624 case *string: 5625 return v, nil 5626 case string: 5627 return &v, nil 5628 case nil: 5629 return (*string)(nil), nil 5630 default: 5631 return nil, fmt.Errorf("unexpected type %T for field %s", v, "a") 5632 } 5633 }) 5634 5635 if resTmp == nil { 5636 return graphql.Null 5637 } 5638 res := resTmp.(*string) 5639 fc.Result = res 5640 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 5641 } 5642 5643 func (ec *executionContext) fieldContext_MapStringInterfaceType_a(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 5644 fc = &graphql.FieldContext{ 5645 Object: "MapStringInterfaceType", 5646 Field: field, 5647 IsMethod: false, 5648 IsResolver: false, 5649 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 5650 return nil, errors.New("field of type String does not have child fields") 5651 }, 5652 } 5653 return fc, nil 5654 } 5655 5656 func (ec *executionContext) _MapStringInterfaceType_b(ctx context.Context, field graphql.CollectedField, obj map[string]interface{}) (ret graphql.Marshaler) { 5657 fc, err := ec.fieldContext_MapStringInterfaceType_b(ctx, field) 5658 if err != nil { 5659 return graphql.Null 5660 } 5661 ctx = graphql.WithFieldContext(ctx, fc) 5662 defer func() { 5663 if r := recover(); r != nil { 5664 ec.Error(ctx, ec.Recover(ctx, r)) 5665 ret = graphql.Null 5666 } 5667 }() 5668 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 5669 ctx = rctx // use context from middleware stack in children 5670 switch v := obj["b"].(type) { 5671 case *int: 5672 return v, nil 5673 case int: 5674 return &v, nil 5675 case nil: 5676 return (*int)(nil), nil 5677 default: 5678 return nil, fmt.Errorf("unexpected type %T for field %s", v, "b") 5679 } 5680 }) 5681 5682 if resTmp == nil { 5683 return graphql.Null 5684 } 5685 res := resTmp.(*int) 5686 fc.Result = res 5687 return ec.marshalOInt2ᚖint(ctx, field.Selections, res) 5688 } 5689 5690 func (ec *executionContext) fieldContext_MapStringInterfaceType_b(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 5691 fc = &graphql.FieldContext{ 5692 Object: "MapStringInterfaceType", 5693 Field: field, 5694 IsMethod: false, 5695 IsResolver: false, 5696 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 5697 return nil, errors.New("field of type Int does not have child fields") 5698 }, 5699 } 5700 return fc, nil 5701 } 5702 5703 func (ec *executionContext) _ModelMethods_resolverField(ctx context.Context, field graphql.CollectedField, obj *ModelMethods) (ret graphql.Marshaler) { 5704 fc, err := ec.fieldContext_ModelMethods_resolverField(ctx, field) 5705 if err != nil { 5706 return graphql.Null 5707 } 5708 ctx = graphql.WithFieldContext(ctx, fc) 5709 defer func() { 5710 if r := recover(); r != nil { 5711 ec.Error(ctx, ec.Recover(ctx, r)) 5712 ret = graphql.Null 5713 } 5714 }() 5715 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 5716 ctx = rctx // use context from middleware stack in children 5717 return ec.resolvers.ModelMethods().ResolverField(rctx, obj) 5718 }) 5719 5720 if resTmp == nil { 5721 if !graphql.HasFieldError(ctx, fc) { 5722 ec.Errorf(ctx, "must not be null") 5723 } 5724 return graphql.Null 5725 } 5726 res := resTmp.(bool) 5727 fc.Result = res 5728 return ec.marshalNBoolean2bool(ctx, field.Selections, res) 5729 } 5730 5731 func (ec *executionContext) fieldContext_ModelMethods_resolverField(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 5732 fc = &graphql.FieldContext{ 5733 Object: "ModelMethods", 5734 Field: field, 5735 IsMethod: true, 5736 IsResolver: true, 5737 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 5738 return nil, errors.New("field of type Boolean does not have child fields") 5739 }, 5740 } 5741 return fc, nil 5742 } 5743 5744 func (ec *executionContext) _ModelMethods_noContext(ctx context.Context, field graphql.CollectedField, obj *ModelMethods) (ret graphql.Marshaler) { 5745 fc, err := ec.fieldContext_ModelMethods_noContext(ctx, field) 5746 if err != nil { 5747 return graphql.Null 5748 } 5749 ctx = graphql.WithFieldContext(ctx, fc) 5750 defer func() { 5751 if r := recover(); r != nil { 5752 ec.Error(ctx, ec.Recover(ctx, r)) 5753 ret = graphql.Null 5754 } 5755 }() 5756 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 5757 ctx = rctx // use context from middleware stack in children 5758 return obj.NoContext(), nil 5759 }) 5760 5761 if resTmp == nil { 5762 if !graphql.HasFieldError(ctx, fc) { 5763 ec.Errorf(ctx, "must not be null") 5764 } 5765 return graphql.Null 5766 } 5767 res := resTmp.(bool) 5768 fc.Result = res 5769 return ec.marshalNBoolean2bool(ctx, field.Selections, res) 5770 } 5771 5772 func (ec *executionContext) fieldContext_ModelMethods_noContext(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 5773 fc = &graphql.FieldContext{ 5774 Object: "ModelMethods", 5775 Field: field, 5776 IsMethod: true, 5777 IsResolver: false, 5778 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 5779 return nil, errors.New("field of type Boolean does not have child fields") 5780 }, 5781 } 5782 return fc, nil 5783 } 5784 5785 func (ec *executionContext) _ModelMethods_withContext(ctx context.Context, field graphql.CollectedField, obj *ModelMethods) (ret graphql.Marshaler) { 5786 fc, err := ec.fieldContext_ModelMethods_withContext(ctx, field) 5787 if err != nil { 5788 return graphql.Null 5789 } 5790 ctx = graphql.WithFieldContext(ctx, fc) 5791 defer func() { 5792 if r := recover(); r != nil { 5793 ec.Error(ctx, ec.Recover(ctx, r)) 5794 ret = graphql.Null 5795 } 5796 }() 5797 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 5798 ctx = rctx // use context from middleware stack in children 5799 return obj.WithContext(ctx), nil 5800 }) 5801 5802 if resTmp == nil { 5803 if !graphql.HasFieldError(ctx, fc) { 5804 ec.Errorf(ctx, "must not be null") 5805 } 5806 return graphql.Null 5807 } 5808 res := resTmp.(bool) 5809 fc.Result = res 5810 return ec.marshalNBoolean2bool(ctx, field.Selections, res) 5811 } 5812 5813 func (ec *executionContext) fieldContext_ModelMethods_withContext(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 5814 fc = &graphql.FieldContext{ 5815 Object: "ModelMethods", 5816 Field: field, 5817 IsMethod: true, 5818 IsResolver: false, 5819 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 5820 return nil, errors.New("field of type Boolean does not have child fields") 5821 }, 5822 } 5823 return fc, nil 5824 } 5825 5826 func (ec *executionContext) _Mutation_defaultInput(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 5827 fc, err := ec.fieldContext_Mutation_defaultInput(ctx, field) 5828 if err != nil { 5829 return graphql.Null 5830 } 5831 ctx = graphql.WithFieldContext(ctx, fc) 5832 defer func() { 5833 if r := recover(); r != nil { 5834 ec.Error(ctx, ec.Recover(ctx, r)) 5835 ret = graphql.Null 5836 } 5837 }() 5838 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 5839 ctx = rctx // use context from middleware stack in children 5840 return ec.resolvers.Mutation().DefaultInput(rctx, fc.Args["input"].(DefaultInput)) 5841 }) 5842 5843 if resTmp == nil { 5844 if !graphql.HasFieldError(ctx, fc) { 5845 ec.Errorf(ctx, "must not be null") 5846 } 5847 return graphql.Null 5848 } 5849 res := resTmp.(*DefaultParametersMirror) 5850 fc.Result = res 5851 return ec.marshalNDefaultParametersMirror2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐDefaultParametersMirror(ctx, field.Selections, res) 5852 } 5853 5854 func (ec *executionContext) fieldContext_Mutation_defaultInput(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 5855 fc = &graphql.FieldContext{ 5856 Object: "Mutation", 5857 Field: field, 5858 IsMethod: true, 5859 IsResolver: true, 5860 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 5861 switch field.Name { 5862 case "falsyBoolean": 5863 return ec.fieldContext_DefaultParametersMirror_falsyBoolean(ctx, field) 5864 case "truthyBoolean": 5865 return ec.fieldContext_DefaultParametersMirror_truthyBoolean(ctx, field) 5866 } 5867 return nil, fmt.Errorf("no field named %q was found under type DefaultParametersMirror", field.Name) 5868 }, 5869 } 5870 defer func() { 5871 if r := recover(); r != nil { 5872 err = ec.Recover(ctx, r) 5873 ec.Error(ctx, err) 5874 } 5875 }() 5876 ctx = graphql.WithFieldContext(ctx, fc) 5877 if fc.Args, err = ec.field_Mutation_defaultInput_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 5878 ec.Error(ctx, err) 5879 return 5880 } 5881 return fc, nil 5882 } 5883 5884 func (ec *executionContext) _Mutation_overrideValueViaInput(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 5885 fc, err := ec.fieldContext_Mutation_overrideValueViaInput(ctx, field) 5886 if err != nil { 5887 return graphql.Null 5888 } 5889 ctx = graphql.WithFieldContext(ctx, fc) 5890 defer func() { 5891 if r := recover(); r != nil { 5892 ec.Error(ctx, ec.Recover(ctx, r)) 5893 ret = graphql.Null 5894 } 5895 }() 5896 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 5897 ctx = rctx // use context from middleware stack in children 5898 return ec.resolvers.Mutation().OverrideValueViaInput(rctx, fc.Args["input"].(FieldsOrderInput)) 5899 }) 5900 5901 if resTmp == nil { 5902 if !graphql.HasFieldError(ctx, fc) { 5903 ec.Errorf(ctx, "must not be null") 5904 } 5905 return graphql.Null 5906 } 5907 res := resTmp.(*FieldsOrderPayload) 5908 fc.Result = res 5909 return ec.marshalNFieldsOrderPayload2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐFieldsOrderPayload(ctx, field.Selections, res) 5910 } 5911 5912 func (ec *executionContext) fieldContext_Mutation_overrideValueViaInput(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 5913 fc = &graphql.FieldContext{ 5914 Object: "Mutation", 5915 Field: field, 5916 IsMethod: true, 5917 IsResolver: true, 5918 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 5919 switch field.Name { 5920 case "firstFieldValue": 5921 return ec.fieldContext_FieldsOrderPayload_firstFieldValue(ctx, field) 5922 } 5923 return nil, fmt.Errorf("no field named %q was found under type FieldsOrderPayload", field.Name) 5924 }, 5925 } 5926 defer func() { 5927 if r := recover(); r != nil { 5928 err = ec.Recover(ctx, r) 5929 ec.Error(ctx, err) 5930 } 5931 }() 5932 ctx = graphql.WithFieldContext(ctx, fc) 5933 if fc.Args, err = ec.field_Mutation_overrideValueViaInput_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 5934 ec.Error(ctx, err) 5935 return 5936 } 5937 return fc, nil 5938 } 5939 5940 func (ec *executionContext) _Mutation_updateSomething(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 5941 fc, err := ec.fieldContext_Mutation_updateSomething(ctx, field) 5942 if err != nil { 5943 return graphql.Null 5944 } 5945 ctx = graphql.WithFieldContext(ctx, fc) 5946 defer func() { 5947 if r := recover(); r != nil { 5948 ec.Error(ctx, ec.Recover(ctx, r)) 5949 ret = graphql.Null 5950 } 5951 }() 5952 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 5953 ctx = rctx // use context from middleware stack in children 5954 return ec.resolvers.Mutation().UpdateSomething(rctx, fc.Args["input"].(SpecialInput)) 5955 }) 5956 5957 if resTmp == nil { 5958 if !graphql.HasFieldError(ctx, fc) { 5959 ec.Errorf(ctx, "must not be null") 5960 } 5961 return graphql.Null 5962 } 5963 res := resTmp.(string) 5964 fc.Result = res 5965 return ec.marshalNString2string(ctx, field.Selections, res) 5966 } 5967 5968 func (ec *executionContext) fieldContext_Mutation_updateSomething(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 5969 fc = &graphql.FieldContext{ 5970 Object: "Mutation", 5971 Field: field, 5972 IsMethod: true, 5973 IsResolver: true, 5974 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 5975 return nil, errors.New("field of type String does not have child fields") 5976 }, 5977 } 5978 defer func() { 5979 if r := recover(); r != nil { 5980 err = ec.Recover(ctx, r) 5981 ec.Error(ctx, err) 5982 } 5983 }() 5984 ctx = graphql.WithFieldContext(ctx, fc) 5985 if fc.Args, err = ec.field_Mutation_updateSomething_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 5986 ec.Error(ctx, err) 5987 return 5988 } 5989 return fc, nil 5990 } 5991 5992 func (ec *executionContext) _Mutation_updatePtrToPtr(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 5993 fc, err := ec.fieldContext_Mutation_updatePtrToPtr(ctx, field) 5994 if err != nil { 5995 return graphql.Null 5996 } 5997 ctx = graphql.WithFieldContext(ctx, fc) 5998 defer func() { 5999 if r := recover(); r != nil { 6000 ec.Error(ctx, ec.Recover(ctx, r)) 6001 ret = graphql.Null 6002 } 6003 }() 6004 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 6005 ctx = rctx // use context from middleware stack in children 6006 return ec.resolvers.Mutation().UpdatePtrToPtr(rctx, fc.Args["input"].(UpdatePtrToPtrOuter)) 6007 }) 6008 6009 if resTmp == nil { 6010 if !graphql.HasFieldError(ctx, fc) { 6011 ec.Errorf(ctx, "must not be null") 6012 } 6013 return graphql.Null 6014 } 6015 res := resTmp.(*PtrToPtrOuter) 6016 fc.Result = res 6017 return ec.marshalNPtrToPtrOuter2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPtrToPtrOuter(ctx, field.Selections, res) 6018 } 6019 6020 func (ec *executionContext) fieldContext_Mutation_updatePtrToPtr(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 6021 fc = &graphql.FieldContext{ 6022 Object: "Mutation", 6023 Field: field, 6024 IsMethod: true, 6025 IsResolver: true, 6026 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 6027 switch field.Name { 6028 case "name": 6029 return ec.fieldContext_PtrToPtrOuter_name(ctx, field) 6030 case "inner": 6031 return ec.fieldContext_PtrToPtrOuter_inner(ctx, field) 6032 case "stupidInner": 6033 return ec.fieldContext_PtrToPtrOuter_stupidInner(ctx, field) 6034 } 6035 return nil, fmt.Errorf("no field named %q was found under type PtrToPtrOuter", field.Name) 6036 }, 6037 } 6038 defer func() { 6039 if r := recover(); r != nil { 6040 err = ec.Recover(ctx, r) 6041 ec.Error(ctx, err) 6042 } 6043 }() 6044 ctx = graphql.WithFieldContext(ctx, fc) 6045 if fc.Args, err = ec.field_Mutation_updatePtrToPtr_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 6046 ec.Error(ctx, err) 6047 return 6048 } 6049 return fc, nil 6050 } 6051 6052 func (ec *executionContext) _ObjectDirectives_text(ctx context.Context, field graphql.CollectedField, obj *ObjectDirectives) (ret graphql.Marshaler) { 6053 fc, err := ec.fieldContext_ObjectDirectives_text(ctx, field) 6054 if err != nil { 6055 return graphql.Null 6056 } 6057 ctx = graphql.WithFieldContext(ctx, fc) 6058 defer func() { 6059 if r := recover(); r != nil { 6060 ec.Error(ctx, ec.Recover(ctx, r)) 6061 ret = graphql.Null 6062 } 6063 }() 6064 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 6065 directive0 := func(rctx context.Context) (interface{}, error) { 6066 ctx = rctx // use context from middleware stack in children 6067 return obj.Text, nil 6068 } 6069 directive1 := func(ctx context.Context) (interface{}, error) { 6070 min, err := ec.unmarshalNInt2int(ctx, 0) 6071 if err != nil { 6072 return nil, err 6073 } 6074 max, err := ec.unmarshalOInt2ᚖint(ctx, 7) 6075 if err != nil { 6076 return nil, err 6077 } 6078 message, err := ec.unmarshalOString2ᚖstring(ctx, "not valid") 6079 if err != nil { 6080 return nil, err 6081 } 6082 if ec.directives.Length == nil { 6083 return nil, errors.New("directive length is not implemented") 6084 } 6085 return ec.directives.Length(ctx, obj, directive0, min, max, message) 6086 } 6087 6088 tmp, err := directive1(rctx) 6089 if err != nil { 6090 return nil, graphql.ErrorOnPath(ctx, err) 6091 } 6092 if tmp == nil { 6093 return nil, nil 6094 } 6095 if data, ok := tmp.(string); ok { 6096 return data, nil 6097 } 6098 return nil, fmt.Errorf(`unexpected type %T from directive, should be string`, tmp) 6099 }) 6100 6101 if resTmp == nil { 6102 if !graphql.HasFieldError(ctx, fc) { 6103 ec.Errorf(ctx, "must not be null") 6104 } 6105 return graphql.Null 6106 } 6107 res := resTmp.(string) 6108 fc.Result = res 6109 return ec.marshalNString2string(ctx, field.Selections, res) 6110 } 6111 6112 func (ec *executionContext) fieldContext_ObjectDirectives_text(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 6113 fc = &graphql.FieldContext{ 6114 Object: "ObjectDirectives", 6115 Field: field, 6116 IsMethod: false, 6117 IsResolver: false, 6118 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 6119 return nil, errors.New("field of type String does not have child fields") 6120 }, 6121 } 6122 return fc, nil 6123 } 6124 6125 func (ec *executionContext) _ObjectDirectives_nullableText(ctx context.Context, field graphql.CollectedField, obj *ObjectDirectives) (ret graphql.Marshaler) { 6126 fc, err := ec.fieldContext_ObjectDirectives_nullableText(ctx, field) 6127 if err != nil { 6128 return graphql.Null 6129 } 6130 ctx = graphql.WithFieldContext(ctx, fc) 6131 defer func() { 6132 if r := recover(); r != nil { 6133 ec.Error(ctx, ec.Recover(ctx, r)) 6134 ret = graphql.Null 6135 } 6136 }() 6137 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 6138 directive0 := func(rctx context.Context) (interface{}, error) { 6139 ctx = rctx // use context from middleware stack in children 6140 return obj.NullableText, nil 6141 } 6142 directive1 := func(ctx context.Context) (interface{}, error) { 6143 if ec.directives.ToNull == nil { 6144 return nil, errors.New("directive toNull is not implemented") 6145 } 6146 return ec.directives.ToNull(ctx, obj, directive0) 6147 } 6148 6149 tmp, err := directive1(rctx) 6150 if err != nil { 6151 return nil, graphql.ErrorOnPath(ctx, err) 6152 } 6153 if tmp == nil { 6154 return nil, nil 6155 } 6156 if data, ok := tmp.(*string); ok { 6157 return data, nil 6158 } 6159 return nil, fmt.Errorf(`unexpected type %T from directive, should be *string`, tmp) 6160 }) 6161 6162 if resTmp == nil { 6163 return graphql.Null 6164 } 6165 res := resTmp.(*string) 6166 fc.Result = res 6167 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 6168 } 6169 6170 func (ec *executionContext) fieldContext_ObjectDirectives_nullableText(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 6171 fc = &graphql.FieldContext{ 6172 Object: "ObjectDirectives", 6173 Field: field, 6174 IsMethod: false, 6175 IsResolver: false, 6176 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 6177 return nil, errors.New("field of type String does not have child fields") 6178 }, 6179 } 6180 return fc, nil 6181 } 6182 6183 func (ec *executionContext) _ObjectDirectives_order(ctx context.Context, field graphql.CollectedField, obj *ObjectDirectives) (ret graphql.Marshaler) { 6184 fc, err := ec.fieldContext_ObjectDirectives_order(ctx, field) 6185 if err != nil { 6186 return graphql.Null 6187 } 6188 ctx = graphql.WithFieldContext(ctx, fc) 6189 defer func() { 6190 if r := recover(); r != nil { 6191 ec.Error(ctx, ec.Recover(ctx, r)) 6192 ret = graphql.Null 6193 } 6194 }() 6195 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 6196 ctx = rctx // use context from middleware stack in children 6197 return obj.Order, nil 6198 }) 6199 6200 if resTmp == nil { 6201 if !graphql.HasFieldError(ctx, fc) { 6202 ec.Errorf(ctx, "must not be null") 6203 } 6204 return graphql.Null 6205 } 6206 res := resTmp.([]string) 6207 fc.Result = res 6208 return ec.marshalNString2ᚕstringᚄ(ctx, field.Selections, res) 6209 } 6210 6211 func (ec *executionContext) fieldContext_ObjectDirectives_order(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 6212 fc = &graphql.FieldContext{ 6213 Object: "ObjectDirectives", 6214 Field: field, 6215 IsMethod: false, 6216 IsResolver: false, 6217 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 6218 return nil, errors.New("field of type String does not have child fields") 6219 }, 6220 } 6221 return fc, nil 6222 } 6223 6224 func (ec *executionContext) _ObjectDirectivesWithCustomGoModel_nullableText(ctx context.Context, field graphql.CollectedField, obj *ObjectDirectivesWithCustomGoModel) (ret graphql.Marshaler) { 6225 fc, err := ec.fieldContext_ObjectDirectivesWithCustomGoModel_nullableText(ctx, field) 6226 if err != nil { 6227 return graphql.Null 6228 } 6229 ctx = graphql.WithFieldContext(ctx, fc) 6230 defer func() { 6231 if r := recover(); r != nil { 6232 ec.Error(ctx, ec.Recover(ctx, r)) 6233 ret = graphql.Null 6234 } 6235 }() 6236 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 6237 directive0 := func(rctx context.Context) (interface{}, error) { 6238 ctx = rctx // use context from middleware stack in children 6239 return obj.NullableText, nil 6240 } 6241 directive1 := func(ctx context.Context) (interface{}, error) { 6242 if ec.directives.ToNull == nil { 6243 return nil, errors.New("directive toNull is not implemented") 6244 } 6245 return ec.directives.ToNull(ctx, obj, directive0) 6246 } 6247 6248 tmp, err := directive1(rctx) 6249 if err != nil { 6250 return nil, graphql.ErrorOnPath(ctx, err) 6251 } 6252 if tmp == nil { 6253 return nil, nil 6254 } 6255 if data, ok := tmp.(string); ok { 6256 return data, nil 6257 } 6258 return nil, fmt.Errorf(`unexpected type %T from directive, should be string`, tmp) 6259 }) 6260 6261 if resTmp == nil { 6262 return graphql.Null 6263 } 6264 res := resTmp.(string) 6265 fc.Result = res 6266 return ec.marshalOString2string(ctx, field.Selections, res) 6267 } 6268 6269 func (ec *executionContext) fieldContext_ObjectDirectivesWithCustomGoModel_nullableText(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 6270 fc = &graphql.FieldContext{ 6271 Object: "ObjectDirectivesWithCustomGoModel", 6272 Field: field, 6273 IsMethod: false, 6274 IsResolver: false, 6275 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 6276 return nil, errors.New("field of type String does not have child fields") 6277 }, 6278 } 6279 return fc, nil 6280 } 6281 6282 func (ec *executionContext) _OuterObject_inner(ctx context.Context, field graphql.CollectedField, obj *OuterObject) (ret graphql.Marshaler) { 6283 fc, err := ec.fieldContext_OuterObject_inner(ctx, field) 6284 if err != nil { 6285 return graphql.Null 6286 } 6287 ctx = graphql.WithFieldContext(ctx, fc) 6288 defer func() { 6289 if r := recover(); r != nil { 6290 ec.Error(ctx, ec.Recover(ctx, r)) 6291 ret = graphql.Null 6292 } 6293 }() 6294 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 6295 ctx = rctx // use context from middleware stack in children 6296 return obj.Inner, nil 6297 }) 6298 6299 if resTmp == nil { 6300 if !graphql.HasFieldError(ctx, fc) { 6301 ec.Errorf(ctx, "must not be null") 6302 } 6303 return graphql.Null 6304 } 6305 res := resTmp.(*InnerObject) 6306 fc.Result = res 6307 return ec.marshalNInnerObject2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐInnerObject(ctx, field.Selections, res) 6308 } 6309 6310 func (ec *executionContext) fieldContext_OuterObject_inner(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 6311 fc = &graphql.FieldContext{ 6312 Object: "OuterObject", 6313 Field: field, 6314 IsMethod: false, 6315 IsResolver: false, 6316 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 6317 switch field.Name { 6318 case "id": 6319 return ec.fieldContext_InnerObject_id(ctx, field) 6320 } 6321 return nil, fmt.Errorf("no field named %q was found under type InnerObject", field.Name) 6322 }, 6323 } 6324 return fc, nil 6325 } 6326 6327 func (ec *executionContext) _OverlappingFields_oneFoo(ctx context.Context, field graphql.CollectedField, obj *OverlappingFields) (ret graphql.Marshaler) { 6328 fc, err := ec.fieldContext_OverlappingFields_oneFoo(ctx, field) 6329 if err != nil { 6330 return graphql.Null 6331 } 6332 ctx = graphql.WithFieldContext(ctx, fc) 6333 defer func() { 6334 if r := recover(); r != nil { 6335 ec.Error(ctx, ec.Recover(ctx, r)) 6336 ret = graphql.Null 6337 } 6338 }() 6339 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 6340 ctx = rctx // use context from middleware stack in children 6341 return obj.Foo, nil 6342 }) 6343 6344 if resTmp == nil { 6345 if !graphql.HasFieldError(ctx, fc) { 6346 ec.Errorf(ctx, "must not be null") 6347 } 6348 return graphql.Null 6349 } 6350 res := resTmp.(int) 6351 fc.Result = res 6352 return ec.marshalNInt2int(ctx, field.Selections, res) 6353 } 6354 6355 func (ec *executionContext) fieldContext_OverlappingFields_oneFoo(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 6356 fc = &graphql.FieldContext{ 6357 Object: "OverlappingFields", 6358 Field: field, 6359 IsMethod: false, 6360 IsResolver: false, 6361 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 6362 return nil, errors.New("field of type Int does not have child fields") 6363 }, 6364 } 6365 return fc, nil 6366 } 6367 6368 func (ec *executionContext) _OverlappingFields_twoFoo(ctx context.Context, field graphql.CollectedField, obj *OverlappingFields) (ret graphql.Marshaler) { 6369 fc, err := ec.fieldContext_OverlappingFields_twoFoo(ctx, field) 6370 if err != nil { 6371 return graphql.Null 6372 } 6373 ctx = graphql.WithFieldContext(ctx, fc) 6374 defer func() { 6375 if r := recover(); r != nil { 6376 ec.Error(ctx, ec.Recover(ctx, r)) 6377 ret = graphql.Null 6378 } 6379 }() 6380 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 6381 ctx = rctx // use context from middleware stack in children 6382 return obj.Foo, nil 6383 }) 6384 6385 if resTmp == nil { 6386 if !graphql.HasFieldError(ctx, fc) { 6387 ec.Errorf(ctx, "must not be null") 6388 } 6389 return graphql.Null 6390 } 6391 res := resTmp.(int) 6392 fc.Result = res 6393 return ec.marshalNInt2int(ctx, field.Selections, res) 6394 } 6395 6396 func (ec *executionContext) fieldContext_OverlappingFields_twoFoo(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 6397 fc = &graphql.FieldContext{ 6398 Object: "OverlappingFields", 6399 Field: field, 6400 IsMethod: false, 6401 IsResolver: false, 6402 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 6403 return nil, errors.New("field of type Int does not have child fields") 6404 }, 6405 } 6406 return fc, nil 6407 } 6408 6409 func (ec *executionContext) _OverlappingFields_oldFoo(ctx context.Context, field graphql.CollectedField, obj *OverlappingFields) (ret graphql.Marshaler) { 6410 fc, err := ec.fieldContext_OverlappingFields_oldFoo(ctx, field) 6411 if err != nil { 6412 return graphql.Null 6413 } 6414 ctx = graphql.WithFieldContext(ctx, fc) 6415 defer func() { 6416 if r := recover(); r != nil { 6417 ec.Error(ctx, ec.Recover(ctx, r)) 6418 ret = graphql.Null 6419 } 6420 }() 6421 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 6422 ctx = rctx // use context from middleware stack in children 6423 return ec.resolvers.OverlappingFields().OldFoo(rctx, obj) 6424 }) 6425 6426 if resTmp == nil { 6427 if !graphql.HasFieldError(ctx, fc) { 6428 ec.Errorf(ctx, "must not be null") 6429 } 6430 return graphql.Null 6431 } 6432 res := resTmp.(int) 6433 fc.Result = res 6434 return ec.marshalNInt2int(ctx, field.Selections, res) 6435 } 6436 6437 func (ec *executionContext) fieldContext_OverlappingFields_oldFoo(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 6438 fc = &graphql.FieldContext{ 6439 Object: "OverlappingFields", 6440 Field: field, 6441 IsMethod: true, 6442 IsResolver: true, 6443 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 6444 return nil, errors.New("field of type Int does not have child fields") 6445 }, 6446 } 6447 return fc, nil 6448 } 6449 6450 func (ec *executionContext) _OverlappingFields_newFoo(ctx context.Context, field graphql.CollectedField, obj *OverlappingFields) (ret graphql.Marshaler) { 6451 fc, err := ec.fieldContext_OverlappingFields_newFoo(ctx, field) 6452 if err != nil { 6453 return graphql.Null 6454 } 6455 ctx = graphql.WithFieldContext(ctx, fc) 6456 defer func() { 6457 if r := recover(); r != nil { 6458 ec.Error(ctx, ec.Recover(ctx, r)) 6459 ret = graphql.Null 6460 } 6461 }() 6462 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 6463 ctx = rctx // use context from middleware stack in children 6464 return obj.NewFoo, nil 6465 }) 6466 6467 if resTmp == nil { 6468 if !graphql.HasFieldError(ctx, fc) { 6469 ec.Errorf(ctx, "must not be null") 6470 } 6471 return graphql.Null 6472 } 6473 res := resTmp.(int) 6474 fc.Result = res 6475 return ec.marshalNInt2int(ctx, field.Selections, res) 6476 } 6477 6478 func (ec *executionContext) fieldContext_OverlappingFields_newFoo(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 6479 fc = &graphql.FieldContext{ 6480 Object: "OverlappingFields", 6481 Field: field, 6482 IsMethod: false, 6483 IsResolver: false, 6484 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 6485 return nil, errors.New("field of type Int does not have child fields") 6486 }, 6487 } 6488 return fc, nil 6489 } 6490 6491 func (ec *executionContext) _OverlappingFields_new_foo(ctx context.Context, field graphql.CollectedField, obj *OverlappingFields) (ret graphql.Marshaler) { 6492 fc, err := ec.fieldContext_OverlappingFields_new_foo(ctx, field) 6493 if err != nil { 6494 return graphql.Null 6495 } 6496 ctx = graphql.WithFieldContext(ctx, fc) 6497 defer func() { 6498 if r := recover(); r != nil { 6499 ec.Error(ctx, ec.Recover(ctx, r)) 6500 ret = graphql.Null 6501 } 6502 }() 6503 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 6504 ctx = rctx // use context from middleware stack in children 6505 return obj.NewFoo, nil 6506 }) 6507 6508 if resTmp == nil { 6509 if !graphql.HasFieldError(ctx, fc) { 6510 ec.Errorf(ctx, "must not be null") 6511 } 6512 return graphql.Null 6513 } 6514 res := resTmp.(int) 6515 fc.Result = res 6516 return ec.marshalNInt2int(ctx, field.Selections, res) 6517 } 6518 6519 func (ec *executionContext) fieldContext_OverlappingFields_new_foo(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 6520 fc = &graphql.FieldContext{ 6521 Object: "OverlappingFields", 6522 Field: field, 6523 IsMethod: false, 6524 IsResolver: false, 6525 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 6526 return nil, errors.New("field of type Int does not have child fields") 6527 }, 6528 } 6529 return fc, nil 6530 } 6531 6532 func (ec *executionContext) _Panics_fieldScalarMarshal(ctx context.Context, field graphql.CollectedField, obj *Panics) (ret graphql.Marshaler) { 6533 fc, err := ec.fieldContext_Panics_fieldScalarMarshal(ctx, field) 6534 if err != nil { 6535 return graphql.Null 6536 } 6537 ctx = graphql.WithFieldContext(ctx, fc) 6538 defer func() { 6539 if r := recover(); r != nil { 6540 ec.Error(ctx, ec.Recover(ctx, r)) 6541 ret = graphql.Null 6542 } 6543 }() 6544 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 6545 ctx = rctx // use context from middleware stack in children 6546 return ec.resolvers.Panics().FieldScalarMarshal(rctx, obj) 6547 }) 6548 6549 if resTmp == nil { 6550 if !graphql.HasFieldError(ctx, fc) { 6551 ec.Errorf(ctx, "must not be null") 6552 } 6553 return graphql.Null 6554 } 6555 res := resTmp.([]MarshalPanic) 6556 fc.Result = res 6557 return ec.marshalNMarshalPanic2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐMarshalPanicᚄ(ctx, field.Selections, res) 6558 } 6559 6560 func (ec *executionContext) fieldContext_Panics_fieldScalarMarshal(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 6561 fc = &graphql.FieldContext{ 6562 Object: "Panics", 6563 Field: field, 6564 IsMethod: true, 6565 IsResolver: true, 6566 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 6567 return nil, errors.New("field of type MarshalPanic does not have child fields") 6568 }, 6569 } 6570 return fc, nil 6571 } 6572 6573 func (ec *executionContext) _Panics_fieldFuncMarshal(ctx context.Context, field graphql.CollectedField, obj *Panics) (ret graphql.Marshaler) { 6574 fc, err := ec.fieldContext_Panics_fieldFuncMarshal(ctx, field) 6575 if err != nil { 6576 return graphql.Null 6577 } 6578 ctx = graphql.WithFieldContext(ctx, fc) 6579 defer func() { 6580 if r := recover(); r != nil { 6581 ec.Error(ctx, ec.Recover(ctx, r)) 6582 ret = graphql.Null 6583 } 6584 }() 6585 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 6586 ctx = rctx // use context from middleware stack in children 6587 return obj.FieldFuncMarshal(ctx, fc.Args["u"].([]MarshalPanic)), nil 6588 }) 6589 6590 if resTmp == nil { 6591 if !graphql.HasFieldError(ctx, fc) { 6592 ec.Errorf(ctx, "must not be null") 6593 } 6594 return graphql.Null 6595 } 6596 res := resTmp.([]MarshalPanic) 6597 fc.Result = res 6598 return ec.marshalNMarshalPanic2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐMarshalPanicᚄ(ctx, field.Selections, res) 6599 } 6600 6601 func (ec *executionContext) fieldContext_Panics_fieldFuncMarshal(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 6602 fc = &graphql.FieldContext{ 6603 Object: "Panics", 6604 Field: field, 6605 IsMethod: true, 6606 IsResolver: false, 6607 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 6608 return nil, errors.New("field of type MarshalPanic does not have child fields") 6609 }, 6610 } 6611 defer func() { 6612 if r := recover(); r != nil { 6613 err = ec.Recover(ctx, r) 6614 ec.Error(ctx, err) 6615 } 6616 }() 6617 ctx = graphql.WithFieldContext(ctx, fc) 6618 if fc.Args, err = ec.field_Panics_fieldFuncMarshal_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 6619 ec.Error(ctx, err) 6620 return 6621 } 6622 return fc, nil 6623 } 6624 6625 func (ec *executionContext) _Panics_argUnmarshal(ctx context.Context, field graphql.CollectedField, obj *Panics) (ret graphql.Marshaler) { 6626 fc, err := ec.fieldContext_Panics_argUnmarshal(ctx, field) 6627 if err != nil { 6628 return graphql.Null 6629 } 6630 ctx = graphql.WithFieldContext(ctx, fc) 6631 defer func() { 6632 if r := recover(); r != nil { 6633 ec.Error(ctx, ec.Recover(ctx, r)) 6634 ret = graphql.Null 6635 } 6636 }() 6637 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 6638 ctx = rctx // use context from middleware stack in children 6639 return ec.resolvers.Panics().ArgUnmarshal(rctx, obj, fc.Args["u"].([]MarshalPanic)) 6640 }) 6641 6642 if resTmp == nil { 6643 if !graphql.HasFieldError(ctx, fc) { 6644 ec.Errorf(ctx, "must not be null") 6645 } 6646 return graphql.Null 6647 } 6648 res := resTmp.(bool) 6649 fc.Result = res 6650 return ec.marshalNBoolean2bool(ctx, field.Selections, res) 6651 } 6652 6653 func (ec *executionContext) fieldContext_Panics_argUnmarshal(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 6654 fc = &graphql.FieldContext{ 6655 Object: "Panics", 6656 Field: field, 6657 IsMethod: true, 6658 IsResolver: true, 6659 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 6660 return nil, errors.New("field of type Boolean does not have child fields") 6661 }, 6662 } 6663 defer func() { 6664 if r := recover(); r != nil { 6665 err = ec.Recover(ctx, r) 6666 ec.Error(ctx, err) 6667 } 6668 }() 6669 ctx = graphql.WithFieldContext(ctx, fc) 6670 if fc.Args, err = ec.field_Panics_argUnmarshal_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 6671 ec.Error(ctx, err) 6672 return 6673 } 6674 return fc, nil 6675 } 6676 6677 func (ec *executionContext) _Pet_id(ctx context.Context, field graphql.CollectedField, obj *Pet) (ret graphql.Marshaler) { 6678 fc, err := ec.fieldContext_Pet_id(ctx, field) 6679 if err != nil { 6680 return graphql.Null 6681 } 6682 ctx = graphql.WithFieldContext(ctx, fc) 6683 defer func() { 6684 if r := recover(); r != nil { 6685 ec.Error(ctx, ec.Recover(ctx, r)) 6686 ret = graphql.Null 6687 } 6688 }() 6689 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 6690 ctx = rctx // use context from middleware stack in children 6691 return obj.ID, nil 6692 }) 6693 6694 if resTmp == nil { 6695 if !graphql.HasFieldError(ctx, fc) { 6696 ec.Errorf(ctx, "must not be null") 6697 } 6698 return graphql.Null 6699 } 6700 res := resTmp.(int) 6701 fc.Result = res 6702 return ec.marshalNInt2int(ctx, field.Selections, res) 6703 } 6704 6705 func (ec *executionContext) fieldContext_Pet_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 6706 fc = &graphql.FieldContext{ 6707 Object: "Pet", 6708 Field: field, 6709 IsMethod: false, 6710 IsResolver: false, 6711 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 6712 return nil, errors.New("field of type Int does not have child fields") 6713 }, 6714 } 6715 return fc, nil 6716 } 6717 6718 func (ec *executionContext) _Pet_friends(ctx context.Context, field graphql.CollectedField, obj *Pet) (ret graphql.Marshaler) { 6719 fc, err := ec.fieldContext_Pet_friends(ctx, field) 6720 if err != nil { 6721 return graphql.Null 6722 } 6723 ctx = graphql.WithFieldContext(ctx, fc) 6724 defer func() { 6725 if r := recover(); r != nil { 6726 ec.Error(ctx, ec.Recover(ctx, r)) 6727 ret = graphql.Null 6728 } 6729 }() 6730 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 6731 ctx = rctx // use context from middleware stack in children 6732 return ec.resolvers.Pet().Friends(rctx, obj, fc.Args["limit"].(*int)) 6733 }) 6734 6735 if resTmp == nil { 6736 return graphql.Null 6737 } 6738 res := resTmp.([]*Pet) 6739 fc.Result = res 6740 return ec.marshalOPet2ᚕᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPetᚄ(ctx, field.Selections, res) 6741 } 6742 6743 func (ec *executionContext) fieldContext_Pet_friends(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 6744 fc = &graphql.FieldContext{ 6745 Object: "Pet", 6746 Field: field, 6747 IsMethod: true, 6748 IsResolver: true, 6749 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 6750 switch field.Name { 6751 case "id": 6752 return ec.fieldContext_Pet_id(ctx, field) 6753 case "friends": 6754 return ec.fieldContext_Pet_friends(ctx, field) 6755 } 6756 return nil, fmt.Errorf("no field named %q was found under type Pet", field.Name) 6757 }, 6758 } 6759 defer func() { 6760 if r := recover(); r != nil { 6761 err = ec.Recover(ctx, r) 6762 ec.Error(ctx, err) 6763 } 6764 }() 6765 ctx = graphql.WithFieldContext(ctx, fc) 6766 if fc.Args, err = ec.field_Pet_friends_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 6767 ec.Error(ctx, err) 6768 return 6769 } 6770 return fc, nil 6771 } 6772 6773 func (ec *executionContext) _Primitive_value(ctx context.Context, field graphql.CollectedField, obj *Primitive) (ret graphql.Marshaler) { 6774 fc, err := ec.fieldContext_Primitive_value(ctx, field) 6775 if err != nil { 6776 return graphql.Null 6777 } 6778 ctx = graphql.WithFieldContext(ctx, fc) 6779 defer func() { 6780 if r := recover(); r != nil { 6781 ec.Error(ctx, ec.Recover(ctx, r)) 6782 ret = graphql.Null 6783 } 6784 }() 6785 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 6786 ctx = rctx // use context from middleware stack in children 6787 return ec.resolvers.Primitive().Value(rctx, obj) 6788 }) 6789 6790 if resTmp == nil { 6791 if !graphql.HasFieldError(ctx, fc) { 6792 ec.Errorf(ctx, "must not be null") 6793 } 6794 return graphql.Null 6795 } 6796 res := resTmp.(int) 6797 fc.Result = res 6798 return ec.marshalNInt2int(ctx, field.Selections, res) 6799 } 6800 6801 func (ec *executionContext) fieldContext_Primitive_value(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 6802 fc = &graphql.FieldContext{ 6803 Object: "Primitive", 6804 Field: field, 6805 IsMethod: true, 6806 IsResolver: true, 6807 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 6808 return nil, errors.New("field of type Int does not have child fields") 6809 }, 6810 } 6811 return fc, nil 6812 } 6813 6814 func (ec *executionContext) _Primitive_squared(ctx context.Context, field graphql.CollectedField, obj *Primitive) (ret graphql.Marshaler) { 6815 fc, err := ec.fieldContext_Primitive_squared(ctx, field) 6816 if err != nil { 6817 return graphql.Null 6818 } 6819 ctx = graphql.WithFieldContext(ctx, fc) 6820 defer func() { 6821 if r := recover(); r != nil { 6822 ec.Error(ctx, ec.Recover(ctx, r)) 6823 ret = graphql.Null 6824 } 6825 }() 6826 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 6827 ctx = rctx // use context from middleware stack in children 6828 return obj.Squared(), nil 6829 }) 6830 6831 if resTmp == nil { 6832 if !graphql.HasFieldError(ctx, fc) { 6833 ec.Errorf(ctx, "must not be null") 6834 } 6835 return graphql.Null 6836 } 6837 res := resTmp.(int) 6838 fc.Result = res 6839 return ec.marshalNInt2int(ctx, field.Selections, res) 6840 } 6841 6842 func (ec *executionContext) fieldContext_Primitive_squared(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 6843 fc = &graphql.FieldContext{ 6844 Object: "Primitive", 6845 Field: field, 6846 IsMethod: true, 6847 IsResolver: false, 6848 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 6849 return nil, errors.New("field of type Int does not have child fields") 6850 }, 6851 } 6852 return fc, nil 6853 } 6854 6855 func (ec *executionContext) _PrimitiveString_value(ctx context.Context, field graphql.CollectedField, obj *PrimitiveString) (ret graphql.Marshaler) { 6856 fc, err := ec.fieldContext_PrimitiveString_value(ctx, field) 6857 if err != nil { 6858 return graphql.Null 6859 } 6860 ctx = graphql.WithFieldContext(ctx, fc) 6861 defer func() { 6862 if r := recover(); r != nil { 6863 ec.Error(ctx, ec.Recover(ctx, r)) 6864 ret = graphql.Null 6865 } 6866 }() 6867 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 6868 ctx = rctx // use context from middleware stack in children 6869 return ec.resolvers.PrimitiveString().Value(rctx, obj) 6870 }) 6871 6872 if resTmp == nil { 6873 if !graphql.HasFieldError(ctx, fc) { 6874 ec.Errorf(ctx, "must not be null") 6875 } 6876 return graphql.Null 6877 } 6878 res := resTmp.(string) 6879 fc.Result = res 6880 return ec.marshalNString2string(ctx, field.Selections, res) 6881 } 6882 6883 func (ec *executionContext) fieldContext_PrimitiveString_value(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 6884 fc = &graphql.FieldContext{ 6885 Object: "PrimitiveString", 6886 Field: field, 6887 IsMethod: true, 6888 IsResolver: true, 6889 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 6890 return nil, errors.New("field of type String does not have child fields") 6891 }, 6892 } 6893 return fc, nil 6894 } 6895 6896 func (ec *executionContext) _PrimitiveString_doubled(ctx context.Context, field graphql.CollectedField, obj *PrimitiveString) (ret graphql.Marshaler) { 6897 fc, err := ec.fieldContext_PrimitiveString_doubled(ctx, field) 6898 if err != nil { 6899 return graphql.Null 6900 } 6901 ctx = graphql.WithFieldContext(ctx, fc) 6902 defer func() { 6903 if r := recover(); r != nil { 6904 ec.Error(ctx, ec.Recover(ctx, r)) 6905 ret = graphql.Null 6906 } 6907 }() 6908 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 6909 ctx = rctx // use context from middleware stack in children 6910 return obj.Doubled(), nil 6911 }) 6912 6913 if resTmp == nil { 6914 if !graphql.HasFieldError(ctx, fc) { 6915 ec.Errorf(ctx, "must not be null") 6916 } 6917 return graphql.Null 6918 } 6919 res := resTmp.(string) 6920 fc.Result = res 6921 return ec.marshalNString2string(ctx, field.Selections, res) 6922 } 6923 6924 func (ec *executionContext) fieldContext_PrimitiveString_doubled(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 6925 fc = &graphql.FieldContext{ 6926 Object: "PrimitiveString", 6927 Field: field, 6928 IsMethod: true, 6929 IsResolver: false, 6930 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 6931 return nil, errors.New("field of type String does not have child fields") 6932 }, 6933 } 6934 return fc, nil 6935 } 6936 6937 func (ec *executionContext) _PrimitiveString_len(ctx context.Context, field graphql.CollectedField, obj *PrimitiveString) (ret graphql.Marshaler) { 6938 fc, err := ec.fieldContext_PrimitiveString_len(ctx, field) 6939 if err != nil { 6940 return graphql.Null 6941 } 6942 ctx = graphql.WithFieldContext(ctx, fc) 6943 defer func() { 6944 if r := recover(); r != nil { 6945 ec.Error(ctx, ec.Recover(ctx, r)) 6946 ret = graphql.Null 6947 } 6948 }() 6949 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 6950 ctx = rctx // use context from middleware stack in children 6951 return ec.resolvers.PrimitiveString().Len(rctx, obj) 6952 }) 6953 6954 if resTmp == nil { 6955 if !graphql.HasFieldError(ctx, fc) { 6956 ec.Errorf(ctx, "must not be null") 6957 } 6958 return graphql.Null 6959 } 6960 res := resTmp.(int) 6961 fc.Result = res 6962 return ec.marshalNInt2int(ctx, field.Selections, res) 6963 } 6964 6965 func (ec *executionContext) fieldContext_PrimitiveString_len(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 6966 fc = &graphql.FieldContext{ 6967 Object: "PrimitiveString", 6968 Field: field, 6969 IsMethod: true, 6970 IsResolver: true, 6971 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 6972 return nil, errors.New("field of type Int does not have child fields") 6973 }, 6974 } 6975 return fc, nil 6976 } 6977 6978 func (ec *executionContext) _PtrToPtrInner_key(ctx context.Context, field graphql.CollectedField, obj *PtrToPtrInner) (ret graphql.Marshaler) { 6979 fc, err := ec.fieldContext_PtrToPtrInner_key(ctx, field) 6980 if err != nil { 6981 return graphql.Null 6982 } 6983 ctx = graphql.WithFieldContext(ctx, fc) 6984 defer func() { 6985 if r := recover(); r != nil { 6986 ec.Error(ctx, ec.Recover(ctx, r)) 6987 ret = graphql.Null 6988 } 6989 }() 6990 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 6991 ctx = rctx // use context from middleware stack in children 6992 return obj.Key, nil 6993 }) 6994 6995 if resTmp == nil { 6996 if !graphql.HasFieldError(ctx, fc) { 6997 ec.Errorf(ctx, "must not be null") 6998 } 6999 return graphql.Null 7000 } 7001 res := resTmp.(string) 7002 fc.Result = res 7003 return ec.marshalNString2string(ctx, field.Selections, res) 7004 } 7005 7006 func (ec *executionContext) fieldContext_PtrToPtrInner_key(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 7007 fc = &graphql.FieldContext{ 7008 Object: "PtrToPtrInner", 7009 Field: field, 7010 IsMethod: false, 7011 IsResolver: false, 7012 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 7013 return nil, errors.New("field of type String does not have child fields") 7014 }, 7015 } 7016 return fc, nil 7017 } 7018 7019 func (ec *executionContext) _PtrToPtrInner_value(ctx context.Context, field graphql.CollectedField, obj *PtrToPtrInner) (ret graphql.Marshaler) { 7020 fc, err := ec.fieldContext_PtrToPtrInner_value(ctx, field) 7021 if err != nil { 7022 return graphql.Null 7023 } 7024 ctx = graphql.WithFieldContext(ctx, fc) 7025 defer func() { 7026 if r := recover(); r != nil { 7027 ec.Error(ctx, ec.Recover(ctx, r)) 7028 ret = graphql.Null 7029 } 7030 }() 7031 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 7032 ctx = rctx // use context from middleware stack in children 7033 return obj.Value, nil 7034 }) 7035 7036 if resTmp == nil { 7037 if !graphql.HasFieldError(ctx, fc) { 7038 ec.Errorf(ctx, "must not be null") 7039 } 7040 return graphql.Null 7041 } 7042 res := resTmp.(string) 7043 fc.Result = res 7044 return ec.marshalNString2string(ctx, field.Selections, res) 7045 } 7046 7047 func (ec *executionContext) fieldContext_PtrToPtrInner_value(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 7048 fc = &graphql.FieldContext{ 7049 Object: "PtrToPtrInner", 7050 Field: field, 7051 IsMethod: false, 7052 IsResolver: false, 7053 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 7054 return nil, errors.New("field of type String does not have child fields") 7055 }, 7056 } 7057 return fc, nil 7058 } 7059 7060 func (ec *executionContext) _PtrToPtrOuter_name(ctx context.Context, field graphql.CollectedField, obj *PtrToPtrOuter) (ret graphql.Marshaler) { 7061 fc, err := ec.fieldContext_PtrToPtrOuter_name(ctx, field) 7062 if err != nil { 7063 return graphql.Null 7064 } 7065 ctx = graphql.WithFieldContext(ctx, fc) 7066 defer func() { 7067 if r := recover(); r != nil { 7068 ec.Error(ctx, ec.Recover(ctx, r)) 7069 ret = graphql.Null 7070 } 7071 }() 7072 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 7073 ctx = rctx // use context from middleware stack in children 7074 return obj.Name, nil 7075 }) 7076 7077 if resTmp == nil { 7078 if !graphql.HasFieldError(ctx, fc) { 7079 ec.Errorf(ctx, "must not be null") 7080 } 7081 return graphql.Null 7082 } 7083 res := resTmp.(string) 7084 fc.Result = res 7085 return ec.marshalNString2string(ctx, field.Selections, res) 7086 } 7087 7088 func (ec *executionContext) fieldContext_PtrToPtrOuter_name(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 7089 fc = &graphql.FieldContext{ 7090 Object: "PtrToPtrOuter", 7091 Field: field, 7092 IsMethod: false, 7093 IsResolver: false, 7094 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 7095 return nil, errors.New("field of type String does not have child fields") 7096 }, 7097 } 7098 return fc, nil 7099 } 7100 7101 func (ec *executionContext) _PtrToPtrOuter_inner(ctx context.Context, field graphql.CollectedField, obj *PtrToPtrOuter) (ret graphql.Marshaler) { 7102 fc, err := ec.fieldContext_PtrToPtrOuter_inner(ctx, field) 7103 if err != nil { 7104 return graphql.Null 7105 } 7106 ctx = graphql.WithFieldContext(ctx, fc) 7107 defer func() { 7108 if r := recover(); r != nil { 7109 ec.Error(ctx, ec.Recover(ctx, r)) 7110 ret = graphql.Null 7111 } 7112 }() 7113 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 7114 ctx = rctx // use context from middleware stack in children 7115 return obj.Inner, nil 7116 }) 7117 7118 if resTmp == nil { 7119 return graphql.Null 7120 } 7121 res := resTmp.(*PtrToPtrInner) 7122 fc.Result = res 7123 return ec.marshalOPtrToPtrInner2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPtrToPtrInner(ctx, field.Selections, res) 7124 } 7125 7126 func (ec *executionContext) fieldContext_PtrToPtrOuter_inner(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 7127 fc = &graphql.FieldContext{ 7128 Object: "PtrToPtrOuter", 7129 Field: field, 7130 IsMethod: false, 7131 IsResolver: false, 7132 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 7133 switch field.Name { 7134 case "key": 7135 return ec.fieldContext_PtrToPtrInner_key(ctx, field) 7136 case "value": 7137 return ec.fieldContext_PtrToPtrInner_value(ctx, field) 7138 } 7139 return nil, fmt.Errorf("no field named %q was found under type PtrToPtrInner", field.Name) 7140 }, 7141 } 7142 return fc, nil 7143 } 7144 7145 func (ec *executionContext) _PtrToPtrOuter_stupidInner(ctx context.Context, field graphql.CollectedField, obj *PtrToPtrOuter) (ret graphql.Marshaler) { 7146 fc, err := ec.fieldContext_PtrToPtrOuter_stupidInner(ctx, field) 7147 if err != nil { 7148 return graphql.Null 7149 } 7150 ctx = graphql.WithFieldContext(ctx, fc) 7151 defer func() { 7152 if r := recover(); r != nil { 7153 ec.Error(ctx, ec.Recover(ctx, r)) 7154 ret = graphql.Null 7155 } 7156 }() 7157 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 7158 ctx = rctx // use context from middleware stack in children 7159 return obj.StupidInner, nil 7160 }) 7161 7162 if resTmp == nil { 7163 return graphql.Null 7164 } 7165 res := resTmp.(*******PtrToPtrInner) 7166 fc.Result = res 7167 return ec.marshalOPtrToPtrInner2ᚖᚖᚖᚖᚖᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPtrToPtrInner(ctx, field.Selections, res) 7168 } 7169 7170 func (ec *executionContext) fieldContext_PtrToPtrOuter_stupidInner(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 7171 fc = &graphql.FieldContext{ 7172 Object: "PtrToPtrOuter", 7173 Field: field, 7174 IsMethod: false, 7175 IsResolver: false, 7176 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 7177 switch field.Name { 7178 case "key": 7179 return ec.fieldContext_PtrToPtrInner_key(ctx, field) 7180 case "value": 7181 return ec.fieldContext_PtrToPtrInner_value(ctx, field) 7182 } 7183 return nil, fmt.Errorf("no field named %q was found under type PtrToPtrInner", field.Name) 7184 }, 7185 } 7186 return fc, nil 7187 } 7188 7189 func (ec *executionContext) _PtrToSliceContainer_ptrToSlice(ctx context.Context, field graphql.CollectedField, obj *PtrToSliceContainer) (ret graphql.Marshaler) { 7190 fc, err := ec.fieldContext_PtrToSliceContainer_ptrToSlice(ctx, field) 7191 if err != nil { 7192 return graphql.Null 7193 } 7194 ctx = graphql.WithFieldContext(ctx, fc) 7195 defer func() { 7196 if r := recover(); r != nil { 7197 ec.Error(ctx, ec.Recover(ctx, r)) 7198 ret = graphql.Null 7199 } 7200 }() 7201 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 7202 ctx = rctx // use context from middleware stack in children 7203 return obj.PtrToSlice, nil 7204 }) 7205 7206 if resTmp == nil { 7207 return graphql.Null 7208 } 7209 res := resTmp.(*[]string) 7210 fc.Result = res 7211 return ec.marshalOString2ᚖᚕstringᚄ(ctx, field.Selections, res) 7212 } 7213 7214 func (ec *executionContext) fieldContext_PtrToSliceContainer_ptrToSlice(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 7215 fc = &graphql.FieldContext{ 7216 Object: "PtrToSliceContainer", 7217 Field: field, 7218 IsMethod: false, 7219 IsResolver: false, 7220 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 7221 return nil, errors.New("field of type String does not have child fields") 7222 }, 7223 } 7224 return fc, nil 7225 } 7226 7227 func (ec *executionContext) _Query_invalidIdentifier(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 7228 fc, err := ec.fieldContext_Query_invalidIdentifier(ctx, field) 7229 if err != nil { 7230 return graphql.Null 7231 } 7232 ctx = graphql.WithFieldContext(ctx, fc) 7233 defer func() { 7234 if r := recover(); r != nil { 7235 ec.Error(ctx, ec.Recover(ctx, r)) 7236 ret = graphql.Null 7237 } 7238 }() 7239 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 7240 ctx = rctx // use context from middleware stack in children 7241 return ec.resolvers.Query().InvalidIdentifier(rctx) 7242 }) 7243 7244 if resTmp == nil { 7245 return graphql.Null 7246 } 7247 res := resTmp.(*invalid_packagename.InvalidIdentifier) 7248 fc.Result = res 7249 return ec.marshalOInvalidIdentifier2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚋinvalidᚑpackagenameᚐInvalidIdentifier(ctx, field.Selections, res) 7250 } 7251 7252 func (ec *executionContext) fieldContext_Query_invalidIdentifier(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 7253 fc = &graphql.FieldContext{ 7254 Object: "Query", 7255 Field: field, 7256 IsMethod: true, 7257 IsResolver: true, 7258 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 7259 switch field.Name { 7260 case "id": 7261 return ec.fieldContext_InvalidIdentifier_id(ctx, field) 7262 } 7263 return nil, fmt.Errorf("no field named %q was found under type InvalidIdentifier", field.Name) 7264 }, 7265 } 7266 return fc, nil 7267 } 7268 7269 func (ec *executionContext) _Query_collision(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 7270 fc, err := ec.fieldContext_Query_collision(ctx, field) 7271 if err != nil { 7272 return graphql.Null 7273 } 7274 ctx = graphql.WithFieldContext(ctx, fc) 7275 defer func() { 7276 if r := recover(); r != nil { 7277 ec.Error(ctx, ec.Recover(ctx, r)) 7278 ret = graphql.Null 7279 } 7280 }() 7281 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 7282 ctx = rctx // use context from middleware stack in children 7283 return ec.resolvers.Query().Collision(rctx) 7284 }) 7285 7286 if resTmp == nil { 7287 return graphql.Null 7288 } 7289 res := resTmp.(*introspection1.It) 7290 fc.Result = res 7291 return ec.marshalOIt2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚋintrospectionᚐIt(ctx, field.Selections, res) 7292 } 7293 7294 func (ec *executionContext) fieldContext_Query_collision(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 7295 fc = &graphql.FieldContext{ 7296 Object: "Query", 7297 Field: field, 7298 IsMethod: true, 7299 IsResolver: true, 7300 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 7301 switch field.Name { 7302 case "id": 7303 return ec.fieldContext_It_id(ctx, field) 7304 } 7305 return nil, fmt.Errorf("no field named %q was found under type It", field.Name) 7306 }, 7307 } 7308 return fc, nil 7309 } 7310 7311 func (ec *executionContext) _Query_mapInput(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 7312 fc, err := ec.fieldContext_Query_mapInput(ctx, field) 7313 if err != nil { 7314 return graphql.Null 7315 } 7316 ctx = graphql.WithFieldContext(ctx, fc) 7317 defer func() { 7318 if r := recover(); r != nil { 7319 ec.Error(ctx, ec.Recover(ctx, r)) 7320 ret = graphql.Null 7321 } 7322 }() 7323 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 7324 ctx = rctx // use context from middleware stack in children 7325 return ec.resolvers.Query().MapInput(rctx, fc.Args["input"].(map[string]interface{})) 7326 }) 7327 7328 if resTmp == nil { 7329 return graphql.Null 7330 } 7331 res := resTmp.(*bool) 7332 fc.Result = res 7333 return ec.marshalOBoolean2ᚖbool(ctx, field.Selections, res) 7334 } 7335 7336 func (ec *executionContext) fieldContext_Query_mapInput(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 7337 fc = &graphql.FieldContext{ 7338 Object: "Query", 7339 Field: field, 7340 IsMethod: true, 7341 IsResolver: true, 7342 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 7343 return nil, errors.New("field of type Boolean does not have child fields") 7344 }, 7345 } 7346 defer func() { 7347 if r := recover(); r != nil { 7348 err = ec.Recover(ctx, r) 7349 ec.Error(ctx, err) 7350 } 7351 }() 7352 ctx = graphql.WithFieldContext(ctx, fc) 7353 if fc.Args, err = ec.field_Query_mapInput_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 7354 ec.Error(ctx, err) 7355 return 7356 } 7357 return fc, nil 7358 } 7359 7360 func (ec *executionContext) _Query_recursive(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 7361 fc, err := ec.fieldContext_Query_recursive(ctx, field) 7362 if err != nil { 7363 return graphql.Null 7364 } 7365 ctx = graphql.WithFieldContext(ctx, fc) 7366 defer func() { 7367 if r := recover(); r != nil { 7368 ec.Error(ctx, ec.Recover(ctx, r)) 7369 ret = graphql.Null 7370 } 7371 }() 7372 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 7373 ctx = rctx // use context from middleware stack in children 7374 return ec.resolvers.Query().Recursive(rctx, fc.Args["input"].(*RecursiveInputSlice)) 7375 }) 7376 7377 if resTmp == nil { 7378 return graphql.Null 7379 } 7380 res := resTmp.(*bool) 7381 fc.Result = res 7382 return ec.marshalOBoolean2ᚖbool(ctx, field.Selections, res) 7383 } 7384 7385 func (ec *executionContext) fieldContext_Query_recursive(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 7386 fc = &graphql.FieldContext{ 7387 Object: "Query", 7388 Field: field, 7389 IsMethod: true, 7390 IsResolver: true, 7391 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 7392 return nil, errors.New("field of type Boolean does not have child fields") 7393 }, 7394 } 7395 defer func() { 7396 if r := recover(); r != nil { 7397 err = ec.Recover(ctx, r) 7398 ec.Error(ctx, err) 7399 } 7400 }() 7401 ctx = graphql.WithFieldContext(ctx, fc) 7402 if fc.Args, err = ec.field_Query_recursive_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 7403 ec.Error(ctx, err) 7404 return 7405 } 7406 return fc, nil 7407 } 7408 7409 func (ec *executionContext) _Query_nestedInputs(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 7410 fc, err := ec.fieldContext_Query_nestedInputs(ctx, field) 7411 if err != nil { 7412 return graphql.Null 7413 } 7414 ctx = graphql.WithFieldContext(ctx, fc) 7415 defer func() { 7416 if r := recover(); r != nil { 7417 ec.Error(ctx, ec.Recover(ctx, r)) 7418 ret = graphql.Null 7419 } 7420 }() 7421 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 7422 ctx = rctx // use context from middleware stack in children 7423 return ec.resolvers.Query().NestedInputs(rctx, fc.Args["input"].([][]*OuterInput)) 7424 }) 7425 7426 if resTmp == nil { 7427 return graphql.Null 7428 } 7429 res := resTmp.(*bool) 7430 fc.Result = res 7431 return ec.marshalOBoolean2ᚖbool(ctx, field.Selections, res) 7432 } 7433 7434 func (ec *executionContext) fieldContext_Query_nestedInputs(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 7435 fc = &graphql.FieldContext{ 7436 Object: "Query", 7437 Field: field, 7438 IsMethod: true, 7439 IsResolver: true, 7440 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 7441 return nil, errors.New("field of type Boolean does not have child fields") 7442 }, 7443 } 7444 defer func() { 7445 if r := recover(); r != nil { 7446 err = ec.Recover(ctx, r) 7447 ec.Error(ctx, err) 7448 } 7449 }() 7450 ctx = graphql.WithFieldContext(ctx, fc) 7451 if fc.Args, err = ec.field_Query_nestedInputs_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 7452 ec.Error(ctx, err) 7453 return 7454 } 7455 return fc, nil 7456 } 7457 7458 func (ec *executionContext) _Query_nestedOutputs(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 7459 fc, err := ec.fieldContext_Query_nestedOutputs(ctx, field) 7460 if err != nil { 7461 return graphql.Null 7462 } 7463 ctx = graphql.WithFieldContext(ctx, fc) 7464 defer func() { 7465 if r := recover(); r != nil { 7466 ec.Error(ctx, ec.Recover(ctx, r)) 7467 ret = graphql.Null 7468 } 7469 }() 7470 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 7471 ctx = rctx // use context from middleware stack in children 7472 return ec.resolvers.Query().NestedOutputs(rctx) 7473 }) 7474 7475 if resTmp == nil { 7476 return graphql.Null 7477 } 7478 res := resTmp.([][]*OuterObject) 7479 fc.Result = res 7480 return ec.marshalOOuterObject2ᚕᚕᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐOuterObject(ctx, field.Selections, res) 7481 } 7482 7483 func (ec *executionContext) fieldContext_Query_nestedOutputs(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 7484 fc = &graphql.FieldContext{ 7485 Object: "Query", 7486 Field: field, 7487 IsMethod: true, 7488 IsResolver: true, 7489 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 7490 switch field.Name { 7491 case "inner": 7492 return ec.fieldContext_OuterObject_inner(ctx, field) 7493 } 7494 return nil, fmt.Errorf("no field named %q was found under type OuterObject", field.Name) 7495 }, 7496 } 7497 return fc, nil 7498 } 7499 7500 func (ec *executionContext) _Query_modelMethods(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 7501 fc, err := ec.fieldContext_Query_modelMethods(ctx, field) 7502 if err != nil { 7503 return graphql.Null 7504 } 7505 ctx = graphql.WithFieldContext(ctx, fc) 7506 defer func() { 7507 if r := recover(); r != nil { 7508 ec.Error(ctx, ec.Recover(ctx, r)) 7509 ret = graphql.Null 7510 } 7511 }() 7512 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 7513 ctx = rctx // use context from middleware stack in children 7514 return ec.resolvers.Query().ModelMethods(rctx) 7515 }) 7516 7517 if resTmp == nil { 7518 return graphql.Null 7519 } 7520 res := resTmp.(*ModelMethods) 7521 fc.Result = res 7522 return ec.marshalOModelMethods2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐModelMethods(ctx, field.Selections, res) 7523 } 7524 7525 func (ec *executionContext) fieldContext_Query_modelMethods(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 7526 fc = &graphql.FieldContext{ 7527 Object: "Query", 7528 Field: field, 7529 IsMethod: true, 7530 IsResolver: true, 7531 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 7532 switch field.Name { 7533 case "resolverField": 7534 return ec.fieldContext_ModelMethods_resolverField(ctx, field) 7535 case "noContext": 7536 return ec.fieldContext_ModelMethods_noContext(ctx, field) 7537 case "withContext": 7538 return ec.fieldContext_ModelMethods_withContext(ctx, field) 7539 } 7540 return nil, fmt.Errorf("no field named %q was found under type ModelMethods", field.Name) 7541 }, 7542 } 7543 return fc, nil 7544 } 7545 7546 func (ec *executionContext) _Query_user(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 7547 fc, err := ec.fieldContext_Query_user(ctx, field) 7548 if err != nil { 7549 return graphql.Null 7550 } 7551 ctx = graphql.WithFieldContext(ctx, fc) 7552 defer func() { 7553 if r := recover(); r != nil { 7554 ec.Error(ctx, ec.Recover(ctx, r)) 7555 ret = graphql.Null 7556 } 7557 }() 7558 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 7559 ctx = rctx // use context from middleware stack in children 7560 return ec.resolvers.Query().User(rctx, fc.Args["id"].(int)) 7561 }) 7562 7563 if resTmp == nil { 7564 if !graphql.HasFieldError(ctx, fc) { 7565 ec.Errorf(ctx, "must not be null") 7566 } 7567 return graphql.Null 7568 } 7569 res := resTmp.(*User) 7570 fc.Result = res 7571 return ec.marshalNUser2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUser(ctx, field.Selections, res) 7572 } 7573 7574 func (ec *executionContext) fieldContext_Query_user(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 7575 fc = &graphql.FieldContext{ 7576 Object: "Query", 7577 Field: field, 7578 IsMethod: true, 7579 IsResolver: true, 7580 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 7581 switch field.Name { 7582 case "id": 7583 return ec.fieldContext_User_id(ctx, field) 7584 case "friends": 7585 return ec.fieldContext_User_friends(ctx, field) 7586 case "created": 7587 return ec.fieldContext_User_created(ctx, field) 7588 case "updated": 7589 return ec.fieldContext_User_updated(ctx, field) 7590 case "pets": 7591 return ec.fieldContext_User_pets(ctx, field) 7592 } 7593 return nil, fmt.Errorf("no field named %q was found under type User", field.Name) 7594 }, 7595 } 7596 defer func() { 7597 if r := recover(); r != nil { 7598 err = ec.Recover(ctx, r) 7599 ec.Error(ctx, err) 7600 } 7601 }() 7602 ctx = graphql.WithFieldContext(ctx, fc) 7603 if fc.Args, err = ec.field_Query_user_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 7604 ec.Error(ctx, err) 7605 return 7606 } 7607 return fc, nil 7608 } 7609 7610 func (ec *executionContext) _Query_nullableArg(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 7611 fc, err := ec.fieldContext_Query_nullableArg(ctx, field) 7612 if err != nil { 7613 return graphql.Null 7614 } 7615 ctx = graphql.WithFieldContext(ctx, fc) 7616 defer func() { 7617 if r := recover(); r != nil { 7618 ec.Error(ctx, ec.Recover(ctx, r)) 7619 ret = graphql.Null 7620 } 7621 }() 7622 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 7623 ctx = rctx // use context from middleware stack in children 7624 return ec.resolvers.Query().NullableArg(rctx, fc.Args["arg"].(*int)) 7625 }) 7626 7627 if resTmp == nil { 7628 return graphql.Null 7629 } 7630 res := resTmp.(*string) 7631 fc.Result = res 7632 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 7633 } 7634 7635 func (ec *executionContext) fieldContext_Query_nullableArg(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 7636 fc = &graphql.FieldContext{ 7637 Object: "Query", 7638 Field: field, 7639 IsMethod: true, 7640 IsResolver: true, 7641 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 7642 return nil, errors.New("field of type String does not have child fields") 7643 }, 7644 } 7645 defer func() { 7646 if r := recover(); r != nil { 7647 err = ec.Recover(ctx, r) 7648 ec.Error(ctx, err) 7649 } 7650 }() 7651 ctx = graphql.WithFieldContext(ctx, fc) 7652 if fc.Args, err = ec.field_Query_nullableArg_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 7653 ec.Error(ctx, err) 7654 return 7655 } 7656 return fc, nil 7657 } 7658 7659 func (ec *executionContext) _Query_inputSlice(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 7660 fc, err := ec.fieldContext_Query_inputSlice(ctx, field) 7661 if err != nil { 7662 return graphql.Null 7663 } 7664 ctx = graphql.WithFieldContext(ctx, fc) 7665 defer func() { 7666 if r := recover(); r != nil { 7667 ec.Error(ctx, ec.Recover(ctx, r)) 7668 ret = graphql.Null 7669 } 7670 }() 7671 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 7672 ctx = rctx // use context from middleware stack in children 7673 return ec.resolvers.Query().InputSlice(rctx, fc.Args["arg"].([]string)) 7674 }) 7675 7676 if resTmp == nil { 7677 if !graphql.HasFieldError(ctx, fc) { 7678 ec.Errorf(ctx, "must not be null") 7679 } 7680 return graphql.Null 7681 } 7682 res := resTmp.(bool) 7683 fc.Result = res 7684 return ec.marshalNBoolean2bool(ctx, field.Selections, res) 7685 } 7686 7687 func (ec *executionContext) fieldContext_Query_inputSlice(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 7688 fc = &graphql.FieldContext{ 7689 Object: "Query", 7690 Field: field, 7691 IsMethod: true, 7692 IsResolver: true, 7693 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 7694 return nil, errors.New("field of type Boolean does not have child fields") 7695 }, 7696 } 7697 defer func() { 7698 if r := recover(); r != nil { 7699 err = ec.Recover(ctx, r) 7700 ec.Error(ctx, err) 7701 } 7702 }() 7703 ctx = graphql.WithFieldContext(ctx, fc) 7704 if fc.Args, err = ec.field_Query_inputSlice_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 7705 ec.Error(ctx, err) 7706 return 7707 } 7708 return fc, nil 7709 } 7710 7711 func (ec *executionContext) _Query_inputNullableSlice(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 7712 fc, err := ec.fieldContext_Query_inputNullableSlice(ctx, field) 7713 if err != nil { 7714 return graphql.Null 7715 } 7716 ctx = graphql.WithFieldContext(ctx, fc) 7717 defer func() { 7718 if r := recover(); r != nil { 7719 ec.Error(ctx, ec.Recover(ctx, r)) 7720 ret = graphql.Null 7721 } 7722 }() 7723 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 7724 ctx = rctx // use context from middleware stack in children 7725 return ec.resolvers.Query().InputNullableSlice(rctx, fc.Args["arg"].([]string)) 7726 }) 7727 7728 if resTmp == nil { 7729 if !graphql.HasFieldError(ctx, fc) { 7730 ec.Errorf(ctx, "must not be null") 7731 } 7732 return graphql.Null 7733 } 7734 res := resTmp.(bool) 7735 fc.Result = res 7736 return ec.marshalNBoolean2bool(ctx, field.Selections, res) 7737 } 7738 7739 func (ec *executionContext) fieldContext_Query_inputNullableSlice(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 7740 fc = &graphql.FieldContext{ 7741 Object: "Query", 7742 Field: field, 7743 IsMethod: true, 7744 IsResolver: true, 7745 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 7746 return nil, errors.New("field of type Boolean does not have child fields") 7747 }, 7748 } 7749 defer func() { 7750 if r := recover(); r != nil { 7751 err = ec.Recover(ctx, r) 7752 ec.Error(ctx, err) 7753 } 7754 }() 7755 ctx = graphql.WithFieldContext(ctx, fc) 7756 if fc.Args, err = ec.field_Query_inputNullableSlice_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 7757 ec.Error(ctx, err) 7758 return 7759 } 7760 return fc, nil 7761 } 7762 7763 func (ec *executionContext) _Query_shapeUnion(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 7764 fc, err := ec.fieldContext_Query_shapeUnion(ctx, field) 7765 if err != nil { 7766 return graphql.Null 7767 } 7768 ctx = graphql.WithFieldContext(ctx, fc) 7769 defer func() { 7770 if r := recover(); r != nil { 7771 ec.Error(ctx, ec.Recover(ctx, r)) 7772 ret = graphql.Null 7773 } 7774 }() 7775 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 7776 ctx = rctx // use context from middleware stack in children 7777 return ec.resolvers.Query().ShapeUnion(rctx) 7778 }) 7779 7780 if resTmp == nil { 7781 if !graphql.HasFieldError(ctx, fc) { 7782 ec.Errorf(ctx, "must not be null") 7783 } 7784 return graphql.Null 7785 } 7786 res := resTmp.(ShapeUnion) 7787 fc.Result = res 7788 return ec.marshalNShapeUnion2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐShapeUnion(ctx, field.Selections, res) 7789 } 7790 7791 func (ec *executionContext) fieldContext_Query_shapeUnion(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 7792 fc = &graphql.FieldContext{ 7793 Object: "Query", 7794 Field: field, 7795 IsMethod: true, 7796 IsResolver: true, 7797 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 7798 return nil, errors.New("field of type ShapeUnion does not have child fields") 7799 }, 7800 } 7801 return fc, nil 7802 } 7803 7804 func (ec *executionContext) _Query_autobind(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 7805 fc, err := ec.fieldContext_Query_autobind(ctx, field) 7806 if err != nil { 7807 return graphql.Null 7808 } 7809 ctx = graphql.WithFieldContext(ctx, fc) 7810 defer func() { 7811 if r := recover(); r != nil { 7812 ec.Error(ctx, ec.Recover(ctx, r)) 7813 ret = graphql.Null 7814 } 7815 }() 7816 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 7817 ctx = rctx // use context from middleware stack in children 7818 return ec.resolvers.Query().Autobind(rctx) 7819 }) 7820 7821 if resTmp == nil { 7822 return graphql.Null 7823 } 7824 res := resTmp.(*Autobind) 7825 fc.Result = res 7826 return ec.marshalOAutobind2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐAutobind(ctx, field.Selections, res) 7827 } 7828 7829 func (ec *executionContext) fieldContext_Query_autobind(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 7830 fc = &graphql.FieldContext{ 7831 Object: "Query", 7832 Field: field, 7833 IsMethod: true, 7834 IsResolver: true, 7835 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 7836 switch field.Name { 7837 case "int": 7838 return ec.fieldContext_Autobind_int(ctx, field) 7839 case "int32": 7840 return ec.fieldContext_Autobind_int32(ctx, field) 7841 case "int64": 7842 return ec.fieldContext_Autobind_int64(ctx, field) 7843 case "idStr": 7844 return ec.fieldContext_Autobind_idStr(ctx, field) 7845 case "idInt": 7846 return ec.fieldContext_Autobind_idInt(ctx, field) 7847 } 7848 return nil, fmt.Errorf("no field named %q was found under type Autobind", field.Name) 7849 }, 7850 } 7851 return fc, nil 7852 } 7853 7854 func (ec *executionContext) _Query_deprecatedField(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 7855 fc, err := ec.fieldContext_Query_deprecatedField(ctx, field) 7856 if err != nil { 7857 return graphql.Null 7858 } 7859 ctx = graphql.WithFieldContext(ctx, fc) 7860 defer func() { 7861 if r := recover(); r != nil { 7862 ec.Error(ctx, ec.Recover(ctx, r)) 7863 ret = graphql.Null 7864 } 7865 }() 7866 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 7867 ctx = rctx // use context from middleware stack in children 7868 return ec.resolvers.Query().DeprecatedField(rctx) 7869 }) 7870 7871 if resTmp == nil { 7872 if !graphql.HasFieldError(ctx, fc) { 7873 ec.Errorf(ctx, "must not be null") 7874 } 7875 return graphql.Null 7876 } 7877 res := resTmp.(string) 7878 fc.Result = res 7879 return ec.marshalNString2string(ctx, field.Selections, res) 7880 } 7881 7882 func (ec *executionContext) fieldContext_Query_deprecatedField(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 7883 fc = &graphql.FieldContext{ 7884 Object: "Query", 7885 Field: field, 7886 IsMethod: true, 7887 IsResolver: true, 7888 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 7889 return nil, errors.New("field of type String does not have child fields") 7890 }, 7891 } 7892 return fc, nil 7893 } 7894 7895 func (ec *executionContext) _Query_overlapping(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 7896 fc, err := ec.fieldContext_Query_overlapping(ctx, field) 7897 if err != nil { 7898 return graphql.Null 7899 } 7900 ctx = graphql.WithFieldContext(ctx, fc) 7901 defer func() { 7902 if r := recover(); r != nil { 7903 ec.Error(ctx, ec.Recover(ctx, r)) 7904 ret = graphql.Null 7905 } 7906 }() 7907 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 7908 ctx = rctx // use context from middleware stack in children 7909 return ec.resolvers.Query().Overlapping(rctx) 7910 }) 7911 7912 if resTmp == nil { 7913 return graphql.Null 7914 } 7915 res := resTmp.(*OverlappingFields) 7916 fc.Result = res 7917 return ec.marshalOOverlappingFields2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐOverlappingFields(ctx, field.Selections, res) 7918 } 7919 7920 func (ec *executionContext) fieldContext_Query_overlapping(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 7921 fc = &graphql.FieldContext{ 7922 Object: "Query", 7923 Field: field, 7924 IsMethod: true, 7925 IsResolver: true, 7926 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 7927 switch field.Name { 7928 case "oneFoo": 7929 return ec.fieldContext_OverlappingFields_oneFoo(ctx, field) 7930 case "twoFoo": 7931 return ec.fieldContext_OverlappingFields_twoFoo(ctx, field) 7932 case "oldFoo": 7933 return ec.fieldContext_OverlappingFields_oldFoo(ctx, field) 7934 case "newFoo": 7935 return ec.fieldContext_OverlappingFields_newFoo(ctx, field) 7936 case "new_foo": 7937 return ec.fieldContext_OverlappingFields_new_foo(ctx, field) 7938 } 7939 return nil, fmt.Errorf("no field named %q was found under type OverlappingFields", field.Name) 7940 }, 7941 } 7942 return fc, nil 7943 } 7944 7945 func (ec *executionContext) _Query_defaultParameters(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 7946 fc, err := ec.fieldContext_Query_defaultParameters(ctx, field) 7947 if err != nil { 7948 return graphql.Null 7949 } 7950 ctx = graphql.WithFieldContext(ctx, fc) 7951 defer func() { 7952 if r := recover(); r != nil { 7953 ec.Error(ctx, ec.Recover(ctx, r)) 7954 ret = graphql.Null 7955 } 7956 }() 7957 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 7958 ctx = rctx // use context from middleware stack in children 7959 return ec.resolvers.Query().DefaultParameters(rctx, fc.Args["falsyBoolean"].(*bool), fc.Args["truthyBoolean"].(*bool)) 7960 }) 7961 7962 if resTmp == nil { 7963 if !graphql.HasFieldError(ctx, fc) { 7964 ec.Errorf(ctx, "must not be null") 7965 } 7966 return graphql.Null 7967 } 7968 res := resTmp.(*DefaultParametersMirror) 7969 fc.Result = res 7970 return ec.marshalNDefaultParametersMirror2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐDefaultParametersMirror(ctx, field.Selections, res) 7971 } 7972 7973 func (ec *executionContext) fieldContext_Query_defaultParameters(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 7974 fc = &graphql.FieldContext{ 7975 Object: "Query", 7976 Field: field, 7977 IsMethod: true, 7978 IsResolver: true, 7979 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 7980 switch field.Name { 7981 case "falsyBoolean": 7982 return ec.fieldContext_DefaultParametersMirror_falsyBoolean(ctx, field) 7983 case "truthyBoolean": 7984 return ec.fieldContext_DefaultParametersMirror_truthyBoolean(ctx, field) 7985 } 7986 return nil, fmt.Errorf("no field named %q was found under type DefaultParametersMirror", field.Name) 7987 }, 7988 } 7989 defer func() { 7990 if r := recover(); r != nil { 7991 err = ec.Recover(ctx, r) 7992 ec.Error(ctx, err) 7993 } 7994 }() 7995 ctx = graphql.WithFieldContext(ctx, fc) 7996 if fc.Args, err = ec.field_Query_defaultParameters_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 7997 ec.Error(ctx, err) 7998 return 7999 } 8000 return fc, nil 8001 } 8002 8003 func (ec *executionContext) _Query_directiveArg(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 8004 fc, err := ec.fieldContext_Query_directiveArg(ctx, field) 8005 if err != nil { 8006 return graphql.Null 8007 } 8008 ctx = graphql.WithFieldContext(ctx, fc) 8009 defer func() { 8010 if r := recover(); r != nil { 8011 ec.Error(ctx, ec.Recover(ctx, r)) 8012 ret = graphql.Null 8013 } 8014 }() 8015 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 8016 ctx = rctx // use context from middleware stack in children 8017 return ec.resolvers.Query().DirectiveArg(rctx, fc.Args["arg"].(string)) 8018 }) 8019 8020 if resTmp == nil { 8021 return graphql.Null 8022 } 8023 res := resTmp.(*string) 8024 fc.Result = res 8025 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 8026 } 8027 8028 func (ec *executionContext) fieldContext_Query_directiveArg(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 8029 fc = &graphql.FieldContext{ 8030 Object: "Query", 8031 Field: field, 8032 IsMethod: true, 8033 IsResolver: true, 8034 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 8035 return nil, errors.New("field of type String does not have child fields") 8036 }, 8037 } 8038 defer func() { 8039 if r := recover(); r != nil { 8040 err = ec.Recover(ctx, r) 8041 ec.Error(ctx, err) 8042 } 8043 }() 8044 ctx = graphql.WithFieldContext(ctx, fc) 8045 if fc.Args, err = ec.field_Query_directiveArg_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 8046 ec.Error(ctx, err) 8047 return 8048 } 8049 return fc, nil 8050 } 8051 8052 func (ec *executionContext) _Query_directiveNullableArg(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 8053 fc, err := ec.fieldContext_Query_directiveNullableArg(ctx, field) 8054 if err != nil { 8055 return graphql.Null 8056 } 8057 ctx = graphql.WithFieldContext(ctx, fc) 8058 defer func() { 8059 if r := recover(); r != nil { 8060 ec.Error(ctx, ec.Recover(ctx, r)) 8061 ret = graphql.Null 8062 } 8063 }() 8064 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 8065 ctx = rctx // use context from middleware stack in children 8066 return ec.resolvers.Query().DirectiveNullableArg(rctx, fc.Args["arg"].(*int), fc.Args["arg2"].(*int), fc.Args["arg3"].(*string)) 8067 }) 8068 8069 if resTmp == nil { 8070 return graphql.Null 8071 } 8072 res := resTmp.(*string) 8073 fc.Result = res 8074 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 8075 } 8076 8077 func (ec *executionContext) fieldContext_Query_directiveNullableArg(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 8078 fc = &graphql.FieldContext{ 8079 Object: "Query", 8080 Field: field, 8081 IsMethod: true, 8082 IsResolver: true, 8083 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 8084 return nil, errors.New("field of type String does not have child fields") 8085 }, 8086 } 8087 defer func() { 8088 if r := recover(); r != nil { 8089 err = ec.Recover(ctx, r) 8090 ec.Error(ctx, err) 8091 } 8092 }() 8093 ctx = graphql.WithFieldContext(ctx, fc) 8094 if fc.Args, err = ec.field_Query_directiveNullableArg_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 8095 ec.Error(ctx, err) 8096 return 8097 } 8098 return fc, nil 8099 } 8100 8101 func (ec *executionContext) _Query_directiveInputNullable(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 8102 fc, err := ec.fieldContext_Query_directiveInputNullable(ctx, field) 8103 if err != nil { 8104 return graphql.Null 8105 } 8106 ctx = graphql.WithFieldContext(ctx, fc) 8107 defer func() { 8108 if r := recover(); r != nil { 8109 ec.Error(ctx, ec.Recover(ctx, r)) 8110 ret = graphql.Null 8111 } 8112 }() 8113 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 8114 ctx = rctx // use context from middleware stack in children 8115 return ec.resolvers.Query().DirectiveInputNullable(rctx, fc.Args["arg"].(*InputDirectives)) 8116 }) 8117 8118 if resTmp == nil { 8119 return graphql.Null 8120 } 8121 res := resTmp.(*string) 8122 fc.Result = res 8123 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 8124 } 8125 8126 func (ec *executionContext) fieldContext_Query_directiveInputNullable(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 8127 fc = &graphql.FieldContext{ 8128 Object: "Query", 8129 Field: field, 8130 IsMethod: true, 8131 IsResolver: true, 8132 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 8133 return nil, errors.New("field of type String does not have child fields") 8134 }, 8135 } 8136 defer func() { 8137 if r := recover(); r != nil { 8138 err = ec.Recover(ctx, r) 8139 ec.Error(ctx, err) 8140 } 8141 }() 8142 ctx = graphql.WithFieldContext(ctx, fc) 8143 if fc.Args, err = ec.field_Query_directiveInputNullable_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 8144 ec.Error(ctx, err) 8145 return 8146 } 8147 return fc, nil 8148 } 8149 8150 func (ec *executionContext) _Query_directiveInput(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 8151 fc, err := ec.fieldContext_Query_directiveInput(ctx, field) 8152 if err != nil { 8153 return graphql.Null 8154 } 8155 ctx = graphql.WithFieldContext(ctx, fc) 8156 defer func() { 8157 if r := recover(); r != nil { 8158 ec.Error(ctx, ec.Recover(ctx, r)) 8159 ret = graphql.Null 8160 } 8161 }() 8162 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 8163 ctx = rctx // use context from middleware stack in children 8164 return ec.resolvers.Query().DirectiveInput(rctx, fc.Args["arg"].(InputDirectives)) 8165 }) 8166 8167 if resTmp == nil { 8168 return graphql.Null 8169 } 8170 res := resTmp.(*string) 8171 fc.Result = res 8172 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 8173 } 8174 8175 func (ec *executionContext) fieldContext_Query_directiveInput(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 8176 fc = &graphql.FieldContext{ 8177 Object: "Query", 8178 Field: field, 8179 IsMethod: true, 8180 IsResolver: true, 8181 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 8182 return nil, errors.New("field of type String does not have child fields") 8183 }, 8184 } 8185 defer func() { 8186 if r := recover(); r != nil { 8187 err = ec.Recover(ctx, r) 8188 ec.Error(ctx, err) 8189 } 8190 }() 8191 ctx = graphql.WithFieldContext(ctx, fc) 8192 if fc.Args, err = ec.field_Query_directiveInput_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 8193 ec.Error(ctx, err) 8194 return 8195 } 8196 return fc, nil 8197 } 8198 8199 func (ec *executionContext) _Query_directiveInputType(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 8200 fc, err := ec.fieldContext_Query_directiveInputType(ctx, field) 8201 if err != nil { 8202 return graphql.Null 8203 } 8204 ctx = graphql.WithFieldContext(ctx, fc) 8205 defer func() { 8206 if r := recover(); r != nil { 8207 ec.Error(ctx, ec.Recover(ctx, r)) 8208 ret = graphql.Null 8209 } 8210 }() 8211 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 8212 ctx = rctx // use context from middleware stack in children 8213 return ec.resolvers.Query().DirectiveInputType(rctx, fc.Args["arg"].(InnerInput)) 8214 }) 8215 8216 if resTmp == nil { 8217 return graphql.Null 8218 } 8219 res := resTmp.(*string) 8220 fc.Result = res 8221 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 8222 } 8223 8224 func (ec *executionContext) fieldContext_Query_directiveInputType(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 8225 fc = &graphql.FieldContext{ 8226 Object: "Query", 8227 Field: field, 8228 IsMethod: true, 8229 IsResolver: true, 8230 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 8231 return nil, errors.New("field of type String does not have child fields") 8232 }, 8233 } 8234 defer func() { 8235 if r := recover(); r != nil { 8236 err = ec.Recover(ctx, r) 8237 ec.Error(ctx, err) 8238 } 8239 }() 8240 ctx = graphql.WithFieldContext(ctx, fc) 8241 if fc.Args, err = ec.field_Query_directiveInputType_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 8242 ec.Error(ctx, err) 8243 return 8244 } 8245 return fc, nil 8246 } 8247 8248 func (ec *executionContext) _Query_directiveObject(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 8249 fc, err := ec.fieldContext_Query_directiveObject(ctx, field) 8250 if err != nil { 8251 return graphql.Null 8252 } 8253 ctx = graphql.WithFieldContext(ctx, fc) 8254 defer func() { 8255 if r := recover(); r != nil { 8256 ec.Error(ctx, ec.Recover(ctx, r)) 8257 ret = graphql.Null 8258 } 8259 }() 8260 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 8261 directive0 := func(rctx context.Context) (interface{}, error) { 8262 ctx = rctx // use context from middleware stack in children 8263 return ec.resolvers.Query().DirectiveObject(rctx) 8264 } 8265 directive1 := func(ctx context.Context) (interface{}, error) { 8266 location, err := ec.unmarshalNString2string(ctx, "order1_1") 8267 if err != nil { 8268 return nil, err 8269 } 8270 if ec.directives.Order1 == nil { 8271 return nil, errors.New("directive order1 is not implemented") 8272 } 8273 return ec.directives.Order1(ctx, nil, directive0, location) 8274 } 8275 directive2 := func(ctx context.Context) (interface{}, error) { 8276 location, err := ec.unmarshalNString2string(ctx, "order1_2") 8277 if err != nil { 8278 return nil, err 8279 } 8280 if ec.directives.Order1 == nil { 8281 return nil, errors.New("directive order1 is not implemented") 8282 } 8283 return ec.directives.Order1(ctx, nil, directive1, location) 8284 } 8285 directive3 := func(ctx context.Context) (interface{}, error) { 8286 location, err := ec.unmarshalNString2string(ctx, "order2_1") 8287 if err != nil { 8288 return nil, err 8289 } 8290 if ec.directives.Order2 == nil { 8291 return nil, errors.New("directive order2 is not implemented") 8292 } 8293 return ec.directives.Order2(ctx, nil, directive2, location) 8294 } 8295 directive4 := func(ctx context.Context) (interface{}, error) { 8296 location, err := ec.unmarshalNString2string(ctx, "Query_field") 8297 if err != nil { 8298 return nil, err 8299 } 8300 if ec.directives.Order1 == nil { 8301 return nil, errors.New("directive order1 is not implemented") 8302 } 8303 return ec.directives.Order1(ctx, nil, directive3, location) 8304 } 8305 8306 tmp, err := directive4(rctx) 8307 if err != nil { 8308 return nil, graphql.ErrorOnPath(ctx, err) 8309 } 8310 if tmp == nil { 8311 return nil, nil 8312 } 8313 if data, ok := tmp.(*ObjectDirectives); ok { 8314 return data, nil 8315 } 8316 return nil, fmt.Errorf(`unexpected type %T from directive, should be *github.com/luciferinlove/gqlgen/codegen/testserver/singlefile.ObjectDirectives`, tmp) 8317 }) 8318 8319 if resTmp == nil { 8320 return graphql.Null 8321 } 8322 res := resTmp.(*ObjectDirectives) 8323 fc.Result = res 8324 return ec.marshalOObjectDirectives2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐObjectDirectives(ctx, field.Selections, res) 8325 } 8326 8327 func (ec *executionContext) fieldContext_Query_directiveObject(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 8328 fc = &graphql.FieldContext{ 8329 Object: "Query", 8330 Field: field, 8331 IsMethod: true, 8332 IsResolver: true, 8333 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 8334 switch field.Name { 8335 case "text": 8336 return ec.fieldContext_ObjectDirectives_text(ctx, field) 8337 case "nullableText": 8338 return ec.fieldContext_ObjectDirectives_nullableText(ctx, field) 8339 case "order": 8340 return ec.fieldContext_ObjectDirectives_order(ctx, field) 8341 } 8342 return nil, fmt.Errorf("no field named %q was found under type ObjectDirectives", field.Name) 8343 }, 8344 } 8345 return fc, nil 8346 } 8347 8348 func (ec *executionContext) _Query_directiveObjectWithCustomGoModel(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 8349 fc, err := ec.fieldContext_Query_directiveObjectWithCustomGoModel(ctx, field) 8350 if err != nil { 8351 return graphql.Null 8352 } 8353 ctx = graphql.WithFieldContext(ctx, fc) 8354 defer func() { 8355 if r := recover(); r != nil { 8356 ec.Error(ctx, ec.Recover(ctx, r)) 8357 ret = graphql.Null 8358 } 8359 }() 8360 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 8361 ctx = rctx // use context from middleware stack in children 8362 return ec.resolvers.Query().DirectiveObjectWithCustomGoModel(rctx) 8363 }) 8364 8365 if resTmp == nil { 8366 return graphql.Null 8367 } 8368 res := resTmp.(*ObjectDirectivesWithCustomGoModel) 8369 fc.Result = res 8370 return ec.marshalOObjectDirectivesWithCustomGoModel2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐObjectDirectivesWithCustomGoModel(ctx, field.Selections, res) 8371 } 8372 8373 func (ec *executionContext) fieldContext_Query_directiveObjectWithCustomGoModel(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 8374 fc = &graphql.FieldContext{ 8375 Object: "Query", 8376 Field: field, 8377 IsMethod: true, 8378 IsResolver: true, 8379 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 8380 switch field.Name { 8381 case "nullableText": 8382 return ec.fieldContext_ObjectDirectivesWithCustomGoModel_nullableText(ctx, field) 8383 } 8384 return nil, fmt.Errorf("no field named %q was found under type ObjectDirectivesWithCustomGoModel", field.Name) 8385 }, 8386 } 8387 return fc, nil 8388 } 8389 8390 func (ec *executionContext) _Query_directiveFieldDef(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 8391 fc, err := ec.fieldContext_Query_directiveFieldDef(ctx, field) 8392 if err != nil { 8393 return graphql.Null 8394 } 8395 ctx = graphql.WithFieldContext(ctx, fc) 8396 defer func() { 8397 if r := recover(); r != nil { 8398 ec.Error(ctx, ec.Recover(ctx, r)) 8399 ret = graphql.Null 8400 } 8401 }() 8402 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 8403 directive0 := func(rctx context.Context) (interface{}, error) { 8404 ctx = rctx // use context from middleware stack in children 8405 return ec.resolvers.Query().DirectiveFieldDef(rctx, fc.Args["ret"].(string)) 8406 } 8407 directive1 := func(ctx context.Context) (interface{}, error) { 8408 min, err := ec.unmarshalNInt2int(ctx, 1) 8409 if err != nil { 8410 return nil, err 8411 } 8412 message, err := ec.unmarshalOString2ᚖstring(ctx, "not valid") 8413 if err != nil { 8414 return nil, err 8415 } 8416 if ec.directives.Length == nil { 8417 return nil, errors.New("directive length is not implemented") 8418 } 8419 return ec.directives.Length(ctx, nil, directive0, min, nil, message) 8420 } 8421 8422 tmp, err := directive1(rctx) 8423 if err != nil { 8424 return nil, graphql.ErrorOnPath(ctx, err) 8425 } 8426 if tmp == nil { 8427 return nil, nil 8428 } 8429 if data, ok := tmp.(string); ok { 8430 return data, nil 8431 } 8432 return nil, fmt.Errorf(`unexpected type %T from directive, should be string`, tmp) 8433 }) 8434 8435 if resTmp == nil { 8436 if !graphql.HasFieldError(ctx, fc) { 8437 ec.Errorf(ctx, "must not be null") 8438 } 8439 return graphql.Null 8440 } 8441 res := resTmp.(string) 8442 fc.Result = res 8443 return ec.marshalNString2string(ctx, field.Selections, res) 8444 } 8445 8446 func (ec *executionContext) fieldContext_Query_directiveFieldDef(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 8447 fc = &graphql.FieldContext{ 8448 Object: "Query", 8449 Field: field, 8450 IsMethod: true, 8451 IsResolver: true, 8452 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 8453 return nil, errors.New("field of type String does not have child fields") 8454 }, 8455 } 8456 defer func() { 8457 if r := recover(); r != nil { 8458 err = ec.Recover(ctx, r) 8459 ec.Error(ctx, err) 8460 } 8461 }() 8462 ctx = graphql.WithFieldContext(ctx, fc) 8463 if fc.Args, err = ec.field_Query_directiveFieldDef_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 8464 ec.Error(ctx, err) 8465 return 8466 } 8467 return fc, nil 8468 } 8469 8470 func (ec *executionContext) _Query_directiveField(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 8471 fc, err := ec.fieldContext_Query_directiveField(ctx, field) 8472 if err != nil { 8473 return graphql.Null 8474 } 8475 ctx = graphql.WithFieldContext(ctx, fc) 8476 defer func() { 8477 if r := recover(); r != nil { 8478 ec.Error(ctx, ec.Recover(ctx, r)) 8479 ret = graphql.Null 8480 } 8481 }() 8482 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 8483 ctx = rctx // use context from middleware stack in children 8484 return ec.resolvers.Query().DirectiveField(rctx) 8485 }) 8486 8487 if resTmp == nil { 8488 return graphql.Null 8489 } 8490 res := resTmp.(*string) 8491 fc.Result = res 8492 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 8493 } 8494 8495 func (ec *executionContext) fieldContext_Query_directiveField(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 8496 fc = &graphql.FieldContext{ 8497 Object: "Query", 8498 Field: field, 8499 IsMethod: true, 8500 IsResolver: true, 8501 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 8502 return nil, errors.New("field of type String does not have child fields") 8503 }, 8504 } 8505 return fc, nil 8506 } 8507 8508 func (ec *executionContext) _Query_directiveDouble(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 8509 fc, err := ec.fieldContext_Query_directiveDouble(ctx, field) 8510 if err != nil { 8511 return graphql.Null 8512 } 8513 ctx = graphql.WithFieldContext(ctx, fc) 8514 defer func() { 8515 if r := recover(); r != nil { 8516 ec.Error(ctx, ec.Recover(ctx, r)) 8517 ret = graphql.Null 8518 } 8519 }() 8520 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 8521 directive0 := func(rctx context.Context) (interface{}, error) { 8522 ctx = rctx // use context from middleware stack in children 8523 return ec.resolvers.Query().DirectiveDouble(rctx) 8524 } 8525 directive1 := func(ctx context.Context) (interface{}, error) { 8526 if ec.directives.Directive1 == nil { 8527 return nil, errors.New("directive directive1 is not implemented") 8528 } 8529 return ec.directives.Directive1(ctx, nil, directive0) 8530 } 8531 directive2 := func(ctx context.Context) (interface{}, error) { 8532 if ec.directives.Directive2 == nil { 8533 return nil, errors.New("directive directive2 is not implemented") 8534 } 8535 return ec.directives.Directive2(ctx, nil, directive1) 8536 } 8537 8538 tmp, err := directive2(rctx) 8539 if err != nil { 8540 return nil, graphql.ErrorOnPath(ctx, err) 8541 } 8542 if tmp == nil { 8543 return nil, nil 8544 } 8545 if data, ok := tmp.(*string); ok { 8546 return data, nil 8547 } 8548 return nil, fmt.Errorf(`unexpected type %T from directive, should be *string`, tmp) 8549 }) 8550 8551 if resTmp == nil { 8552 return graphql.Null 8553 } 8554 res := resTmp.(*string) 8555 fc.Result = res 8556 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 8557 } 8558 8559 func (ec *executionContext) fieldContext_Query_directiveDouble(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 8560 fc = &graphql.FieldContext{ 8561 Object: "Query", 8562 Field: field, 8563 IsMethod: true, 8564 IsResolver: true, 8565 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 8566 return nil, errors.New("field of type String does not have child fields") 8567 }, 8568 } 8569 return fc, nil 8570 } 8571 8572 func (ec *executionContext) _Query_directiveUnimplemented(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 8573 fc, err := ec.fieldContext_Query_directiveUnimplemented(ctx, field) 8574 if err != nil { 8575 return graphql.Null 8576 } 8577 ctx = graphql.WithFieldContext(ctx, fc) 8578 defer func() { 8579 if r := recover(); r != nil { 8580 ec.Error(ctx, ec.Recover(ctx, r)) 8581 ret = graphql.Null 8582 } 8583 }() 8584 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 8585 directive0 := func(rctx context.Context) (interface{}, error) { 8586 ctx = rctx // use context from middleware stack in children 8587 return ec.resolvers.Query().DirectiveUnimplemented(rctx) 8588 } 8589 directive1 := func(ctx context.Context) (interface{}, error) { 8590 if ec.directives.Unimplemented == nil { 8591 return nil, errors.New("directive unimplemented is not implemented") 8592 } 8593 return ec.directives.Unimplemented(ctx, nil, directive0) 8594 } 8595 8596 tmp, err := directive1(rctx) 8597 if err != nil { 8598 return nil, graphql.ErrorOnPath(ctx, err) 8599 } 8600 if tmp == nil { 8601 return nil, nil 8602 } 8603 if data, ok := tmp.(*string); ok { 8604 return data, nil 8605 } 8606 return nil, fmt.Errorf(`unexpected type %T from directive, should be *string`, tmp) 8607 }) 8608 8609 if resTmp == nil { 8610 return graphql.Null 8611 } 8612 res := resTmp.(*string) 8613 fc.Result = res 8614 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 8615 } 8616 8617 func (ec *executionContext) fieldContext_Query_directiveUnimplemented(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 8618 fc = &graphql.FieldContext{ 8619 Object: "Query", 8620 Field: field, 8621 IsMethod: true, 8622 IsResolver: true, 8623 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 8624 return nil, errors.New("field of type String does not have child fields") 8625 }, 8626 } 8627 return fc, nil 8628 } 8629 8630 func (ec *executionContext) _Query_embeddedCase1(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 8631 fc, err := ec.fieldContext_Query_embeddedCase1(ctx, field) 8632 if err != nil { 8633 return graphql.Null 8634 } 8635 ctx = graphql.WithFieldContext(ctx, fc) 8636 defer func() { 8637 if r := recover(); r != nil { 8638 ec.Error(ctx, ec.Recover(ctx, r)) 8639 ret = graphql.Null 8640 } 8641 }() 8642 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 8643 ctx = rctx // use context from middleware stack in children 8644 return ec.resolvers.Query().EmbeddedCase1(rctx) 8645 }) 8646 8647 if resTmp == nil { 8648 return graphql.Null 8649 } 8650 res := resTmp.(*EmbeddedCase1) 8651 fc.Result = res 8652 return ec.marshalOEmbeddedCase12ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐEmbeddedCase1(ctx, field.Selections, res) 8653 } 8654 8655 func (ec *executionContext) fieldContext_Query_embeddedCase1(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 8656 fc = &graphql.FieldContext{ 8657 Object: "Query", 8658 Field: field, 8659 IsMethod: true, 8660 IsResolver: true, 8661 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 8662 switch field.Name { 8663 case "exportedEmbeddedPointerExportedMethod": 8664 return ec.fieldContext_EmbeddedCase1_exportedEmbeddedPointerExportedMethod(ctx, field) 8665 } 8666 return nil, fmt.Errorf("no field named %q was found under type EmbeddedCase1", field.Name) 8667 }, 8668 } 8669 return fc, nil 8670 } 8671 8672 func (ec *executionContext) _Query_embeddedCase2(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 8673 fc, err := ec.fieldContext_Query_embeddedCase2(ctx, field) 8674 if err != nil { 8675 return graphql.Null 8676 } 8677 ctx = graphql.WithFieldContext(ctx, fc) 8678 defer func() { 8679 if r := recover(); r != nil { 8680 ec.Error(ctx, ec.Recover(ctx, r)) 8681 ret = graphql.Null 8682 } 8683 }() 8684 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 8685 ctx = rctx // use context from middleware stack in children 8686 return ec.resolvers.Query().EmbeddedCase2(rctx) 8687 }) 8688 8689 if resTmp == nil { 8690 return graphql.Null 8691 } 8692 res := resTmp.(*EmbeddedCase2) 8693 fc.Result = res 8694 return ec.marshalOEmbeddedCase22ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐEmbeddedCase2(ctx, field.Selections, res) 8695 } 8696 8697 func (ec *executionContext) fieldContext_Query_embeddedCase2(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 8698 fc = &graphql.FieldContext{ 8699 Object: "Query", 8700 Field: field, 8701 IsMethod: true, 8702 IsResolver: true, 8703 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 8704 switch field.Name { 8705 case "unexportedEmbeddedPointerExportedMethod": 8706 return ec.fieldContext_EmbeddedCase2_unexportedEmbeddedPointerExportedMethod(ctx, field) 8707 } 8708 return nil, fmt.Errorf("no field named %q was found under type EmbeddedCase2", field.Name) 8709 }, 8710 } 8711 return fc, nil 8712 } 8713 8714 func (ec *executionContext) _Query_embeddedCase3(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 8715 fc, err := ec.fieldContext_Query_embeddedCase3(ctx, field) 8716 if err != nil { 8717 return graphql.Null 8718 } 8719 ctx = graphql.WithFieldContext(ctx, fc) 8720 defer func() { 8721 if r := recover(); r != nil { 8722 ec.Error(ctx, ec.Recover(ctx, r)) 8723 ret = graphql.Null 8724 } 8725 }() 8726 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 8727 ctx = rctx // use context from middleware stack in children 8728 return ec.resolvers.Query().EmbeddedCase3(rctx) 8729 }) 8730 8731 if resTmp == nil { 8732 return graphql.Null 8733 } 8734 res := resTmp.(*EmbeddedCase3) 8735 fc.Result = res 8736 return ec.marshalOEmbeddedCase32ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐEmbeddedCase3(ctx, field.Selections, res) 8737 } 8738 8739 func (ec *executionContext) fieldContext_Query_embeddedCase3(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 8740 fc = &graphql.FieldContext{ 8741 Object: "Query", 8742 Field: field, 8743 IsMethod: true, 8744 IsResolver: true, 8745 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 8746 switch field.Name { 8747 case "unexportedEmbeddedInterfaceExportedMethod": 8748 return ec.fieldContext_EmbeddedCase3_unexportedEmbeddedInterfaceExportedMethod(ctx, field) 8749 } 8750 return nil, fmt.Errorf("no field named %q was found under type EmbeddedCase3", field.Name) 8751 }, 8752 } 8753 return fc, nil 8754 } 8755 8756 func (ec *executionContext) _Query_enumInInput(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 8757 fc, err := ec.fieldContext_Query_enumInInput(ctx, field) 8758 if err != nil { 8759 return graphql.Null 8760 } 8761 ctx = graphql.WithFieldContext(ctx, fc) 8762 defer func() { 8763 if r := recover(); r != nil { 8764 ec.Error(ctx, ec.Recover(ctx, r)) 8765 ret = graphql.Null 8766 } 8767 }() 8768 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 8769 ctx = rctx // use context from middleware stack in children 8770 return ec.resolvers.Query().EnumInInput(rctx, fc.Args["input"].(*InputWithEnumValue)) 8771 }) 8772 8773 if resTmp == nil { 8774 if !graphql.HasFieldError(ctx, fc) { 8775 ec.Errorf(ctx, "must not be null") 8776 } 8777 return graphql.Null 8778 } 8779 res := resTmp.(EnumTest) 8780 fc.Result = res 8781 return ec.marshalNEnumTest2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐEnumTest(ctx, field.Selections, res) 8782 } 8783 8784 func (ec *executionContext) fieldContext_Query_enumInInput(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 8785 fc = &graphql.FieldContext{ 8786 Object: "Query", 8787 Field: field, 8788 IsMethod: true, 8789 IsResolver: true, 8790 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 8791 return nil, errors.New("field of type EnumTest does not have child fields") 8792 }, 8793 } 8794 defer func() { 8795 if r := recover(); r != nil { 8796 err = ec.Recover(ctx, r) 8797 ec.Error(ctx, err) 8798 } 8799 }() 8800 ctx = graphql.WithFieldContext(ctx, fc) 8801 if fc.Args, err = ec.field_Query_enumInInput_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 8802 ec.Error(ctx, err) 8803 return 8804 } 8805 return fc, nil 8806 } 8807 8808 func (ec *executionContext) _Query_shapes(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 8809 fc, err := ec.fieldContext_Query_shapes(ctx, field) 8810 if err != nil { 8811 return graphql.Null 8812 } 8813 ctx = graphql.WithFieldContext(ctx, fc) 8814 defer func() { 8815 if r := recover(); r != nil { 8816 ec.Error(ctx, ec.Recover(ctx, r)) 8817 ret = graphql.Null 8818 } 8819 }() 8820 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 8821 ctx = rctx // use context from middleware stack in children 8822 return ec.resolvers.Query().Shapes(rctx) 8823 }) 8824 8825 if resTmp == nil { 8826 return graphql.Null 8827 } 8828 res := resTmp.([]Shape) 8829 fc.Result = res 8830 return ec.marshalOShape2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐShape(ctx, field.Selections, res) 8831 } 8832 8833 func (ec *executionContext) fieldContext_Query_shapes(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 8834 fc = &graphql.FieldContext{ 8835 Object: "Query", 8836 Field: field, 8837 IsMethod: true, 8838 IsResolver: true, 8839 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 8840 return nil, errors.New("FieldContext.Child cannot be called on type INTERFACE") 8841 }, 8842 } 8843 return fc, nil 8844 } 8845 8846 func (ec *executionContext) _Query_noShape(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 8847 fc, err := ec.fieldContext_Query_noShape(ctx, field) 8848 if err != nil { 8849 return graphql.Null 8850 } 8851 ctx = graphql.WithFieldContext(ctx, fc) 8852 defer func() { 8853 if r := recover(); r != nil { 8854 ec.Error(ctx, ec.Recover(ctx, r)) 8855 ret = graphql.Null 8856 } 8857 }() 8858 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 8859 directive0 := func(rctx context.Context) (interface{}, error) { 8860 ctx = rctx // use context from middleware stack in children 8861 return ec.resolvers.Query().NoShape(rctx) 8862 } 8863 directive1 := func(ctx context.Context) (interface{}, error) { 8864 if ec.directives.MakeNil == nil { 8865 return nil, errors.New("directive makeNil is not implemented") 8866 } 8867 return ec.directives.MakeNil(ctx, nil, directive0) 8868 } 8869 8870 tmp, err := directive1(rctx) 8871 if err != nil { 8872 return nil, graphql.ErrorOnPath(ctx, err) 8873 } 8874 if tmp == nil { 8875 return nil, nil 8876 } 8877 if data, ok := tmp.(Shape); ok { 8878 return data, nil 8879 } 8880 return nil, fmt.Errorf(`unexpected type %T from directive, should be github.com/luciferinlove/gqlgen/codegen/testserver/singlefile.Shape`, tmp) 8881 }) 8882 8883 if resTmp == nil { 8884 return graphql.Null 8885 } 8886 res := resTmp.(Shape) 8887 fc.Result = res 8888 return ec.marshalOShape2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐShape(ctx, field.Selections, res) 8889 } 8890 8891 func (ec *executionContext) fieldContext_Query_noShape(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 8892 fc = &graphql.FieldContext{ 8893 Object: "Query", 8894 Field: field, 8895 IsMethod: true, 8896 IsResolver: true, 8897 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 8898 return nil, errors.New("FieldContext.Child cannot be called on type INTERFACE") 8899 }, 8900 } 8901 return fc, nil 8902 } 8903 8904 func (ec *executionContext) _Query_node(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 8905 fc, err := ec.fieldContext_Query_node(ctx, field) 8906 if err != nil { 8907 return graphql.Null 8908 } 8909 ctx = graphql.WithFieldContext(ctx, fc) 8910 defer func() { 8911 if r := recover(); r != nil { 8912 ec.Error(ctx, ec.Recover(ctx, r)) 8913 ret = graphql.Null 8914 } 8915 }() 8916 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 8917 ctx = rctx // use context from middleware stack in children 8918 return ec.resolvers.Query().Node(rctx) 8919 }) 8920 8921 if resTmp == nil { 8922 if !graphql.HasFieldError(ctx, fc) { 8923 ec.Errorf(ctx, "must not be null") 8924 } 8925 return graphql.Null 8926 } 8927 res := resTmp.(Node) 8928 fc.Result = res 8929 return ec.marshalNNode2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐNode(ctx, field.Selections, res) 8930 } 8931 8932 func (ec *executionContext) fieldContext_Query_node(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 8933 fc = &graphql.FieldContext{ 8934 Object: "Query", 8935 Field: field, 8936 IsMethod: true, 8937 IsResolver: true, 8938 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 8939 return nil, errors.New("FieldContext.Child cannot be called on type INTERFACE") 8940 }, 8941 } 8942 return fc, nil 8943 } 8944 8945 func (ec *executionContext) _Query_noShapeTypedNil(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 8946 fc, err := ec.fieldContext_Query_noShapeTypedNil(ctx, field) 8947 if err != nil { 8948 return graphql.Null 8949 } 8950 ctx = graphql.WithFieldContext(ctx, fc) 8951 defer func() { 8952 if r := recover(); r != nil { 8953 ec.Error(ctx, ec.Recover(ctx, r)) 8954 ret = graphql.Null 8955 } 8956 }() 8957 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 8958 directive0 := func(rctx context.Context) (interface{}, error) { 8959 ctx = rctx // use context from middleware stack in children 8960 return ec.resolvers.Query().NoShapeTypedNil(rctx) 8961 } 8962 directive1 := func(ctx context.Context) (interface{}, error) { 8963 if ec.directives.MakeTypedNil == nil { 8964 return nil, errors.New("directive makeTypedNil is not implemented") 8965 } 8966 return ec.directives.MakeTypedNil(ctx, nil, directive0) 8967 } 8968 8969 tmp, err := directive1(rctx) 8970 if err != nil { 8971 return nil, graphql.ErrorOnPath(ctx, err) 8972 } 8973 if tmp == nil { 8974 return nil, nil 8975 } 8976 if data, ok := tmp.(Shape); ok { 8977 return data, nil 8978 } 8979 return nil, fmt.Errorf(`unexpected type %T from directive, should be github.com/luciferinlove/gqlgen/codegen/testserver/singlefile.Shape`, tmp) 8980 }) 8981 8982 if resTmp == nil { 8983 return graphql.Null 8984 } 8985 res := resTmp.(Shape) 8986 fc.Result = res 8987 return ec.marshalOShape2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐShape(ctx, field.Selections, res) 8988 } 8989 8990 func (ec *executionContext) fieldContext_Query_noShapeTypedNil(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 8991 fc = &graphql.FieldContext{ 8992 Object: "Query", 8993 Field: field, 8994 IsMethod: true, 8995 IsResolver: true, 8996 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 8997 return nil, errors.New("FieldContext.Child cannot be called on type INTERFACE") 8998 }, 8999 } 9000 return fc, nil 9001 } 9002 9003 func (ec *executionContext) _Query_animal(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 9004 fc, err := ec.fieldContext_Query_animal(ctx, field) 9005 if err != nil { 9006 return graphql.Null 9007 } 9008 ctx = graphql.WithFieldContext(ctx, fc) 9009 defer func() { 9010 if r := recover(); r != nil { 9011 ec.Error(ctx, ec.Recover(ctx, r)) 9012 ret = graphql.Null 9013 } 9014 }() 9015 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 9016 directive0 := func(rctx context.Context) (interface{}, error) { 9017 ctx = rctx // use context from middleware stack in children 9018 return ec.resolvers.Query().Animal(rctx) 9019 } 9020 directive1 := func(ctx context.Context) (interface{}, error) { 9021 if ec.directives.MakeTypedNil == nil { 9022 return nil, errors.New("directive makeTypedNil is not implemented") 9023 } 9024 return ec.directives.MakeTypedNil(ctx, nil, directive0) 9025 } 9026 9027 tmp, err := directive1(rctx) 9028 if err != nil { 9029 return nil, graphql.ErrorOnPath(ctx, err) 9030 } 9031 if tmp == nil { 9032 return nil, nil 9033 } 9034 if data, ok := tmp.(Animal); ok { 9035 return data, nil 9036 } 9037 return nil, fmt.Errorf(`unexpected type %T from directive, should be github.com/luciferinlove/gqlgen/codegen/testserver/singlefile.Animal`, tmp) 9038 }) 9039 9040 if resTmp == nil { 9041 return graphql.Null 9042 } 9043 res := resTmp.(Animal) 9044 fc.Result = res 9045 return ec.marshalOAnimal2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐAnimal(ctx, field.Selections, res) 9046 } 9047 9048 func (ec *executionContext) fieldContext_Query_animal(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 9049 fc = &graphql.FieldContext{ 9050 Object: "Query", 9051 Field: field, 9052 IsMethod: true, 9053 IsResolver: true, 9054 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 9055 return nil, errors.New("FieldContext.Child cannot be called on type INTERFACE") 9056 }, 9057 } 9058 return fc, nil 9059 } 9060 9061 func (ec *executionContext) _Query_notAnInterface(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 9062 fc, err := ec.fieldContext_Query_notAnInterface(ctx, field) 9063 if err != nil { 9064 return graphql.Null 9065 } 9066 ctx = graphql.WithFieldContext(ctx, fc) 9067 defer func() { 9068 if r := recover(); r != nil { 9069 ec.Error(ctx, ec.Recover(ctx, r)) 9070 ret = graphql.Null 9071 } 9072 }() 9073 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 9074 ctx = rctx // use context from middleware stack in children 9075 return ec.resolvers.Query().NotAnInterface(rctx) 9076 }) 9077 9078 if resTmp == nil { 9079 return graphql.Null 9080 } 9081 res := resTmp.(BackedByInterface) 9082 fc.Result = res 9083 return ec.marshalOBackedByInterface2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐBackedByInterface(ctx, field.Selections, res) 9084 } 9085 9086 func (ec *executionContext) fieldContext_Query_notAnInterface(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 9087 fc = &graphql.FieldContext{ 9088 Object: "Query", 9089 Field: field, 9090 IsMethod: true, 9091 IsResolver: true, 9092 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 9093 switch field.Name { 9094 case "id": 9095 return ec.fieldContext_BackedByInterface_id(ctx, field) 9096 case "thisShouldBind": 9097 return ec.fieldContext_BackedByInterface_thisShouldBind(ctx, field) 9098 case "thisShouldBindWithError": 9099 return ec.fieldContext_BackedByInterface_thisShouldBindWithError(ctx, field) 9100 } 9101 return nil, fmt.Errorf("no field named %q was found under type BackedByInterface", field.Name) 9102 }, 9103 } 9104 return fc, nil 9105 } 9106 9107 func (ec *executionContext) _Query_issue896a(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 9108 fc, err := ec.fieldContext_Query_issue896a(ctx, field) 9109 if err != nil { 9110 return graphql.Null 9111 } 9112 ctx = graphql.WithFieldContext(ctx, fc) 9113 defer func() { 9114 if r := recover(); r != nil { 9115 ec.Error(ctx, ec.Recover(ctx, r)) 9116 ret = graphql.Null 9117 } 9118 }() 9119 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 9120 ctx = rctx // use context from middleware stack in children 9121 return ec.resolvers.Query().Issue896a(rctx) 9122 }) 9123 9124 if resTmp == nil { 9125 return graphql.Null 9126 } 9127 res := resTmp.([]*CheckIssue896) 9128 fc.Result = res 9129 return ec.marshalOCheckIssue8962ᚕᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐCheckIssue896ᚄ(ctx, field.Selections, res) 9130 } 9131 9132 func (ec *executionContext) fieldContext_Query_issue896a(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 9133 fc = &graphql.FieldContext{ 9134 Object: "Query", 9135 Field: field, 9136 IsMethod: true, 9137 IsResolver: true, 9138 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 9139 switch field.Name { 9140 case "id": 9141 return ec.fieldContext_CheckIssue896_id(ctx, field) 9142 } 9143 return nil, fmt.Errorf("no field named %q was found under type CheckIssue896", field.Name) 9144 }, 9145 } 9146 return fc, nil 9147 } 9148 9149 func (ec *executionContext) _Query_mapStringInterface(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 9150 fc, err := ec.fieldContext_Query_mapStringInterface(ctx, field) 9151 if err != nil { 9152 return graphql.Null 9153 } 9154 ctx = graphql.WithFieldContext(ctx, fc) 9155 defer func() { 9156 if r := recover(); r != nil { 9157 ec.Error(ctx, ec.Recover(ctx, r)) 9158 ret = graphql.Null 9159 } 9160 }() 9161 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 9162 ctx = rctx // use context from middleware stack in children 9163 return ec.resolvers.Query().MapStringInterface(rctx, fc.Args["in"].(map[string]interface{})) 9164 }) 9165 9166 if resTmp == nil { 9167 return graphql.Null 9168 } 9169 res := resTmp.(map[string]interface{}) 9170 fc.Result = res 9171 return ec.marshalOMapStringInterfaceType2map(ctx, field.Selections, res) 9172 } 9173 9174 func (ec *executionContext) fieldContext_Query_mapStringInterface(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 9175 fc = &graphql.FieldContext{ 9176 Object: "Query", 9177 Field: field, 9178 IsMethod: true, 9179 IsResolver: true, 9180 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 9181 switch field.Name { 9182 case "a": 9183 return ec.fieldContext_MapStringInterfaceType_a(ctx, field) 9184 case "b": 9185 return ec.fieldContext_MapStringInterfaceType_b(ctx, field) 9186 } 9187 return nil, fmt.Errorf("no field named %q was found under type MapStringInterfaceType", field.Name) 9188 }, 9189 } 9190 defer func() { 9191 if r := recover(); r != nil { 9192 err = ec.Recover(ctx, r) 9193 ec.Error(ctx, err) 9194 } 9195 }() 9196 ctx = graphql.WithFieldContext(ctx, fc) 9197 if fc.Args, err = ec.field_Query_mapStringInterface_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 9198 ec.Error(ctx, err) 9199 return 9200 } 9201 return fc, nil 9202 } 9203 9204 func (ec *executionContext) _Query_mapNestedStringInterface(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 9205 fc, err := ec.fieldContext_Query_mapNestedStringInterface(ctx, field) 9206 if err != nil { 9207 return graphql.Null 9208 } 9209 ctx = graphql.WithFieldContext(ctx, fc) 9210 defer func() { 9211 if r := recover(); r != nil { 9212 ec.Error(ctx, ec.Recover(ctx, r)) 9213 ret = graphql.Null 9214 } 9215 }() 9216 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 9217 ctx = rctx // use context from middleware stack in children 9218 return ec.resolvers.Query().MapNestedStringInterface(rctx, fc.Args["in"].(*NestedMapInput)) 9219 }) 9220 9221 if resTmp == nil { 9222 return graphql.Null 9223 } 9224 res := resTmp.(map[string]interface{}) 9225 fc.Result = res 9226 return ec.marshalOMapStringInterfaceType2map(ctx, field.Selections, res) 9227 } 9228 9229 func (ec *executionContext) fieldContext_Query_mapNestedStringInterface(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 9230 fc = &graphql.FieldContext{ 9231 Object: "Query", 9232 Field: field, 9233 IsMethod: true, 9234 IsResolver: true, 9235 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 9236 switch field.Name { 9237 case "a": 9238 return ec.fieldContext_MapStringInterfaceType_a(ctx, field) 9239 case "b": 9240 return ec.fieldContext_MapStringInterfaceType_b(ctx, field) 9241 } 9242 return nil, fmt.Errorf("no field named %q was found under type MapStringInterfaceType", field.Name) 9243 }, 9244 } 9245 defer func() { 9246 if r := recover(); r != nil { 9247 err = ec.Recover(ctx, r) 9248 ec.Error(ctx, err) 9249 } 9250 }() 9251 ctx = graphql.WithFieldContext(ctx, fc) 9252 if fc.Args, err = ec.field_Query_mapNestedStringInterface_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 9253 ec.Error(ctx, err) 9254 return 9255 } 9256 return fc, nil 9257 } 9258 9259 func (ec *executionContext) _Query_errorBubble(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 9260 fc, err := ec.fieldContext_Query_errorBubble(ctx, field) 9261 if err != nil { 9262 return graphql.Null 9263 } 9264 ctx = graphql.WithFieldContext(ctx, fc) 9265 defer func() { 9266 if r := recover(); r != nil { 9267 ec.Error(ctx, ec.Recover(ctx, r)) 9268 ret = graphql.Null 9269 } 9270 }() 9271 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 9272 ctx = rctx // use context from middleware stack in children 9273 return ec.resolvers.Query().ErrorBubble(rctx) 9274 }) 9275 9276 if resTmp == nil { 9277 return graphql.Null 9278 } 9279 res := resTmp.(*Error) 9280 fc.Result = res 9281 return ec.marshalOError2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐError(ctx, field.Selections, res) 9282 } 9283 9284 func (ec *executionContext) fieldContext_Query_errorBubble(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 9285 fc = &graphql.FieldContext{ 9286 Object: "Query", 9287 Field: field, 9288 IsMethod: true, 9289 IsResolver: true, 9290 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 9291 switch field.Name { 9292 case "id": 9293 return ec.fieldContext_Error_id(ctx, field) 9294 case "errorOnNonRequiredField": 9295 return ec.fieldContext_Error_errorOnNonRequiredField(ctx, field) 9296 case "errorOnRequiredField": 9297 return ec.fieldContext_Error_errorOnRequiredField(ctx, field) 9298 case "nilOnRequiredField": 9299 return ec.fieldContext_Error_nilOnRequiredField(ctx, field) 9300 } 9301 return nil, fmt.Errorf("no field named %q was found under type Error", field.Name) 9302 }, 9303 } 9304 return fc, nil 9305 } 9306 9307 func (ec *executionContext) _Query_errorBubbleList(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 9308 fc, err := ec.fieldContext_Query_errorBubbleList(ctx, field) 9309 if err != nil { 9310 return graphql.Null 9311 } 9312 ctx = graphql.WithFieldContext(ctx, fc) 9313 defer func() { 9314 if r := recover(); r != nil { 9315 ec.Error(ctx, ec.Recover(ctx, r)) 9316 ret = graphql.Null 9317 } 9318 }() 9319 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 9320 ctx = rctx // use context from middleware stack in children 9321 return ec.resolvers.Query().ErrorBubbleList(rctx) 9322 }) 9323 9324 if resTmp == nil { 9325 return graphql.Null 9326 } 9327 res := resTmp.([]*Error) 9328 fc.Result = res 9329 return ec.marshalOError2ᚕᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐErrorᚄ(ctx, field.Selections, res) 9330 } 9331 9332 func (ec *executionContext) fieldContext_Query_errorBubbleList(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 9333 fc = &graphql.FieldContext{ 9334 Object: "Query", 9335 Field: field, 9336 IsMethod: true, 9337 IsResolver: true, 9338 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 9339 switch field.Name { 9340 case "id": 9341 return ec.fieldContext_Error_id(ctx, field) 9342 case "errorOnNonRequiredField": 9343 return ec.fieldContext_Error_errorOnNonRequiredField(ctx, field) 9344 case "errorOnRequiredField": 9345 return ec.fieldContext_Error_errorOnRequiredField(ctx, field) 9346 case "nilOnRequiredField": 9347 return ec.fieldContext_Error_nilOnRequiredField(ctx, field) 9348 } 9349 return nil, fmt.Errorf("no field named %q was found under type Error", field.Name) 9350 }, 9351 } 9352 return fc, nil 9353 } 9354 9355 func (ec *executionContext) _Query_errorList(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 9356 fc, err := ec.fieldContext_Query_errorList(ctx, field) 9357 if err != nil { 9358 return graphql.Null 9359 } 9360 ctx = graphql.WithFieldContext(ctx, fc) 9361 defer func() { 9362 if r := recover(); r != nil { 9363 ec.Error(ctx, ec.Recover(ctx, r)) 9364 ret = graphql.Null 9365 } 9366 }() 9367 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 9368 ctx = rctx // use context from middleware stack in children 9369 return ec.resolvers.Query().ErrorList(rctx) 9370 }) 9371 9372 if resTmp == nil { 9373 return graphql.Null 9374 } 9375 res := resTmp.([]*Error) 9376 fc.Result = res 9377 return ec.marshalOError2ᚕᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐError(ctx, field.Selections, res) 9378 } 9379 9380 func (ec *executionContext) fieldContext_Query_errorList(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 9381 fc = &graphql.FieldContext{ 9382 Object: "Query", 9383 Field: field, 9384 IsMethod: true, 9385 IsResolver: true, 9386 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 9387 switch field.Name { 9388 case "id": 9389 return ec.fieldContext_Error_id(ctx, field) 9390 case "errorOnNonRequiredField": 9391 return ec.fieldContext_Error_errorOnNonRequiredField(ctx, field) 9392 case "errorOnRequiredField": 9393 return ec.fieldContext_Error_errorOnRequiredField(ctx, field) 9394 case "nilOnRequiredField": 9395 return ec.fieldContext_Error_nilOnRequiredField(ctx, field) 9396 } 9397 return nil, fmt.Errorf("no field named %q was found under type Error", field.Name) 9398 }, 9399 } 9400 return fc, nil 9401 } 9402 9403 func (ec *executionContext) _Query_errors(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 9404 fc, err := ec.fieldContext_Query_errors(ctx, field) 9405 if err != nil { 9406 return graphql.Null 9407 } 9408 ctx = graphql.WithFieldContext(ctx, fc) 9409 defer func() { 9410 if r := recover(); r != nil { 9411 ec.Error(ctx, ec.Recover(ctx, r)) 9412 ret = graphql.Null 9413 } 9414 }() 9415 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 9416 ctx = rctx // use context from middleware stack in children 9417 return ec.resolvers.Query().Errors(rctx) 9418 }) 9419 9420 if resTmp == nil { 9421 return graphql.Null 9422 } 9423 res := resTmp.(*Errors) 9424 fc.Result = res 9425 return ec.marshalOErrors2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐErrors(ctx, field.Selections, res) 9426 } 9427 9428 func (ec *executionContext) fieldContext_Query_errors(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 9429 fc = &graphql.FieldContext{ 9430 Object: "Query", 9431 Field: field, 9432 IsMethod: true, 9433 IsResolver: true, 9434 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 9435 switch field.Name { 9436 case "a": 9437 return ec.fieldContext_Errors_a(ctx, field) 9438 case "b": 9439 return ec.fieldContext_Errors_b(ctx, field) 9440 case "c": 9441 return ec.fieldContext_Errors_c(ctx, field) 9442 case "d": 9443 return ec.fieldContext_Errors_d(ctx, field) 9444 case "e": 9445 return ec.fieldContext_Errors_e(ctx, field) 9446 } 9447 return nil, fmt.Errorf("no field named %q was found under type Errors", field.Name) 9448 }, 9449 } 9450 return fc, nil 9451 } 9452 9453 func (ec *executionContext) _Query_valid(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 9454 fc, err := ec.fieldContext_Query_valid(ctx, field) 9455 if err != nil { 9456 return graphql.Null 9457 } 9458 ctx = graphql.WithFieldContext(ctx, fc) 9459 defer func() { 9460 if r := recover(); r != nil { 9461 ec.Error(ctx, ec.Recover(ctx, r)) 9462 ret = graphql.Null 9463 } 9464 }() 9465 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 9466 ctx = rctx // use context from middleware stack in children 9467 return ec.resolvers.Query().Valid(rctx) 9468 }) 9469 9470 if resTmp == nil { 9471 if !graphql.HasFieldError(ctx, fc) { 9472 ec.Errorf(ctx, "must not be null") 9473 } 9474 return graphql.Null 9475 } 9476 res := resTmp.(string) 9477 fc.Result = res 9478 return ec.marshalNString2string(ctx, field.Selections, res) 9479 } 9480 9481 func (ec *executionContext) fieldContext_Query_valid(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 9482 fc = &graphql.FieldContext{ 9483 Object: "Query", 9484 Field: field, 9485 IsMethod: true, 9486 IsResolver: true, 9487 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 9488 return nil, errors.New("field of type String does not have child fields") 9489 }, 9490 } 9491 return fc, nil 9492 } 9493 9494 func (ec *executionContext) _Query_panics(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 9495 fc, err := ec.fieldContext_Query_panics(ctx, field) 9496 if err != nil { 9497 return graphql.Null 9498 } 9499 ctx = graphql.WithFieldContext(ctx, fc) 9500 defer func() { 9501 if r := recover(); r != nil { 9502 ec.Error(ctx, ec.Recover(ctx, r)) 9503 ret = graphql.Null 9504 } 9505 }() 9506 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 9507 ctx = rctx // use context from middleware stack in children 9508 return ec.resolvers.Query().Panics(rctx) 9509 }) 9510 9511 if resTmp == nil { 9512 return graphql.Null 9513 } 9514 res := resTmp.(*Panics) 9515 fc.Result = res 9516 return ec.marshalOPanics2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPanics(ctx, field.Selections, res) 9517 } 9518 9519 func (ec *executionContext) fieldContext_Query_panics(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 9520 fc = &graphql.FieldContext{ 9521 Object: "Query", 9522 Field: field, 9523 IsMethod: true, 9524 IsResolver: true, 9525 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 9526 switch field.Name { 9527 case "fieldScalarMarshal": 9528 return ec.fieldContext_Panics_fieldScalarMarshal(ctx, field) 9529 case "fieldFuncMarshal": 9530 return ec.fieldContext_Panics_fieldFuncMarshal(ctx, field) 9531 case "argUnmarshal": 9532 return ec.fieldContext_Panics_argUnmarshal(ctx, field) 9533 } 9534 return nil, fmt.Errorf("no field named %q was found under type Panics", field.Name) 9535 }, 9536 } 9537 return fc, nil 9538 } 9539 9540 func (ec *executionContext) _Query_primitiveObject(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 9541 fc, err := ec.fieldContext_Query_primitiveObject(ctx, field) 9542 if err != nil { 9543 return graphql.Null 9544 } 9545 ctx = graphql.WithFieldContext(ctx, fc) 9546 defer func() { 9547 if r := recover(); r != nil { 9548 ec.Error(ctx, ec.Recover(ctx, r)) 9549 ret = graphql.Null 9550 } 9551 }() 9552 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 9553 ctx = rctx // use context from middleware stack in children 9554 return ec.resolvers.Query().PrimitiveObject(rctx) 9555 }) 9556 9557 if resTmp == nil { 9558 if !graphql.HasFieldError(ctx, fc) { 9559 ec.Errorf(ctx, "must not be null") 9560 } 9561 return graphql.Null 9562 } 9563 res := resTmp.([]Primitive) 9564 fc.Result = res 9565 return ec.marshalNPrimitive2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPrimitiveᚄ(ctx, field.Selections, res) 9566 } 9567 9568 func (ec *executionContext) fieldContext_Query_primitiveObject(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 9569 fc = &graphql.FieldContext{ 9570 Object: "Query", 9571 Field: field, 9572 IsMethod: true, 9573 IsResolver: true, 9574 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 9575 switch field.Name { 9576 case "value": 9577 return ec.fieldContext_Primitive_value(ctx, field) 9578 case "squared": 9579 return ec.fieldContext_Primitive_squared(ctx, field) 9580 } 9581 return nil, fmt.Errorf("no field named %q was found under type Primitive", field.Name) 9582 }, 9583 } 9584 return fc, nil 9585 } 9586 9587 func (ec *executionContext) _Query_primitiveStringObject(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 9588 fc, err := ec.fieldContext_Query_primitiveStringObject(ctx, field) 9589 if err != nil { 9590 return graphql.Null 9591 } 9592 ctx = graphql.WithFieldContext(ctx, fc) 9593 defer func() { 9594 if r := recover(); r != nil { 9595 ec.Error(ctx, ec.Recover(ctx, r)) 9596 ret = graphql.Null 9597 } 9598 }() 9599 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 9600 ctx = rctx // use context from middleware stack in children 9601 return ec.resolvers.Query().PrimitiveStringObject(rctx) 9602 }) 9603 9604 if resTmp == nil { 9605 if !graphql.HasFieldError(ctx, fc) { 9606 ec.Errorf(ctx, "must not be null") 9607 } 9608 return graphql.Null 9609 } 9610 res := resTmp.([]PrimitiveString) 9611 fc.Result = res 9612 return ec.marshalNPrimitiveString2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPrimitiveStringᚄ(ctx, field.Selections, res) 9613 } 9614 9615 func (ec *executionContext) fieldContext_Query_primitiveStringObject(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 9616 fc = &graphql.FieldContext{ 9617 Object: "Query", 9618 Field: field, 9619 IsMethod: true, 9620 IsResolver: true, 9621 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 9622 switch field.Name { 9623 case "value": 9624 return ec.fieldContext_PrimitiveString_value(ctx, field) 9625 case "doubled": 9626 return ec.fieldContext_PrimitiveString_doubled(ctx, field) 9627 case "len": 9628 return ec.fieldContext_PrimitiveString_len(ctx, field) 9629 } 9630 return nil, fmt.Errorf("no field named %q was found under type PrimitiveString", field.Name) 9631 }, 9632 } 9633 return fc, nil 9634 } 9635 9636 func (ec *executionContext) _Query_ptrToSliceContainer(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 9637 fc, err := ec.fieldContext_Query_ptrToSliceContainer(ctx, field) 9638 if err != nil { 9639 return graphql.Null 9640 } 9641 ctx = graphql.WithFieldContext(ctx, fc) 9642 defer func() { 9643 if r := recover(); r != nil { 9644 ec.Error(ctx, ec.Recover(ctx, r)) 9645 ret = graphql.Null 9646 } 9647 }() 9648 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 9649 ctx = rctx // use context from middleware stack in children 9650 return ec.resolvers.Query().PtrToSliceContainer(rctx) 9651 }) 9652 9653 if resTmp == nil { 9654 if !graphql.HasFieldError(ctx, fc) { 9655 ec.Errorf(ctx, "must not be null") 9656 } 9657 return graphql.Null 9658 } 9659 res := resTmp.(*PtrToSliceContainer) 9660 fc.Result = res 9661 return ec.marshalNPtrToSliceContainer2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPtrToSliceContainer(ctx, field.Selections, res) 9662 } 9663 9664 func (ec *executionContext) fieldContext_Query_ptrToSliceContainer(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 9665 fc = &graphql.FieldContext{ 9666 Object: "Query", 9667 Field: field, 9668 IsMethod: true, 9669 IsResolver: true, 9670 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 9671 switch field.Name { 9672 case "ptrToSlice": 9673 return ec.fieldContext_PtrToSliceContainer_ptrToSlice(ctx, field) 9674 } 9675 return nil, fmt.Errorf("no field named %q was found under type PtrToSliceContainer", field.Name) 9676 }, 9677 } 9678 return fc, nil 9679 } 9680 9681 func (ec *executionContext) _Query_infinity(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 9682 fc, err := ec.fieldContext_Query_infinity(ctx, field) 9683 if err != nil { 9684 return graphql.Null 9685 } 9686 ctx = graphql.WithFieldContext(ctx, fc) 9687 defer func() { 9688 if r := recover(); r != nil { 9689 ec.Error(ctx, ec.Recover(ctx, r)) 9690 ret = graphql.Null 9691 } 9692 }() 9693 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 9694 ctx = rctx // use context from middleware stack in children 9695 return ec.resolvers.Query().Infinity(rctx) 9696 }) 9697 9698 if resTmp == nil { 9699 if !graphql.HasFieldError(ctx, fc) { 9700 ec.Errorf(ctx, "must not be null") 9701 } 9702 return graphql.Null 9703 } 9704 res := resTmp.(float64) 9705 fc.Result = res 9706 return ec.marshalNFloat2float64(ctx, field.Selections, res) 9707 } 9708 9709 func (ec *executionContext) fieldContext_Query_infinity(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 9710 fc = &graphql.FieldContext{ 9711 Object: "Query", 9712 Field: field, 9713 IsMethod: true, 9714 IsResolver: true, 9715 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 9716 return nil, errors.New("field of type Float does not have child fields") 9717 }, 9718 } 9719 return fc, nil 9720 } 9721 9722 func (ec *executionContext) _Query_stringFromContextInterface(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 9723 fc, err := ec.fieldContext_Query_stringFromContextInterface(ctx, field) 9724 if err != nil { 9725 return graphql.Null 9726 } 9727 ctx = graphql.WithFieldContext(ctx, fc) 9728 defer func() { 9729 if r := recover(); r != nil { 9730 ec.Error(ctx, ec.Recover(ctx, r)) 9731 ret = graphql.Null 9732 } 9733 }() 9734 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 9735 ctx = rctx // use context from middleware stack in children 9736 return ec.resolvers.Query().StringFromContextInterface(rctx) 9737 }) 9738 9739 if resTmp == nil { 9740 if !graphql.HasFieldError(ctx, fc) { 9741 ec.Errorf(ctx, "must not be null") 9742 } 9743 return graphql.Null 9744 } 9745 res := resTmp.(*StringFromContextInterface) 9746 fc.Result = res 9747 return ec.marshalNStringFromContextInterface2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐStringFromContextInterface(ctx, field.Selections, res) 9748 } 9749 9750 func (ec *executionContext) fieldContext_Query_stringFromContextInterface(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 9751 fc = &graphql.FieldContext{ 9752 Object: "Query", 9753 Field: field, 9754 IsMethod: true, 9755 IsResolver: true, 9756 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 9757 return nil, errors.New("field of type StringFromContextInterface does not have child fields") 9758 }, 9759 } 9760 return fc, nil 9761 } 9762 9763 func (ec *executionContext) _Query_stringFromContextFunction(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 9764 fc, err := ec.fieldContext_Query_stringFromContextFunction(ctx, field) 9765 if err != nil { 9766 return graphql.Null 9767 } 9768 ctx = graphql.WithFieldContext(ctx, fc) 9769 defer func() { 9770 if r := recover(); r != nil { 9771 ec.Error(ctx, ec.Recover(ctx, r)) 9772 ret = graphql.Null 9773 } 9774 }() 9775 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 9776 ctx = rctx // use context from middleware stack in children 9777 return ec.resolvers.Query().StringFromContextFunction(rctx) 9778 }) 9779 9780 if resTmp == nil { 9781 if !graphql.HasFieldError(ctx, fc) { 9782 ec.Errorf(ctx, "must not be null") 9783 } 9784 return graphql.Null 9785 } 9786 res := resTmp.(string) 9787 fc.Result = res 9788 return ec.marshalNStringFromContextFunction2string(ctx, field.Selections, res) 9789 } 9790 9791 func (ec *executionContext) fieldContext_Query_stringFromContextFunction(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 9792 fc = &graphql.FieldContext{ 9793 Object: "Query", 9794 Field: field, 9795 IsMethod: true, 9796 IsResolver: true, 9797 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 9798 return nil, errors.New("field of type StringFromContextFunction does not have child fields") 9799 }, 9800 } 9801 return fc, nil 9802 } 9803 9804 func (ec *executionContext) _Query_defaultScalar(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 9805 fc, err := ec.fieldContext_Query_defaultScalar(ctx, field) 9806 if err != nil { 9807 return graphql.Null 9808 } 9809 ctx = graphql.WithFieldContext(ctx, fc) 9810 defer func() { 9811 if r := recover(); r != nil { 9812 ec.Error(ctx, ec.Recover(ctx, r)) 9813 ret = graphql.Null 9814 } 9815 }() 9816 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 9817 ctx = rctx // use context from middleware stack in children 9818 return ec.resolvers.Query().DefaultScalar(rctx, fc.Args["arg"].(string)) 9819 }) 9820 9821 if resTmp == nil { 9822 if !graphql.HasFieldError(ctx, fc) { 9823 ec.Errorf(ctx, "must not be null") 9824 } 9825 return graphql.Null 9826 } 9827 res := resTmp.(string) 9828 fc.Result = res 9829 return ec.marshalNDefaultScalarImplementation2string(ctx, field.Selections, res) 9830 } 9831 9832 func (ec *executionContext) fieldContext_Query_defaultScalar(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 9833 fc = &graphql.FieldContext{ 9834 Object: "Query", 9835 Field: field, 9836 IsMethod: true, 9837 IsResolver: true, 9838 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 9839 return nil, errors.New("field of type DefaultScalarImplementation does not have child fields") 9840 }, 9841 } 9842 defer func() { 9843 if r := recover(); r != nil { 9844 err = ec.Recover(ctx, r) 9845 ec.Error(ctx, err) 9846 } 9847 }() 9848 ctx = graphql.WithFieldContext(ctx, fc) 9849 if fc.Args, err = ec.field_Query_defaultScalar_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 9850 ec.Error(ctx, err) 9851 return 9852 } 9853 return fc, nil 9854 } 9855 9856 func (ec *executionContext) _Query_slices(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 9857 fc, err := ec.fieldContext_Query_slices(ctx, field) 9858 if err != nil { 9859 return graphql.Null 9860 } 9861 ctx = graphql.WithFieldContext(ctx, fc) 9862 defer func() { 9863 if r := recover(); r != nil { 9864 ec.Error(ctx, ec.Recover(ctx, r)) 9865 ret = graphql.Null 9866 } 9867 }() 9868 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 9869 ctx = rctx // use context from middleware stack in children 9870 return ec.resolvers.Query().Slices(rctx) 9871 }) 9872 9873 if resTmp == nil { 9874 return graphql.Null 9875 } 9876 res := resTmp.(*Slices) 9877 fc.Result = res 9878 return ec.marshalOSlices2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐSlices(ctx, field.Selections, res) 9879 } 9880 9881 func (ec *executionContext) fieldContext_Query_slices(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 9882 fc = &graphql.FieldContext{ 9883 Object: "Query", 9884 Field: field, 9885 IsMethod: true, 9886 IsResolver: true, 9887 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 9888 switch field.Name { 9889 case "test1": 9890 return ec.fieldContext_Slices_test1(ctx, field) 9891 case "test2": 9892 return ec.fieldContext_Slices_test2(ctx, field) 9893 case "test3": 9894 return ec.fieldContext_Slices_test3(ctx, field) 9895 case "test4": 9896 return ec.fieldContext_Slices_test4(ctx, field) 9897 } 9898 return nil, fmt.Errorf("no field named %q was found under type Slices", field.Name) 9899 }, 9900 } 9901 return fc, nil 9902 } 9903 9904 func (ec *executionContext) _Query_scalarSlice(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 9905 fc, err := ec.fieldContext_Query_scalarSlice(ctx, field) 9906 if err != nil { 9907 return graphql.Null 9908 } 9909 ctx = graphql.WithFieldContext(ctx, fc) 9910 defer func() { 9911 if r := recover(); r != nil { 9912 ec.Error(ctx, ec.Recover(ctx, r)) 9913 ret = graphql.Null 9914 } 9915 }() 9916 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 9917 ctx = rctx // use context from middleware stack in children 9918 return ec.resolvers.Query().ScalarSlice(rctx) 9919 }) 9920 9921 if resTmp == nil { 9922 if !graphql.HasFieldError(ctx, fc) { 9923 ec.Errorf(ctx, "must not be null") 9924 } 9925 return graphql.Null 9926 } 9927 res := resTmp.([]byte) 9928 fc.Result = res 9929 return ec.marshalNBytes2ᚕbyte(ctx, field.Selections, res) 9930 } 9931 9932 func (ec *executionContext) fieldContext_Query_scalarSlice(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 9933 fc = &graphql.FieldContext{ 9934 Object: "Query", 9935 Field: field, 9936 IsMethod: true, 9937 IsResolver: true, 9938 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 9939 return nil, errors.New("field of type Bytes does not have child fields") 9940 }, 9941 } 9942 return fc, nil 9943 } 9944 9945 func (ec *executionContext) _Query_fallback(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 9946 fc, err := ec.fieldContext_Query_fallback(ctx, field) 9947 if err != nil { 9948 return graphql.Null 9949 } 9950 ctx = graphql.WithFieldContext(ctx, fc) 9951 defer func() { 9952 if r := recover(); r != nil { 9953 ec.Error(ctx, ec.Recover(ctx, r)) 9954 ret = graphql.Null 9955 } 9956 }() 9957 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 9958 ctx = rctx // use context from middleware stack in children 9959 return ec.resolvers.Query().Fallback(rctx, fc.Args["arg"].(FallbackToStringEncoding)) 9960 }) 9961 9962 if resTmp == nil { 9963 if !graphql.HasFieldError(ctx, fc) { 9964 ec.Errorf(ctx, "must not be null") 9965 } 9966 return graphql.Null 9967 } 9968 res := resTmp.(FallbackToStringEncoding) 9969 fc.Result = res 9970 return ec.marshalNFallbackToStringEncoding2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐFallbackToStringEncoding(ctx, field.Selections, res) 9971 } 9972 9973 func (ec *executionContext) fieldContext_Query_fallback(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 9974 fc = &graphql.FieldContext{ 9975 Object: "Query", 9976 Field: field, 9977 IsMethod: true, 9978 IsResolver: true, 9979 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 9980 return nil, errors.New("field of type FallbackToStringEncoding does not have child fields") 9981 }, 9982 } 9983 defer func() { 9984 if r := recover(); r != nil { 9985 err = ec.Recover(ctx, r) 9986 ec.Error(ctx, err) 9987 } 9988 }() 9989 ctx = graphql.WithFieldContext(ctx, fc) 9990 if fc.Args, err = ec.field_Query_fallback_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 9991 ec.Error(ctx, err) 9992 return 9993 } 9994 return fc, nil 9995 } 9996 9997 func (ec *executionContext) _Query_optionalUnion(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 9998 fc, err := ec.fieldContext_Query_optionalUnion(ctx, field) 9999 if err != nil { 10000 return graphql.Null 10001 } 10002 ctx = graphql.WithFieldContext(ctx, fc) 10003 defer func() { 10004 if r := recover(); r != nil { 10005 ec.Error(ctx, ec.Recover(ctx, r)) 10006 ret = graphql.Null 10007 } 10008 }() 10009 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 10010 ctx = rctx // use context from middleware stack in children 10011 return ec.resolvers.Query().OptionalUnion(rctx) 10012 }) 10013 10014 if resTmp == nil { 10015 return graphql.Null 10016 } 10017 res := resTmp.(TestUnion) 10018 fc.Result = res 10019 return ec.marshalOTestUnion2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐTestUnion(ctx, field.Selections, res) 10020 } 10021 10022 func (ec *executionContext) fieldContext_Query_optionalUnion(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 10023 fc = &graphql.FieldContext{ 10024 Object: "Query", 10025 Field: field, 10026 IsMethod: true, 10027 IsResolver: true, 10028 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 10029 return nil, errors.New("field of type TestUnion does not have child fields") 10030 }, 10031 } 10032 return fc, nil 10033 } 10034 10035 func (ec *executionContext) _Query_vOkCaseValue(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 10036 fc, err := ec.fieldContext_Query_vOkCaseValue(ctx, field) 10037 if err != nil { 10038 return graphql.Null 10039 } 10040 ctx = graphql.WithFieldContext(ctx, fc) 10041 defer func() { 10042 if r := recover(); r != nil { 10043 ec.Error(ctx, ec.Recover(ctx, r)) 10044 ret = graphql.Null 10045 } 10046 }() 10047 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 10048 ctx = rctx // use context from middleware stack in children 10049 return ec.resolvers.Query().VOkCaseValue(rctx) 10050 }) 10051 10052 if resTmp == nil { 10053 return graphql.Null 10054 } 10055 res := resTmp.(*VOkCaseValue) 10056 fc.Result = res 10057 return ec.marshalOVOkCaseValue2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐVOkCaseValue(ctx, field.Selections, res) 10058 } 10059 10060 func (ec *executionContext) fieldContext_Query_vOkCaseValue(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 10061 fc = &graphql.FieldContext{ 10062 Object: "Query", 10063 Field: field, 10064 IsMethod: true, 10065 IsResolver: true, 10066 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 10067 switch field.Name { 10068 case "value": 10069 return ec.fieldContext_VOkCaseValue_value(ctx, field) 10070 } 10071 return nil, fmt.Errorf("no field named %q was found under type VOkCaseValue", field.Name) 10072 }, 10073 } 10074 return fc, nil 10075 } 10076 10077 func (ec *executionContext) _Query_vOkCaseNil(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 10078 fc, err := ec.fieldContext_Query_vOkCaseNil(ctx, field) 10079 if err != nil { 10080 return graphql.Null 10081 } 10082 ctx = graphql.WithFieldContext(ctx, fc) 10083 defer func() { 10084 if r := recover(); r != nil { 10085 ec.Error(ctx, ec.Recover(ctx, r)) 10086 ret = graphql.Null 10087 } 10088 }() 10089 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 10090 ctx = rctx // use context from middleware stack in children 10091 return ec.resolvers.Query().VOkCaseNil(rctx) 10092 }) 10093 10094 if resTmp == nil { 10095 return graphql.Null 10096 } 10097 res := resTmp.(*VOkCaseNil) 10098 fc.Result = res 10099 return ec.marshalOVOkCaseNil2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐVOkCaseNil(ctx, field.Selections, res) 10100 } 10101 10102 func (ec *executionContext) fieldContext_Query_vOkCaseNil(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 10103 fc = &graphql.FieldContext{ 10104 Object: "Query", 10105 Field: field, 10106 IsMethod: true, 10107 IsResolver: true, 10108 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 10109 switch field.Name { 10110 case "value": 10111 return ec.fieldContext_VOkCaseNil_value(ctx, field) 10112 } 10113 return nil, fmt.Errorf("no field named %q was found under type VOkCaseNil", field.Name) 10114 }, 10115 } 10116 return fc, nil 10117 } 10118 10119 func (ec *executionContext) _Query_validType(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 10120 fc, err := ec.fieldContext_Query_validType(ctx, field) 10121 if err != nil { 10122 return graphql.Null 10123 } 10124 ctx = graphql.WithFieldContext(ctx, fc) 10125 defer func() { 10126 if r := recover(); r != nil { 10127 ec.Error(ctx, ec.Recover(ctx, r)) 10128 ret = graphql.Null 10129 } 10130 }() 10131 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 10132 ctx = rctx // use context from middleware stack in children 10133 return ec.resolvers.Query().ValidType(rctx) 10134 }) 10135 10136 if resTmp == nil { 10137 return graphql.Null 10138 } 10139 res := resTmp.(*ValidType) 10140 fc.Result = res 10141 return ec.marshalOValidType2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐValidType(ctx, field.Selections, res) 10142 } 10143 10144 func (ec *executionContext) fieldContext_Query_validType(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 10145 fc = &graphql.FieldContext{ 10146 Object: "Query", 10147 Field: field, 10148 IsMethod: true, 10149 IsResolver: true, 10150 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 10151 switch field.Name { 10152 case "differentCase": 10153 return ec.fieldContext_ValidType_differentCase(ctx, field) 10154 case "different_case": 10155 return ec.fieldContext_ValidType_different_case(ctx, field) 10156 case "validInputKeywords": 10157 return ec.fieldContext_ValidType_validInputKeywords(ctx, field) 10158 case "validArgs": 10159 return ec.fieldContext_ValidType_validArgs(ctx, field) 10160 } 10161 return nil, fmt.Errorf("no field named %q was found under type ValidType", field.Name) 10162 }, 10163 } 10164 return fc, nil 10165 } 10166 10167 func (ec *executionContext) _Query_variadicModel(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 10168 fc, err := ec.fieldContext_Query_variadicModel(ctx, field) 10169 if err != nil { 10170 return graphql.Null 10171 } 10172 ctx = graphql.WithFieldContext(ctx, fc) 10173 defer func() { 10174 if r := recover(); r != nil { 10175 ec.Error(ctx, ec.Recover(ctx, r)) 10176 ret = graphql.Null 10177 } 10178 }() 10179 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 10180 ctx = rctx // use context from middleware stack in children 10181 return ec.resolvers.Query().VariadicModel(rctx) 10182 }) 10183 10184 if resTmp == nil { 10185 return graphql.Null 10186 } 10187 res := resTmp.(*VariadicModel) 10188 fc.Result = res 10189 return ec.marshalOVariadicModel2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐVariadicModel(ctx, field.Selections, res) 10190 } 10191 10192 func (ec *executionContext) fieldContext_Query_variadicModel(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 10193 fc = &graphql.FieldContext{ 10194 Object: "Query", 10195 Field: field, 10196 IsMethod: true, 10197 IsResolver: true, 10198 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 10199 switch field.Name { 10200 case "value": 10201 return ec.fieldContext_VariadicModel_value(ctx, field) 10202 } 10203 return nil, fmt.Errorf("no field named %q was found under type VariadicModel", field.Name) 10204 }, 10205 } 10206 return fc, nil 10207 } 10208 10209 func (ec *executionContext) _Query_wrappedStruct(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 10210 fc, err := ec.fieldContext_Query_wrappedStruct(ctx, field) 10211 if err != nil { 10212 return graphql.Null 10213 } 10214 ctx = graphql.WithFieldContext(ctx, fc) 10215 defer func() { 10216 if r := recover(); r != nil { 10217 ec.Error(ctx, ec.Recover(ctx, r)) 10218 ret = graphql.Null 10219 } 10220 }() 10221 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 10222 ctx = rctx // use context from middleware stack in children 10223 return ec.resolvers.Query().WrappedStruct(rctx) 10224 }) 10225 10226 if resTmp == nil { 10227 if !graphql.HasFieldError(ctx, fc) { 10228 ec.Errorf(ctx, "must not be null") 10229 } 10230 return graphql.Null 10231 } 10232 res := resTmp.(*WrappedStruct) 10233 fc.Result = res 10234 return ec.marshalNWrappedStruct2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐWrappedStruct(ctx, field.Selections, res) 10235 } 10236 10237 func (ec *executionContext) fieldContext_Query_wrappedStruct(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 10238 fc = &graphql.FieldContext{ 10239 Object: "Query", 10240 Field: field, 10241 IsMethod: true, 10242 IsResolver: true, 10243 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 10244 switch field.Name { 10245 case "name": 10246 return ec.fieldContext_WrappedStruct_name(ctx, field) 10247 case "desc": 10248 return ec.fieldContext_WrappedStruct_desc(ctx, field) 10249 } 10250 return nil, fmt.Errorf("no field named %q was found under type WrappedStruct", field.Name) 10251 }, 10252 } 10253 return fc, nil 10254 } 10255 10256 func (ec *executionContext) _Query_wrappedScalar(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 10257 fc, err := ec.fieldContext_Query_wrappedScalar(ctx, field) 10258 if err != nil { 10259 return graphql.Null 10260 } 10261 ctx = graphql.WithFieldContext(ctx, fc) 10262 defer func() { 10263 if r := recover(); r != nil { 10264 ec.Error(ctx, ec.Recover(ctx, r)) 10265 ret = graphql.Null 10266 } 10267 }() 10268 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 10269 ctx = rctx // use context from middleware stack in children 10270 return ec.resolvers.Query().WrappedScalar(rctx) 10271 }) 10272 10273 if resTmp == nil { 10274 if !graphql.HasFieldError(ctx, fc) { 10275 ec.Errorf(ctx, "must not be null") 10276 } 10277 return graphql.Null 10278 } 10279 res := resTmp.(otherpkg.Scalar) 10280 fc.Result = res 10281 return ec.marshalNWrappedScalar2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚋotherpkgᚐScalar(ctx, field.Selections, res) 10282 } 10283 10284 func (ec *executionContext) fieldContext_Query_wrappedScalar(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 10285 fc = &graphql.FieldContext{ 10286 Object: "Query", 10287 Field: field, 10288 IsMethod: true, 10289 IsResolver: true, 10290 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 10291 return nil, errors.New("field of type WrappedScalar does not have child fields") 10292 }, 10293 } 10294 return fc, nil 10295 } 10296 10297 func (ec *executionContext) _Query_wrappedMap(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 10298 fc, err := ec.fieldContext_Query_wrappedMap(ctx, field) 10299 if err != nil { 10300 return graphql.Null 10301 } 10302 ctx = graphql.WithFieldContext(ctx, fc) 10303 defer func() { 10304 if r := recover(); r != nil { 10305 ec.Error(ctx, ec.Recover(ctx, r)) 10306 ret = graphql.Null 10307 } 10308 }() 10309 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 10310 ctx = rctx // use context from middleware stack in children 10311 return ec.resolvers.Query().WrappedMap(rctx) 10312 }) 10313 10314 if resTmp == nil { 10315 if !graphql.HasFieldError(ctx, fc) { 10316 ec.Errorf(ctx, "must not be null") 10317 } 10318 return graphql.Null 10319 } 10320 res := resTmp.(WrappedMap) 10321 fc.Result = res 10322 return ec.marshalNWrappedMap2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐWrappedMap(ctx, field.Selections, res) 10323 } 10324 10325 func (ec *executionContext) fieldContext_Query_wrappedMap(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 10326 fc = &graphql.FieldContext{ 10327 Object: "Query", 10328 Field: field, 10329 IsMethod: true, 10330 IsResolver: true, 10331 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 10332 switch field.Name { 10333 case "get": 10334 return ec.fieldContext_WrappedMap_get(ctx, field) 10335 } 10336 return nil, fmt.Errorf("no field named %q was found under type WrappedMap", field.Name) 10337 }, 10338 } 10339 return fc, nil 10340 } 10341 10342 func (ec *executionContext) _Query_wrappedSlice(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 10343 fc, err := ec.fieldContext_Query_wrappedSlice(ctx, field) 10344 if err != nil { 10345 return graphql.Null 10346 } 10347 ctx = graphql.WithFieldContext(ctx, fc) 10348 defer func() { 10349 if r := recover(); r != nil { 10350 ec.Error(ctx, ec.Recover(ctx, r)) 10351 ret = graphql.Null 10352 } 10353 }() 10354 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 10355 ctx = rctx // use context from middleware stack in children 10356 return ec.resolvers.Query().WrappedSlice(rctx) 10357 }) 10358 10359 if resTmp == nil { 10360 if !graphql.HasFieldError(ctx, fc) { 10361 ec.Errorf(ctx, "must not be null") 10362 } 10363 return graphql.Null 10364 } 10365 res := resTmp.(WrappedSlice) 10366 fc.Result = res 10367 return ec.marshalNWrappedSlice2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐWrappedSlice(ctx, field.Selections, res) 10368 } 10369 10370 func (ec *executionContext) fieldContext_Query_wrappedSlice(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 10371 fc = &graphql.FieldContext{ 10372 Object: "Query", 10373 Field: field, 10374 IsMethod: true, 10375 IsResolver: true, 10376 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 10377 switch field.Name { 10378 case "get": 10379 return ec.fieldContext_WrappedSlice_get(ctx, field) 10380 } 10381 return nil, fmt.Errorf("no field named %q was found under type WrappedSlice", field.Name) 10382 }, 10383 } 10384 return fc, nil 10385 } 10386 10387 func (ec *executionContext) _Query___type(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 10388 fc, err := ec.fieldContext_Query___type(ctx, field) 10389 if err != nil { 10390 return graphql.Null 10391 } 10392 ctx = graphql.WithFieldContext(ctx, fc) 10393 defer func() { 10394 if r := recover(); r != nil { 10395 ec.Error(ctx, ec.Recover(ctx, r)) 10396 ret = graphql.Null 10397 } 10398 }() 10399 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 10400 ctx = rctx // use context from middleware stack in children 10401 return ec.introspectType(fc.Args["name"].(string)) 10402 }) 10403 10404 if resTmp == nil { 10405 return graphql.Null 10406 } 10407 res := resTmp.(*introspection.Type) 10408 fc.Result = res 10409 return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) 10410 } 10411 10412 func (ec *executionContext) fieldContext_Query___type(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 10413 fc = &graphql.FieldContext{ 10414 Object: "Query", 10415 Field: field, 10416 IsMethod: true, 10417 IsResolver: false, 10418 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 10419 switch field.Name { 10420 case "kind": 10421 return ec.fieldContext___Type_kind(ctx, field) 10422 case "name": 10423 return ec.fieldContext___Type_name(ctx, field) 10424 case "description": 10425 return ec.fieldContext___Type_description(ctx, field) 10426 case "fields": 10427 return ec.fieldContext___Type_fields(ctx, field) 10428 case "interfaces": 10429 return ec.fieldContext___Type_interfaces(ctx, field) 10430 case "possibleTypes": 10431 return ec.fieldContext___Type_possibleTypes(ctx, field) 10432 case "enumValues": 10433 return ec.fieldContext___Type_enumValues(ctx, field) 10434 case "inputFields": 10435 return ec.fieldContext___Type_inputFields(ctx, field) 10436 case "ofType": 10437 return ec.fieldContext___Type_ofType(ctx, field) 10438 case "specifiedByURL": 10439 return ec.fieldContext___Type_specifiedByURL(ctx, field) 10440 } 10441 return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) 10442 }, 10443 } 10444 defer func() { 10445 if r := recover(); r != nil { 10446 err = ec.Recover(ctx, r) 10447 ec.Error(ctx, err) 10448 } 10449 }() 10450 ctx = graphql.WithFieldContext(ctx, fc) 10451 if fc.Args, err = ec.field_Query___type_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 10452 ec.Error(ctx, err) 10453 return 10454 } 10455 return fc, nil 10456 } 10457 10458 func (ec *executionContext) _Query___schema(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 10459 fc, err := ec.fieldContext_Query___schema(ctx, field) 10460 if err != nil { 10461 return graphql.Null 10462 } 10463 ctx = graphql.WithFieldContext(ctx, fc) 10464 defer func() { 10465 if r := recover(); r != nil { 10466 ec.Error(ctx, ec.Recover(ctx, r)) 10467 ret = graphql.Null 10468 } 10469 }() 10470 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 10471 ctx = rctx // use context from middleware stack in children 10472 return ec.introspectSchema() 10473 }) 10474 10475 if resTmp == nil { 10476 return graphql.Null 10477 } 10478 res := resTmp.(*introspection.Schema) 10479 fc.Result = res 10480 return ec.marshalO__Schema2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐSchema(ctx, field.Selections, res) 10481 } 10482 10483 func (ec *executionContext) fieldContext_Query___schema(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 10484 fc = &graphql.FieldContext{ 10485 Object: "Query", 10486 Field: field, 10487 IsMethod: true, 10488 IsResolver: false, 10489 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 10490 switch field.Name { 10491 case "description": 10492 return ec.fieldContext___Schema_description(ctx, field) 10493 case "types": 10494 return ec.fieldContext___Schema_types(ctx, field) 10495 case "queryType": 10496 return ec.fieldContext___Schema_queryType(ctx, field) 10497 case "mutationType": 10498 return ec.fieldContext___Schema_mutationType(ctx, field) 10499 case "subscriptionType": 10500 return ec.fieldContext___Schema_subscriptionType(ctx, field) 10501 case "directives": 10502 return ec.fieldContext___Schema_directives(ctx, field) 10503 } 10504 return nil, fmt.Errorf("no field named %q was found under type __Schema", field.Name) 10505 }, 10506 } 10507 return fc, nil 10508 } 10509 10510 func (ec *executionContext) _Rectangle_length(ctx context.Context, field graphql.CollectedField, obj *Rectangle) (ret graphql.Marshaler) { 10511 fc, err := ec.fieldContext_Rectangle_length(ctx, field) 10512 if err != nil { 10513 return graphql.Null 10514 } 10515 ctx = graphql.WithFieldContext(ctx, fc) 10516 defer func() { 10517 if r := recover(); r != nil { 10518 ec.Error(ctx, ec.Recover(ctx, r)) 10519 ret = graphql.Null 10520 } 10521 }() 10522 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 10523 ctx = rctx // use context from middleware stack in children 10524 return obj.Length, nil 10525 }) 10526 10527 if resTmp == nil { 10528 return graphql.Null 10529 } 10530 res := resTmp.(float64) 10531 fc.Result = res 10532 return ec.marshalOFloat2float64(ctx, field.Selections, res) 10533 } 10534 10535 func (ec *executionContext) fieldContext_Rectangle_length(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 10536 fc = &graphql.FieldContext{ 10537 Object: "Rectangle", 10538 Field: field, 10539 IsMethod: false, 10540 IsResolver: false, 10541 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 10542 return nil, errors.New("field of type Float does not have child fields") 10543 }, 10544 } 10545 return fc, nil 10546 } 10547 10548 func (ec *executionContext) _Rectangle_width(ctx context.Context, field graphql.CollectedField, obj *Rectangle) (ret graphql.Marshaler) { 10549 fc, err := ec.fieldContext_Rectangle_width(ctx, field) 10550 if err != nil { 10551 return graphql.Null 10552 } 10553 ctx = graphql.WithFieldContext(ctx, fc) 10554 defer func() { 10555 if r := recover(); r != nil { 10556 ec.Error(ctx, ec.Recover(ctx, r)) 10557 ret = graphql.Null 10558 } 10559 }() 10560 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 10561 ctx = rctx // use context from middleware stack in children 10562 return obj.Width, nil 10563 }) 10564 10565 if resTmp == nil { 10566 return graphql.Null 10567 } 10568 res := resTmp.(float64) 10569 fc.Result = res 10570 return ec.marshalOFloat2float64(ctx, field.Selections, res) 10571 } 10572 10573 func (ec *executionContext) fieldContext_Rectangle_width(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 10574 fc = &graphql.FieldContext{ 10575 Object: "Rectangle", 10576 Field: field, 10577 IsMethod: false, 10578 IsResolver: false, 10579 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 10580 return nil, errors.New("field of type Float does not have child fields") 10581 }, 10582 } 10583 return fc, nil 10584 } 10585 10586 func (ec *executionContext) _Rectangle_area(ctx context.Context, field graphql.CollectedField, obj *Rectangle) (ret graphql.Marshaler) { 10587 fc, err := ec.fieldContext_Rectangle_area(ctx, field) 10588 if err != nil { 10589 return graphql.Null 10590 } 10591 ctx = graphql.WithFieldContext(ctx, fc) 10592 defer func() { 10593 if r := recover(); r != nil { 10594 ec.Error(ctx, ec.Recover(ctx, r)) 10595 ret = graphql.Null 10596 } 10597 }() 10598 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 10599 ctx = rctx // use context from middleware stack in children 10600 return obj.Area(), nil 10601 }) 10602 10603 if resTmp == nil { 10604 return graphql.Null 10605 } 10606 res := resTmp.(float64) 10607 fc.Result = res 10608 return ec.marshalOFloat2float64(ctx, field.Selections, res) 10609 } 10610 10611 func (ec *executionContext) fieldContext_Rectangle_area(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 10612 fc = &graphql.FieldContext{ 10613 Object: "Rectangle", 10614 Field: field, 10615 IsMethod: true, 10616 IsResolver: false, 10617 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 10618 return nil, errors.New("field of type Float does not have child fields") 10619 }, 10620 } 10621 return fc, nil 10622 } 10623 10624 func (ec *executionContext) _Rectangle_coordinates(ctx context.Context, field graphql.CollectedField, obj *Rectangle) (ret graphql.Marshaler) { 10625 fc, err := ec.fieldContext_Rectangle_coordinates(ctx, field) 10626 if err != nil { 10627 return graphql.Null 10628 } 10629 ctx = graphql.WithFieldContext(ctx, fc) 10630 defer func() { 10631 if r := recover(); r != nil { 10632 ec.Error(ctx, ec.Recover(ctx, r)) 10633 ret = graphql.Null 10634 } 10635 }() 10636 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 10637 ctx = rctx // use context from middleware stack in children 10638 return obj.Coordinates, nil 10639 }) 10640 10641 if resTmp == nil { 10642 return graphql.Null 10643 } 10644 res := resTmp.(Coordinates) 10645 fc.Result = res 10646 return ec.marshalOCoordinates2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐCoordinates(ctx, field.Selections, res) 10647 } 10648 10649 func (ec *executionContext) fieldContext_Rectangle_coordinates(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 10650 fc = &graphql.FieldContext{ 10651 Object: "Rectangle", 10652 Field: field, 10653 IsMethod: false, 10654 IsResolver: false, 10655 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 10656 switch field.Name { 10657 case "x": 10658 return ec.fieldContext_Coordinates_x(ctx, field) 10659 case "y": 10660 return ec.fieldContext_Coordinates_y(ctx, field) 10661 } 10662 return nil, fmt.Errorf("no field named %q was found under type Coordinates", field.Name) 10663 }, 10664 } 10665 return fc, nil 10666 } 10667 10668 func (ec *executionContext) _Slices_test1(ctx context.Context, field graphql.CollectedField, obj *Slices) (ret graphql.Marshaler) { 10669 fc, err := ec.fieldContext_Slices_test1(ctx, field) 10670 if err != nil { 10671 return graphql.Null 10672 } 10673 ctx = graphql.WithFieldContext(ctx, fc) 10674 defer func() { 10675 if r := recover(); r != nil { 10676 ec.Error(ctx, ec.Recover(ctx, r)) 10677 ret = graphql.Null 10678 } 10679 }() 10680 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 10681 ctx = rctx // use context from middleware stack in children 10682 return obj.Test1, nil 10683 }) 10684 10685 if resTmp == nil { 10686 return graphql.Null 10687 } 10688 res := resTmp.([]*string) 10689 fc.Result = res 10690 return ec.marshalOString2ᚕᚖstring(ctx, field.Selections, res) 10691 } 10692 10693 func (ec *executionContext) fieldContext_Slices_test1(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 10694 fc = &graphql.FieldContext{ 10695 Object: "Slices", 10696 Field: field, 10697 IsMethod: false, 10698 IsResolver: false, 10699 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 10700 return nil, errors.New("field of type String does not have child fields") 10701 }, 10702 } 10703 return fc, nil 10704 } 10705 10706 func (ec *executionContext) _Slices_test2(ctx context.Context, field graphql.CollectedField, obj *Slices) (ret graphql.Marshaler) { 10707 fc, err := ec.fieldContext_Slices_test2(ctx, field) 10708 if err != nil { 10709 return graphql.Null 10710 } 10711 ctx = graphql.WithFieldContext(ctx, fc) 10712 defer func() { 10713 if r := recover(); r != nil { 10714 ec.Error(ctx, ec.Recover(ctx, r)) 10715 ret = graphql.Null 10716 } 10717 }() 10718 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 10719 ctx = rctx // use context from middleware stack in children 10720 return obj.Test2, nil 10721 }) 10722 10723 if resTmp == nil { 10724 return graphql.Null 10725 } 10726 res := resTmp.([]string) 10727 fc.Result = res 10728 return ec.marshalOString2ᚕstringᚄ(ctx, field.Selections, res) 10729 } 10730 10731 func (ec *executionContext) fieldContext_Slices_test2(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 10732 fc = &graphql.FieldContext{ 10733 Object: "Slices", 10734 Field: field, 10735 IsMethod: false, 10736 IsResolver: false, 10737 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 10738 return nil, errors.New("field of type String does not have child fields") 10739 }, 10740 } 10741 return fc, nil 10742 } 10743 10744 func (ec *executionContext) _Slices_test3(ctx context.Context, field graphql.CollectedField, obj *Slices) (ret graphql.Marshaler) { 10745 fc, err := ec.fieldContext_Slices_test3(ctx, field) 10746 if err != nil { 10747 return graphql.Null 10748 } 10749 ctx = graphql.WithFieldContext(ctx, fc) 10750 defer func() { 10751 if r := recover(); r != nil { 10752 ec.Error(ctx, ec.Recover(ctx, r)) 10753 ret = graphql.Null 10754 } 10755 }() 10756 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 10757 ctx = rctx // use context from middleware stack in children 10758 return obj.Test3, nil 10759 }) 10760 10761 if resTmp == nil { 10762 if !graphql.HasFieldError(ctx, fc) { 10763 ec.Errorf(ctx, "must not be null") 10764 } 10765 return graphql.Null 10766 } 10767 res := resTmp.([]*string) 10768 fc.Result = res 10769 return ec.marshalNString2ᚕᚖstring(ctx, field.Selections, res) 10770 } 10771 10772 func (ec *executionContext) fieldContext_Slices_test3(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 10773 fc = &graphql.FieldContext{ 10774 Object: "Slices", 10775 Field: field, 10776 IsMethod: false, 10777 IsResolver: false, 10778 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 10779 return nil, errors.New("field of type String does not have child fields") 10780 }, 10781 } 10782 return fc, nil 10783 } 10784 10785 func (ec *executionContext) _Slices_test4(ctx context.Context, field graphql.CollectedField, obj *Slices) (ret graphql.Marshaler) { 10786 fc, err := ec.fieldContext_Slices_test4(ctx, field) 10787 if err != nil { 10788 return graphql.Null 10789 } 10790 ctx = graphql.WithFieldContext(ctx, fc) 10791 defer func() { 10792 if r := recover(); r != nil { 10793 ec.Error(ctx, ec.Recover(ctx, r)) 10794 ret = graphql.Null 10795 } 10796 }() 10797 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 10798 ctx = rctx // use context from middleware stack in children 10799 return obj.Test4, nil 10800 }) 10801 10802 if resTmp == nil { 10803 if !graphql.HasFieldError(ctx, fc) { 10804 ec.Errorf(ctx, "must not be null") 10805 } 10806 return graphql.Null 10807 } 10808 res := resTmp.([]string) 10809 fc.Result = res 10810 return ec.marshalNString2ᚕstringᚄ(ctx, field.Selections, res) 10811 } 10812 10813 func (ec *executionContext) fieldContext_Slices_test4(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 10814 fc = &graphql.FieldContext{ 10815 Object: "Slices", 10816 Field: field, 10817 IsMethod: false, 10818 IsResolver: false, 10819 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 10820 return nil, errors.New("field of type String does not have child fields") 10821 }, 10822 } 10823 return fc, nil 10824 } 10825 10826 func (ec *executionContext) _Subscription_updated(ctx context.Context, field graphql.CollectedField) (ret func(ctx context.Context) graphql.Marshaler) { 10827 fc, err := ec.fieldContext_Subscription_updated(ctx, field) 10828 if err != nil { 10829 return nil 10830 } 10831 ctx = graphql.WithFieldContext(ctx, fc) 10832 defer func() { 10833 if r := recover(); r != nil { 10834 ec.Error(ctx, ec.Recover(ctx, r)) 10835 ret = nil 10836 } 10837 }() 10838 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 10839 ctx = rctx // use context from middleware stack in children 10840 return ec.resolvers.Subscription().Updated(rctx) 10841 }) 10842 10843 if resTmp == nil { 10844 if !graphql.HasFieldError(ctx, fc) { 10845 ec.Errorf(ctx, "must not be null") 10846 } 10847 return nil 10848 } 10849 return func(ctx context.Context) graphql.Marshaler { 10850 select { 10851 case res, ok := <-resTmp.(<-chan string): 10852 if !ok { 10853 return nil 10854 } 10855 return graphql.WriterFunc(func(w io.Writer) { 10856 w.Write([]byte{'{'}) 10857 graphql.MarshalString(field.Alias).MarshalGQL(w) 10858 w.Write([]byte{':'}) 10859 ec.marshalNString2string(ctx, field.Selections, res).MarshalGQL(w) 10860 w.Write([]byte{'}'}) 10861 }) 10862 case <-ctx.Done(): 10863 return nil 10864 } 10865 } 10866 } 10867 10868 func (ec *executionContext) fieldContext_Subscription_updated(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 10869 fc = &graphql.FieldContext{ 10870 Object: "Subscription", 10871 Field: field, 10872 IsMethod: true, 10873 IsResolver: true, 10874 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 10875 return nil, errors.New("field of type String does not have child fields") 10876 }, 10877 } 10878 return fc, nil 10879 } 10880 10881 func (ec *executionContext) _Subscription_initPayload(ctx context.Context, field graphql.CollectedField) (ret func(ctx context.Context) graphql.Marshaler) { 10882 fc, err := ec.fieldContext_Subscription_initPayload(ctx, field) 10883 if err != nil { 10884 return nil 10885 } 10886 ctx = graphql.WithFieldContext(ctx, fc) 10887 defer func() { 10888 if r := recover(); r != nil { 10889 ec.Error(ctx, ec.Recover(ctx, r)) 10890 ret = nil 10891 } 10892 }() 10893 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 10894 ctx = rctx // use context from middleware stack in children 10895 return ec.resolvers.Subscription().InitPayload(rctx) 10896 }) 10897 10898 if resTmp == nil { 10899 if !graphql.HasFieldError(ctx, fc) { 10900 ec.Errorf(ctx, "must not be null") 10901 } 10902 return nil 10903 } 10904 return func(ctx context.Context) graphql.Marshaler { 10905 select { 10906 case res, ok := <-resTmp.(<-chan string): 10907 if !ok { 10908 return nil 10909 } 10910 return graphql.WriterFunc(func(w io.Writer) { 10911 w.Write([]byte{'{'}) 10912 graphql.MarshalString(field.Alias).MarshalGQL(w) 10913 w.Write([]byte{':'}) 10914 ec.marshalNString2string(ctx, field.Selections, res).MarshalGQL(w) 10915 w.Write([]byte{'}'}) 10916 }) 10917 case <-ctx.Done(): 10918 return nil 10919 } 10920 } 10921 } 10922 10923 func (ec *executionContext) fieldContext_Subscription_initPayload(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 10924 fc = &graphql.FieldContext{ 10925 Object: "Subscription", 10926 Field: field, 10927 IsMethod: true, 10928 IsResolver: true, 10929 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 10930 return nil, errors.New("field of type String does not have child fields") 10931 }, 10932 } 10933 return fc, nil 10934 } 10935 10936 func (ec *executionContext) _Subscription_directiveArg(ctx context.Context, field graphql.CollectedField) (ret func(ctx context.Context) graphql.Marshaler) { 10937 fc, err := ec.fieldContext_Subscription_directiveArg(ctx, field) 10938 if err != nil { 10939 return nil 10940 } 10941 ctx = graphql.WithFieldContext(ctx, fc) 10942 defer func() { 10943 if r := recover(); r != nil { 10944 ec.Error(ctx, ec.Recover(ctx, r)) 10945 ret = nil 10946 } 10947 }() 10948 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 10949 ctx = rctx // use context from middleware stack in children 10950 return ec.resolvers.Subscription().DirectiveArg(rctx, fc.Args["arg"].(string)) 10951 }) 10952 10953 if resTmp == nil { 10954 return nil 10955 } 10956 return func(ctx context.Context) graphql.Marshaler { 10957 select { 10958 case res, ok := <-resTmp.(<-chan *string): 10959 if !ok { 10960 return nil 10961 } 10962 return graphql.WriterFunc(func(w io.Writer) { 10963 w.Write([]byte{'{'}) 10964 graphql.MarshalString(field.Alias).MarshalGQL(w) 10965 w.Write([]byte{':'}) 10966 ec.marshalOString2ᚖstring(ctx, field.Selections, res).MarshalGQL(w) 10967 w.Write([]byte{'}'}) 10968 }) 10969 case <-ctx.Done(): 10970 return nil 10971 } 10972 } 10973 } 10974 10975 func (ec *executionContext) fieldContext_Subscription_directiveArg(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 10976 fc = &graphql.FieldContext{ 10977 Object: "Subscription", 10978 Field: field, 10979 IsMethod: true, 10980 IsResolver: true, 10981 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 10982 return nil, errors.New("field of type String does not have child fields") 10983 }, 10984 } 10985 defer func() { 10986 if r := recover(); r != nil { 10987 err = ec.Recover(ctx, r) 10988 ec.Error(ctx, err) 10989 } 10990 }() 10991 ctx = graphql.WithFieldContext(ctx, fc) 10992 if fc.Args, err = ec.field_Subscription_directiveArg_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 10993 ec.Error(ctx, err) 10994 return 10995 } 10996 return fc, nil 10997 } 10998 10999 func (ec *executionContext) _Subscription_directiveNullableArg(ctx context.Context, field graphql.CollectedField) (ret func(ctx context.Context) graphql.Marshaler) { 11000 fc, err := ec.fieldContext_Subscription_directiveNullableArg(ctx, field) 11001 if err != nil { 11002 return nil 11003 } 11004 ctx = graphql.WithFieldContext(ctx, fc) 11005 defer func() { 11006 if r := recover(); r != nil { 11007 ec.Error(ctx, ec.Recover(ctx, r)) 11008 ret = nil 11009 } 11010 }() 11011 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 11012 ctx = rctx // use context from middleware stack in children 11013 return ec.resolvers.Subscription().DirectiveNullableArg(rctx, fc.Args["arg"].(*int), fc.Args["arg2"].(*int), fc.Args["arg3"].(*string)) 11014 }) 11015 11016 if resTmp == nil { 11017 return nil 11018 } 11019 return func(ctx context.Context) graphql.Marshaler { 11020 select { 11021 case res, ok := <-resTmp.(<-chan *string): 11022 if !ok { 11023 return nil 11024 } 11025 return graphql.WriterFunc(func(w io.Writer) { 11026 w.Write([]byte{'{'}) 11027 graphql.MarshalString(field.Alias).MarshalGQL(w) 11028 w.Write([]byte{':'}) 11029 ec.marshalOString2ᚖstring(ctx, field.Selections, res).MarshalGQL(w) 11030 w.Write([]byte{'}'}) 11031 }) 11032 case <-ctx.Done(): 11033 return nil 11034 } 11035 } 11036 } 11037 11038 func (ec *executionContext) fieldContext_Subscription_directiveNullableArg(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 11039 fc = &graphql.FieldContext{ 11040 Object: "Subscription", 11041 Field: field, 11042 IsMethod: true, 11043 IsResolver: true, 11044 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 11045 return nil, errors.New("field of type String does not have child fields") 11046 }, 11047 } 11048 defer func() { 11049 if r := recover(); r != nil { 11050 err = ec.Recover(ctx, r) 11051 ec.Error(ctx, err) 11052 } 11053 }() 11054 ctx = graphql.WithFieldContext(ctx, fc) 11055 if fc.Args, err = ec.field_Subscription_directiveNullableArg_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 11056 ec.Error(ctx, err) 11057 return 11058 } 11059 return fc, nil 11060 } 11061 11062 func (ec *executionContext) _Subscription_directiveDouble(ctx context.Context, field graphql.CollectedField) (ret func(ctx context.Context) graphql.Marshaler) { 11063 fc, err := ec.fieldContext_Subscription_directiveDouble(ctx, field) 11064 if err != nil { 11065 return nil 11066 } 11067 ctx = graphql.WithFieldContext(ctx, fc) 11068 defer func() { 11069 if r := recover(); r != nil { 11070 ec.Error(ctx, ec.Recover(ctx, r)) 11071 ret = nil 11072 } 11073 }() 11074 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 11075 directive0 := func(rctx context.Context) (interface{}, error) { 11076 ctx = rctx // use context from middleware stack in children 11077 return ec.resolvers.Subscription().DirectiveDouble(rctx) 11078 } 11079 directive1 := func(ctx context.Context) (interface{}, error) { 11080 if ec.directives.Directive1 == nil { 11081 return nil, errors.New("directive directive1 is not implemented") 11082 } 11083 return ec.directives.Directive1(ctx, nil, directive0) 11084 } 11085 directive2 := func(ctx context.Context) (interface{}, error) { 11086 if ec.directives.Directive2 == nil { 11087 return nil, errors.New("directive directive2 is not implemented") 11088 } 11089 return ec.directives.Directive2(ctx, nil, directive1) 11090 } 11091 11092 tmp, err := directive2(rctx) 11093 if err != nil { 11094 return nil, graphql.ErrorOnPath(ctx, err) 11095 } 11096 if tmp == nil { 11097 return nil, nil 11098 } 11099 if data, ok := tmp.(<-chan *string); ok { 11100 return data, nil 11101 } 11102 return nil, fmt.Errorf(`unexpected type %T from directive, should be <-chan *string`, tmp) 11103 }) 11104 11105 if resTmp == nil { 11106 return nil 11107 } 11108 return func(ctx context.Context) graphql.Marshaler { 11109 select { 11110 case res, ok := <-resTmp.(<-chan *string): 11111 if !ok { 11112 return nil 11113 } 11114 return graphql.WriterFunc(func(w io.Writer) { 11115 w.Write([]byte{'{'}) 11116 graphql.MarshalString(field.Alias).MarshalGQL(w) 11117 w.Write([]byte{':'}) 11118 ec.marshalOString2ᚖstring(ctx, field.Selections, res).MarshalGQL(w) 11119 w.Write([]byte{'}'}) 11120 }) 11121 case <-ctx.Done(): 11122 return nil 11123 } 11124 } 11125 } 11126 11127 func (ec *executionContext) fieldContext_Subscription_directiveDouble(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 11128 fc = &graphql.FieldContext{ 11129 Object: "Subscription", 11130 Field: field, 11131 IsMethod: true, 11132 IsResolver: true, 11133 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 11134 return nil, errors.New("field of type String does not have child fields") 11135 }, 11136 } 11137 return fc, nil 11138 } 11139 11140 func (ec *executionContext) _Subscription_directiveUnimplemented(ctx context.Context, field graphql.CollectedField) (ret func(ctx context.Context) graphql.Marshaler) { 11141 fc, err := ec.fieldContext_Subscription_directiveUnimplemented(ctx, field) 11142 if err != nil { 11143 return nil 11144 } 11145 ctx = graphql.WithFieldContext(ctx, fc) 11146 defer func() { 11147 if r := recover(); r != nil { 11148 ec.Error(ctx, ec.Recover(ctx, r)) 11149 ret = nil 11150 } 11151 }() 11152 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 11153 directive0 := func(rctx context.Context) (interface{}, error) { 11154 ctx = rctx // use context from middleware stack in children 11155 return ec.resolvers.Subscription().DirectiveUnimplemented(rctx) 11156 } 11157 directive1 := func(ctx context.Context) (interface{}, error) { 11158 if ec.directives.Unimplemented == nil { 11159 return nil, errors.New("directive unimplemented is not implemented") 11160 } 11161 return ec.directives.Unimplemented(ctx, nil, directive0) 11162 } 11163 11164 tmp, err := directive1(rctx) 11165 if err != nil { 11166 return nil, graphql.ErrorOnPath(ctx, err) 11167 } 11168 if tmp == nil { 11169 return nil, nil 11170 } 11171 if data, ok := tmp.(<-chan *string); ok { 11172 return data, nil 11173 } 11174 return nil, fmt.Errorf(`unexpected type %T from directive, should be <-chan *string`, tmp) 11175 }) 11176 11177 if resTmp == nil { 11178 return nil 11179 } 11180 return func(ctx context.Context) graphql.Marshaler { 11181 select { 11182 case res, ok := <-resTmp.(<-chan *string): 11183 if !ok { 11184 return nil 11185 } 11186 return graphql.WriterFunc(func(w io.Writer) { 11187 w.Write([]byte{'{'}) 11188 graphql.MarshalString(field.Alias).MarshalGQL(w) 11189 w.Write([]byte{':'}) 11190 ec.marshalOString2ᚖstring(ctx, field.Selections, res).MarshalGQL(w) 11191 w.Write([]byte{'}'}) 11192 }) 11193 case <-ctx.Done(): 11194 return nil 11195 } 11196 } 11197 } 11198 11199 func (ec *executionContext) fieldContext_Subscription_directiveUnimplemented(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 11200 fc = &graphql.FieldContext{ 11201 Object: "Subscription", 11202 Field: field, 11203 IsMethod: true, 11204 IsResolver: true, 11205 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 11206 return nil, errors.New("field of type String does not have child fields") 11207 }, 11208 } 11209 return fc, nil 11210 } 11211 11212 func (ec *executionContext) _Subscription_issue896b(ctx context.Context, field graphql.CollectedField) (ret func(ctx context.Context) graphql.Marshaler) { 11213 fc, err := ec.fieldContext_Subscription_issue896b(ctx, field) 11214 if err != nil { 11215 return nil 11216 } 11217 ctx = graphql.WithFieldContext(ctx, fc) 11218 defer func() { 11219 if r := recover(); r != nil { 11220 ec.Error(ctx, ec.Recover(ctx, r)) 11221 ret = nil 11222 } 11223 }() 11224 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 11225 ctx = rctx // use context from middleware stack in children 11226 return ec.resolvers.Subscription().Issue896b(rctx) 11227 }) 11228 11229 if resTmp == nil { 11230 return nil 11231 } 11232 return func(ctx context.Context) graphql.Marshaler { 11233 select { 11234 case res, ok := <-resTmp.(<-chan []*CheckIssue896): 11235 if !ok { 11236 return nil 11237 } 11238 return graphql.WriterFunc(func(w io.Writer) { 11239 w.Write([]byte{'{'}) 11240 graphql.MarshalString(field.Alias).MarshalGQL(w) 11241 w.Write([]byte{':'}) 11242 ec.marshalOCheckIssue8962ᚕᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐCheckIssue896(ctx, field.Selections, res).MarshalGQL(w) 11243 w.Write([]byte{'}'}) 11244 }) 11245 case <-ctx.Done(): 11246 return nil 11247 } 11248 } 11249 } 11250 11251 func (ec *executionContext) fieldContext_Subscription_issue896b(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 11252 fc = &graphql.FieldContext{ 11253 Object: "Subscription", 11254 Field: field, 11255 IsMethod: true, 11256 IsResolver: true, 11257 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 11258 switch field.Name { 11259 case "id": 11260 return ec.fieldContext_CheckIssue896_id(ctx, field) 11261 } 11262 return nil, fmt.Errorf("no field named %q was found under type CheckIssue896", field.Name) 11263 }, 11264 } 11265 return fc, nil 11266 } 11267 11268 func (ec *executionContext) _Subscription_errorRequired(ctx context.Context, field graphql.CollectedField) (ret func(ctx context.Context) graphql.Marshaler) { 11269 fc, err := ec.fieldContext_Subscription_errorRequired(ctx, field) 11270 if err != nil { 11271 return nil 11272 } 11273 ctx = graphql.WithFieldContext(ctx, fc) 11274 defer func() { 11275 if r := recover(); r != nil { 11276 ec.Error(ctx, ec.Recover(ctx, r)) 11277 ret = nil 11278 } 11279 }() 11280 resTmp := ec._fieldMiddleware(ctx, nil, func(rctx context.Context) (interface{}, error) { 11281 ctx = rctx // use context from middleware stack in children 11282 return ec.resolvers.Subscription().ErrorRequired(rctx) 11283 }) 11284 11285 if resTmp == nil { 11286 if !graphql.HasFieldError(ctx, fc) { 11287 ec.Errorf(ctx, "must not be null") 11288 } 11289 return nil 11290 } 11291 return func(ctx context.Context) graphql.Marshaler { 11292 select { 11293 case res, ok := <-resTmp.(<-chan *Error): 11294 if !ok { 11295 return nil 11296 } 11297 return graphql.WriterFunc(func(w io.Writer) { 11298 w.Write([]byte{'{'}) 11299 graphql.MarshalString(field.Alias).MarshalGQL(w) 11300 w.Write([]byte{':'}) 11301 ec.marshalNError2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐError(ctx, field.Selections, res).MarshalGQL(w) 11302 w.Write([]byte{'}'}) 11303 }) 11304 case <-ctx.Done(): 11305 return nil 11306 } 11307 } 11308 } 11309 11310 func (ec *executionContext) fieldContext_Subscription_errorRequired(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 11311 fc = &graphql.FieldContext{ 11312 Object: "Subscription", 11313 Field: field, 11314 IsMethod: true, 11315 IsResolver: true, 11316 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 11317 switch field.Name { 11318 case "id": 11319 return ec.fieldContext_Error_id(ctx, field) 11320 case "errorOnNonRequiredField": 11321 return ec.fieldContext_Error_errorOnNonRequiredField(ctx, field) 11322 case "errorOnRequiredField": 11323 return ec.fieldContext_Error_errorOnRequiredField(ctx, field) 11324 case "nilOnRequiredField": 11325 return ec.fieldContext_Error_nilOnRequiredField(ctx, field) 11326 } 11327 return nil, fmt.Errorf("no field named %q was found under type Error", field.Name) 11328 }, 11329 } 11330 return fc, nil 11331 } 11332 11333 func (ec *executionContext) _User_id(ctx context.Context, field graphql.CollectedField, obj *User) (ret graphql.Marshaler) { 11334 fc, err := ec.fieldContext_User_id(ctx, field) 11335 if err != nil { 11336 return graphql.Null 11337 } 11338 ctx = graphql.WithFieldContext(ctx, fc) 11339 defer func() { 11340 if r := recover(); r != nil { 11341 ec.Error(ctx, ec.Recover(ctx, r)) 11342 ret = graphql.Null 11343 } 11344 }() 11345 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 11346 ctx = rctx // use context from middleware stack in children 11347 return obj.ID, nil 11348 }) 11349 11350 if resTmp == nil { 11351 if !graphql.HasFieldError(ctx, fc) { 11352 ec.Errorf(ctx, "must not be null") 11353 } 11354 return graphql.Null 11355 } 11356 res := resTmp.(int) 11357 fc.Result = res 11358 return ec.marshalNInt2int(ctx, field.Selections, res) 11359 } 11360 11361 func (ec *executionContext) fieldContext_User_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 11362 fc = &graphql.FieldContext{ 11363 Object: "User", 11364 Field: field, 11365 IsMethod: false, 11366 IsResolver: false, 11367 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 11368 return nil, errors.New("field of type Int does not have child fields") 11369 }, 11370 } 11371 return fc, nil 11372 } 11373 11374 func (ec *executionContext) _User_friends(ctx context.Context, field graphql.CollectedField, obj *User) (ret graphql.Marshaler) { 11375 fc, err := ec.fieldContext_User_friends(ctx, field) 11376 if err != nil { 11377 return graphql.Null 11378 } 11379 ctx = graphql.WithFieldContext(ctx, fc) 11380 defer func() { 11381 if r := recover(); r != nil { 11382 ec.Error(ctx, ec.Recover(ctx, r)) 11383 ret = graphql.Null 11384 } 11385 }() 11386 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 11387 ctx = rctx // use context from middleware stack in children 11388 return ec.resolvers.User().Friends(rctx, obj) 11389 }) 11390 11391 if resTmp == nil { 11392 if !graphql.HasFieldError(ctx, fc) { 11393 ec.Errorf(ctx, "must not be null") 11394 } 11395 return graphql.Null 11396 } 11397 res := resTmp.([]*User) 11398 fc.Result = res 11399 return ec.marshalNUser2ᚕᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUserᚄ(ctx, field.Selections, res) 11400 } 11401 11402 func (ec *executionContext) fieldContext_User_friends(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 11403 fc = &graphql.FieldContext{ 11404 Object: "User", 11405 Field: field, 11406 IsMethod: true, 11407 IsResolver: true, 11408 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 11409 switch field.Name { 11410 case "id": 11411 return ec.fieldContext_User_id(ctx, field) 11412 case "friends": 11413 return ec.fieldContext_User_friends(ctx, field) 11414 case "created": 11415 return ec.fieldContext_User_created(ctx, field) 11416 case "updated": 11417 return ec.fieldContext_User_updated(ctx, field) 11418 case "pets": 11419 return ec.fieldContext_User_pets(ctx, field) 11420 } 11421 return nil, fmt.Errorf("no field named %q was found under type User", field.Name) 11422 }, 11423 } 11424 return fc, nil 11425 } 11426 11427 func (ec *executionContext) _User_created(ctx context.Context, field graphql.CollectedField, obj *User) (ret graphql.Marshaler) { 11428 fc, err := ec.fieldContext_User_created(ctx, field) 11429 if err != nil { 11430 return graphql.Null 11431 } 11432 ctx = graphql.WithFieldContext(ctx, fc) 11433 defer func() { 11434 if r := recover(); r != nil { 11435 ec.Error(ctx, ec.Recover(ctx, r)) 11436 ret = graphql.Null 11437 } 11438 }() 11439 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 11440 ctx = rctx // use context from middleware stack in children 11441 return obj.Created, nil 11442 }) 11443 11444 if resTmp == nil { 11445 if !graphql.HasFieldError(ctx, fc) { 11446 ec.Errorf(ctx, "must not be null") 11447 } 11448 return graphql.Null 11449 } 11450 res := resTmp.(time.Time) 11451 fc.Result = res 11452 return ec.marshalNTime2timeᚐTime(ctx, field.Selections, res) 11453 } 11454 11455 func (ec *executionContext) fieldContext_User_created(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 11456 fc = &graphql.FieldContext{ 11457 Object: "User", 11458 Field: field, 11459 IsMethod: false, 11460 IsResolver: false, 11461 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 11462 return nil, errors.New("field of type Time does not have child fields") 11463 }, 11464 } 11465 return fc, nil 11466 } 11467 11468 func (ec *executionContext) _User_updated(ctx context.Context, field graphql.CollectedField, obj *User) (ret graphql.Marshaler) { 11469 fc, err := ec.fieldContext_User_updated(ctx, field) 11470 if err != nil { 11471 return graphql.Null 11472 } 11473 ctx = graphql.WithFieldContext(ctx, fc) 11474 defer func() { 11475 if r := recover(); r != nil { 11476 ec.Error(ctx, ec.Recover(ctx, r)) 11477 ret = graphql.Null 11478 } 11479 }() 11480 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 11481 ctx = rctx // use context from middleware stack in children 11482 return obj.Updated, nil 11483 }) 11484 11485 if resTmp == nil { 11486 return graphql.Null 11487 } 11488 res := resTmp.(*time.Time) 11489 fc.Result = res 11490 return ec.marshalOTime2ᚖtimeᚐTime(ctx, field.Selections, res) 11491 } 11492 11493 func (ec *executionContext) fieldContext_User_updated(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 11494 fc = &graphql.FieldContext{ 11495 Object: "User", 11496 Field: field, 11497 IsMethod: false, 11498 IsResolver: false, 11499 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 11500 return nil, errors.New("field of type Time does not have child fields") 11501 }, 11502 } 11503 return fc, nil 11504 } 11505 11506 func (ec *executionContext) _User_pets(ctx context.Context, field graphql.CollectedField, obj *User) (ret graphql.Marshaler) { 11507 fc, err := ec.fieldContext_User_pets(ctx, field) 11508 if err != nil { 11509 return graphql.Null 11510 } 11511 ctx = graphql.WithFieldContext(ctx, fc) 11512 defer func() { 11513 if r := recover(); r != nil { 11514 ec.Error(ctx, ec.Recover(ctx, r)) 11515 ret = graphql.Null 11516 } 11517 }() 11518 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 11519 ctx = rctx // use context from middleware stack in children 11520 return ec.resolvers.User().Pets(rctx, obj, fc.Args["limit"].(*int)) 11521 }) 11522 11523 if resTmp == nil { 11524 return graphql.Null 11525 } 11526 res := resTmp.([]*Pet) 11527 fc.Result = res 11528 return ec.marshalOPet2ᚕᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPetᚄ(ctx, field.Selections, res) 11529 } 11530 11531 func (ec *executionContext) fieldContext_User_pets(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 11532 fc = &graphql.FieldContext{ 11533 Object: "User", 11534 Field: field, 11535 IsMethod: true, 11536 IsResolver: true, 11537 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 11538 switch field.Name { 11539 case "id": 11540 return ec.fieldContext_Pet_id(ctx, field) 11541 case "friends": 11542 return ec.fieldContext_Pet_friends(ctx, field) 11543 } 11544 return nil, fmt.Errorf("no field named %q was found under type Pet", field.Name) 11545 }, 11546 } 11547 defer func() { 11548 if r := recover(); r != nil { 11549 err = ec.Recover(ctx, r) 11550 ec.Error(ctx, err) 11551 } 11552 }() 11553 ctx = graphql.WithFieldContext(ctx, fc) 11554 if fc.Args, err = ec.field_User_pets_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 11555 ec.Error(ctx, err) 11556 return 11557 } 11558 return fc, nil 11559 } 11560 11561 func (ec *executionContext) _VOkCaseNil_value(ctx context.Context, field graphql.CollectedField, obj *VOkCaseNil) (ret graphql.Marshaler) { 11562 fc, err := ec.fieldContext_VOkCaseNil_value(ctx, field) 11563 if err != nil { 11564 return graphql.Null 11565 } 11566 ctx = graphql.WithFieldContext(ctx, fc) 11567 defer func() { 11568 if r := recover(); r != nil { 11569 ec.Error(ctx, ec.Recover(ctx, r)) 11570 ret = graphql.Null 11571 } 11572 }() 11573 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 11574 ctx = rctx // use context from middleware stack in children 11575 v, ok := obj.Value() 11576 if !ok { 11577 return nil, nil 11578 } 11579 return v, nil 11580 }) 11581 11582 if resTmp == nil { 11583 return graphql.Null 11584 } 11585 res := resTmp.(string) 11586 fc.Result = res 11587 return ec.marshalOString2string(ctx, field.Selections, res) 11588 } 11589 11590 func (ec *executionContext) fieldContext_VOkCaseNil_value(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 11591 fc = &graphql.FieldContext{ 11592 Object: "VOkCaseNil", 11593 Field: field, 11594 IsMethod: true, 11595 IsResolver: false, 11596 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 11597 return nil, errors.New("field of type String does not have child fields") 11598 }, 11599 } 11600 return fc, nil 11601 } 11602 11603 func (ec *executionContext) _VOkCaseValue_value(ctx context.Context, field graphql.CollectedField, obj *VOkCaseValue) (ret graphql.Marshaler) { 11604 fc, err := ec.fieldContext_VOkCaseValue_value(ctx, field) 11605 if err != nil { 11606 return graphql.Null 11607 } 11608 ctx = graphql.WithFieldContext(ctx, fc) 11609 defer func() { 11610 if r := recover(); r != nil { 11611 ec.Error(ctx, ec.Recover(ctx, r)) 11612 ret = graphql.Null 11613 } 11614 }() 11615 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 11616 ctx = rctx // use context from middleware stack in children 11617 v, ok := obj.Value() 11618 if !ok { 11619 return nil, nil 11620 } 11621 return v, nil 11622 }) 11623 11624 if resTmp == nil { 11625 return graphql.Null 11626 } 11627 res := resTmp.(string) 11628 fc.Result = res 11629 return ec.marshalOString2string(ctx, field.Selections, res) 11630 } 11631 11632 func (ec *executionContext) fieldContext_VOkCaseValue_value(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 11633 fc = &graphql.FieldContext{ 11634 Object: "VOkCaseValue", 11635 Field: field, 11636 IsMethod: true, 11637 IsResolver: false, 11638 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 11639 return nil, errors.New("field of type String does not have child fields") 11640 }, 11641 } 11642 return fc, nil 11643 } 11644 11645 func (ec *executionContext) _ValidType_differentCase(ctx context.Context, field graphql.CollectedField, obj *ValidType) (ret graphql.Marshaler) { 11646 fc, err := ec.fieldContext_ValidType_differentCase(ctx, field) 11647 if err != nil { 11648 return graphql.Null 11649 } 11650 ctx = graphql.WithFieldContext(ctx, fc) 11651 defer func() { 11652 if r := recover(); r != nil { 11653 ec.Error(ctx, ec.Recover(ctx, r)) 11654 ret = graphql.Null 11655 } 11656 }() 11657 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 11658 ctx = rctx // use context from middleware stack in children 11659 return obj.DifferentCase, nil 11660 }) 11661 11662 if resTmp == nil { 11663 if !graphql.HasFieldError(ctx, fc) { 11664 ec.Errorf(ctx, "must not be null") 11665 } 11666 return graphql.Null 11667 } 11668 res := resTmp.(string) 11669 fc.Result = res 11670 return ec.marshalNString2string(ctx, field.Selections, res) 11671 } 11672 11673 func (ec *executionContext) fieldContext_ValidType_differentCase(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 11674 fc = &graphql.FieldContext{ 11675 Object: "ValidType", 11676 Field: field, 11677 IsMethod: false, 11678 IsResolver: false, 11679 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 11680 return nil, errors.New("field of type String does not have child fields") 11681 }, 11682 } 11683 return fc, nil 11684 } 11685 11686 func (ec *executionContext) _ValidType_different_case(ctx context.Context, field graphql.CollectedField, obj *ValidType) (ret graphql.Marshaler) { 11687 fc, err := ec.fieldContext_ValidType_different_case(ctx, field) 11688 if err != nil { 11689 return graphql.Null 11690 } 11691 ctx = graphql.WithFieldContext(ctx, fc) 11692 defer func() { 11693 if r := recover(); r != nil { 11694 ec.Error(ctx, ec.Recover(ctx, r)) 11695 ret = graphql.Null 11696 } 11697 }() 11698 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 11699 ctx = rctx // use context from middleware stack in children 11700 return obj.DifferentCaseOld, nil 11701 }) 11702 11703 if resTmp == nil { 11704 if !graphql.HasFieldError(ctx, fc) { 11705 ec.Errorf(ctx, "must not be null") 11706 } 11707 return graphql.Null 11708 } 11709 res := resTmp.(string) 11710 fc.Result = res 11711 return ec.marshalNString2string(ctx, field.Selections, res) 11712 } 11713 11714 func (ec *executionContext) fieldContext_ValidType_different_case(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 11715 fc = &graphql.FieldContext{ 11716 Object: "ValidType", 11717 Field: field, 11718 IsMethod: false, 11719 IsResolver: false, 11720 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 11721 return nil, errors.New("field of type String does not have child fields") 11722 }, 11723 } 11724 return fc, nil 11725 } 11726 11727 func (ec *executionContext) _ValidType_validInputKeywords(ctx context.Context, field graphql.CollectedField, obj *ValidType) (ret graphql.Marshaler) { 11728 fc, err := ec.fieldContext_ValidType_validInputKeywords(ctx, field) 11729 if err != nil { 11730 return graphql.Null 11731 } 11732 ctx = graphql.WithFieldContext(ctx, fc) 11733 defer func() { 11734 if r := recover(); r != nil { 11735 ec.Error(ctx, ec.Recover(ctx, r)) 11736 ret = graphql.Null 11737 } 11738 }() 11739 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 11740 ctx = rctx // use context from middleware stack in children 11741 return obj.ValidInputKeywords, nil 11742 }) 11743 11744 if resTmp == nil { 11745 if !graphql.HasFieldError(ctx, fc) { 11746 ec.Errorf(ctx, "must not be null") 11747 } 11748 return graphql.Null 11749 } 11750 res := resTmp.(bool) 11751 fc.Result = res 11752 return ec.marshalNBoolean2bool(ctx, field.Selections, res) 11753 } 11754 11755 func (ec *executionContext) fieldContext_ValidType_validInputKeywords(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 11756 fc = &graphql.FieldContext{ 11757 Object: "ValidType", 11758 Field: field, 11759 IsMethod: false, 11760 IsResolver: false, 11761 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 11762 return nil, errors.New("field of type Boolean does not have child fields") 11763 }, 11764 } 11765 defer func() { 11766 if r := recover(); r != nil { 11767 err = ec.Recover(ctx, r) 11768 ec.Error(ctx, err) 11769 } 11770 }() 11771 ctx = graphql.WithFieldContext(ctx, fc) 11772 if fc.Args, err = ec.field_ValidType_validInputKeywords_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 11773 ec.Error(ctx, err) 11774 return 11775 } 11776 return fc, nil 11777 } 11778 11779 func (ec *executionContext) _ValidType_validArgs(ctx context.Context, field graphql.CollectedField, obj *ValidType) (ret graphql.Marshaler) { 11780 fc, err := ec.fieldContext_ValidType_validArgs(ctx, field) 11781 if err != nil { 11782 return graphql.Null 11783 } 11784 ctx = graphql.WithFieldContext(ctx, fc) 11785 defer func() { 11786 if r := recover(); r != nil { 11787 ec.Error(ctx, ec.Recover(ctx, r)) 11788 ret = graphql.Null 11789 } 11790 }() 11791 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 11792 ctx = rctx // use context from middleware stack in children 11793 return obj.ValidArgs, nil 11794 }) 11795 11796 if resTmp == nil { 11797 if !graphql.HasFieldError(ctx, fc) { 11798 ec.Errorf(ctx, "must not be null") 11799 } 11800 return graphql.Null 11801 } 11802 res := resTmp.(bool) 11803 fc.Result = res 11804 return ec.marshalNBoolean2bool(ctx, field.Selections, res) 11805 } 11806 11807 func (ec *executionContext) fieldContext_ValidType_validArgs(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 11808 fc = &graphql.FieldContext{ 11809 Object: "ValidType", 11810 Field: field, 11811 IsMethod: false, 11812 IsResolver: false, 11813 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 11814 return nil, errors.New("field of type Boolean does not have child fields") 11815 }, 11816 } 11817 defer func() { 11818 if r := recover(); r != nil { 11819 err = ec.Recover(ctx, r) 11820 ec.Error(ctx, err) 11821 } 11822 }() 11823 ctx = graphql.WithFieldContext(ctx, fc) 11824 if fc.Args, err = ec.field_ValidType_validArgs_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 11825 ec.Error(ctx, err) 11826 return 11827 } 11828 return fc, nil 11829 } 11830 11831 func (ec *executionContext) _VariadicModel_value(ctx context.Context, field graphql.CollectedField, obj *VariadicModel) (ret graphql.Marshaler) { 11832 fc, err := ec.fieldContext_VariadicModel_value(ctx, field) 11833 if err != nil { 11834 return graphql.Null 11835 } 11836 ctx = graphql.WithFieldContext(ctx, fc) 11837 defer func() { 11838 if r := recover(); r != nil { 11839 ec.Error(ctx, ec.Recover(ctx, r)) 11840 ret = graphql.Null 11841 } 11842 }() 11843 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 11844 ctx = rctx // use context from middleware stack in children 11845 return obj.Value(ctx, fc.Args["rank"].(int)) 11846 }) 11847 11848 if resTmp == nil { 11849 return graphql.Null 11850 } 11851 res := resTmp.(string) 11852 fc.Result = res 11853 return ec.marshalOString2string(ctx, field.Selections, res) 11854 } 11855 11856 func (ec *executionContext) fieldContext_VariadicModel_value(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 11857 fc = &graphql.FieldContext{ 11858 Object: "VariadicModel", 11859 Field: field, 11860 IsMethod: true, 11861 IsResolver: false, 11862 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 11863 return nil, errors.New("field of type String does not have child fields") 11864 }, 11865 } 11866 defer func() { 11867 if r := recover(); r != nil { 11868 err = ec.Recover(ctx, r) 11869 ec.Error(ctx, err) 11870 } 11871 }() 11872 ctx = graphql.WithFieldContext(ctx, fc) 11873 if fc.Args, err = ec.field_VariadicModel_value_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 11874 ec.Error(ctx, err) 11875 return 11876 } 11877 return fc, nil 11878 } 11879 11880 func (ec *executionContext) _WrappedMap_get(ctx context.Context, field graphql.CollectedField, obj WrappedMap) (ret graphql.Marshaler) { 11881 fc, err := ec.fieldContext_WrappedMap_get(ctx, field) 11882 if err != nil { 11883 return graphql.Null 11884 } 11885 ctx = graphql.WithFieldContext(ctx, fc) 11886 defer func() { 11887 if r := recover(); r != nil { 11888 ec.Error(ctx, ec.Recover(ctx, r)) 11889 ret = graphql.Null 11890 } 11891 }() 11892 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 11893 ctx = rctx // use context from middleware stack in children 11894 return ec.resolvers.WrappedMap().Get(rctx, obj, fc.Args["key"].(string)) 11895 }) 11896 11897 if resTmp == nil { 11898 if !graphql.HasFieldError(ctx, fc) { 11899 ec.Errorf(ctx, "must not be null") 11900 } 11901 return graphql.Null 11902 } 11903 res := resTmp.(string) 11904 fc.Result = res 11905 return ec.marshalNString2string(ctx, field.Selections, res) 11906 } 11907 11908 func (ec *executionContext) fieldContext_WrappedMap_get(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 11909 fc = &graphql.FieldContext{ 11910 Object: "WrappedMap", 11911 Field: field, 11912 IsMethod: true, 11913 IsResolver: true, 11914 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 11915 return nil, errors.New("field of type String does not have child fields") 11916 }, 11917 } 11918 defer func() { 11919 if r := recover(); r != nil { 11920 err = ec.Recover(ctx, r) 11921 ec.Error(ctx, err) 11922 } 11923 }() 11924 ctx = graphql.WithFieldContext(ctx, fc) 11925 if fc.Args, err = ec.field_WrappedMap_get_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 11926 ec.Error(ctx, err) 11927 return 11928 } 11929 return fc, nil 11930 } 11931 11932 func (ec *executionContext) _WrappedSlice_get(ctx context.Context, field graphql.CollectedField, obj WrappedSlice) (ret graphql.Marshaler) { 11933 fc, err := ec.fieldContext_WrappedSlice_get(ctx, field) 11934 if err != nil { 11935 return graphql.Null 11936 } 11937 ctx = graphql.WithFieldContext(ctx, fc) 11938 defer func() { 11939 if r := recover(); r != nil { 11940 ec.Error(ctx, ec.Recover(ctx, r)) 11941 ret = graphql.Null 11942 } 11943 }() 11944 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 11945 ctx = rctx // use context from middleware stack in children 11946 return ec.resolvers.WrappedSlice().Get(rctx, obj, fc.Args["idx"].(int)) 11947 }) 11948 11949 if resTmp == nil { 11950 if !graphql.HasFieldError(ctx, fc) { 11951 ec.Errorf(ctx, "must not be null") 11952 } 11953 return graphql.Null 11954 } 11955 res := resTmp.(string) 11956 fc.Result = res 11957 return ec.marshalNString2string(ctx, field.Selections, res) 11958 } 11959 11960 func (ec *executionContext) fieldContext_WrappedSlice_get(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 11961 fc = &graphql.FieldContext{ 11962 Object: "WrappedSlice", 11963 Field: field, 11964 IsMethod: true, 11965 IsResolver: true, 11966 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 11967 return nil, errors.New("field of type String does not have child fields") 11968 }, 11969 } 11970 defer func() { 11971 if r := recover(); r != nil { 11972 err = ec.Recover(ctx, r) 11973 ec.Error(ctx, err) 11974 } 11975 }() 11976 ctx = graphql.WithFieldContext(ctx, fc) 11977 if fc.Args, err = ec.field_WrappedSlice_get_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 11978 ec.Error(ctx, err) 11979 return 11980 } 11981 return fc, nil 11982 } 11983 11984 func (ec *executionContext) _WrappedStruct_name(ctx context.Context, field graphql.CollectedField, obj *WrappedStruct) (ret graphql.Marshaler) { 11985 fc, err := ec.fieldContext_WrappedStruct_name(ctx, field) 11986 if err != nil { 11987 return graphql.Null 11988 } 11989 ctx = graphql.WithFieldContext(ctx, fc) 11990 defer func() { 11991 if r := recover(); r != nil { 11992 ec.Error(ctx, ec.Recover(ctx, r)) 11993 ret = graphql.Null 11994 } 11995 }() 11996 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 11997 ctx = rctx // use context from middleware stack in children 11998 return obj.Name, nil 11999 }) 12000 12001 if resTmp == nil { 12002 if !graphql.HasFieldError(ctx, fc) { 12003 ec.Errorf(ctx, "must not be null") 12004 } 12005 return graphql.Null 12006 } 12007 res := resTmp.(otherpkg.Scalar) 12008 fc.Result = res 12009 return ec.marshalNWrappedScalar2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚋotherpkgᚐScalar(ctx, field.Selections, res) 12010 } 12011 12012 func (ec *executionContext) fieldContext_WrappedStruct_name(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 12013 fc = &graphql.FieldContext{ 12014 Object: "WrappedStruct", 12015 Field: field, 12016 IsMethod: false, 12017 IsResolver: false, 12018 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 12019 return nil, errors.New("field of type WrappedScalar does not have child fields") 12020 }, 12021 } 12022 return fc, nil 12023 } 12024 12025 func (ec *executionContext) _WrappedStruct_desc(ctx context.Context, field graphql.CollectedField, obj *WrappedStruct) (ret graphql.Marshaler) { 12026 fc, err := ec.fieldContext_WrappedStruct_desc(ctx, field) 12027 if err != nil { 12028 return graphql.Null 12029 } 12030 ctx = graphql.WithFieldContext(ctx, fc) 12031 defer func() { 12032 if r := recover(); r != nil { 12033 ec.Error(ctx, ec.Recover(ctx, r)) 12034 ret = graphql.Null 12035 } 12036 }() 12037 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 12038 ctx = rctx // use context from middleware stack in children 12039 return obj.Desc, nil 12040 }) 12041 12042 if resTmp == nil { 12043 return graphql.Null 12044 } 12045 res := resTmp.(*otherpkg.Scalar) 12046 fc.Result = res 12047 return ec.marshalOWrappedScalar2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚋotherpkgᚐScalar(ctx, field.Selections, res) 12048 } 12049 12050 func (ec *executionContext) fieldContext_WrappedStruct_desc(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 12051 fc = &graphql.FieldContext{ 12052 Object: "WrappedStruct", 12053 Field: field, 12054 IsMethod: false, 12055 IsResolver: false, 12056 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 12057 return nil, errors.New("field of type WrappedScalar does not have child fields") 12058 }, 12059 } 12060 return fc, nil 12061 } 12062 12063 func (ec *executionContext) _XXIt_id(ctx context.Context, field graphql.CollectedField, obj *XXIt) (ret graphql.Marshaler) { 12064 fc, err := ec.fieldContext_XXIt_id(ctx, field) 12065 if err != nil { 12066 return graphql.Null 12067 } 12068 ctx = graphql.WithFieldContext(ctx, fc) 12069 defer func() { 12070 if r := recover(); r != nil { 12071 ec.Error(ctx, ec.Recover(ctx, r)) 12072 ret = graphql.Null 12073 } 12074 }() 12075 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 12076 ctx = rctx // use context from middleware stack in children 12077 return obj.ID, nil 12078 }) 12079 12080 if resTmp == nil { 12081 if !graphql.HasFieldError(ctx, fc) { 12082 ec.Errorf(ctx, "must not be null") 12083 } 12084 return graphql.Null 12085 } 12086 res := resTmp.(string) 12087 fc.Result = res 12088 return ec.marshalNID2string(ctx, field.Selections, res) 12089 } 12090 12091 func (ec *executionContext) fieldContext_XXIt_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 12092 fc = &graphql.FieldContext{ 12093 Object: "XXIt", 12094 Field: field, 12095 IsMethod: false, 12096 IsResolver: false, 12097 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 12098 return nil, errors.New("field of type ID does not have child fields") 12099 }, 12100 } 12101 return fc, nil 12102 } 12103 12104 func (ec *executionContext) _XxIt_id(ctx context.Context, field graphql.CollectedField, obj *XxIt) (ret graphql.Marshaler) { 12105 fc, err := ec.fieldContext_XxIt_id(ctx, field) 12106 if err != nil { 12107 return graphql.Null 12108 } 12109 ctx = graphql.WithFieldContext(ctx, fc) 12110 defer func() { 12111 if r := recover(); r != nil { 12112 ec.Error(ctx, ec.Recover(ctx, r)) 12113 ret = graphql.Null 12114 } 12115 }() 12116 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 12117 ctx = rctx // use context from middleware stack in children 12118 return obj.ID, nil 12119 }) 12120 12121 if resTmp == nil { 12122 if !graphql.HasFieldError(ctx, fc) { 12123 ec.Errorf(ctx, "must not be null") 12124 } 12125 return graphql.Null 12126 } 12127 res := resTmp.(string) 12128 fc.Result = res 12129 return ec.marshalNID2string(ctx, field.Selections, res) 12130 } 12131 12132 func (ec *executionContext) fieldContext_XxIt_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 12133 fc = &graphql.FieldContext{ 12134 Object: "XxIt", 12135 Field: field, 12136 IsMethod: false, 12137 IsResolver: false, 12138 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 12139 return nil, errors.New("field of type ID does not have child fields") 12140 }, 12141 } 12142 return fc, nil 12143 } 12144 12145 func (ec *executionContext) ___Directive_name(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) { 12146 fc, err := ec.fieldContext___Directive_name(ctx, field) 12147 if err != nil { 12148 return graphql.Null 12149 } 12150 ctx = graphql.WithFieldContext(ctx, fc) 12151 defer func() { 12152 if r := recover(); r != nil { 12153 ec.Error(ctx, ec.Recover(ctx, r)) 12154 ret = graphql.Null 12155 } 12156 }() 12157 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 12158 ctx = rctx // use context from middleware stack in children 12159 return obj.Name, nil 12160 }) 12161 12162 if resTmp == nil { 12163 if !graphql.HasFieldError(ctx, fc) { 12164 ec.Errorf(ctx, "must not be null") 12165 } 12166 return graphql.Null 12167 } 12168 res := resTmp.(string) 12169 fc.Result = res 12170 return ec.marshalNString2string(ctx, field.Selections, res) 12171 } 12172 12173 func (ec *executionContext) fieldContext___Directive_name(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 12174 fc = &graphql.FieldContext{ 12175 Object: "__Directive", 12176 Field: field, 12177 IsMethod: false, 12178 IsResolver: false, 12179 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 12180 return nil, errors.New("field of type String does not have child fields") 12181 }, 12182 } 12183 return fc, nil 12184 } 12185 12186 func (ec *executionContext) ___Directive_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) { 12187 fc, err := ec.fieldContext___Directive_description(ctx, field) 12188 if err != nil { 12189 return graphql.Null 12190 } 12191 ctx = graphql.WithFieldContext(ctx, fc) 12192 defer func() { 12193 if r := recover(); r != nil { 12194 ec.Error(ctx, ec.Recover(ctx, r)) 12195 ret = graphql.Null 12196 } 12197 }() 12198 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 12199 ctx = rctx // use context from middleware stack in children 12200 return obj.Description(), nil 12201 }) 12202 12203 if resTmp == nil { 12204 return graphql.Null 12205 } 12206 res := resTmp.(*string) 12207 fc.Result = res 12208 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 12209 } 12210 12211 func (ec *executionContext) fieldContext___Directive_description(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 12212 fc = &graphql.FieldContext{ 12213 Object: "__Directive", 12214 Field: field, 12215 IsMethod: true, 12216 IsResolver: false, 12217 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 12218 return nil, errors.New("field of type String does not have child fields") 12219 }, 12220 } 12221 return fc, nil 12222 } 12223 12224 func (ec *executionContext) ___Directive_locations(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) { 12225 fc, err := ec.fieldContext___Directive_locations(ctx, field) 12226 if err != nil { 12227 return graphql.Null 12228 } 12229 ctx = graphql.WithFieldContext(ctx, fc) 12230 defer func() { 12231 if r := recover(); r != nil { 12232 ec.Error(ctx, ec.Recover(ctx, r)) 12233 ret = graphql.Null 12234 } 12235 }() 12236 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 12237 ctx = rctx // use context from middleware stack in children 12238 return obj.Locations, nil 12239 }) 12240 12241 if resTmp == nil { 12242 if !graphql.HasFieldError(ctx, fc) { 12243 ec.Errorf(ctx, "must not be null") 12244 } 12245 return graphql.Null 12246 } 12247 res := resTmp.([]string) 12248 fc.Result = res 12249 return ec.marshalN__DirectiveLocation2ᚕstringᚄ(ctx, field.Selections, res) 12250 } 12251 12252 func (ec *executionContext) fieldContext___Directive_locations(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 12253 fc = &graphql.FieldContext{ 12254 Object: "__Directive", 12255 Field: field, 12256 IsMethod: false, 12257 IsResolver: false, 12258 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 12259 return nil, errors.New("field of type __DirectiveLocation does not have child fields") 12260 }, 12261 } 12262 return fc, nil 12263 } 12264 12265 func (ec *executionContext) ___Directive_args(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) { 12266 fc, err := ec.fieldContext___Directive_args(ctx, field) 12267 if err != nil { 12268 return graphql.Null 12269 } 12270 ctx = graphql.WithFieldContext(ctx, fc) 12271 defer func() { 12272 if r := recover(); r != nil { 12273 ec.Error(ctx, ec.Recover(ctx, r)) 12274 ret = graphql.Null 12275 } 12276 }() 12277 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 12278 ctx = rctx // use context from middleware stack in children 12279 return obj.Args, nil 12280 }) 12281 12282 if resTmp == nil { 12283 if !graphql.HasFieldError(ctx, fc) { 12284 ec.Errorf(ctx, "must not be null") 12285 } 12286 return graphql.Null 12287 } 12288 res := resTmp.([]introspection.InputValue) 12289 fc.Result = res 12290 return ec.marshalN__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx, field.Selections, res) 12291 } 12292 12293 func (ec *executionContext) fieldContext___Directive_args(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 12294 fc = &graphql.FieldContext{ 12295 Object: "__Directive", 12296 Field: field, 12297 IsMethod: false, 12298 IsResolver: false, 12299 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 12300 switch field.Name { 12301 case "name": 12302 return ec.fieldContext___InputValue_name(ctx, field) 12303 case "description": 12304 return ec.fieldContext___InputValue_description(ctx, field) 12305 case "type": 12306 return ec.fieldContext___InputValue_type(ctx, field) 12307 case "defaultValue": 12308 return ec.fieldContext___InputValue_defaultValue(ctx, field) 12309 } 12310 return nil, fmt.Errorf("no field named %q was found under type __InputValue", field.Name) 12311 }, 12312 } 12313 return fc, nil 12314 } 12315 12316 func (ec *executionContext) ___Directive_isRepeatable(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) { 12317 fc, err := ec.fieldContext___Directive_isRepeatable(ctx, field) 12318 if err != nil { 12319 return graphql.Null 12320 } 12321 ctx = graphql.WithFieldContext(ctx, fc) 12322 defer func() { 12323 if r := recover(); r != nil { 12324 ec.Error(ctx, ec.Recover(ctx, r)) 12325 ret = graphql.Null 12326 } 12327 }() 12328 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 12329 ctx = rctx // use context from middleware stack in children 12330 return obj.IsRepeatable, nil 12331 }) 12332 12333 if resTmp == nil { 12334 if !graphql.HasFieldError(ctx, fc) { 12335 ec.Errorf(ctx, "must not be null") 12336 } 12337 return graphql.Null 12338 } 12339 res := resTmp.(bool) 12340 fc.Result = res 12341 return ec.marshalNBoolean2bool(ctx, field.Selections, res) 12342 } 12343 12344 func (ec *executionContext) fieldContext___Directive_isRepeatable(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 12345 fc = &graphql.FieldContext{ 12346 Object: "__Directive", 12347 Field: field, 12348 IsMethod: false, 12349 IsResolver: false, 12350 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 12351 return nil, errors.New("field of type Boolean does not have child fields") 12352 }, 12353 } 12354 return fc, nil 12355 } 12356 12357 func (ec *executionContext) ___EnumValue_name(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) { 12358 fc, err := ec.fieldContext___EnumValue_name(ctx, field) 12359 if err != nil { 12360 return graphql.Null 12361 } 12362 ctx = graphql.WithFieldContext(ctx, fc) 12363 defer func() { 12364 if r := recover(); r != nil { 12365 ec.Error(ctx, ec.Recover(ctx, r)) 12366 ret = graphql.Null 12367 } 12368 }() 12369 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 12370 ctx = rctx // use context from middleware stack in children 12371 return obj.Name, nil 12372 }) 12373 12374 if resTmp == nil { 12375 if !graphql.HasFieldError(ctx, fc) { 12376 ec.Errorf(ctx, "must not be null") 12377 } 12378 return graphql.Null 12379 } 12380 res := resTmp.(string) 12381 fc.Result = res 12382 return ec.marshalNString2string(ctx, field.Selections, res) 12383 } 12384 12385 func (ec *executionContext) fieldContext___EnumValue_name(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 12386 fc = &graphql.FieldContext{ 12387 Object: "__EnumValue", 12388 Field: field, 12389 IsMethod: false, 12390 IsResolver: false, 12391 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 12392 return nil, errors.New("field of type String does not have child fields") 12393 }, 12394 } 12395 return fc, nil 12396 } 12397 12398 func (ec *executionContext) ___EnumValue_description(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) { 12399 fc, err := ec.fieldContext___EnumValue_description(ctx, field) 12400 if err != nil { 12401 return graphql.Null 12402 } 12403 ctx = graphql.WithFieldContext(ctx, fc) 12404 defer func() { 12405 if r := recover(); r != nil { 12406 ec.Error(ctx, ec.Recover(ctx, r)) 12407 ret = graphql.Null 12408 } 12409 }() 12410 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 12411 ctx = rctx // use context from middleware stack in children 12412 return obj.Description(), nil 12413 }) 12414 12415 if resTmp == nil { 12416 return graphql.Null 12417 } 12418 res := resTmp.(*string) 12419 fc.Result = res 12420 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 12421 } 12422 12423 func (ec *executionContext) fieldContext___EnumValue_description(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 12424 fc = &graphql.FieldContext{ 12425 Object: "__EnumValue", 12426 Field: field, 12427 IsMethod: true, 12428 IsResolver: false, 12429 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 12430 return nil, errors.New("field of type String does not have child fields") 12431 }, 12432 } 12433 return fc, nil 12434 } 12435 12436 func (ec *executionContext) ___EnumValue_isDeprecated(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) { 12437 fc, err := ec.fieldContext___EnumValue_isDeprecated(ctx, field) 12438 if err != nil { 12439 return graphql.Null 12440 } 12441 ctx = graphql.WithFieldContext(ctx, fc) 12442 defer func() { 12443 if r := recover(); r != nil { 12444 ec.Error(ctx, ec.Recover(ctx, r)) 12445 ret = graphql.Null 12446 } 12447 }() 12448 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 12449 ctx = rctx // use context from middleware stack in children 12450 return obj.IsDeprecated(), nil 12451 }) 12452 12453 if resTmp == nil { 12454 if !graphql.HasFieldError(ctx, fc) { 12455 ec.Errorf(ctx, "must not be null") 12456 } 12457 return graphql.Null 12458 } 12459 res := resTmp.(bool) 12460 fc.Result = res 12461 return ec.marshalNBoolean2bool(ctx, field.Selections, res) 12462 } 12463 12464 func (ec *executionContext) fieldContext___EnumValue_isDeprecated(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 12465 fc = &graphql.FieldContext{ 12466 Object: "__EnumValue", 12467 Field: field, 12468 IsMethod: true, 12469 IsResolver: false, 12470 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 12471 return nil, errors.New("field of type Boolean does not have child fields") 12472 }, 12473 } 12474 return fc, nil 12475 } 12476 12477 func (ec *executionContext) ___EnumValue_deprecationReason(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) { 12478 fc, err := ec.fieldContext___EnumValue_deprecationReason(ctx, field) 12479 if err != nil { 12480 return graphql.Null 12481 } 12482 ctx = graphql.WithFieldContext(ctx, fc) 12483 defer func() { 12484 if r := recover(); r != nil { 12485 ec.Error(ctx, ec.Recover(ctx, r)) 12486 ret = graphql.Null 12487 } 12488 }() 12489 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 12490 ctx = rctx // use context from middleware stack in children 12491 return obj.DeprecationReason(), nil 12492 }) 12493 12494 if resTmp == nil { 12495 return graphql.Null 12496 } 12497 res := resTmp.(*string) 12498 fc.Result = res 12499 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 12500 } 12501 12502 func (ec *executionContext) fieldContext___EnumValue_deprecationReason(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 12503 fc = &graphql.FieldContext{ 12504 Object: "__EnumValue", 12505 Field: field, 12506 IsMethod: true, 12507 IsResolver: false, 12508 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 12509 return nil, errors.New("field of type String does not have child fields") 12510 }, 12511 } 12512 return fc, nil 12513 } 12514 12515 func (ec *executionContext) ___Field_name(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { 12516 fc, err := ec.fieldContext___Field_name(ctx, field) 12517 if err != nil { 12518 return graphql.Null 12519 } 12520 ctx = graphql.WithFieldContext(ctx, fc) 12521 defer func() { 12522 if r := recover(); r != nil { 12523 ec.Error(ctx, ec.Recover(ctx, r)) 12524 ret = graphql.Null 12525 } 12526 }() 12527 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 12528 ctx = rctx // use context from middleware stack in children 12529 return obj.Name, nil 12530 }) 12531 12532 if resTmp == nil { 12533 if !graphql.HasFieldError(ctx, fc) { 12534 ec.Errorf(ctx, "must not be null") 12535 } 12536 return graphql.Null 12537 } 12538 res := resTmp.(string) 12539 fc.Result = res 12540 return ec.marshalNString2string(ctx, field.Selections, res) 12541 } 12542 12543 func (ec *executionContext) fieldContext___Field_name(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 12544 fc = &graphql.FieldContext{ 12545 Object: "__Field", 12546 Field: field, 12547 IsMethod: false, 12548 IsResolver: false, 12549 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 12550 return nil, errors.New("field of type String does not have child fields") 12551 }, 12552 } 12553 return fc, nil 12554 } 12555 12556 func (ec *executionContext) ___Field_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { 12557 fc, err := ec.fieldContext___Field_description(ctx, field) 12558 if err != nil { 12559 return graphql.Null 12560 } 12561 ctx = graphql.WithFieldContext(ctx, fc) 12562 defer func() { 12563 if r := recover(); r != nil { 12564 ec.Error(ctx, ec.Recover(ctx, r)) 12565 ret = graphql.Null 12566 } 12567 }() 12568 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 12569 ctx = rctx // use context from middleware stack in children 12570 return obj.Description(), nil 12571 }) 12572 12573 if resTmp == nil { 12574 return graphql.Null 12575 } 12576 res := resTmp.(*string) 12577 fc.Result = res 12578 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 12579 } 12580 12581 func (ec *executionContext) fieldContext___Field_description(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 12582 fc = &graphql.FieldContext{ 12583 Object: "__Field", 12584 Field: field, 12585 IsMethod: true, 12586 IsResolver: false, 12587 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 12588 return nil, errors.New("field of type String does not have child fields") 12589 }, 12590 } 12591 return fc, nil 12592 } 12593 12594 func (ec *executionContext) ___Field_args(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { 12595 fc, err := ec.fieldContext___Field_args(ctx, field) 12596 if err != nil { 12597 return graphql.Null 12598 } 12599 ctx = graphql.WithFieldContext(ctx, fc) 12600 defer func() { 12601 if r := recover(); r != nil { 12602 ec.Error(ctx, ec.Recover(ctx, r)) 12603 ret = graphql.Null 12604 } 12605 }() 12606 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 12607 ctx = rctx // use context from middleware stack in children 12608 return obj.Args, nil 12609 }) 12610 12611 if resTmp == nil { 12612 if !graphql.HasFieldError(ctx, fc) { 12613 ec.Errorf(ctx, "must not be null") 12614 } 12615 return graphql.Null 12616 } 12617 res := resTmp.([]introspection.InputValue) 12618 fc.Result = res 12619 return ec.marshalN__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx, field.Selections, res) 12620 } 12621 12622 func (ec *executionContext) fieldContext___Field_args(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 12623 fc = &graphql.FieldContext{ 12624 Object: "__Field", 12625 Field: field, 12626 IsMethod: false, 12627 IsResolver: false, 12628 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 12629 switch field.Name { 12630 case "name": 12631 return ec.fieldContext___InputValue_name(ctx, field) 12632 case "description": 12633 return ec.fieldContext___InputValue_description(ctx, field) 12634 case "type": 12635 return ec.fieldContext___InputValue_type(ctx, field) 12636 case "defaultValue": 12637 return ec.fieldContext___InputValue_defaultValue(ctx, field) 12638 } 12639 return nil, fmt.Errorf("no field named %q was found under type __InputValue", field.Name) 12640 }, 12641 } 12642 return fc, nil 12643 } 12644 12645 func (ec *executionContext) ___Field_type(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { 12646 fc, err := ec.fieldContext___Field_type(ctx, field) 12647 if err != nil { 12648 return graphql.Null 12649 } 12650 ctx = graphql.WithFieldContext(ctx, fc) 12651 defer func() { 12652 if r := recover(); r != nil { 12653 ec.Error(ctx, ec.Recover(ctx, r)) 12654 ret = graphql.Null 12655 } 12656 }() 12657 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 12658 ctx = rctx // use context from middleware stack in children 12659 return obj.Type, nil 12660 }) 12661 12662 if resTmp == nil { 12663 if !graphql.HasFieldError(ctx, fc) { 12664 ec.Errorf(ctx, "must not be null") 12665 } 12666 return graphql.Null 12667 } 12668 res := resTmp.(*introspection.Type) 12669 fc.Result = res 12670 return ec.marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) 12671 } 12672 12673 func (ec *executionContext) fieldContext___Field_type(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 12674 fc = &graphql.FieldContext{ 12675 Object: "__Field", 12676 Field: field, 12677 IsMethod: false, 12678 IsResolver: false, 12679 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 12680 switch field.Name { 12681 case "kind": 12682 return ec.fieldContext___Type_kind(ctx, field) 12683 case "name": 12684 return ec.fieldContext___Type_name(ctx, field) 12685 case "description": 12686 return ec.fieldContext___Type_description(ctx, field) 12687 case "fields": 12688 return ec.fieldContext___Type_fields(ctx, field) 12689 case "interfaces": 12690 return ec.fieldContext___Type_interfaces(ctx, field) 12691 case "possibleTypes": 12692 return ec.fieldContext___Type_possibleTypes(ctx, field) 12693 case "enumValues": 12694 return ec.fieldContext___Type_enumValues(ctx, field) 12695 case "inputFields": 12696 return ec.fieldContext___Type_inputFields(ctx, field) 12697 case "ofType": 12698 return ec.fieldContext___Type_ofType(ctx, field) 12699 case "specifiedByURL": 12700 return ec.fieldContext___Type_specifiedByURL(ctx, field) 12701 } 12702 return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) 12703 }, 12704 } 12705 return fc, nil 12706 } 12707 12708 func (ec *executionContext) ___Field_isDeprecated(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { 12709 fc, err := ec.fieldContext___Field_isDeprecated(ctx, field) 12710 if err != nil { 12711 return graphql.Null 12712 } 12713 ctx = graphql.WithFieldContext(ctx, fc) 12714 defer func() { 12715 if r := recover(); r != nil { 12716 ec.Error(ctx, ec.Recover(ctx, r)) 12717 ret = graphql.Null 12718 } 12719 }() 12720 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 12721 ctx = rctx // use context from middleware stack in children 12722 return obj.IsDeprecated(), nil 12723 }) 12724 12725 if resTmp == nil { 12726 if !graphql.HasFieldError(ctx, fc) { 12727 ec.Errorf(ctx, "must not be null") 12728 } 12729 return graphql.Null 12730 } 12731 res := resTmp.(bool) 12732 fc.Result = res 12733 return ec.marshalNBoolean2bool(ctx, field.Selections, res) 12734 } 12735 12736 func (ec *executionContext) fieldContext___Field_isDeprecated(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 12737 fc = &graphql.FieldContext{ 12738 Object: "__Field", 12739 Field: field, 12740 IsMethod: true, 12741 IsResolver: false, 12742 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 12743 return nil, errors.New("field of type Boolean does not have child fields") 12744 }, 12745 } 12746 return fc, nil 12747 } 12748 12749 func (ec *executionContext) ___Field_deprecationReason(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { 12750 fc, err := ec.fieldContext___Field_deprecationReason(ctx, field) 12751 if err != nil { 12752 return graphql.Null 12753 } 12754 ctx = graphql.WithFieldContext(ctx, fc) 12755 defer func() { 12756 if r := recover(); r != nil { 12757 ec.Error(ctx, ec.Recover(ctx, r)) 12758 ret = graphql.Null 12759 } 12760 }() 12761 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 12762 ctx = rctx // use context from middleware stack in children 12763 return obj.DeprecationReason(), nil 12764 }) 12765 12766 if resTmp == nil { 12767 return graphql.Null 12768 } 12769 res := resTmp.(*string) 12770 fc.Result = res 12771 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 12772 } 12773 12774 func (ec *executionContext) fieldContext___Field_deprecationReason(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 12775 fc = &graphql.FieldContext{ 12776 Object: "__Field", 12777 Field: field, 12778 IsMethod: true, 12779 IsResolver: false, 12780 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 12781 return nil, errors.New("field of type String does not have child fields") 12782 }, 12783 } 12784 return fc, nil 12785 } 12786 12787 func (ec *executionContext) ___InputValue_name(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) { 12788 fc, err := ec.fieldContext___InputValue_name(ctx, field) 12789 if err != nil { 12790 return graphql.Null 12791 } 12792 ctx = graphql.WithFieldContext(ctx, fc) 12793 defer func() { 12794 if r := recover(); r != nil { 12795 ec.Error(ctx, ec.Recover(ctx, r)) 12796 ret = graphql.Null 12797 } 12798 }() 12799 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 12800 ctx = rctx // use context from middleware stack in children 12801 return obj.Name, nil 12802 }) 12803 12804 if resTmp == nil { 12805 if !graphql.HasFieldError(ctx, fc) { 12806 ec.Errorf(ctx, "must not be null") 12807 } 12808 return graphql.Null 12809 } 12810 res := resTmp.(string) 12811 fc.Result = res 12812 return ec.marshalNString2string(ctx, field.Selections, res) 12813 } 12814 12815 func (ec *executionContext) fieldContext___InputValue_name(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 12816 fc = &graphql.FieldContext{ 12817 Object: "__InputValue", 12818 Field: field, 12819 IsMethod: false, 12820 IsResolver: false, 12821 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 12822 return nil, errors.New("field of type String does not have child fields") 12823 }, 12824 } 12825 return fc, nil 12826 } 12827 12828 func (ec *executionContext) ___InputValue_description(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) { 12829 fc, err := ec.fieldContext___InputValue_description(ctx, field) 12830 if err != nil { 12831 return graphql.Null 12832 } 12833 ctx = graphql.WithFieldContext(ctx, fc) 12834 defer func() { 12835 if r := recover(); r != nil { 12836 ec.Error(ctx, ec.Recover(ctx, r)) 12837 ret = graphql.Null 12838 } 12839 }() 12840 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 12841 ctx = rctx // use context from middleware stack in children 12842 return obj.Description(), nil 12843 }) 12844 12845 if resTmp == nil { 12846 return graphql.Null 12847 } 12848 res := resTmp.(*string) 12849 fc.Result = res 12850 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 12851 } 12852 12853 func (ec *executionContext) fieldContext___InputValue_description(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 12854 fc = &graphql.FieldContext{ 12855 Object: "__InputValue", 12856 Field: field, 12857 IsMethod: true, 12858 IsResolver: false, 12859 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 12860 return nil, errors.New("field of type String does not have child fields") 12861 }, 12862 } 12863 return fc, nil 12864 } 12865 12866 func (ec *executionContext) ___InputValue_type(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) { 12867 fc, err := ec.fieldContext___InputValue_type(ctx, field) 12868 if err != nil { 12869 return graphql.Null 12870 } 12871 ctx = graphql.WithFieldContext(ctx, fc) 12872 defer func() { 12873 if r := recover(); r != nil { 12874 ec.Error(ctx, ec.Recover(ctx, r)) 12875 ret = graphql.Null 12876 } 12877 }() 12878 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 12879 ctx = rctx // use context from middleware stack in children 12880 return obj.Type, nil 12881 }) 12882 12883 if resTmp == nil { 12884 if !graphql.HasFieldError(ctx, fc) { 12885 ec.Errorf(ctx, "must not be null") 12886 } 12887 return graphql.Null 12888 } 12889 res := resTmp.(*introspection.Type) 12890 fc.Result = res 12891 return ec.marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) 12892 } 12893 12894 func (ec *executionContext) fieldContext___InputValue_type(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 12895 fc = &graphql.FieldContext{ 12896 Object: "__InputValue", 12897 Field: field, 12898 IsMethod: false, 12899 IsResolver: false, 12900 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 12901 switch field.Name { 12902 case "kind": 12903 return ec.fieldContext___Type_kind(ctx, field) 12904 case "name": 12905 return ec.fieldContext___Type_name(ctx, field) 12906 case "description": 12907 return ec.fieldContext___Type_description(ctx, field) 12908 case "fields": 12909 return ec.fieldContext___Type_fields(ctx, field) 12910 case "interfaces": 12911 return ec.fieldContext___Type_interfaces(ctx, field) 12912 case "possibleTypes": 12913 return ec.fieldContext___Type_possibleTypes(ctx, field) 12914 case "enumValues": 12915 return ec.fieldContext___Type_enumValues(ctx, field) 12916 case "inputFields": 12917 return ec.fieldContext___Type_inputFields(ctx, field) 12918 case "ofType": 12919 return ec.fieldContext___Type_ofType(ctx, field) 12920 case "specifiedByURL": 12921 return ec.fieldContext___Type_specifiedByURL(ctx, field) 12922 } 12923 return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) 12924 }, 12925 } 12926 return fc, nil 12927 } 12928 12929 func (ec *executionContext) ___InputValue_defaultValue(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) { 12930 fc, err := ec.fieldContext___InputValue_defaultValue(ctx, field) 12931 if err != nil { 12932 return graphql.Null 12933 } 12934 ctx = graphql.WithFieldContext(ctx, fc) 12935 defer func() { 12936 if r := recover(); r != nil { 12937 ec.Error(ctx, ec.Recover(ctx, r)) 12938 ret = graphql.Null 12939 } 12940 }() 12941 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 12942 ctx = rctx // use context from middleware stack in children 12943 return obj.DefaultValue, nil 12944 }) 12945 12946 if resTmp == nil { 12947 return graphql.Null 12948 } 12949 res := resTmp.(*string) 12950 fc.Result = res 12951 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 12952 } 12953 12954 func (ec *executionContext) fieldContext___InputValue_defaultValue(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 12955 fc = &graphql.FieldContext{ 12956 Object: "__InputValue", 12957 Field: field, 12958 IsMethod: false, 12959 IsResolver: false, 12960 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 12961 return nil, errors.New("field of type String does not have child fields") 12962 }, 12963 } 12964 return fc, nil 12965 } 12966 12967 func (ec *executionContext) ___Schema_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { 12968 fc, err := ec.fieldContext___Schema_description(ctx, field) 12969 if err != nil { 12970 return graphql.Null 12971 } 12972 ctx = graphql.WithFieldContext(ctx, fc) 12973 defer func() { 12974 if r := recover(); r != nil { 12975 ec.Error(ctx, ec.Recover(ctx, r)) 12976 ret = graphql.Null 12977 } 12978 }() 12979 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 12980 ctx = rctx // use context from middleware stack in children 12981 return obj.Description(), nil 12982 }) 12983 12984 if resTmp == nil { 12985 return graphql.Null 12986 } 12987 res := resTmp.(*string) 12988 fc.Result = res 12989 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 12990 } 12991 12992 func (ec *executionContext) fieldContext___Schema_description(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 12993 fc = &graphql.FieldContext{ 12994 Object: "__Schema", 12995 Field: field, 12996 IsMethod: true, 12997 IsResolver: false, 12998 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 12999 return nil, errors.New("field of type String does not have child fields") 13000 }, 13001 } 13002 return fc, nil 13003 } 13004 13005 func (ec *executionContext) ___Schema_types(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { 13006 fc, err := ec.fieldContext___Schema_types(ctx, field) 13007 if err != nil { 13008 return graphql.Null 13009 } 13010 ctx = graphql.WithFieldContext(ctx, fc) 13011 defer func() { 13012 if r := recover(); r != nil { 13013 ec.Error(ctx, ec.Recover(ctx, r)) 13014 ret = graphql.Null 13015 } 13016 }() 13017 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 13018 ctx = rctx // use context from middleware stack in children 13019 return obj.Types(), nil 13020 }) 13021 13022 if resTmp == nil { 13023 if !graphql.HasFieldError(ctx, fc) { 13024 ec.Errorf(ctx, "must not be null") 13025 } 13026 return graphql.Null 13027 } 13028 res := resTmp.([]introspection.Type) 13029 fc.Result = res 13030 return ec.marshalN__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx, field.Selections, res) 13031 } 13032 13033 func (ec *executionContext) fieldContext___Schema_types(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 13034 fc = &graphql.FieldContext{ 13035 Object: "__Schema", 13036 Field: field, 13037 IsMethod: true, 13038 IsResolver: false, 13039 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 13040 switch field.Name { 13041 case "kind": 13042 return ec.fieldContext___Type_kind(ctx, field) 13043 case "name": 13044 return ec.fieldContext___Type_name(ctx, field) 13045 case "description": 13046 return ec.fieldContext___Type_description(ctx, field) 13047 case "fields": 13048 return ec.fieldContext___Type_fields(ctx, field) 13049 case "interfaces": 13050 return ec.fieldContext___Type_interfaces(ctx, field) 13051 case "possibleTypes": 13052 return ec.fieldContext___Type_possibleTypes(ctx, field) 13053 case "enumValues": 13054 return ec.fieldContext___Type_enumValues(ctx, field) 13055 case "inputFields": 13056 return ec.fieldContext___Type_inputFields(ctx, field) 13057 case "ofType": 13058 return ec.fieldContext___Type_ofType(ctx, field) 13059 case "specifiedByURL": 13060 return ec.fieldContext___Type_specifiedByURL(ctx, field) 13061 } 13062 return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) 13063 }, 13064 } 13065 return fc, nil 13066 } 13067 13068 func (ec *executionContext) ___Schema_queryType(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { 13069 fc, err := ec.fieldContext___Schema_queryType(ctx, field) 13070 if err != nil { 13071 return graphql.Null 13072 } 13073 ctx = graphql.WithFieldContext(ctx, fc) 13074 defer func() { 13075 if r := recover(); r != nil { 13076 ec.Error(ctx, ec.Recover(ctx, r)) 13077 ret = graphql.Null 13078 } 13079 }() 13080 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 13081 ctx = rctx // use context from middleware stack in children 13082 return obj.QueryType(), nil 13083 }) 13084 13085 if resTmp == nil { 13086 if !graphql.HasFieldError(ctx, fc) { 13087 ec.Errorf(ctx, "must not be null") 13088 } 13089 return graphql.Null 13090 } 13091 res := resTmp.(*introspection.Type) 13092 fc.Result = res 13093 return ec.marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) 13094 } 13095 13096 func (ec *executionContext) fieldContext___Schema_queryType(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 13097 fc = &graphql.FieldContext{ 13098 Object: "__Schema", 13099 Field: field, 13100 IsMethod: true, 13101 IsResolver: false, 13102 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 13103 switch field.Name { 13104 case "kind": 13105 return ec.fieldContext___Type_kind(ctx, field) 13106 case "name": 13107 return ec.fieldContext___Type_name(ctx, field) 13108 case "description": 13109 return ec.fieldContext___Type_description(ctx, field) 13110 case "fields": 13111 return ec.fieldContext___Type_fields(ctx, field) 13112 case "interfaces": 13113 return ec.fieldContext___Type_interfaces(ctx, field) 13114 case "possibleTypes": 13115 return ec.fieldContext___Type_possibleTypes(ctx, field) 13116 case "enumValues": 13117 return ec.fieldContext___Type_enumValues(ctx, field) 13118 case "inputFields": 13119 return ec.fieldContext___Type_inputFields(ctx, field) 13120 case "ofType": 13121 return ec.fieldContext___Type_ofType(ctx, field) 13122 case "specifiedByURL": 13123 return ec.fieldContext___Type_specifiedByURL(ctx, field) 13124 } 13125 return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) 13126 }, 13127 } 13128 return fc, nil 13129 } 13130 13131 func (ec *executionContext) ___Schema_mutationType(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { 13132 fc, err := ec.fieldContext___Schema_mutationType(ctx, field) 13133 if err != nil { 13134 return graphql.Null 13135 } 13136 ctx = graphql.WithFieldContext(ctx, fc) 13137 defer func() { 13138 if r := recover(); r != nil { 13139 ec.Error(ctx, ec.Recover(ctx, r)) 13140 ret = graphql.Null 13141 } 13142 }() 13143 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 13144 ctx = rctx // use context from middleware stack in children 13145 return obj.MutationType(), nil 13146 }) 13147 13148 if resTmp == nil { 13149 return graphql.Null 13150 } 13151 res := resTmp.(*introspection.Type) 13152 fc.Result = res 13153 return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) 13154 } 13155 13156 func (ec *executionContext) fieldContext___Schema_mutationType(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 13157 fc = &graphql.FieldContext{ 13158 Object: "__Schema", 13159 Field: field, 13160 IsMethod: true, 13161 IsResolver: false, 13162 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 13163 switch field.Name { 13164 case "kind": 13165 return ec.fieldContext___Type_kind(ctx, field) 13166 case "name": 13167 return ec.fieldContext___Type_name(ctx, field) 13168 case "description": 13169 return ec.fieldContext___Type_description(ctx, field) 13170 case "fields": 13171 return ec.fieldContext___Type_fields(ctx, field) 13172 case "interfaces": 13173 return ec.fieldContext___Type_interfaces(ctx, field) 13174 case "possibleTypes": 13175 return ec.fieldContext___Type_possibleTypes(ctx, field) 13176 case "enumValues": 13177 return ec.fieldContext___Type_enumValues(ctx, field) 13178 case "inputFields": 13179 return ec.fieldContext___Type_inputFields(ctx, field) 13180 case "ofType": 13181 return ec.fieldContext___Type_ofType(ctx, field) 13182 case "specifiedByURL": 13183 return ec.fieldContext___Type_specifiedByURL(ctx, field) 13184 } 13185 return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) 13186 }, 13187 } 13188 return fc, nil 13189 } 13190 13191 func (ec *executionContext) ___Schema_subscriptionType(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { 13192 fc, err := ec.fieldContext___Schema_subscriptionType(ctx, field) 13193 if err != nil { 13194 return graphql.Null 13195 } 13196 ctx = graphql.WithFieldContext(ctx, fc) 13197 defer func() { 13198 if r := recover(); r != nil { 13199 ec.Error(ctx, ec.Recover(ctx, r)) 13200 ret = graphql.Null 13201 } 13202 }() 13203 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 13204 ctx = rctx // use context from middleware stack in children 13205 return obj.SubscriptionType(), nil 13206 }) 13207 13208 if resTmp == nil { 13209 return graphql.Null 13210 } 13211 res := resTmp.(*introspection.Type) 13212 fc.Result = res 13213 return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) 13214 } 13215 13216 func (ec *executionContext) fieldContext___Schema_subscriptionType(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 13217 fc = &graphql.FieldContext{ 13218 Object: "__Schema", 13219 Field: field, 13220 IsMethod: true, 13221 IsResolver: false, 13222 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 13223 switch field.Name { 13224 case "kind": 13225 return ec.fieldContext___Type_kind(ctx, field) 13226 case "name": 13227 return ec.fieldContext___Type_name(ctx, field) 13228 case "description": 13229 return ec.fieldContext___Type_description(ctx, field) 13230 case "fields": 13231 return ec.fieldContext___Type_fields(ctx, field) 13232 case "interfaces": 13233 return ec.fieldContext___Type_interfaces(ctx, field) 13234 case "possibleTypes": 13235 return ec.fieldContext___Type_possibleTypes(ctx, field) 13236 case "enumValues": 13237 return ec.fieldContext___Type_enumValues(ctx, field) 13238 case "inputFields": 13239 return ec.fieldContext___Type_inputFields(ctx, field) 13240 case "ofType": 13241 return ec.fieldContext___Type_ofType(ctx, field) 13242 case "specifiedByURL": 13243 return ec.fieldContext___Type_specifiedByURL(ctx, field) 13244 } 13245 return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) 13246 }, 13247 } 13248 return fc, nil 13249 } 13250 13251 func (ec *executionContext) ___Schema_directives(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { 13252 fc, err := ec.fieldContext___Schema_directives(ctx, field) 13253 if err != nil { 13254 return graphql.Null 13255 } 13256 ctx = graphql.WithFieldContext(ctx, fc) 13257 defer func() { 13258 if r := recover(); r != nil { 13259 ec.Error(ctx, ec.Recover(ctx, r)) 13260 ret = graphql.Null 13261 } 13262 }() 13263 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 13264 ctx = rctx // use context from middleware stack in children 13265 return obj.Directives(), nil 13266 }) 13267 13268 if resTmp == nil { 13269 if !graphql.HasFieldError(ctx, fc) { 13270 ec.Errorf(ctx, "must not be null") 13271 } 13272 return graphql.Null 13273 } 13274 res := resTmp.([]introspection.Directive) 13275 fc.Result = res 13276 return ec.marshalN__Directive2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirectiveᚄ(ctx, field.Selections, res) 13277 } 13278 13279 func (ec *executionContext) fieldContext___Schema_directives(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 13280 fc = &graphql.FieldContext{ 13281 Object: "__Schema", 13282 Field: field, 13283 IsMethod: true, 13284 IsResolver: false, 13285 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 13286 switch field.Name { 13287 case "name": 13288 return ec.fieldContext___Directive_name(ctx, field) 13289 case "description": 13290 return ec.fieldContext___Directive_description(ctx, field) 13291 case "locations": 13292 return ec.fieldContext___Directive_locations(ctx, field) 13293 case "args": 13294 return ec.fieldContext___Directive_args(ctx, field) 13295 case "isRepeatable": 13296 return ec.fieldContext___Directive_isRepeatable(ctx, field) 13297 } 13298 return nil, fmt.Errorf("no field named %q was found under type __Directive", field.Name) 13299 }, 13300 } 13301 return fc, nil 13302 } 13303 13304 func (ec *executionContext) ___Type_kind(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { 13305 fc, err := ec.fieldContext___Type_kind(ctx, field) 13306 if err != nil { 13307 return graphql.Null 13308 } 13309 ctx = graphql.WithFieldContext(ctx, fc) 13310 defer func() { 13311 if r := recover(); r != nil { 13312 ec.Error(ctx, ec.Recover(ctx, r)) 13313 ret = graphql.Null 13314 } 13315 }() 13316 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 13317 ctx = rctx // use context from middleware stack in children 13318 return obj.Kind(), nil 13319 }) 13320 13321 if resTmp == nil { 13322 if !graphql.HasFieldError(ctx, fc) { 13323 ec.Errorf(ctx, "must not be null") 13324 } 13325 return graphql.Null 13326 } 13327 res := resTmp.(string) 13328 fc.Result = res 13329 return ec.marshalN__TypeKind2string(ctx, field.Selections, res) 13330 } 13331 13332 func (ec *executionContext) fieldContext___Type_kind(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 13333 fc = &graphql.FieldContext{ 13334 Object: "__Type", 13335 Field: field, 13336 IsMethod: true, 13337 IsResolver: false, 13338 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 13339 return nil, errors.New("field of type __TypeKind does not have child fields") 13340 }, 13341 } 13342 return fc, nil 13343 } 13344 13345 func (ec *executionContext) ___Type_name(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { 13346 fc, err := ec.fieldContext___Type_name(ctx, field) 13347 if err != nil { 13348 return graphql.Null 13349 } 13350 ctx = graphql.WithFieldContext(ctx, fc) 13351 defer func() { 13352 if r := recover(); r != nil { 13353 ec.Error(ctx, ec.Recover(ctx, r)) 13354 ret = graphql.Null 13355 } 13356 }() 13357 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 13358 ctx = rctx // use context from middleware stack in children 13359 return obj.Name(), nil 13360 }) 13361 13362 if resTmp == nil { 13363 return graphql.Null 13364 } 13365 res := resTmp.(*string) 13366 fc.Result = res 13367 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 13368 } 13369 13370 func (ec *executionContext) fieldContext___Type_name(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 13371 fc = &graphql.FieldContext{ 13372 Object: "__Type", 13373 Field: field, 13374 IsMethod: true, 13375 IsResolver: false, 13376 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 13377 return nil, errors.New("field of type String does not have child fields") 13378 }, 13379 } 13380 return fc, nil 13381 } 13382 13383 func (ec *executionContext) ___Type_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { 13384 fc, err := ec.fieldContext___Type_description(ctx, field) 13385 if err != nil { 13386 return graphql.Null 13387 } 13388 ctx = graphql.WithFieldContext(ctx, fc) 13389 defer func() { 13390 if r := recover(); r != nil { 13391 ec.Error(ctx, ec.Recover(ctx, r)) 13392 ret = graphql.Null 13393 } 13394 }() 13395 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 13396 ctx = rctx // use context from middleware stack in children 13397 return obj.Description(), nil 13398 }) 13399 13400 if resTmp == nil { 13401 return graphql.Null 13402 } 13403 res := resTmp.(*string) 13404 fc.Result = res 13405 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 13406 } 13407 13408 func (ec *executionContext) fieldContext___Type_description(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 13409 fc = &graphql.FieldContext{ 13410 Object: "__Type", 13411 Field: field, 13412 IsMethod: true, 13413 IsResolver: false, 13414 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 13415 return nil, errors.New("field of type String does not have child fields") 13416 }, 13417 } 13418 return fc, nil 13419 } 13420 13421 func (ec *executionContext) ___Type_fields(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { 13422 fc, err := ec.fieldContext___Type_fields(ctx, field) 13423 if err != nil { 13424 return graphql.Null 13425 } 13426 ctx = graphql.WithFieldContext(ctx, fc) 13427 defer func() { 13428 if r := recover(); r != nil { 13429 ec.Error(ctx, ec.Recover(ctx, r)) 13430 ret = graphql.Null 13431 } 13432 }() 13433 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 13434 ctx = rctx // use context from middleware stack in children 13435 return obj.Fields(fc.Args["includeDeprecated"].(bool)), nil 13436 }) 13437 13438 if resTmp == nil { 13439 return graphql.Null 13440 } 13441 res := resTmp.([]introspection.Field) 13442 fc.Result = res 13443 return ec.marshalO__Field2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐFieldᚄ(ctx, field.Selections, res) 13444 } 13445 13446 func (ec *executionContext) fieldContext___Type_fields(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 13447 fc = &graphql.FieldContext{ 13448 Object: "__Type", 13449 Field: field, 13450 IsMethod: true, 13451 IsResolver: false, 13452 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 13453 switch field.Name { 13454 case "name": 13455 return ec.fieldContext___Field_name(ctx, field) 13456 case "description": 13457 return ec.fieldContext___Field_description(ctx, field) 13458 case "args": 13459 return ec.fieldContext___Field_args(ctx, field) 13460 case "type": 13461 return ec.fieldContext___Field_type(ctx, field) 13462 case "isDeprecated": 13463 return ec.fieldContext___Field_isDeprecated(ctx, field) 13464 case "deprecationReason": 13465 return ec.fieldContext___Field_deprecationReason(ctx, field) 13466 } 13467 return nil, fmt.Errorf("no field named %q was found under type __Field", field.Name) 13468 }, 13469 } 13470 defer func() { 13471 if r := recover(); r != nil { 13472 err = ec.Recover(ctx, r) 13473 ec.Error(ctx, err) 13474 } 13475 }() 13476 ctx = graphql.WithFieldContext(ctx, fc) 13477 if fc.Args, err = ec.field___Type_fields_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 13478 ec.Error(ctx, err) 13479 return 13480 } 13481 return fc, nil 13482 } 13483 13484 func (ec *executionContext) ___Type_interfaces(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { 13485 fc, err := ec.fieldContext___Type_interfaces(ctx, field) 13486 if err != nil { 13487 return graphql.Null 13488 } 13489 ctx = graphql.WithFieldContext(ctx, fc) 13490 defer func() { 13491 if r := recover(); r != nil { 13492 ec.Error(ctx, ec.Recover(ctx, r)) 13493 ret = graphql.Null 13494 } 13495 }() 13496 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 13497 ctx = rctx // use context from middleware stack in children 13498 return obj.Interfaces(), nil 13499 }) 13500 13501 if resTmp == nil { 13502 return graphql.Null 13503 } 13504 res := resTmp.([]introspection.Type) 13505 fc.Result = res 13506 return ec.marshalO__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx, field.Selections, res) 13507 } 13508 13509 func (ec *executionContext) fieldContext___Type_interfaces(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 13510 fc = &graphql.FieldContext{ 13511 Object: "__Type", 13512 Field: field, 13513 IsMethod: true, 13514 IsResolver: false, 13515 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 13516 switch field.Name { 13517 case "kind": 13518 return ec.fieldContext___Type_kind(ctx, field) 13519 case "name": 13520 return ec.fieldContext___Type_name(ctx, field) 13521 case "description": 13522 return ec.fieldContext___Type_description(ctx, field) 13523 case "fields": 13524 return ec.fieldContext___Type_fields(ctx, field) 13525 case "interfaces": 13526 return ec.fieldContext___Type_interfaces(ctx, field) 13527 case "possibleTypes": 13528 return ec.fieldContext___Type_possibleTypes(ctx, field) 13529 case "enumValues": 13530 return ec.fieldContext___Type_enumValues(ctx, field) 13531 case "inputFields": 13532 return ec.fieldContext___Type_inputFields(ctx, field) 13533 case "ofType": 13534 return ec.fieldContext___Type_ofType(ctx, field) 13535 case "specifiedByURL": 13536 return ec.fieldContext___Type_specifiedByURL(ctx, field) 13537 } 13538 return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) 13539 }, 13540 } 13541 return fc, nil 13542 } 13543 13544 func (ec *executionContext) ___Type_possibleTypes(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { 13545 fc, err := ec.fieldContext___Type_possibleTypes(ctx, field) 13546 if err != nil { 13547 return graphql.Null 13548 } 13549 ctx = graphql.WithFieldContext(ctx, fc) 13550 defer func() { 13551 if r := recover(); r != nil { 13552 ec.Error(ctx, ec.Recover(ctx, r)) 13553 ret = graphql.Null 13554 } 13555 }() 13556 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 13557 ctx = rctx // use context from middleware stack in children 13558 return obj.PossibleTypes(), nil 13559 }) 13560 13561 if resTmp == nil { 13562 return graphql.Null 13563 } 13564 res := resTmp.([]introspection.Type) 13565 fc.Result = res 13566 return ec.marshalO__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx, field.Selections, res) 13567 } 13568 13569 func (ec *executionContext) fieldContext___Type_possibleTypes(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 13570 fc = &graphql.FieldContext{ 13571 Object: "__Type", 13572 Field: field, 13573 IsMethod: true, 13574 IsResolver: false, 13575 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 13576 switch field.Name { 13577 case "kind": 13578 return ec.fieldContext___Type_kind(ctx, field) 13579 case "name": 13580 return ec.fieldContext___Type_name(ctx, field) 13581 case "description": 13582 return ec.fieldContext___Type_description(ctx, field) 13583 case "fields": 13584 return ec.fieldContext___Type_fields(ctx, field) 13585 case "interfaces": 13586 return ec.fieldContext___Type_interfaces(ctx, field) 13587 case "possibleTypes": 13588 return ec.fieldContext___Type_possibleTypes(ctx, field) 13589 case "enumValues": 13590 return ec.fieldContext___Type_enumValues(ctx, field) 13591 case "inputFields": 13592 return ec.fieldContext___Type_inputFields(ctx, field) 13593 case "ofType": 13594 return ec.fieldContext___Type_ofType(ctx, field) 13595 case "specifiedByURL": 13596 return ec.fieldContext___Type_specifiedByURL(ctx, field) 13597 } 13598 return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) 13599 }, 13600 } 13601 return fc, nil 13602 } 13603 13604 func (ec *executionContext) ___Type_enumValues(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { 13605 fc, err := ec.fieldContext___Type_enumValues(ctx, field) 13606 if err != nil { 13607 return graphql.Null 13608 } 13609 ctx = graphql.WithFieldContext(ctx, fc) 13610 defer func() { 13611 if r := recover(); r != nil { 13612 ec.Error(ctx, ec.Recover(ctx, r)) 13613 ret = graphql.Null 13614 } 13615 }() 13616 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 13617 ctx = rctx // use context from middleware stack in children 13618 return obj.EnumValues(fc.Args["includeDeprecated"].(bool)), nil 13619 }) 13620 13621 if resTmp == nil { 13622 return graphql.Null 13623 } 13624 res := resTmp.([]introspection.EnumValue) 13625 fc.Result = res 13626 return ec.marshalO__EnumValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValueᚄ(ctx, field.Selections, res) 13627 } 13628 13629 func (ec *executionContext) fieldContext___Type_enumValues(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 13630 fc = &graphql.FieldContext{ 13631 Object: "__Type", 13632 Field: field, 13633 IsMethod: true, 13634 IsResolver: false, 13635 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 13636 switch field.Name { 13637 case "name": 13638 return ec.fieldContext___EnumValue_name(ctx, field) 13639 case "description": 13640 return ec.fieldContext___EnumValue_description(ctx, field) 13641 case "isDeprecated": 13642 return ec.fieldContext___EnumValue_isDeprecated(ctx, field) 13643 case "deprecationReason": 13644 return ec.fieldContext___EnumValue_deprecationReason(ctx, field) 13645 } 13646 return nil, fmt.Errorf("no field named %q was found under type __EnumValue", field.Name) 13647 }, 13648 } 13649 defer func() { 13650 if r := recover(); r != nil { 13651 err = ec.Recover(ctx, r) 13652 ec.Error(ctx, err) 13653 } 13654 }() 13655 ctx = graphql.WithFieldContext(ctx, fc) 13656 if fc.Args, err = ec.field___Type_enumValues_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { 13657 ec.Error(ctx, err) 13658 return 13659 } 13660 return fc, nil 13661 } 13662 13663 func (ec *executionContext) ___Type_inputFields(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { 13664 fc, err := ec.fieldContext___Type_inputFields(ctx, field) 13665 if err != nil { 13666 return graphql.Null 13667 } 13668 ctx = graphql.WithFieldContext(ctx, fc) 13669 defer func() { 13670 if r := recover(); r != nil { 13671 ec.Error(ctx, ec.Recover(ctx, r)) 13672 ret = graphql.Null 13673 } 13674 }() 13675 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 13676 ctx = rctx // use context from middleware stack in children 13677 return obj.InputFields(), nil 13678 }) 13679 13680 if resTmp == nil { 13681 return graphql.Null 13682 } 13683 res := resTmp.([]introspection.InputValue) 13684 fc.Result = res 13685 return ec.marshalO__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx, field.Selections, res) 13686 } 13687 13688 func (ec *executionContext) fieldContext___Type_inputFields(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 13689 fc = &graphql.FieldContext{ 13690 Object: "__Type", 13691 Field: field, 13692 IsMethod: true, 13693 IsResolver: false, 13694 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 13695 switch field.Name { 13696 case "name": 13697 return ec.fieldContext___InputValue_name(ctx, field) 13698 case "description": 13699 return ec.fieldContext___InputValue_description(ctx, field) 13700 case "type": 13701 return ec.fieldContext___InputValue_type(ctx, field) 13702 case "defaultValue": 13703 return ec.fieldContext___InputValue_defaultValue(ctx, field) 13704 } 13705 return nil, fmt.Errorf("no field named %q was found under type __InputValue", field.Name) 13706 }, 13707 } 13708 return fc, nil 13709 } 13710 13711 func (ec *executionContext) ___Type_ofType(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { 13712 fc, err := ec.fieldContext___Type_ofType(ctx, field) 13713 if err != nil { 13714 return graphql.Null 13715 } 13716 ctx = graphql.WithFieldContext(ctx, fc) 13717 defer func() { 13718 if r := recover(); r != nil { 13719 ec.Error(ctx, ec.Recover(ctx, r)) 13720 ret = graphql.Null 13721 } 13722 }() 13723 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 13724 ctx = rctx // use context from middleware stack in children 13725 return obj.OfType(), nil 13726 }) 13727 13728 if resTmp == nil { 13729 return graphql.Null 13730 } 13731 res := resTmp.(*introspection.Type) 13732 fc.Result = res 13733 return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) 13734 } 13735 13736 func (ec *executionContext) fieldContext___Type_ofType(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 13737 fc = &graphql.FieldContext{ 13738 Object: "__Type", 13739 Field: field, 13740 IsMethod: true, 13741 IsResolver: false, 13742 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 13743 switch field.Name { 13744 case "kind": 13745 return ec.fieldContext___Type_kind(ctx, field) 13746 case "name": 13747 return ec.fieldContext___Type_name(ctx, field) 13748 case "description": 13749 return ec.fieldContext___Type_description(ctx, field) 13750 case "fields": 13751 return ec.fieldContext___Type_fields(ctx, field) 13752 case "interfaces": 13753 return ec.fieldContext___Type_interfaces(ctx, field) 13754 case "possibleTypes": 13755 return ec.fieldContext___Type_possibleTypes(ctx, field) 13756 case "enumValues": 13757 return ec.fieldContext___Type_enumValues(ctx, field) 13758 case "inputFields": 13759 return ec.fieldContext___Type_inputFields(ctx, field) 13760 case "ofType": 13761 return ec.fieldContext___Type_ofType(ctx, field) 13762 case "specifiedByURL": 13763 return ec.fieldContext___Type_specifiedByURL(ctx, field) 13764 } 13765 return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) 13766 }, 13767 } 13768 return fc, nil 13769 } 13770 13771 func (ec *executionContext) ___Type_specifiedByURL(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { 13772 fc, err := ec.fieldContext___Type_specifiedByURL(ctx, field) 13773 if err != nil { 13774 return graphql.Null 13775 } 13776 ctx = graphql.WithFieldContext(ctx, fc) 13777 defer func() { 13778 if r := recover(); r != nil { 13779 ec.Error(ctx, ec.Recover(ctx, r)) 13780 ret = graphql.Null 13781 } 13782 }() 13783 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 13784 ctx = rctx // use context from middleware stack in children 13785 return obj.SpecifiedByURL(), nil 13786 }) 13787 13788 if resTmp == nil { 13789 return graphql.Null 13790 } 13791 res := resTmp.(*string) 13792 fc.Result = res 13793 return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 13794 } 13795 13796 func (ec *executionContext) fieldContext___Type_specifiedByURL(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 13797 fc = &graphql.FieldContext{ 13798 Object: "__Type", 13799 Field: field, 13800 IsMethod: true, 13801 IsResolver: false, 13802 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 13803 return nil, errors.New("field of type String does not have child fields") 13804 }, 13805 } 13806 return fc, nil 13807 } 13808 13809 func (ec *executionContext) _asdfIt_id(ctx context.Context, field graphql.CollectedField, obj *AsdfIt) (ret graphql.Marshaler) { 13810 fc, err := ec.fieldContext_asdfIt_id(ctx, field) 13811 if err != nil { 13812 return graphql.Null 13813 } 13814 ctx = graphql.WithFieldContext(ctx, fc) 13815 defer func() { 13816 if r := recover(); r != nil { 13817 ec.Error(ctx, ec.Recover(ctx, r)) 13818 ret = graphql.Null 13819 } 13820 }() 13821 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 13822 ctx = rctx // use context from middleware stack in children 13823 return obj.ID, nil 13824 }) 13825 13826 if resTmp == nil { 13827 if !graphql.HasFieldError(ctx, fc) { 13828 ec.Errorf(ctx, "must not be null") 13829 } 13830 return graphql.Null 13831 } 13832 res := resTmp.(string) 13833 fc.Result = res 13834 return ec.marshalNID2string(ctx, field.Selections, res) 13835 } 13836 13837 func (ec *executionContext) fieldContext_asdfIt_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 13838 fc = &graphql.FieldContext{ 13839 Object: "asdfIt", 13840 Field: field, 13841 IsMethod: false, 13842 IsResolver: false, 13843 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 13844 return nil, errors.New("field of type ID does not have child fields") 13845 }, 13846 } 13847 return fc, nil 13848 } 13849 13850 func (ec *executionContext) _iIt_id(ctx context.Context, field graphql.CollectedField, obj *IIt) (ret graphql.Marshaler) { 13851 fc, err := ec.fieldContext_iIt_id(ctx, field) 13852 if err != nil { 13853 return graphql.Null 13854 } 13855 ctx = graphql.WithFieldContext(ctx, fc) 13856 defer func() { 13857 if r := recover(); r != nil { 13858 ec.Error(ctx, ec.Recover(ctx, r)) 13859 ret = graphql.Null 13860 } 13861 }() 13862 resTmp := ec._fieldMiddleware(ctx, obj, func(rctx context.Context) (interface{}, error) { 13863 ctx = rctx // use context from middleware stack in children 13864 return obj.ID, nil 13865 }) 13866 13867 if resTmp == nil { 13868 if !graphql.HasFieldError(ctx, fc) { 13869 ec.Errorf(ctx, "must not be null") 13870 } 13871 return graphql.Null 13872 } 13873 res := resTmp.(string) 13874 fc.Result = res 13875 return ec.marshalNID2string(ctx, field.Selections, res) 13876 } 13877 13878 func (ec *executionContext) fieldContext_iIt_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { 13879 fc = &graphql.FieldContext{ 13880 Object: "iIt", 13881 Field: field, 13882 IsMethod: false, 13883 IsResolver: false, 13884 Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { 13885 return nil, errors.New("field of type ID does not have child fields") 13886 }, 13887 } 13888 return fc, nil 13889 } 13890 13891 // endregion **************************** field.gotpl ***************************** 13892 13893 // region **************************** input.gotpl ***************************** 13894 13895 func (ec *executionContext) unmarshalInputDefaultInput(ctx context.Context, obj interface{}) (DefaultInput, error) { 13896 var it DefaultInput 13897 asMap := map[string]interface{}{} 13898 for k, v := range obj.(map[string]interface{}) { 13899 asMap[k] = v 13900 } 13901 13902 if _, present := asMap["falsyBoolean"]; !present { 13903 asMap["falsyBoolean"] = false 13904 } 13905 if _, present := asMap["truthyBoolean"]; !present { 13906 asMap["truthyBoolean"] = true 13907 } 13908 13909 fieldsInOrder := [...]string{"falsyBoolean", "truthyBoolean"} 13910 for _, k := range fieldsInOrder { 13911 v, ok := asMap[k] 13912 if !ok { 13913 continue 13914 } 13915 switch k { 13916 case "falsyBoolean": 13917 var err error 13918 13919 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("falsyBoolean")) 13920 it.FalsyBoolean, err = ec.unmarshalOBoolean2ᚖbool(ctx, v) 13921 if err != nil { 13922 return it, err 13923 } 13924 case "truthyBoolean": 13925 var err error 13926 13927 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("truthyBoolean")) 13928 it.TruthyBoolean, err = ec.unmarshalOBoolean2ᚖbool(ctx, v) 13929 if err != nil { 13930 return it, err 13931 } 13932 } 13933 } 13934 13935 return it, nil 13936 } 13937 13938 func (ec *executionContext) unmarshalInputFieldsOrderInput(ctx context.Context, obj interface{}) (FieldsOrderInput, error) { 13939 var it FieldsOrderInput 13940 asMap := map[string]interface{}{} 13941 for k, v := range obj.(map[string]interface{}) { 13942 asMap[k] = v 13943 } 13944 13945 fieldsInOrder := [...]string{"firstField", "overrideFirstField"} 13946 for _, k := range fieldsInOrder { 13947 v, ok := asMap[k] 13948 if !ok { 13949 continue 13950 } 13951 switch k { 13952 case "firstField": 13953 var err error 13954 13955 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("firstField")) 13956 it.FirstField, err = ec.unmarshalOString2ᚖstring(ctx, v) 13957 if err != nil { 13958 return it, err 13959 } 13960 case "overrideFirstField": 13961 var err error 13962 13963 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("overrideFirstField")) 13964 data, err := ec.unmarshalOString2ᚖstring(ctx, v) 13965 if err != nil { 13966 return it, err 13967 } 13968 if err = ec.resolvers.FieldsOrderInput().OverrideFirstField(ctx, &it, data); err != nil { 13969 return it, err 13970 } 13971 } 13972 } 13973 13974 return it, nil 13975 } 13976 13977 func (ec *executionContext) unmarshalInputInnerDirectives(ctx context.Context, obj interface{}) (InnerDirectives, error) { 13978 var it InnerDirectives 13979 asMap := map[string]interface{}{} 13980 for k, v := range obj.(map[string]interface{}) { 13981 asMap[k] = v 13982 } 13983 13984 fieldsInOrder := [...]string{"message"} 13985 for _, k := range fieldsInOrder { 13986 v, ok := asMap[k] 13987 if !ok { 13988 continue 13989 } 13990 switch k { 13991 case "message": 13992 var err error 13993 13994 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("message")) 13995 directive0 := func(ctx context.Context) (interface{}, error) { return ec.unmarshalNString2string(ctx, v) } 13996 directive1 := func(ctx context.Context) (interface{}, error) { 13997 min, err := ec.unmarshalNInt2int(ctx, 1) 13998 if err != nil { 13999 return nil, err 14000 } 14001 message, err := ec.unmarshalOString2ᚖstring(ctx, "not valid") 14002 if err != nil { 14003 return nil, err 14004 } 14005 if ec.directives.Length == nil { 14006 return nil, errors.New("directive length is not implemented") 14007 } 14008 return ec.directives.Length(ctx, obj, directive0, min, nil, message) 14009 } 14010 14011 tmp, err := directive1(ctx) 14012 if err != nil { 14013 return it, graphql.ErrorOnPath(ctx, err) 14014 } 14015 if data, ok := tmp.(string); ok { 14016 it.Message = data 14017 } else { 14018 err := fmt.Errorf(`unexpected type %T from directive, should be string`, tmp) 14019 return it, graphql.ErrorOnPath(ctx, err) 14020 } 14021 } 14022 } 14023 14024 return it, nil 14025 } 14026 14027 func (ec *executionContext) unmarshalInputInnerInput(ctx context.Context, obj interface{}) (InnerInput, error) { 14028 var it InnerInput 14029 asMap := map[string]interface{}{} 14030 for k, v := range obj.(map[string]interface{}) { 14031 asMap[k] = v 14032 } 14033 14034 fieldsInOrder := [...]string{"id"} 14035 for _, k := range fieldsInOrder { 14036 v, ok := asMap[k] 14037 if !ok { 14038 continue 14039 } 14040 switch k { 14041 case "id": 14042 var err error 14043 14044 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) 14045 it.ID, err = ec.unmarshalNInt2int(ctx, v) 14046 if err != nil { 14047 return it, err 14048 } 14049 } 14050 } 14051 14052 return it, nil 14053 } 14054 14055 func (ec *executionContext) unmarshalInputInputDirectives(ctx context.Context, obj interface{}) (InputDirectives, error) { 14056 var it InputDirectives 14057 asMap := map[string]interface{}{} 14058 for k, v := range obj.(map[string]interface{}) { 14059 asMap[k] = v 14060 } 14061 14062 fieldsInOrder := [...]string{"text", "nullableText", "inner", "innerNullable", "thirdParty"} 14063 for _, k := range fieldsInOrder { 14064 v, ok := asMap[k] 14065 if !ok { 14066 continue 14067 } 14068 switch k { 14069 case "text": 14070 var err error 14071 14072 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("text")) 14073 directive0 := func(ctx context.Context) (interface{}, error) { return ec.unmarshalNString2string(ctx, v) } 14074 directive1 := func(ctx context.Context) (interface{}, error) { 14075 if ec.directives.Directive3 == nil { 14076 return nil, errors.New("directive directive3 is not implemented") 14077 } 14078 return ec.directives.Directive3(ctx, obj, directive0) 14079 } 14080 directive2 := func(ctx context.Context) (interface{}, error) { 14081 min, err := ec.unmarshalNInt2int(ctx, 0) 14082 if err != nil { 14083 return nil, err 14084 } 14085 max, err := ec.unmarshalOInt2ᚖint(ctx, 7) 14086 if err != nil { 14087 return nil, err 14088 } 14089 message, err := ec.unmarshalOString2ᚖstring(ctx, "not valid") 14090 if err != nil { 14091 return nil, err 14092 } 14093 if ec.directives.Length == nil { 14094 return nil, errors.New("directive length is not implemented") 14095 } 14096 return ec.directives.Length(ctx, obj, directive1, min, max, message) 14097 } 14098 14099 tmp, err := directive2(ctx) 14100 if err != nil { 14101 return it, graphql.ErrorOnPath(ctx, err) 14102 } 14103 if data, ok := tmp.(string); ok { 14104 it.Text = data 14105 } else { 14106 err := fmt.Errorf(`unexpected type %T from directive, should be string`, tmp) 14107 return it, graphql.ErrorOnPath(ctx, err) 14108 } 14109 case "nullableText": 14110 var err error 14111 14112 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("nullableText")) 14113 directive0 := func(ctx context.Context) (interface{}, error) { return ec.unmarshalOString2ᚖstring(ctx, v) } 14114 directive1 := func(ctx context.Context) (interface{}, error) { 14115 if ec.directives.Directive3 == nil { 14116 return nil, errors.New("directive directive3 is not implemented") 14117 } 14118 return ec.directives.Directive3(ctx, obj, directive0) 14119 } 14120 directive2 := func(ctx context.Context) (interface{}, error) { 14121 if ec.directives.ToNull == nil { 14122 return nil, errors.New("directive toNull is not implemented") 14123 } 14124 return ec.directives.ToNull(ctx, obj, directive1) 14125 } 14126 14127 tmp, err := directive2(ctx) 14128 if err != nil { 14129 return it, graphql.ErrorOnPath(ctx, err) 14130 } 14131 if data, ok := tmp.(*string); ok { 14132 it.NullableText = data 14133 } else if tmp == nil { 14134 it.NullableText = nil 14135 } else { 14136 err := fmt.Errorf(`unexpected type %T from directive, should be *string`, tmp) 14137 return it, graphql.ErrorOnPath(ctx, err) 14138 } 14139 case "inner": 14140 var err error 14141 14142 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("inner")) 14143 directive0 := func(ctx context.Context) (interface{}, error) { 14144 return ec.unmarshalNInnerDirectives2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐInnerDirectives(ctx, v) 14145 } 14146 directive1 := func(ctx context.Context) (interface{}, error) { 14147 if ec.directives.Directive3 == nil { 14148 return nil, errors.New("directive directive3 is not implemented") 14149 } 14150 return ec.directives.Directive3(ctx, obj, directive0) 14151 } 14152 14153 tmp, err := directive1(ctx) 14154 if err != nil { 14155 return it, graphql.ErrorOnPath(ctx, err) 14156 } 14157 if data, ok := tmp.(*InnerDirectives); ok { 14158 it.Inner = data 14159 } else if tmp == nil { 14160 it.Inner = nil 14161 } else { 14162 err := fmt.Errorf(`unexpected type %T from directive, should be *github.com/luciferinlove/gqlgen/codegen/testserver/singlefile.InnerDirectives`, tmp) 14163 return it, graphql.ErrorOnPath(ctx, err) 14164 } 14165 case "innerNullable": 14166 var err error 14167 14168 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("innerNullable")) 14169 directive0 := func(ctx context.Context) (interface{}, error) { 14170 return ec.unmarshalOInnerDirectives2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐInnerDirectives(ctx, v) 14171 } 14172 directive1 := func(ctx context.Context) (interface{}, error) { 14173 if ec.directives.Directive3 == nil { 14174 return nil, errors.New("directive directive3 is not implemented") 14175 } 14176 return ec.directives.Directive3(ctx, obj, directive0) 14177 } 14178 14179 tmp, err := directive1(ctx) 14180 if err != nil { 14181 return it, graphql.ErrorOnPath(ctx, err) 14182 } 14183 if data, ok := tmp.(*InnerDirectives); ok { 14184 it.InnerNullable = data 14185 } else if tmp == nil { 14186 it.InnerNullable = nil 14187 } else { 14188 err := fmt.Errorf(`unexpected type %T from directive, should be *github.com/luciferinlove/gqlgen/codegen/testserver/singlefile.InnerDirectives`, tmp) 14189 return it, graphql.ErrorOnPath(ctx, err) 14190 } 14191 case "thirdParty": 14192 var err error 14193 14194 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("thirdParty")) 14195 directive0 := func(ctx context.Context) (interface{}, error) { 14196 return ec.unmarshalOThirdParty2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐThirdParty(ctx, v) 14197 } 14198 directive1 := func(ctx context.Context) (interface{}, error) { 14199 if ec.directives.Directive3 == nil { 14200 return nil, errors.New("directive directive3 is not implemented") 14201 } 14202 return ec.directives.Directive3(ctx, obj, directive0) 14203 } 14204 directive2 := func(ctx context.Context) (interface{}, error) { 14205 min, err := ec.unmarshalNInt2int(ctx, 0) 14206 if err != nil { 14207 return nil, err 14208 } 14209 max, err := ec.unmarshalOInt2ᚖint(ctx, 7) 14210 if err != nil { 14211 return nil, err 14212 } 14213 if ec.directives.Length == nil { 14214 return nil, errors.New("directive length is not implemented") 14215 } 14216 return ec.directives.Length(ctx, obj, directive1, min, max, nil) 14217 } 14218 14219 tmp, err := directive2(ctx) 14220 if err != nil { 14221 return it, graphql.ErrorOnPath(ctx, err) 14222 } 14223 if data, ok := tmp.(*ThirdParty); ok { 14224 it.ThirdParty = data 14225 } else if tmp == nil { 14226 it.ThirdParty = nil 14227 } else { 14228 err := fmt.Errorf(`unexpected type %T from directive, should be *github.com/luciferinlove/gqlgen/codegen/testserver/singlefile.ThirdParty`, tmp) 14229 return it, graphql.ErrorOnPath(ctx, err) 14230 } 14231 } 14232 } 14233 14234 return it, nil 14235 } 14236 14237 func (ec *executionContext) unmarshalInputInputWithEnumValue(ctx context.Context, obj interface{}) (InputWithEnumValue, error) { 14238 var it InputWithEnumValue 14239 asMap := map[string]interface{}{} 14240 for k, v := range obj.(map[string]interface{}) { 14241 asMap[k] = v 14242 } 14243 14244 fieldsInOrder := [...]string{"enum"} 14245 for _, k := range fieldsInOrder { 14246 v, ok := asMap[k] 14247 if !ok { 14248 continue 14249 } 14250 switch k { 14251 case "enum": 14252 var err error 14253 14254 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("enum")) 14255 it.Enum, err = ec.unmarshalNEnumTest2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐEnumTest(ctx, v) 14256 if err != nil { 14257 return it, err 14258 } 14259 } 14260 } 14261 14262 return it, nil 14263 } 14264 14265 func (ec *executionContext) unmarshalInputNestedInput(ctx context.Context, obj interface{}) (NestedInput, error) { 14266 var it NestedInput 14267 asMap := map[string]interface{}{} 14268 for k, v := range obj.(map[string]interface{}) { 14269 asMap[k] = v 14270 } 14271 14272 fieldsInOrder := [...]string{"field"} 14273 for _, k := range fieldsInOrder { 14274 v, ok := asMap[k] 14275 if !ok { 14276 continue 14277 } 14278 switch k { 14279 case "field": 14280 var err error 14281 14282 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("field")) 14283 it.Field, err = ec.unmarshalNEmail2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐEmail(ctx, v) 14284 if err != nil { 14285 return it, err 14286 } 14287 } 14288 } 14289 14290 return it, nil 14291 } 14292 14293 func (ec *executionContext) unmarshalInputNestedMapInput(ctx context.Context, obj interface{}) (NestedMapInput, error) { 14294 var it NestedMapInput 14295 asMap := map[string]interface{}{} 14296 for k, v := range obj.(map[string]interface{}) { 14297 asMap[k] = v 14298 } 14299 14300 fieldsInOrder := [...]string{"map"} 14301 for _, k := range fieldsInOrder { 14302 v, ok := asMap[k] 14303 if !ok { 14304 continue 14305 } 14306 switch k { 14307 case "map": 14308 var err error 14309 14310 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("map")) 14311 it.Map, err = ec.unmarshalOMapStringInterfaceInput2map(ctx, v) 14312 if err != nil { 14313 return it, err 14314 } 14315 } 14316 } 14317 14318 return it, nil 14319 } 14320 14321 func (ec *executionContext) unmarshalInputOuterInput(ctx context.Context, obj interface{}) (OuterInput, error) { 14322 var it OuterInput 14323 asMap := map[string]interface{}{} 14324 for k, v := range obj.(map[string]interface{}) { 14325 asMap[k] = v 14326 } 14327 14328 fieldsInOrder := [...]string{"inner"} 14329 for _, k := range fieldsInOrder { 14330 v, ok := asMap[k] 14331 if !ok { 14332 continue 14333 } 14334 switch k { 14335 case "inner": 14336 var err error 14337 14338 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("inner")) 14339 it.Inner, err = ec.unmarshalNInnerInput2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐInnerInput(ctx, v) 14340 if err != nil { 14341 return it, err 14342 } 14343 } 14344 } 14345 14346 return it, nil 14347 } 14348 14349 func (ec *executionContext) unmarshalInputRecursiveInputSlice(ctx context.Context, obj interface{}) (RecursiveInputSlice, error) { 14350 var it RecursiveInputSlice 14351 asMap := map[string]interface{}{} 14352 for k, v := range obj.(map[string]interface{}) { 14353 asMap[k] = v 14354 } 14355 14356 fieldsInOrder := [...]string{"self"} 14357 for _, k := range fieldsInOrder { 14358 v, ok := asMap[k] 14359 if !ok { 14360 continue 14361 } 14362 switch k { 14363 case "self": 14364 var err error 14365 14366 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("self")) 14367 it.Self, err = ec.unmarshalORecursiveInputSlice2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐRecursiveInputSliceᚄ(ctx, v) 14368 if err != nil { 14369 return it, err 14370 } 14371 } 14372 } 14373 14374 return it, nil 14375 } 14376 14377 func (ec *executionContext) unmarshalInputSpecialInput(ctx context.Context, obj interface{}) (SpecialInput, error) { 14378 var it SpecialInput 14379 asMap := map[string]interface{}{} 14380 for k, v := range obj.(map[string]interface{}) { 14381 asMap[k] = v 14382 } 14383 14384 fieldsInOrder := [...]string{"nesting"} 14385 for _, k := range fieldsInOrder { 14386 v, ok := asMap[k] 14387 if !ok { 14388 continue 14389 } 14390 switch k { 14391 case "nesting": 14392 var err error 14393 14394 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("nesting")) 14395 it.Nesting, err = ec.unmarshalNNestedInput2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐNestedInput(ctx, v) 14396 if err != nil { 14397 return it, err 14398 } 14399 } 14400 } 14401 14402 return it, nil 14403 } 14404 14405 func (ec *executionContext) unmarshalInputUpdatePtrToPtrInner(ctx context.Context, obj interface{}) (UpdatePtrToPtrInner, error) { 14406 var it UpdatePtrToPtrInner 14407 asMap := map[string]interface{}{} 14408 for k, v := range obj.(map[string]interface{}) { 14409 asMap[k] = v 14410 } 14411 14412 fieldsInOrder := [...]string{"key", "value"} 14413 for _, k := range fieldsInOrder { 14414 v, ok := asMap[k] 14415 if !ok { 14416 continue 14417 } 14418 switch k { 14419 case "key": 14420 var err error 14421 14422 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("key")) 14423 it.Key, err = ec.unmarshalOString2ᚖstring(ctx, v) 14424 if err != nil { 14425 return it, err 14426 } 14427 case "value": 14428 var err error 14429 14430 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("value")) 14431 it.Value, err = ec.unmarshalOString2ᚖstring(ctx, v) 14432 if err != nil { 14433 return it, err 14434 } 14435 } 14436 } 14437 14438 return it, nil 14439 } 14440 14441 func (ec *executionContext) unmarshalInputUpdatePtrToPtrOuter(ctx context.Context, obj interface{}) (UpdatePtrToPtrOuter, error) { 14442 var it UpdatePtrToPtrOuter 14443 asMap := map[string]interface{}{} 14444 for k, v := range obj.(map[string]interface{}) { 14445 asMap[k] = v 14446 } 14447 14448 fieldsInOrder := [...]string{"name", "inner", "stupidInner"} 14449 for _, k := range fieldsInOrder { 14450 v, ok := asMap[k] 14451 if !ok { 14452 continue 14453 } 14454 switch k { 14455 case "name": 14456 var err error 14457 14458 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("name")) 14459 it.Name, err = ec.unmarshalOString2ᚖstring(ctx, v) 14460 if err != nil { 14461 return it, err 14462 } 14463 case "inner": 14464 var err error 14465 14466 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("inner")) 14467 it.Inner, err = ec.unmarshalOUpdatePtrToPtrInner2ᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUpdatePtrToPtrInner(ctx, v) 14468 if err != nil { 14469 return it, err 14470 } 14471 case "stupidInner": 14472 var err error 14473 14474 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("stupidInner")) 14475 it.StupidInner, err = ec.unmarshalOUpdatePtrToPtrInner2ᚖᚖᚖᚖᚖᚖᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUpdatePtrToPtrInner(ctx, v) 14476 if err != nil { 14477 return it, err 14478 } 14479 } 14480 } 14481 14482 return it, nil 14483 } 14484 14485 func (ec *executionContext) unmarshalInputValidInput(ctx context.Context, obj interface{}) (ValidInput, error) { 14486 var it ValidInput 14487 asMap := map[string]interface{}{} 14488 for k, v := range obj.(map[string]interface{}) { 14489 asMap[k] = v 14490 } 14491 14492 fieldsInOrder := [...]string{"break", "default", "func", "interface", "select", "case", "defer", "go", "map", "struct", "chan", "else", "goto", "package", "switch", "const", "fallthrough", "if", "range", "type", "continue", "for", "import", "return", "var", "_"} 14493 for _, k := range fieldsInOrder { 14494 v, ok := asMap[k] 14495 if !ok { 14496 continue 14497 } 14498 switch k { 14499 case "break": 14500 var err error 14501 14502 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("break")) 14503 it.Break, err = ec.unmarshalNString2string(ctx, v) 14504 if err != nil { 14505 return it, err 14506 } 14507 case "default": 14508 var err error 14509 14510 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("default")) 14511 it.Default, err = ec.unmarshalNString2string(ctx, v) 14512 if err != nil { 14513 return it, err 14514 } 14515 case "func": 14516 var err error 14517 14518 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("func")) 14519 it.Func, err = ec.unmarshalNString2string(ctx, v) 14520 if err != nil { 14521 return it, err 14522 } 14523 case "interface": 14524 var err error 14525 14526 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("interface")) 14527 it.Interface, err = ec.unmarshalNString2string(ctx, v) 14528 if err != nil { 14529 return it, err 14530 } 14531 case "select": 14532 var err error 14533 14534 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("select")) 14535 it.Select, err = ec.unmarshalNString2string(ctx, v) 14536 if err != nil { 14537 return it, err 14538 } 14539 case "case": 14540 var err error 14541 14542 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("case")) 14543 it.Case, err = ec.unmarshalNString2string(ctx, v) 14544 if err != nil { 14545 return it, err 14546 } 14547 case "defer": 14548 var err error 14549 14550 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("defer")) 14551 it.Defer, err = ec.unmarshalNString2string(ctx, v) 14552 if err != nil { 14553 return it, err 14554 } 14555 case "go": 14556 var err error 14557 14558 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("go")) 14559 it.Go, err = ec.unmarshalNString2string(ctx, v) 14560 if err != nil { 14561 return it, err 14562 } 14563 case "map": 14564 var err error 14565 14566 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("map")) 14567 it.Map, err = ec.unmarshalNString2string(ctx, v) 14568 if err != nil { 14569 return it, err 14570 } 14571 case "struct": 14572 var err error 14573 14574 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("struct")) 14575 it.Struct, err = ec.unmarshalNString2string(ctx, v) 14576 if err != nil { 14577 return it, err 14578 } 14579 case "chan": 14580 var err error 14581 14582 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("chan")) 14583 it.Chan, err = ec.unmarshalNString2string(ctx, v) 14584 if err != nil { 14585 return it, err 14586 } 14587 case "else": 14588 var err error 14589 14590 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("else")) 14591 it.Else, err = ec.unmarshalNString2string(ctx, v) 14592 if err != nil { 14593 return it, err 14594 } 14595 case "goto": 14596 var err error 14597 14598 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("goto")) 14599 it.Goto, err = ec.unmarshalNString2string(ctx, v) 14600 if err != nil { 14601 return it, err 14602 } 14603 case "package": 14604 var err error 14605 14606 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("package")) 14607 it.Package, err = ec.unmarshalNString2string(ctx, v) 14608 if err != nil { 14609 return it, err 14610 } 14611 case "switch": 14612 var err error 14613 14614 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("switch")) 14615 it.Switch, err = ec.unmarshalNString2string(ctx, v) 14616 if err != nil { 14617 return it, err 14618 } 14619 case "const": 14620 var err error 14621 14622 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("const")) 14623 it.Const, err = ec.unmarshalNString2string(ctx, v) 14624 if err != nil { 14625 return it, err 14626 } 14627 case "fallthrough": 14628 var err error 14629 14630 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("fallthrough")) 14631 it.Fallthrough, err = ec.unmarshalNString2string(ctx, v) 14632 if err != nil { 14633 return it, err 14634 } 14635 case "if": 14636 var err error 14637 14638 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("if")) 14639 it.If, err = ec.unmarshalNString2string(ctx, v) 14640 if err != nil { 14641 return it, err 14642 } 14643 case "range": 14644 var err error 14645 14646 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("range")) 14647 it.Range, err = ec.unmarshalNString2string(ctx, v) 14648 if err != nil { 14649 return it, err 14650 } 14651 case "type": 14652 var err error 14653 14654 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("type")) 14655 it.Type, err = ec.unmarshalNString2string(ctx, v) 14656 if err != nil { 14657 return it, err 14658 } 14659 case "continue": 14660 var err error 14661 14662 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("continue")) 14663 it.Continue, err = ec.unmarshalNString2string(ctx, v) 14664 if err != nil { 14665 return it, err 14666 } 14667 case "for": 14668 var err error 14669 14670 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("for")) 14671 it.For, err = ec.unmarshalNString2string(ctx, v) 14672 if err != nil { 14673 return it, err 14674 } 14675 case "import": 14676 var err error 14677 14678 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("import")) 14679 it.Import, err = ec.unmarshalNString2string(ctx, v) 14680 if err != nil { 14681 return it, err 14682 } 14683 case "return": 14684 var err error 14685 14686 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("return")) 14687 it.Return, err = ec.unmarshalNString2string(ctx, v) 14688 if err != nil { 14689 return it, err 14690 } 14691 case "var": 14692 var err error 14693 14694 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("var")) 14695 it.Var, err = ec.unmarshalNString2string(ctx, v) 14696 if err != nil { 14697 return it, err 14698 } 14699 case "_": 14700 var err error 14701 14702 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("_")) 14703 it.Underscore, err = ec.unmarshalNString2string(ctx, v) 14704 if err != nil { 14705 return it, err 14706 } 14707 } 14708 } 14709 14710 return it, nil 14711 } 14712 14713 // endregion **************************** input.gotpl ***************************** 14714 14715 // region ************************** interface.gotpl *************************** 14716 14717 func (ec *executionContext) _Animal(ctx context.Context, sel ast.SelectionSet, obj Animal) graphql.Marshaler { 14718 switch obj := (obj).(type) { 14719 case nil: 14720 return graphql.Null 14721 case Dog: 14722 return ec._Dog(ctx, sel, &obj) 14723 case *Dog: 14724 if obj == nil { 14725 return graphql.Null 14726 } 14727 return ec._Dog(ctx, sel, obj) 14728 case Cat: 14729 return ec._Cat(ctx, sel, &obj) 14730 case *Cat: 14731 if obj == nil { 14732 return graphql.Null 14733 } 14734 return ec._Cat(ctx, sel, obj) 14735 default: 14736 panic(fmt.Errorf("unexpected type %T", obj)) 14737 } 14738 } 14739 14740 func (ec *executionContext) _Content_Child(ctx context.Context, sel ast.SelectionSet, obj ContentChild) graphql.Marshaler { 14741 switch obj := (obj).(type) { 14742 case nil: 14743 return graphql.Null 14744 case ContentUser: 14745 return ec._Content_User(ctx, sel, &obj) 14746 case *ContentUser: 14747 if obj == nil { 14748 return graphql.Null 14749 } 14750 return ec._Content_User(ctx, sel, obj) 14751 case ContentPost: 14752 return ec._Content_Post(ctx, sel, &obj) 14753 case *ContentPost: 14754 if obj == nil { 14755 return graphql.Null 14756 } 14757 return ec._Content_Post(ctx, sel, obj) 14758 default: 14759 panic(fmt.Errorf("unexpected type %T", obj)) 14760 } 14761 } 14762 14763 func (ec *executionContext) _Node(ctx context.Context, sel ast.SelectionSet, obj Node) graphql.Marshaler { 14764 switch obj := (obj).(type) { 14765 case nil: 14766 return graphql.Null 14767 case *ConcreteNodeA: 14768 if obj == nil { 14769 return graphql.Null 14770 } 14771 return ec._ConcreteNodeA(ctx, sel, obj) 14772 case ConcreteNodeInterface: 14773 if obj == nil { 14774 return graphql.Null 14775 } 14776 return ec._ConcreteNodeInterface(ctx, sel, obj) 14777 default: 14778 panic(fmt.Errorf("unexpected type %T", obj)) 14779 } 14780 } 14781 14782 func (ec *executionContext) _Shape(ctx context.Context, sel ast.SelectionSet, obj Shape) graphql.Marshaler { 14783 switch obj := (obj).(type) { 14784 case nil: 14785 return graphql.Null 14786 case *Circle: 14787 if obj == nil { 14788 return graphql.Null 14789 } 14790 return ec._Circle(ctx, sel, obj) 14791 case *Rectangle: 14792 if obj == nil { 14793 return graphql.Null 14794 } 14795 return ec._Rectangle(ctx, sel, obj) 14796 default: 14797 panic(fmt.Errorf("unexpected type %T", obj)) 14798 } 14799 } 14800 14801 func (ec *executionContext) _ShapeUnion(ctx context.Context, sel ast.SelectionSet, obj ShapeUnion) graphql.Marshaler { 14802 switch obj := (obj).(type) { 14803 case nil: 14804 return graphql.Null 14805 case *Circle: 14806 if obj == nil { 14807 return graphql.Null 14808 } 14809 return ec._Circle(ctx, sel, obj) 14810 case *Rectangle: 14811 if obj == nil { 14812 return graphql.Null 14813 } 14814 return ec._Rectangle(ctx, sel, obj) 14815 default: 14816 panic(fmt.Errorf("unexpected type %T", obj)) 14817 } 14818 } 14819 14820 func (ec *executionContext) _TestUnion(ctx context.Context, sel ast.SelectionSet, obj TestUnion) graphql.Marshaler { 14821 switch obj := (obj).(type) { 14822 case nil: 14823 return graphql.Null 14824 case A: 14825 return ec._A(ctx, sel, &obj) 14826 case *A: 14827 if obj == nil { 14828 return graphql.Null 14829 } 14830 return ec._A(ctx, sel, obj) 14831 case B: 14832 return ec._B(ctx, sel, &obj) 14833 case *B: 14834 if obj == nil { 14835 return graphql.Null 14836 } 14837 return ec._B(ctx, sel, obj) 14838 default: 14839 panic(fmt.Errorf("unexpected type %T", obj)) 14840 } 14841 } 14842 14843 // endregion ************************** interface.gotpl *************************** 14844 14845 // region **************************** object.gotpl **************************** 14846 14847 var aImplementors = []string{"A", "TestUnion"} 14848 14849 func (ec *executionContext) _A(ctx context.Context, sel ast.SelectionSet, obj *A) graphql.Marshaler { 14850 fields := graphql.CollectFields(ec.OperationContext, sel, aImplementors) 14851 out := graphql.NewFieldSet(fields) 14852 var invalids uint32 14853 for i, field := range fields { 14854 switch field.Name { 14855 case "__typename": 14856 out.Values[i] = graphql.MarshalString("A") 14857 case "id": 14858 14859 out.Values[i] = ec._A_id(ctx, field, obj) 14860 14861 if out.Values[i] == graphql.Null { 14862 invalids++ 14863 } 14864 default: 14865 panic("unknown field " + strconv.Quote(field.Name)) 14866 } 14867 } 14868 out.Dispatch() 14869 if invalids > 0 { 14870 return graphql.Null 14871 } 14872 return out 14873 } 14874 14875 var aItImplementors = []string{"AIt"} 14876 14877 func (ec *executionContext) _AIt(ctx context.Context, sel ast.SelectionSet, obj *AIt) graphql.Marshaler { 14878 fields := graphql.CollectFields(ec.OperationContext, sel, aItImplementors) 14879 out := graphql.NewFieldSet(fields) 14880 var invalids uint32 14881 for i, field := range fields { 14882 switch field.Name { 14883 case "__typename": 14884 out.Values[i] = graphql.MarshalString("AIt") 14885 case "id": 14886 14887 out.Values[i] = ec._AIt_id(ctx, field, obj) 14888 14889 if out.Values[i] == graphql.Null { 14890 invalids++ 14891 } 14892 default: 14893 panic("unknown field " + strconv.Quote(field.Name)) 14894 } 14895 } 14896 out.Dispatch() 14897 if invalids > 0 { 14898 return graphql.Null 14899 } 14900 return out 14901 } 14902 14903 var abItImplementors = []string{"AbIt"} 14904 14905 func (ec *executionContext) _AbIt(ctx context.Context, sel ast.SelectionSet, obj *AbIt) graphql.Marshaler { 14906 fields := graphql.CollectFields(ec.OperationContext, sel, abItImplementors) 14907 out := graphql.NewFieldSet(fields) 14908 var invalids uint32 14909 for i, field := range fields { 14910 switch field.Name { 14911 case "__typename": 14912 out.Values[i] = graphql.MarshalString("AbIt") 14913 case "id": 14914 14915 out.Values[i] = ec._AbIt_id(ctx, field, obj) 14916 14917 if out.Values[i] == graphql.Null { 14918 invalids++ 14919 } 14920 default: 14921 panic("unknown field " + strconv.Quote(field.Name)) 14922 } 14923 } 14924 out.Dispatch() 14925 if invalids > 0 { 14926 return graphql.Null 14927 } 14928 return out 14929 } 14930 14931 var autobindImplementors = []string{"Autobind"} 14932 14933 func (ec *executionContext) _Autobind(ctx context.Context, sel ast.SelectionSet, obj *Autobind) graphql.Marshaler { 14934 fields := graphql.CollectFields(ec.OperationContext, sel, autobindImplementors) 14935 out := graphql.NewFieldSet(fields) 14936 var invalids uint32 14937 for i, field := range fields { 14938 switch field.Name { 14939 case "__typename": 14940 out.Values[i] = graphql.MarshalString("Autobind") 14941 case "int": 14942 14943 out.Values[i] = ec._Autobind_int(ctx, field, obj) 14944 14945 if out.Values[i] == graphql.Null { 14946 invalids++ 14947 } 14948 case "int32": 14949 14950 out.Values[i] = ec._Autobind_int32(ctx, field, obj) 14951 14952 if out.Values[i] == graphql.Null { 14953 invalids++ 14954 } 14955 case "int64": 14956 14957 out.Values[i] = ec._Autobind_int64(ctx, field, obj) 14958 14959 if out.Values[i] == graphql.Null { 14960 invalids++ 14961 } 14962 case "idStr": 14963 14964 out.Values[i] = ec._Autobind_idStr(ctx, field, obj) 14965 14966 if out.Values[i] == graphql.Null { 14967 invalids++ 14968 } 14969 case "idInt": 14970 14971 out.Values[i] = ec._Autobind_idInt(ctx, field, obj) 14972 14973 if out.Values[i] == graphql.Null { 14974 invalids++ 14975 } 14976 default: 14977 panic("unknown field " + strconv.Quote(field.Name)) 14978 } 14979 } 14980 out.Dispatch() 14981 if invalids > 0 { 14982 return graphql.Null 14983 } 14984 return out 14985 } 14986 14987 var bImplementors = []string{"B", "TestUnion"} 14988 14989 func (ec *executionContext) _B(ctx context.Context, sel ast.SelectionSet, obj *B) graphql.Marshaler { 14990 fields := graphql.CollectFields(ec.OperationContext, sel, bImplementors) 14991 out := graphql.NewFieldSet(fields) 14992 var invalids uint32 14993 for i, field := range fields { 14994 switch field.Name { 14995 case "__typename": 14996 out.Values[i] = graphql.MarshalString("B") 14997 case "id": 14998 14999 out.Values[i] = ec._B_id(ctx, field, obj) 15000 15001 if out.Values[i] == graphql.Null { 15002 invalids++ 15003 } 15004 default: 15005 panic("unknown field " + strconv.Quote(field.Name)) 15006 } 15007 } 15008 out.Dispatch() 15009 if invalids > 0 { 15010 return graphql.Null 15011 } 15012 return out 15013 } 15014 15015 var backedByInterfaceImplementors = []string{"BackedByInterface"} 15016 15017 func (ec *executionContext) _BackedByInterface(ctx context.Context, sel ast.SelectionSet, obj BackedByInterface) graphql.Marshaler { 15018 fields := graphql.CollectFields(ec.OperationContext, sel, backedByInterfaceImplementors) 15019 out := graphql.NewFieldSet(fields) 15020 var invalids uint32 15021 for i, field := range fields { 15022 switch field.Name { 15023 case "__typename": 15024 out.Values[i] = graphql.MarshalString("BackedByInterface") 15025 case "id": 15026 field := field 15027 15028 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 15029 defer func() { 15030 if r := recover(); r != nil { 15031 ec.Error(ctx, ec.Recover(ctx, r)) 15032 } 15033 }() 15034 res = ec._BackedByInterface_id(ctx, field, obj) 15035 if res == graphql.Null { 15036 atomic.AddUint32(&invalids, 1) 15037 } 15038 return res 15039 } 15040 15041 out.Concurrently(i, func() graphql.Marshaler { 15042 return innerFunc(ctx) 15043 15044 }) 15045 case "thisShouldBind": 15046 15047 out.Values[i] = ec._BackedByInterface_thisShouldBind(ctx, field, obj) 15048 15049 if out.Values[i] == graphql.Null { 15050 atomic.AddUint32(&invalids, 1) 15051 } 15052 case "thisShouldBindWithError": 15053 15054 out.Values[i] = ec._BackedByInterface_thisShouldBindWithError(ctx, field, obj) 15055 15056 if out.Values[i] == graphql.Null { 15057 atomic.AddUint32(&invalids, 1) 15058 } 15059 default: 15060 panic("unknown field " + strconv.Quote(field.Name)) 15061 } 15062 } 15063 out.Dispatch() 15064 if invalids > 0 { 15065 return graphql.Null 15066 } 15067 return out 15068 } 15069 15070 var catImplementors = []string{"Cat", "Animal"} 15071 15072 func (ec *executionContext) _Cat(ctx context.Context, sel ast.SelectionSet, obj *Cat) graphql.Marshaler { 15073 fields := graphql.CollectFields(ec.OperationContext, sel, catImplementors) 15074 out := graphql.NewFieldSet(fields) 15075 var invalids uint32 15076 for i, field := range fields { 15077 switch field.Name { 15078 case "__typename": 15079 out.Values[i] = graphql.MarshalString("Cat") 15080 case "species": 15081 15082 out.Values[i] = ec._Cat_species(ctx, field, obj) 15083 15084 if out.Values[i] == graphql.Null { 15085 invalids++ 15086 } 15087 case "catBreed": 15088 15089 out.Values[i] = ec._Cat_catBreed(ctx, field, obj) 15090 15091 if out.Values[i] == graphql.Null { 15092 invalids++ 15093 } 15094 default: 15095 panic("unknown field " + strconv.Quote(field.Name)) 15096 } 15097 } 15098 out.Dispatch() 15099 if invalids > 0 { 15100 return graphql.Null 15101 } 15102 return out 15103 } 15104 15105 var checkIssue896Implementors = []string{"CheckIssue896"} 15106 15107 func (ec *executionContext) _CheckIssue896(ctx context.Context, sel ast.SelectionSet, obj *CheckIssue896) graphql.Marshaler { 15108 fields := graphql.CollectFields(ec.OperationContext, sel, checkIssue896Implementors) 15109 out := graphql.NewFieldSet(fields) 15110 var invalids uint32 15111 for i, field := range fields { 15112 switch field.Name { 15113 case "__typename": 15114 out.Values[i] = graphql.MarshalString("CheckIssue896") 15115 case "id": 15116 15117 out.Values[i] = ec._CheckIssue896_id(ctx, field, obj) 15118 15119 default: 15120 panic("unknown field " + strconv.Quote(field.Name)) 15121 } 15122 } 15123 out.Dispatch() 15124 if invalids > 0 { 15125 return graphql.Null 15126 } 15127 return out 15128 } 15129 15130 var circleImplementors = []string{"Circle", "Shape", "ShapeUnion"} 15131 15132 func (ec *executionContext) _Circle(ctx context.Context, sel ast.SelectionSet, obj *Circle) graphql.Marshaler { 15133 fields := graphql.CollectFields(ec.OperationContext, sel, circleImplementors) 15134 out := graphql.NewFieldSet(fields) 15135 var invalids uint32 15136 for i, field := range fields { 15137 switch field.Name { 15138 case "__typename": 15139 out.Values[i] = graphql.MarshalString("Circle") 15140 case "radius": 15141 15142 out.Values[i] = ec._Circle_radius(ctx, field, obj) 15143 15144 case "area": 15145 15146 out.Values[i] = ec._Circle_area(ctx, field, obj) 15147 15148 case "coordinates": 15149 15150 out.Values[i] = ec._Circle_coordinates(ctx, field, obj) 15151 15152 default: 15153 panic("unknown field " + strconv.Quote(field.Name)) 15154 } 15155 } 15156 out.Dispatch() 15157 if invalids > 0 { 15158 return graphql.Null 15159 } 15160 return out 15161 } 15162 15163 var concreteNodeAImplementors = []string{"ConcreteNodeA", "Node"} 15164 15165 func (ec *executionContext) _ConcreteNodeA(ctx context.Context, sel ast.SelectionSet, obj *ConcreteNodeA) graphql.Marshaler { 15166 fields := graphql.CollectFields(ec.OperationContext, sel, concreteNodeAImplementors) 15167 out := graphql.NewFieldSet(fields) 15168 var invalids uint32 15169 for i, field := range fields { 15170 switch field.Name { 15171 case "__typename": 15172 out.Values[i] = graphql.MarshalString("ConcreteNodeA") 15173 case "id": 15174 15175 out.Values[i] = ec._ConcreteNodeA_id(ctx, field, obj) 15176 15177 if out.Values[i] == graphql.Null { 15178 invalids++ 15179 } 15180 case "child": 15181 15182 out.Values[i] = ec._ConcreteNodeA_child(ctx, field, obj) 15183 15184 if out.Values[i] == graphql.Null { 15185 invalids++ 15186 } 15187 case "name": 15188 15189 out.Values[i] = ec._ConcreteNodeA_name(ctx, field, obj) 15190 15191 if out.Values[i] == graphql.Null { 15192 invalids++ 15193 } 15194 default: 15195 panic("unknown field " + strconv.Quote(field.Name)) 15196 } 15197 } 15198 out.Dispatch() 15199 if invalids > 0 { 15200 return graphql.Null 15201 } 15202 return out 15203 } 15204 15205 var concreteNodeInterfaceImplementors = []string{"ConcreteNodeInterface", "Node"} 15206 15207 func (ec *executionContext) _ConcreteNodeInterface(ctx context.Context, sel ast.SelectionSet, obj ConcreteNodeInterface) graphql.Marshaler { 15208 fields := graphql.CollectFields(ec.OperationContext, sel, concreteNodeInterfaceImplementors) 15209 out := graphql.NewFieldSet(fields) 15210 var invalids uint32 15211 for i, field := range fields { 15212 switch field.Name { 15213 case "__typename": 15214 out.Values[i] = graphql.MarshalString("ConcreteNodeInterface") 15215 case "id": 15216 15217 out.Values[i] = ec._ConcreteNodeInterface_id(ctx, field, obj) 15218 15219 if out.Values[i] == graphql.Null { 15220 invalids++ 15221 } 15222 case "child": 15223 15224 out.Values[i] = ec._ConcreteNodeInterface_child(ctx, field, obj) 15225 15226 if out.Values[i] == graphql.Null { 15227 invalids++ 15228 } 15229 default: 15230 panic("unknown field " + strconv.Quote(field.Name)) 15231 } 15232 } 15233 out.Dispatch() 15234 if invalids > 0 { 15235 return graphql.Null 15236 } 15237 return out 15238 } 15239 15240 var content_PostImplementors = []string{"Content_Post", "Content_Child"} 15241 15242 func (ec *executionContext) _Content_Post(ctx context.Context, sel ast.SelectionSet, obj *ContentPost) graphql.Marshaler { 15243 fields := graphql.CollectFields(ec.OperationContext, sel, content_PostImplementors) 15244 out := graphql.NewFieldSet(fields) 15245 var invalids uint32 15246 for i, field := range fields { 15247 switch field.Name { 15248 case "__typename": 15249 out.Values[i] = graphql.MarshalString("Content_Post") 15250 case "foo": 15251 15252 out.Values[i] = ec._Content_Post_foo(ctx, field, obj) 15253 15254 default: 15255 panic("unknown field " + strconv.Quote(field.Name)) 15256 } 15257 } 15258 out.Dispatch() 15259 if invalids > 0 { 15260 return graphql.Null 15261 } 15262 return out 15263 } 15264 15265 var content_UserImplementors = []string{"Content_User", "Content_Child"} 15266 15267 func (ec *executionContext) _Content_User(ctx context.Context, sel ast.SelectionSet, obj *ContentUser) graphql.Marshaler { 15268 fields := graphql.CollectFields(ec.OperationContext, sel, content_UserImplementors) 15269 out := graphql.NewFieldSet(fields) 15270 var invalids uint32 15271 for i, field := range fields { 15272 switch field.Name { 15273 case "__typename": 15274 out.Values[i] = graphql.MarshalString("Content_User") 15275 case "foo": 15276 15277 out.Values[i] = ec._Content_User_foo(ctx, field, obj) 15278 15279 default: 15280 panic("unknown field " + strconv.Quote(field.Name)) 15281 } 15282 } 15283 out.Dispatch() 15284 if invalids > 0 { 15285 return graphql.Null 15286 } 15287 return out 15288 } 15289 15290 var coordinatesImplementors = []string{"Coordinates"} 15291 15292 func (ec *executionContext) _Coordinates(ctx context.Context, sel ast.SelectionSet, obj *Coordinates) graphql.Marshaler { 15293 fields := graphql.CollectFields(ec.OperationContext, sel, coordinatesImplementors) 15294 out := graphql.NewFieldSet(fields) 15295 var invalids uint32 15296 for i, field := range fields { 15297 switch field.Name { 15298 case "__typename": 15299 out.Values[i] = graphql.MarshalString("Coordinates") 15300 case "x": 15301 15302 out.Values[i] = ec._Coordinates_x(ctx, field, obj) 15303 15304 if out.Values[i] == graphql.Null { 15305 invalids++ 15306 } 15307 case "y": 15308 15309 out.Values[i] = ec._Coordinates_y(ctx, field, obj) 15310 15311 if out.Values[i] == graphql.Null { 15312 invalids++ 15313 } 15314 default: 15315 panic("unknown field " + strconv.Quote(field.Name)) 15316 } 15317 } 15318 out.Dispatch() 15319 if invalids > 0 { 15320 return graphql.Null 15321 } 15322 return out 15323 } 15324 15325 var defaultParametersMirrorImplementors = []string{"DefaultParametersMirror"} 15326 15327 func (ec *executionContext) _DefaultParametersMirror(ctx context.Context, sel ast.SelectionSet, obj *DefaultParametersMirror) graphql.Marshaler { 15328 fields := graphql.CollectFields(ec.OperationContext, sel, defaultParametersMirrorImplementors) 15329 out := graphql.NewFieldSet(fields) 15330 var invalids uint32 15331 for i, field := range fields { 15332 switch field.Name { 15333 case "__typename": 15334 out.Values[i] = graphql.MarshalString("DefaultParametersMirror") 15335 case "falsyBoolean": 15336 15337 out.Values[i] = ec._DefaultParametersMirror_falsyBoolean(ctx, field, obj) 15338 15339 case "truthyBoolean": 15340 15341 out.Values[i] = ec._DefaultParametersMirror_truthyBoolean(ctx, field, obj) 15342 15343 default: 15344 panic("unknown field " + strconv.Quote(field.Name)) 15345 } 15346 } 15347 out.Dispatch() 15348 if invalids > 0 { 15349 return graphql.Null 15350 } 15351 return out 15352 } 15353 15354 var dogImplementors = []string{"Dog", "Animal"} 15355 15356 func (ec *executionContext) _Dog(ctx context.Context, sel ast.SelectionSet, obj *Dog) graphql.Marshaler { 15357 fields := graphql.CollectFields(ec.OperationContext, sel, dogImplementors) 15358 out := graphql.NewFieldSet(fields) 15359 var invalids uint32 15360 for i, field := range fields { 15361 switch field.Name { 15362 case "__typename": 15363 out.Values[i] = graphql.MarshalString("Dog") 15364 case "species": 15365 15366 out.Values[i] = ec._Dog_species(ctx, field, obj) 15367 15368 if out.Values[i] == graphql.Null { 15369 invalids++ 15370 } 15371 case "dogBreed": 15372 15373 out.Values[i] = ec._Dog_dogBreed(ctx, field, obj) 15374 15375 if out.Values[i] == graphql.Null { 15376 invalids++ 15377 } 15378 default: 15379 panic("unknown field " + strconv.Quote(field.Name)) 15380 } 15381 } 15382 out.Dispatch() 15383 if invalids > 0 { 15384 return graphql.Null 15385 } 15386 return out 15387 } 15388 15389 var embeddedCase1Implementors = []string{"EmbeddedCase1"} 15390 15391 func (ec *executionContext) _EmbeddedCase1(ctx context.Context, sel ast.SelectionSet, obj *EmbeddedCase1) graphql.Marshaler { 15392 fields := graphql.CollectFields(ec.OperationContext, sel, embeddedCase1Implementors) 15393 out := graphql.NewFieldSet(fields) 15394 var invalids uint32 15395 for i, field := range fields { 15396 switch field.Name { 15397 case "__typename": 15398 out.Values[i] = graphql.MarshalString("EmbeddedCase1") 15399 case "exportedEmbeddedPointerExportedMethod": 15400 15401 out.Values[i] = ec._EmbeddedCase1_exportedEmbeddedPointerExportedMethod(ctx, field, obj) 15402 15403 if out.Values[i] == graphql.Null { 15404 invalids++ 15405 } 15406 default: 15407 panic("unknown field " + strconv.Quote(field.Name)) 15408 } 15409 } 15410 out.Dispatch() 15411 if invalids > 0 { 15412 return graphql.Null 15413 } 15414 return out 15415 } 15416 15417 var embeddedCase2Implementors = []string{"EmbeddedCase2"} 15418 15419 func (ec *executionContext) _EmbeddedCase2(ctx context.Context, sel ast.SelectionSet, obj *EmbeddedCase2) graphql.Marshaler { 15420 fields := graphql.CollectFields(ec.OperationContext, sel, embeddedCase2Implementors) 15421 out := graphql.NewFieldSet(fields) 15422 var invalids uint32 15423 for i, field := range fields { 15424 switch field.Name { 15425 case "__typename": 15426 out.Values[i] = graphql.MarshalString("EmbeddedCase2") 15427 case "unexportedEmbeddedPointerExportedMethod": 15428 15429 out.Values[i] = ec._EmbeddedCase2_unexportedEmbeddedPointerExportedMethod(ctx, field, obj) 15430 15431 if out.Values[i] == graphql.Null { 15432 invalids++ 15433 } 15434 default: 15435 panic("unknown field " + strconv.Quote(field.Name)) 15436 } 15437 } 15438 out.Dispatch() 15439 if invalids > 0 { 15440 return graphql.Null 15441 } 15442 return out 15443 } 15444 15445 var embeddedCase3Implementors = []string{"EmbeddedCase3"} 15446 15447 func (ec *executionContext) _EmbeddedCase3(ctx context.Context, sel ast.SelectionSet, obj *EmbeddedCase3) graphql.Marshaler { 15448 fields := graphql.CollectFields(ec.OperationContext, sel, embeddedCase3Implementors) 15449 out := graphql.NewFieldSet(fields) 15450 var invalids uint32 15451 for i, field := range fields { 15452 switch field.Name { 15453 case "__typename": 15454 out.Values[i] = graphql.MarshalString("EmbeddedCase3") 15455 case "unexportedEmbeddedInterfaceExportedMethod": 15456 15457 out.Values[i] = ec._EmbeddedCase3_unexportedEmbeddedInterfaceExportedMethod(ctx, field, obj) 15458 15459 if out.Values[i] == graphql.Null { 15460 invalids++ 15461 } 15462 default: 15463 panic("unknown field " + strconv.Quote(field.Name)) 15464 } 15465 } 15466 out.Dispatch() 15467 if invalids > 0 { 15468 return graphql.Null 15469 } 15470 return out 15471 } 15472 15473 var embeddedDefaultScalarImplementors = []string{"EmbeddedDefaultScalar"} 15474 15475 func (ec *executionContext) _EmbeddedDefaultScalar(ctx context.Context, sel ast.SelectionSet, obj *EmbeddedDefaultScalar) graphql.Marshaler { 15476 fields := graphql.CollectFields(ec.OperationContext, sel, embeddedDefaultScalarImplementors) 15477 out := graphql.NewFieldSet(fields) 15478 var invalids uint32 15479 for i, field := range fields { 15480 switch field.Name { 15481 case "__typename": 15482 out.Values[i] = graphql.MarshalString("EmbeddedDefaultScalar") 15483 case "value": 15484 15485 out.Values[i] = ec._EmbeddedDefaultScalar_value(ctx, field, obj) 15486 15487 default: 15488 panic("unknown field " + strconv.Quote(field.Name)) 15489 } 15490 } 15491 out.Dispatch() 15492 if invalids > 0 { 15493 return graphql.Null 15494 } 15495 return out 15496 } 15497 15498 var embeddedPointerImplementors = []string{"EmbeddedPointer"} 15499 15500 func (ec *executionContext) _EmbeddedPointer(ctx context.Context, sel ast.SelectionSet, obj *EmbeddedPointerModel) graphql.Marshaler { 15501 fields := graphql.CollectFields(ec.OperationContext, sel, embeddedPointerImplementors) 15502 out := graphql.NewFieldSet(fields) 15503 var invalids uint32 15504 for i, field := range fields { 15505 switch field.Name { 15506 case "__typename": 15507 out.Values[i] = graphql.MarshalString("EmbeddedPointer") 15508 case "ID": 15509 15510 out.Values[i] = ec._EmbeddedPointer_ID(ctx, field, obj) 15511 15512 case "Title": 15513 15514 out.Values[i] = ec._EmbeddedPointer_Title(ctx, field, obj) 15515 15516 default: 15517 panic("unknown field " + strconv.Quote(field.Name)) 15518 } 15519 } 15520 out.Dispatch() 15521 if invalids > 0 { 15522 return graphql.Null 15523 } 15524 return out 15525 } 15526 15527 var errorImplementors = []string{"Error"} 15528 15529 func (ec *executionContext) _Error(ctx context.Context, sel ast.SelectionSet, obj *Error) graphql.Marshaler { 15530 fields := graphql.CollectFields(ec.OperationContext, sel, errorImplementors) 15531 out := graphql.NewFieldSet(fields) 15532 var invalids uint32 15533 for i, field := range fields { 15534 switch field.Name { 15535 case "__typename": 15536 out.Values[i] = graphql.MarshalString("Error") 15537 case "id": 15538 15539 out.Values[i] = ec._Error_id(ctx, field, obj) 15540 15541 if out.Values[i] == graphql.Null { 15542 invalids++ 15543 } 15544 case "errorOnNonRequiredField": 15545 15546 out.Values[i] = ec._Error_errorOnNonRequiredField(ctx, field, obj) 15547 15548 case "errorOnRequiredField": 15549 15550 out.Values[i] = ec._Error_errorOnRequiredField(ctx, field, obj) 15551 15552 if out.Values[i] == graphql.Null { 15553 invalids++ 15554 } 15555 case "nilOnRequiredField": 15556 15557 out.Values[i] = ec._Error_nilOnRequiredField(ctx, field, obj) 15558 15559 if out.Values[i] == graphql.Null { 15560 invalids++ 15561 } 15562 default: 15563 panic("unknown field " + strconv.Quote(field.Name)) 15564 } 15565 } 15566 out.Dispatch() 15567 if invalids > 0 { 15568 return graphql.Null 15569 } 15570 return out 15571 } 15572 15573 var errorsImplementors = []string{"Errors"} 15574 15575 func (ec *executionContext) _Errors(ctx context.Context, sel ast.SelectionSet, obj *Errors) graphql.Marshaler { 15576 fields := graphql.CollectFields(ec.OperationContext, sel, errorsImplementors) 15577 out := graphql.NewFieldSet(fields) 15578 var invalids uint32 15579 for i, field := range fields { 15580 switch field.Name { 15581 case "__typename": 15582 out.Values[i] = graphql.MarshalString("Errors") 15583 case "a": 15584 field := field 15585 15586 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 15587 defer func() { 15588 if r := recover(); r != nil { 15589 ec.Error(ctx, ec.Recover(ctx, r)) 15590 } 15591 }() 15592 res = ec._Errors_a(ctx, field, obj) 15593 if res == graphql.Null { 15594 atomic.AddUint32(&invalids, 1) 15595 } 15596 return res 15597 } 15598 15599 out.Concurrently(i, func() graphql.Marshaler { 15600 return innerFunc(ctx) 15601 15602 }) 15603 case "b": 15604 field := field 15605 15606 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 15607 defer func() { 15608 if r := recover(); r != nil { 15609 ec.Error(ctx, ec.Recover(ctx, r)) 15610 } 15611 }() 15612 res = ec._Errors_b(ctx, field, obj) 15613 if res == graphql.Null { 15614 atomic.AddUint32(&invalids, 1) 15615 } 15616 return res 15617 } 15618 15619 out.Concurrently(i, func() graphql.Marshaler { 15620 return innerFunc(ctx) 15621 15622 }) 15623 case "c": 15624 field := field 15625 15626 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 15627 defer func() { 15628 if r := recover(); r != nil { 15629 ec.Error(ctx, ec.Recover(ctx, r)) 15630 } 15631 }() 15632 res = ec._Errors_c(ctx, field, obj) 15633 if res == graphql.Null { 15634 atomic.AddUint32(&invalids, 1) 15635 } 15636 return res 15637 } 15638 15639 out.Concurrently(i, func() graphql.Marshaler { 15640 return innerFunc(ctx) 15641 15642 }) 15643 case "d": 15644 field := field 15645 15646 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 15647 defer func() { 15648 if r := recover(); r != nil { 15649 ec.Error(ctx, ec.Recover(ctx, r)) 15650 } 15651 }() 15652 res = ec._Errors_d(ctx, field, obj) 15653 if res == graphql.Null { 15654 atomic.AddUint32(&invalids, 1) 15655 } 15656 return res 15657 } 15658 15659 out.Concurrently(i, func() graphql.Marshaler { 15660 return innerFunc(ctx) 15661 15662 }) 15663 case "e": 15664 field := field 15665 15666 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 15667 defer func() { 15668 if r := recover(); r != nil { 15669 ec.Error(ctx, ec.Recover(ctx, r)) 15670 } 15671 }() 15672 res = ec._Errors_e(ctx, field, obj) 15673 if res == graphql.Null { 15674 atomic.AddUint32(&invalids, 1) 15675 } 15676 return res 15677 } 15678 15679 out.Concurrently(i, func() graphql.Marshaler { 15680 return innerFunc(ctx) 15681 15682 }) 15683 default: 15684 panic("unknown field " + strconv.Quote(field.Name)) 15685 } 15686 } 15687 out.Dispatch() 15688 if invalids > 0 { 15689 return graphql.Null 15690 } 15691 return out 15692 } 15693 15694 var fieldsOrderPayloadImplementors = []string{"FieldsOrderPayload"} 15695 15696 func (ec *executionContext) _FieldsOrderPayload(ctx context.Context, sel ast.SelectionSet, obj *FieldsOrderPayload) graphql.Marshaler { 15697 fields := graphql.CollectFields(ec.OperationContext, sel, fieldsOrderPayloadImplementors) 15698 out := graphql.NewFieldSet(fields) 15699 var invalids uint32 15700 for i, field := range fields { 15701 switch field.Name { 15702 case "__typename": 15703 out.Values[i] = graphql.MarshalString("FieldsOrderPayload") 15704 case "firstFieldValue": 15705 15706 out.Values[i] = ec._FieldsOrderPayload_firstFieldValue(ctx, field, obj) 15707 15708 default: 15709 panic("unknown field " + strconv.Quote(field.Name)) 15710 } 15711 } 15712 out.Dispatch() 15713 if invalids > 0 { 15714 return graphql.Null 15715 } 15716 return out 15717 } 15718 15719 var forcedResolverImplementors = []string{"ForcedResolver"} 15720 15721 func (ec *executionContext) _ForcedResolver(ctx context.Context, sel ast.SelectionSet, obj *ForcedResolver) graphql.Marshaler { 15722 fields := graphql.CollectFields(ec.OperationContext, sel, forcedResolverImplementors) 15723 out := graphql.NewFieldSet(fields) 15724 var invalids uint32 15725 for i, field := range fields { 15726 switch field.Name { 15727 case "__typename": 15728 out.Values[i] = graphql.MarshalString("ForcedResolver") 15729 case "field": 15730 field := field 15731 15732 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 15733 defer func() { 15734 if r := recover(); r != nil { 15735 ec.Error(ctx, ec.Recover(ctx, r)) 15736 } 15737 }() 15738 res = ec._ForcedResolver_field(ctx, field, obj) 15739 return res 15740 } 15741 15742 out.Concurrently(i, func() graphql.Marshaler { 15743 return innerFunc(ctx) 15744 15745 }) 15746 default: 15747 panic("unknown field " + strconv.Quote(field.Name)) 15748 } 15749 } 15750 out.Dispatch() 15751 if invalids > 0 { 15752 return graphql.Null 15753 } 15754 return out 15755 } 15756 15757 var innerObjectImplementors = []string{"InnerObject"} 15758 15759 func (ec *executionContext) _InnerObject(ctx context.Context, sel ast.SelectionSet, obj *InnerObject) graphql.Marshaler { 15760 fields := graphql.CollectFields(ec.OperationContext, sel, innerObjectImplementors) 15761 out := graphql.NewFieldSet(fields) 15762 var invalids uint32 15763 for i, field := range fields { 15764 switch field.Name { 15765 case "__typename": 15766 out.Values[i] = graphql.MarshalString("InnerObject") 15767 case "id": 15768 15769 out.Values[i] = ec._InnerObject_id(ctx, field, obj) 15770 15771 if out.Values[i] == graphql.Null { 15772 invalids++ 15773 } 15774 default: 15775 panic("unknown field " + strconv.Quote(field.Name)) 15776 } 15777 } 15778 out.Dispatch() 15779 if invalids > 0 { 15780 return graphql.Null 15781 } 15782 return out 15783 } 15784 15785 var invalidIdentifierImplementors = []string{"InvalidIdentifier"} 15786 15787 func (ec *executionContext) _InvalidIdentifier(ctx context.Context, sel ast.SelectionSet, obj *invalid_packagename.InvalidIdentifier) graphql.Marshaler { 15788 fields := graphql.CollectFields(ec.OperationContext, sel, invalidIdentifierImplementors) 15789 out := graphql.NewFieldSet(fields) 15790 var invalids uint32 15791 for i, field := range fields { 15792 switch field.Name { 15793 case "__typename": 15794 out.Values[i] = graphql.MarshalString("InvalidIdentifier") 15795 case "id": 15796 15797 out.Values[i] = ec._InvalidIdentifier_id(ctx, field, obj) 15798 15799 if out.Values[i] == graphql.Null { 15800 invalids++ 15801 } 15802 default: 15803 panic("unknown field " + strconv.Quote(field.Name)) 15804 } 15805 } 15806 out.Dispatch() 15807 if invalids > 0 { 15808 return graphql.Null 15809 } 15810 return out 15811 } 15812 15813 var itImplementors = []string{"It"} 15814 15815 func (ec *executionContext) _It(ctx context.Context, sel ast.SelectionSet, obj *introspection1.It) graphql.Marshaler { 15816 fields := graphql.CollectFields(ec.OperationContext, sel, itImplementors) 15817 out := graphql.NewFieldSet(fields) 15818 var invalids uint32 15819 for i, field := range fields { 15820 switch field.Name { 15821 case "__typename": 15822 out.Values[i] = graphql.MarshalString("It") 15823 case "id": 15824 15825 out.Values[i] = ec._It_id(ctx, field, obj) 15826 15827 if out.Values[i] == graphql.Null { 15828 invalids++ 15829 } 15830 default: 15831 panic("unknown field " + strconv.Quote(field.Name)) 15832 } 15833 } 15834 out.Dispatch() 15835 if invalids > 0 { 15836 return graphql.Null 15837 } 15838 return out 15839 } 15840 15841 var loopAImplementors = []string{"LoopA"} 15842 15843 func (ec *executionContext) _LoopA(ctx context.Context, sel ast.SelectionSet, obj *LoopA) graphql.Marshaler { 15844 fields := graphql.CollectFields(ec.OperationContext, sel, loopAImplementors) 15845 out := graphql.NewFieldSet(fields) 15846 var invalids uint32 15847 for i, field := range fields { 15848 switch field.Name { 15849 case "__typename": 15850 out.Values[i] = graphql.MarshalString("LoopA") 15851 case "b": 15852 15853 out.Values[i] = ec._LoopA_b(ctx, field, obj) 15854 15855 if out.Values[i] == graphql.Null { 15856 invalids++ 15857 } 15858 default: 15859 panic("unknown field " + strconv.Quote(field.Name)) 15860 } 15861 } 15862 out.Dispatch() 15863 if invalids > 0 { 15864 return graphql.Null 15865 } 15866 return out 15867 } 15868 15869 var loopBImplementors = []string{"LoopB"} 15870 15871 func (ec *executionContext) _LoopB(ctx context.Context, sel ast.SelectionSet, obj *LoopB) graphql.Marshaler { 15872 fields := graphql.CollectFields(ec.OperationContext, sel, loopBImplementors) 15873 out := graphql.NewFieldSet(fields) 15874 var invalids uint32 15875 for i, field := range fields { 15876 switch field.Name { 15877 case "__typename": 15878 out.Values[i] = graphql.MarshalString("LoopB") 15879 case "a": 15880 15881 out.Values[i] = ec._LoopB_a(ctx, field, obj) 15882 15883 if out.Values[i] == graphql.Null { 15884 invalids++ 15885 } 15886 default: 15887 panic("unknown field " + strconv.Quote(field.Name)) 15888 } 15889 } 15890 out.Dispatch() 15891 if invalids > 0 { 15892 return graphql.Null 15893 } 15894 return out 15895 } 15896 15897 var mapImplementors = []string{"Map"} 15898 15899 func (ec *executionContext) _Map(ctx context.Context, sel ast.SelectionSet, obj *Map) graphql.Marshaler { 15900 fields := graphql.CollectFields(ec.OperationContext, sel, mapImplementors) 15901 out := graphql.NewFieldSet(fields) 15902 var invalids uint32 15903 for i, field := range fields { 15904 switch field.Name { 15905 case "__typename": 15906 out.Values[i] = graphql.MarshalString("Map") 15907 case "id": 15908 15909 out.Values[i] = ec._Map_id(ctx, field, obj) 15910 15911 if out.Values[i] == graphql.Null { 15912 invalids++ 15913 } 15914 default: 15915 panic("unknown field " + strconv.Quote(field.Name)) 15916 } 15917 } 15918 out.Dispatch() 15919 if invalids > 0 { 15920 return graphql.Null 15921 } 15922 return out 15923 } 15924 15925 var mapStringInterfaceTypeImplementors = []string{"MapStringInterfaceType"} 15926 15927 func (ec *executionContext) _MapStringInterfaceType(ctx context.Context, sel ast.SelectionSet, obj map[string]interface{}) graphql.Marshaler { 15928 fields := graphql.CollectFields(ec.OperationContext, sel, mapStringInterfaceTypeImplementors) 15929 out := graphql.NewFieldSet(fields) 15930 var invalids uint32 15931 for i, field := range fields { 15932 switch field.Name { 15933 case "__typename": 15934 out.Values[i] = graphql.MarshalString("MapStringInterfaceType") 15935 case "a": 15936 15937 out.Values[i] = ec._MapStringInterfaceType_a(ctx, field, obj) 15938 15939 case "b": 15940 15941 out.Values[i] = ec._MapStringInterfaceType_b(ctx, field, obj) 15942 15943 default: 15944 panic("unknown field " + strconv.Quote(field.Name)) 15945 } 15946 } 15947 out.Dispatch() 15948 if invalids > 0 { 15949 return graphql.Null 15950 } 15951 return out 15952 } 15953 15954 var modelMethodsImplementors = []string{"ModelMethods"} 15955 15956 func (ec *executionContext) _ModelMethods(ctx context.Context, sel ast.SelectionSet, obj *ModelMethods) graphql.Marshaler { 15957 fields := graphql.CollectFields(ec.OperationContext, sel, modelMethodsImplementors) 15958 out := graphql.NewFieldSet(fields) 15959 var invalids uint32 15960 for i, field := range fields { 15961 switch field.Name { 15962 case "__typename": 15963 out.Values[i] = graphql.MarshalString("ModelMethods") 15964 case "resolverField": 15965 field := field 15966 15967 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 15968 defer func() { 15969 if r := recover(); r != nil { 15970 ec.Error(ctx, ec.Recover(ctx, r)) 15971 } 15972 }() 15973 res = ec._ModelMethods_resolverField(ctx, field, obj) 15974 if res == graphql.Null { 15975 atomic.AddUint32(&invalids, 1) 15976 } 15977 return res 15978 } 15979 15980 out.Concurrently(i, func() graphql.Marshaler { 15981 return innerFunc(ctx) 15982 15983 }) 15984 case "noContext": 15985 15986 out.Values[i] = ec._ModelMethods_noContext(ctx, field, obj) 15987 15988 if out.Values[i] == graphql.Null { 15989 atomic.AddUint32(&invalids, 1) 15990 } 15991 case "withContext": 15992 field := field 15993 15994 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 15995 defer func() { 15996 if r := recover(); r != nil { 15997 ec.Error(ctx, ec.Recover(ctx, r)) 15998 } 15999 }() 16000 res = ec._ModelMethods_withContext(ctx, field, obj) 16001 if res == graphql.Null { 16002 atomic.AddUint32(&invalids, 1) 16003 } 16004 return res 16005 } 16006 16007 out.Concurrently(i, func() graphql.Marshaler { 16008 return innerFunc(ctx) 16009 16010 }) 16011 default: 16012 panic("unknown field " + strconv.Quote(field.Name)) 16013 } 16014 } 16015 out.Dispatch() 16016 if invalids > 0 { 16017 return graphql.Null 16018 } 16019 return out 16020 } 16021 16022 var mutationImplementors = []string{"Mutation"} 16023 16024 func (ec *executionContext) _Mutation(ctx context.Context, sel ast.SelectionSet) graphql.Marshaler { 16025 fields := graphql.CollectFields(ec.OperationContext, sel, mutationImplementors) 16026 ctx = graphql.WithFieldContext(ctx, &graphql.FieldContext{ 16027 Object: "Mutation", 16028 }) 16029 16030 out := graphql.NewFieldSet(fields) 16031 var invalids uint32 16032 for i, field := range fields { 16033 innerCtx := graphql.WithRootFieldContext(ctx, &graphql.RootFieldContext{ 16034 Object: field.Name, 16035 Field: field, 16036 }) 16037 16038 switch field.Name { 16039 case "__typename": 16040 out.Values[i] = graphql.MarshalString("Mutation") 16041 case "defaultInput": 16042 16043 out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { 16044 return ec._Mutation_defaultInput(ctx, field) 16045 }) 16046 16047 if out.Values[i] == graphql.Null { 16048 invalids++ 16049 } 16050 case "overrideValueViaInput": 16051 16052 out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { 16053 return ec._Mutation_overrideValueViaInput(ctx, field) 16054 }) 16055 16056 if out.Values[i] == graphql.Null { 16057 invalids++ 16058 } 16059 case "updateSomething": 16060 16061 out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { 16062 return ec._Mutation_updateSomething(ctx, field) 16063 }) 16064 16065 if out.Values[i] == graphql.Null { 16066 invalids++ 16067 } 16068 case "updatePtrToPtr": 16069 16070 out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { 16071 return ec._Mutation_updatePtrToPtr(ctx, field) 16072 }) 16073 16074 if out.Values[i] == graphql.Null { 16075 invalids++ 16076 } 16077 default: 16078 panic("unknown field " + strconv.Quote(field.Name)) 16079 } 16080 } 16081 out.Dispatch() 16082 if invalids > 0 { 16083 return graphql.Null 16084 } 16085 return out 16086 } 16087 16088 var objectDirectivesImplementors = []string{"ObjectDirectives"} 16089 16090 func (ec *executionContext) _ObjectDirectives(ctx context.Context, sel ast.SelectionSet, obj *ObjectDirectives) graphql.Marshaler { 16091 fields := graphql.CollectFields(ec.OperationContext, sel, objectDirectivesImplementors) 16092 out := graphql.NewFieldSet(fields) 16093 var invalids uint32 16094 for i, field := range fields { 16095 switch field.Name { 16096 case "__typename": 16097 out.Values[i] = graphql.MarshalString("ObjectDirectives") 16098 case "text": 16099 16100 out.Values[i] = ec._ObjectDirectives_text(ctx, field, obj) 16101 16102 if out.Values[i] == graphql.Null { 16103 invalids++ 16104 } 16105 case "nullableText": 16106 16107 out.Values[i] = ec._ObjectDirectives_nullableText(ctx, field, obj) 16108 16109 case "order": 16110 16111 out.Values[i] = ec._ObjectDirectives_order(ctx, field, obj) 16112 16113 if out.Values[i] == graphql.Null { 16114 invalids++ 16115 } 16116 default: 16117 panic("unknown field " + strconv.Quote(field.Name)) 16118 } 16119 } 16120 out.Dispatch() 16121 if invalids > 0 { 16122 return graphql.Null 16123 } 16124 return out 16125 } 16126 16127 var objectDirectivesWithCustomGoModelImplementors = []string{"ObjectDirectivesWithCustomGoModel"} 16128 16129 func (ec *executionContext) _ObjectDirectivesWithCustomGoModel(ctx context.Context, sel ast.SelectionSet, obj *ObjectDirectivesWithCustomGoModel) graphql.Marshaler { 16130 fields := graphql.CollectFields(ec.OperationContext, sel, objectDirectivesWithCustomGoModelImplementors) 16131 out := graphql.NewFieldSet(fields) 16132 var invalids uint32 16133 for i, field := range fields { 16134 switch field.Name { 16135 case "__typename": 16136 out.Values[i] = graphql.MarshalString("ObjectDirectivesWithCustomGoModel") 16137 case "nullableText": 16138 16139 out.Values[i] = ec._ObjectDirectivesWithCustomGoModel_nullableText(ctx, field, obj) 16140 16141 default: 16142 panic("unknown field " + strconv.Quote(field.Name)) 16143 } 16144 } 16145 out.Dispatch() 16146 if invalids > 0 { 16147 return graphql.Null 16148 } 16149 return out 16150 } 16151 16152 var outerObjectImplementors = []string{"OuterObject"} 16153 16154 func (ec *executionContext) _OuterObject(ctx context.Context, sel ast.SelectionSet, obj *OuterObject) graphql.Marshaler { 16155 fields := graphql.CollectFields(ec.OperationContext, sel, outerObjectImplementors) 16156 out := graphql.NewFieldSet(fields) 16157 var invalids uint32 16158 for i, field := range fields { 16159 switch field.Name { 16160 case "__typename": 16161 out.Values[i] = graphql.MarshalString("OuterObject") 16162 case "inner": 16163 16164 out.Values[i] = ec._OuterObject_inner(ctx, field, obj) 16165 16166 if out.Values[i] == graphql.Null { 16167 invalids++ 16168 } 16169 default: 16170 panic("unknown field " + strconv.Quote(field.Name)) 16171 } 16172 } 16173 out.Dispatch() 16174 if invalids > 0 { 16175 return graphql.Null 16176 } 16177 return out 16178 } 16179 16180 var overlappingFieldsImplementors = []string{"OverlappingFields"} 16181 16182 func (ec *executionContext) _OverlappingFields(ctx context.Context, sel ast.SelectionSet, obj *OverlappingFields) graphql.Marshaler { 16183 fields := graphql.CollectFields(ec.OperationContext, sel, overlappingFieldsImplementors) 16184 out := graphql.NewFieldSet(fields) 16185 var invalids uint32 16186 for i, field := range fields { 16187 switch field.Name { 16188 case "__typename": 16189 out.Values[i] = graphql.MarshalString("OverlappingFields") 16190 case "oneFoo": 16191 16192 out.Values[i] = ec._OverlappingFields_oneFoo(ctx, field, obj) 16193 16194 if out.Values[i] == graphql.Null { 16195 atomic.AddUint32(&invalids, 1) 16196 } 16197 case "twoFoo": 16198 16199 out.Values[i] = ec._OverlappingFields_twoFoo(ctx, field, obj) 16200 16201 if out.Values[i] == graphql.Null { 16202 atomic.AddUint32(&invalids, 1) 16203 } 16204 case "oldFoo": 16205 field := field 16206 16207 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16208 defer func() { 16209 if r := recover(); r != nil { 16210 ec.Error(ctx, ec.Recover(ctx, r)) 16211 } 16212 }() 16213 res = ec._OverlappingFields_oldFoo(ctx, field, obj) 16214 if res == graphql.Null { 16215 atomic.AddUint32(&invalids, 1) 16216 } 16217 return res 16218 } 16219 16220 out.Concurrently(i, func() graphql.Marshaler { 16221 return innerFunc(ctx) 16222 16223 }) 16224 case "newFoo": 16225 16226 out.Values[i] = ec._OverlappingFields_newFoo(ctx, field, obj) 16227 16228 if out.Values[i] == graphql.Null { 16229 atomic.AddUint32(&invalids, 1) 16230 } 16231 case "new_foo": 16232 16233 out.Values[i] = ec._OverlappingFields_new_foo(ctx, field, obj) 16234 16235 if out.Values[i] == graphql.Null { 16236 atomic.AddUint32(&invalids, 1) 16237 } 16238 default: 16239 panic("unknown field " + strconv.Quote(field.Name)) 16240 } 16241 } 16242 out.Dispatch() 16243 if invalids > 0 { 16244 return graphql.Null 16245 } 16246 return out 16247 } 16248 16249 var panicsImplementors = []string{"Panics"} 16250 16251 func (ec *executionContext) _Panics(ctx context.Context, sel ast.SelectionSet, obj *Panics) graphql.Marshaler { 16252 fields := graphql.CollectFields(ec.OperationContext, sel, panicsImplementors) 16253 out := graphql.NewFieldSet(fields) 16254 var invalids uint32 16255 for i, field := range fields { 16256 switch field.Name { 16257 case "__typename": 16258 out.Values[i] = graphql.MarshalString("Panics") 16259 case "fieldScalarMarshal": 16260 field := field 16261 16262 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16263 defer func() { 16264 if r := recover(); r != nil { 16265 ec.Error(ctx, ec.Recover(ctx, r)) 16266 } 16267 }() 16268 res = ec._Panics_fieldScalarMarshal(ctx, field, obj) 16269 if res == graphql.Null { 16270 atomic.AddUint32(&invalids, 1) 16271 } 16272 return res 16273 } 16274 16275 out.Concurrently(i, func() graphql.Marshaler { 16276 return innerFunc(ctx) 16277 16278 }) 16279 case "fieldFuncMarshal": 16280 field := field 16281 16282 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16283 defer func() { 16284 if r := recover(); r != nil { 16285 ec.Error(ctx, ec.Recover(ctx, r)) 16286 } 16287 }() 16288 res = ec._Panics_fieldFuncMarshal(ctx, field, obj) 16289 if res == graphql.Null { 16290 atomic.AddUint32(&invalids, 1) 16291 } 16292 return res 16293 } 16294 16295 out.Concurrently(i, func() graphql.Marshaler { 16296 return innerFunc(ctx) 16297 16298 }) 16299 case "argUnmarshal": 16300 field := field 16301 16302 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16303 defer func() { 16304 if r := recover(); r != nil { 16305 ec.Error(ctx, ec.Recover(ctx, r)) 16306 } 16307 }() 16308 res = ec._Panics_argUnmarshal(ctx, field, obj) 16309 if res == graphql.Null { 16310 atomic.AddUint32(&invalids, 1) 16311 } 16312 return res 16313 } 16314 16315 out.Concurrently(i, func() graphql.Marshaler { 16316 return innerFunc(ctx) 16317 16318 }) 16319 default: 16320 panic("unknown field " + strconv.Quote(field.Name)) 16321 } 16322 } 16323 out.Dispatch() 16324 if invalids > 0 { 16325 return graphql.Null 16326 } 16327 return out 16328 } 16329 16330 var petImplementors = []string{"Pet"} 16331 16332 func (ec *executionContext) _Pet(ctx context.Context, sel ast.SelectionSet, obj *Pet) graphql.Marshaler { 16333 fields := graphql.CollectFields(ec.OperationContext, sel, petImplementors) 16334 out := graphql.NewFieldSet(fields) 16335 var invalids uint32 16336 for i, field := range fields { 16337 switch field.Name { 16338 case "__typename": 16339 out.Values[i] = graphql.MarshalString("Pet") 16340 case "id": 16341 16342 out.Values[i] = ec._Pet_id(ctx, field, obj) 16343 16344 if out.Values[i] == graphql.Null { 16345 atomic.AddUint32(&invalids, 1) 16346 } 16347 case "friends": 16348 field := field 16349 16350 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16351 defer func() { 16352 if r := recover(); r != nil { 16353 ec.Error(ctx, ec.Recover(ctx, r)) 16354 } 16355 }() 16356 res = ec._Pet_friends(ctx, field, obj) 16357 return res 16358 } 16359 16360 out.Concurrently(i, func() graphql.Marshaler { 16361 return innerFunc(ctx) 16362 16363 }) 16364 default: 16365 panic("unknown field " + strconv.Quote(field.Name)) 16366 } 16367 } 16368 out.Dispatch() 16369 if invalids > 0 { 16370 return graphql.Null 16371 } 16372 return out 16373 } 16374 16375 var primitiveImplementors = []string{"Primitive"} 16376 16377 func (ec *executionContext) _Primitive(ctx context.Context, sel ast.SelectionSet, obj *Primitive) graphql.Marshaler { 16378 fields := graphql.CollectFields(ec.OperationContext, sel, primitiveImplementors) 16379 out := graphql.NewFieldSet(fields) 16380 var invalids uint32 16381 for i, field := range fields { 16382 switch field.Name { 16383 case "__typename": 16384 out.Values[i] = graphql.MarshalString("Primitive") 16385 case "value": 16386 field := field 16387 16388 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16389 defer func() { 16390 if r := recover(); r != nil { 16391 ec.Error(ctx, ec.Recover(ctx, r)) 16392 } 16393 }() 16394 res = ec._Primitive_value(ctx, field, obj) 16395 if res == graphql.Null { 16396 atomic.AddUint32(&invalids, 1) 16397 } 16398 return res 16399 } 16400 16401 out.Concurrently(i, func() graphql.Marshaler { 16402 return innerFunc(ctx) 16403 16404 }) 16405 case "squared": 16406 16407 out.Values[i] = ec._Primitive_squared(ctx, field, obj) 16408 16409 if out.Values[i] == graphql.Null { 16410 atomic.AddUint32(&invalids, 1) 16411 } 16412 default: 16413 panic("unknown field " + strconv.Quote(field.Name)) 16414 } 16415 } 16416 out.Dispatch() 16417 if invalids > 0 { 16418 return graphql.Null 16419 } 16420 return out 16421 } 16422 16423 var primitiveStringImplementors = []string{"PrimitiveString"} 16424 16425 func (ec *executionContext) _PrimitiveString(ctx context.Context, sel ast.SelectionSet, obj *PrimitiveString) graphql.Marshaler { 16426 fields := graphql.CollectFields(ec.OperationContext, sel, primitiveStringImplementors) 16427 out := graphql.NewFieldSet(fields) 16428 var invalids uint32 16429 for i, field := range fields { 16430 switch field.Name { 16431 case "__typename": 16432 out.Values[i] = graphql.MarshalString("PrimitiveString") 16433 case "value": 16434 field := field 16435 16436 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16437 defer func() { 16438 if r := recover(); r != nil { 16439 ec.Error(ctx, ec.Recover(ctx, r)) 16440 } 16441 }() 16442 res = ec._PrimitiveString_value(ctx, field, obj) 16443 if res == graphql.Null { 16444 atomic.AddUint32(&invalids, 1) 16445 } 16446 return res 16447 } 16448 16449 out.Concurrently(i, func() graphql.Marshaler { 16450 return innerFunc(ctx) 16451 16452 }) 16453 case "doubled": 16454 16455 out.Values[i] = ec._PrimitiveString_doubled(ctx, field, obj) 16456 16457 if out.Values[i] == graphql.Null { 16458 atomic.AddUint32(&invalids, 1) 16459 } 16460 case "len": 16461 field := field 16462 16463 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16464 defer func() { 16465 if r := recover(); r != nil { 16466 ec.Error(ctx, ec.Recover(ctx, r)) 16467 } 16468 }() 16469 res = ec._PrimitiveString_len(ctx, field, obj) 16470 if res == graphql.Null { 16471 atomic.AddUint32(&invalids, 1) 16472 } 16473 return res 16474 } 16475 16476 out.Concurrently(i, func() graphql.Marshaler { 16477 return innerFunc(ctx) 16478 16479 }) 16480 default: 16481 panic("unknown field " + strconv.Quote(field.Name)) 16482 } 16483 } 16484 out.Dispatch() 16485 if invalids > 0 { 16486 return graphql.Null 16487 } 16488 return out 16489 } 16490 16491 var ptrToPtrInnerImplementors = []string{"PtrToPtrInner"} 16492 16493 func (ec *executionContext) _PtrToPtrInner(ctx context.Context, sel ast.SelectionSet, obj *PtrToPtrInner) graphql.Marshaler { 16494 fields := graphql.CollectFields(ec.OperationContext, sel, ptrToPtrInnerImplementors) 16495 out := graphql.NewFieldSet(fields) 16496 var invalids uint32 16497 for i, field := range fields { 16498 switch field.Name { 16499 case "__typename": 16500 out.Values[i] = graphql.MarshalString("PtrToPtrInner") 16501 case "key": 16502 16503 out.Values[i] = ec._PtrToPtrInner_key(ctx, field, obj) 16504 16505 if out.Values[i] == graphql.Null { 16506 invalids++ 16507 } 16508 case "value": 16509 16510 out.Values[i] = ec._PtrToPtrInner_value(ctx, field, obj) 16511 16512 if out.Values[i] == graphql.Null { 16513 invalids++ 16514 } 16515 default: 16516 panic("unknown field " + strconv.Quote(field.Name)) 16517 } 16518 } 16519 out.Dispatch() 16520 if invalids > 0 { 16521 return graphql.Null 16522 } 16523 return out 16524 } 16525 16526 var ptrToPtrOuterImplementors = []string{"PtrToPtrOuter"} 16527 16528 func (ec *executionContext) _PtrToPtrOuter(ctx context.Context, sel ast.SelectionSet, obj *PtrToPtrOuter) graphql.Marshaler { 16529 fields := graphql.CollectFields(ec.OperationContext, sel, ptrToPtrOuterImplementors) 16530 out := graphql.NewFieldSet(fields) 16531 var invalids uint32 16532 for i, field := range fields { 16533 switch field.Name { 16534 case "__typename": 16535 out.Values[i] = graphql.MarshalString("PtrToPtrOuter") 16536 case "name": 16537 16538 out.Values[i] = ec._PtrToPtrOuter_name(ctx, field, obj) 16539 16540 if out.Values[i] == graphql.Null { 16541 invalids++ 16542 } 16543 case "inner": 16544 16545 out.Values[i] = ec._PtrToPtrOuter_inner(ctx, field, obj) 16546 16547 case "stupidInner": 16548 16549 out.Values[i] = ec._PtrToPtrOuter_stupidInner(ctx, field, obj) 16550 16551 default: 16552 panic("unknown field " + strconv.Quote(field.Name)) 16553 } 16554 } 16555 out.Dispatch() 16556 if invalids > 0 { 16557 return graphql.Null 16558 } 16559 return out 16560 } 16561 16562 var ptrToSliceContainerImplementors = []string{"PtrToSliceContainer"} 16563 16564 func (ec *executionContext) _PtrToSliceContainer(ctx context.Context, sel ast.SelectionSet, obj *PtrToSliceContainer) graphql.Marshaler { 16565 fields := graphql.CollectFields(ec.OperationContext, sel, ptrToSliceContainerImplementors) 16566 out := graphql.NewFieldSet(fields) 16567 var invalids uint32 16568 for i, field := range fields { 16569 switch field.Name { 16570 case "__typename": 16571 out.Values[i] = graphql.MarshalString("PtrToSliceContainer") 16572 case "ptrToSlice": 16573 16574 out.Values[i] = ec._PtrToSliceContainer_ptrToSlice(ctx, field, obj) 16575 16576 default: 16577 panic("unknown field " + strconv.Quote(field.Name)) 16578 } 16579 } 16580 out.Dispatch() 16581 if invalids > 0 { 16582 return graphql.Null 16583 } 16584 return out 16585 } 16586 16587 var queryImplementors = []string{"Query"} 16588 16589 func (ec *executionContext) _Query(ctx context.Context, sel ast.SelectionSet) graphql.Marshaler { 16590 fields := graphql.CollectFields(ec.OperationContext, sel, queryImplementors) 16591 ctx = graphql.WithFieldContext(ctx, &graphql.FieldContext{ 16592 Object: "Query", 16593 }) 16594 16595 out := graphql.NewFieldSet(fields) 16596 var invalids uint32 16597 for i, field := range fields { 16598 innerCtx := graphql.WithRootFieldContext(ctx, &graphql.RootFieldContext{ 16599 Object: field.Name, 16600 Field: field, 16601 }) 16602 16603 switch field.Name { 16604 case "__typename": 16605 out.Values[i] = graphql.MarshalString("Query") 16606 case "invalidIdentifier": 16607 field := field 16608 16609 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16610 defer func() { 16611 if r := recover(); r != nil { 16612 ec.Error(ctx, ec.Recover(ctx, r)) 16613 } 16614 }() 16615 res = ec._Query_invalidIdentifier(ctx, field) 16616 return res 16617 } 16618 16619 rrm := func(ctx context.Context) graphql.Marshaler { 16620 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 16621 } 16622 16623 out.Concurrently(i, func() graphql.Marshaler { 16624 return rrm(innerCtx) 16625 }) 16626 case "collision": 16627 field := field 16628 16629 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16630 defer func() { 16631 if r := recover(); r != nil { 16632 ec.Error(ctx, ec.Recover(ctx, r)) 16633 } 16634 }() 16635 res = ec._Query_collision(ctx, field) 16636 return res 16637 } 16638 16639 rrm := func(ctx context.Context) graphql.Marshaler { 16640 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 16641 } 16642 16643 out.Concurrently(i, func() graphql.Marshaler { 16644 return rrm(innerCtx) 16645 }) 16646 case "mapInput": 16647 field := field 16648 16649 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16650 defer func() { 16651 if r := recover(); r != nil { 16652 ec.Error(ctx, ec.Recover(ctx, r)) 16653 } 16654 }() 16655 res = ec._Query_mapInput(ctx, field) 16656 return res 16657 } 16658 16659 rrm := func(ctx context.Context) graphql.Marshaler { 16660 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 16661 } 16662 16663 out.Concurrently(i, func() graphql.Marshaler { 16664 return rrm(innerCtx) 16665 }) 16666 case "recursive": 16667 field := field 16668 16669 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16670 defer func() { 16671 if r := recover(); r != nil { 16672 ec.Error(ctx, ec.Recover(ctx, r)) 16673 } 16674 }() 16675 res = ec._Query_recursive(ctx, field) 16676 return res 16677 } 16678 16679 rrm := func(ctx context.Context) graphql.Marshaler { 16680 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 16681 } 16682 16683 out.Concurrently(i, func() graphql.Marshaler { 16684 return rrm(innerCtx) 16685 }) 16686 case "nestedInputs": 16687 field := field 16688 16689 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16690 defer func() { 16691 if r := recover(); r != nil { 16692 ec.Error(ctx, ec.Recover(ctx, r)) 16693 } 16694 }() 16695 res = ec._Query_nestedInputs(ctx, field) 16696 return res 16697 } 16698 16699 rrm := func(ctx context.Context) graphql.Marshaler { 16700 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 16701 } 16702 16703 out.Concurrently(i, func() graphql.Marshaler { 16704 return rrm(innerCtx) 16705 }) 16706 case "nestedOutputs": 16707 field := field 16708 16709 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16710 defer func() { 16711 if r := recover(); r != nil { 16712 ec.Error(ctx, ec.Recover(ctx, r)) 16713 } 16714 }() 16715 res = ec._Query_nestedOutputs(ctx, field) 16716 return res 16717 } 16718 16719 rrm := func(ctx context.Context) graphql.Marshaler { 16720 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 16721 } 16722 16723 out.Concurrently(i, func() graphql.Marshaler { 16724 return rrm(innerCtx) 16725 }) 16726 case "modelMethods": 16727 field := field 16728 16729 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16730 defer func() { 16731 if r := recover(); r != nil { 16732 ec.Error(ctx, ec.Recover(ctx, r)) 16733 } 16734 }() 16735 res = ec._Query_modelMethods(ctx, field) 16736 return res 16737 } 16738 16739 rrm := func(ctx context.Context) graphql.Marshaler { 16740 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 16741 } 16742 16743 out.Concurrently(i, func() graphql.Marshaler { 16744 return rrm(innerCtx) 16745 }) 16746 case "user": 16747 field := field 16748 16749 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16750 defer func() { 16751 if r := recover(); r != nil { 16752 ec.Error(ctx, ec.Recover(ctx, r)) 16753 } 16754 }() 16755 res = ec._Query_user(ctx, field) 16756 if res == graphql.Null { 16757 atomic.AddUint32(&invalids, 1) 16758 } 16759 return res 16760 } 16761 16762 rrm := func(ctx context.Context) graphql.Marshaler { 16763 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 16764 } 16765 16766 out.Concurrently(i, func() graphql.Marshaler { 16767 return rrm(innerCtx) 16768 }) 16769 case "nullableArg": 16770 field := field 16771 16772 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16773 defer func() { 16774 if r := recover(); r != nil { 16775 ec.Error(ctx, ec.Recover(ctx, r)) 16776 } 16777 }() 16778 res = ec._Query_nullableArg(ctx, field) 16779 return res 16780 } 16781 16782 rrm := func(ctx context.Context) graphql.Marshaler { 16783 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 16784 } 16785 16786 out.Concurrently(i, func() graphql.Marshaler { 16787 return rrm(innerCtx) 16788 }) 16789 case "inputSlice": 16790 field := field 16791 16792 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16793 defer func() { 16794 if r := recover(); r != nil { 16795 ec.Error(ctx, ec.Recover(ctx, r)) 16796 } 16797 }() 16798 res = ec._Query_inputSlice(ctx, field) 16799 if res == graphql.Null { 16800 atomic.AddUint32(&invalids, 1) 16801 } 16802 return res 16803 } 16804 16805 rrm := func(ctx context.Context) graphql.Marshaler { 16806 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 16807 } 16808 16809 out.Concurrently(i, func() graphql.Marshaler { 16810 return rrm(innerCtx) 16811 }) 16812 case "inputNullableSlice": 16813 field := field 16814 16815 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16816 defer func() { 16817 if r := recover(); r != nil { 16818 ec.Error(ctx, ec.Recover(ctx, r)) 16819 } 16820 }() 16821 res = ec._Query_inputNullableSlice(ctx, field) 16822 if res == graphql.Null { 16823 atomic.AddUint32(&invalids, 1) 16824 } 16825 return res 16826 } 16827 16828 rrm := func(ctx context.Context) graphql.Marshaler { 16829 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 16830 } 16831 16832 out.Concurrently(i, func() graphql.Marshaler { 16833 return rrm(innerCtx) 16834 }) 16835 case "shapeUnion": 16836 field := field 16837 16838 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16839 defer func() { 16840 if r := recover(); r != nil { 16841 ec.Error(ctx, ec.Recover(ctx, r)) 16842 } 16843 }() 16844 res = ec._Query_shapeUnion(ctx, field) 16845 if res == graphql.Null { 16846 atomic.AddUint32(&invalids, 1) 16847 } 16848 return res 16849 } 16850 16851 rrm := func(ctx context.Context) graphql.Marshaler { 16852 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 16853 } 16854 16855 out.Concurrently(i, func() graphql.Marshaler { 16856 return rrm(innerCtx) 16857 }) 16858 case "autobind": 16859 field := field 16860 16861 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16862 defer func() { 16863 if r := recover(); r != nil { 16864 ec.Error(ctx, ec.Recover(ctx, r)) 16865 } 16866 }() 16867 res = ec._Query_autobind(ctx, field) 16868 return res 16869 } 16870 16871 rrm := func(ctx context.Context) graphql.Marshaler { 16872 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 16873 } 16874 16875 out.Concurrently(i, func() graphql.Marshaler { 16876 return rrm(innerCtx) 16877 }) 16878 case "deprecatedField": 16879 field := field 16880 16881 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16882 defer func() { 16883 if r := recover(); r != nil { 16884 ec.Error(ctx, ec.Recover(ctx, r)) 16885 } 16886 }() 16887 res = ec._Query_deprecatedField(ctx, field) 16888 if res == graphql.Null { 16889 atomic.AddUint32(&invalids, 1) 16890 } 16891 return res 16892 } 16893 16894 rrm := func(ctx context.Context) graphql.Marshaler { 16895 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 16896 } 16897 16898 out.Concurrently(i, func() graphql.Marshaler { 16899 return rrm(innerCtx) 16900 }) 16901 case "overlapping": 16902 field := field 16903 16904 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16905 defer func() { 16906 if r := recover(); r != nil { 16907 ec.Error(ctx, ec.Recover(ctx, r)) 16908 } 16909 }() 16910 res = ec._Query_overlapping(ctx, field) 16911 return res 16912 } 16913 16914 rrm := func(ctx context.Context) graphql.Marshaler { 16915 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 16916 } 16917 16918 out.Concurrently(i, func() graphql.Marshaler { 16919 return rrm(innerCtx) 16920 }) 16921 case "defaultParameters": 16922 field := field 16923 16924 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16925 defer func() { 16926 if r := recover(); r != nil { 16927 ec.Error(ctx, ec.Recover(ctx, r)) 16928 } 16929 }() 16930 res = ec._Query_defaultParameters(ctx, field) 16931 if res == graphql.Null { 16932 atomic.AddUint32(&invalids, 1) 16933 } 16934 return res 16935 } 16936 16937 rrm := func(ctx context.Context) graphql.Marshaler { 16938 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 16939 } 16940 16941 out.Concurrently(i, func() graphql.Marshaler { 16942 return rrm(innerCtx) 16943 }) 16944 case "directiveArg": 16945 field := field 16946 16947 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16948 defer func() { 16949 if r := recover(); r != nil { 16950 ec.Error(ctx, ec.Recover(ctx, r)) 16951 } 16952 }() 16953 res = ec._Query_directiveArg(ctx, field) 16954 return res 16955 } 16956 16957 rrm := func(ctx context.Context) graphql.Marshaler { 16958 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 16959 } 16960 16961 out.Concurrently(i, func() graphql.Marshaler { 16962 return rrm(innerCtx) 16963 }) 16964 case "directiveNullableArg": 16965 field := field 16966 16967 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16968 defer func() { 16969 if r := recover(); r != nil { 16970 ec.Error(ctx, ec.Recover(ctx, r)) 16971 } 16972 }() 16973 res = ec._Query_directiveNullableArg(ctx, field) 16974 return res 16975 } 16976 16977 rrm := func(ctx context.Context) graphql.Marshaler { 16978 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 16979 } 16980 16981 out.Concurrently(i, func() graphql.Marshaler { 16982 return rrm(innerCtx) 16983 }) 16984 case "directiveInputNullable": 16985 field := field 16986 16987 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 16988 defer func() { 16989 if r := recover(); r != nil { 16990 ec.Error(ctx, ec.Recover(ctx, r)) 16991 } 16992 }() 16993 res = ec._Query_directiveInputNullable(ctx, field) 16994 return res 16995 } 16996 16997 rrm := func(ctx context.Context) graphql.Marshaler { 16998 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 16999 } 17000 17001 out.Concurrently(i, func() graphql.Marshaler { 17002 return rrm(innerCtx) 17003 }) 17004 case "directiveInput": 17005 field := field 17006 17007 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17008 defer func() { 17009 if r := recover(); r != nil { 17010 ec.Error(ctx, ec.Recover(ctx, r)) 17011 } 17012 }() 17013 res = ec._Query_directiveInput(ctx, field) 17014 return res 17015 } 17016 17017 rrm := func(ctx context.Context) graphql.Marshaler { 17018 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17019 } 17020 17021 out.Concurrently(i, func() graphql.Marshaler { 17022 return rrm(innerCtx) 17023 }) 17024 case "directiveInputType": 17025 field := field 17026 17027 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17028 defer func() { 17029 if r := recover(); r != nil { 17030 ec.Error(ctx, ec.Recover(ctx, r)) 17031 } 17032 }() 17033 res = ec._Query_directiveInputType(ctx, field) 17034 return res 17035 } 17036 17037 rrm := func(ctx context.Context) graphql.Marshaler { 17038 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17039 } 17040 17041 out.Concurrently(i, func() graphql.Marshaler { 17042 return rrm(innerCtx) 17043 }) 17044 case "directiveObject": 17045 field := field 17046 17047 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17048 defer func() { 17049 if r := recover(); r != nil { 17050 ec.Error(ctx, ec.Recover(ctx, r)) 17051 } 17052 }() 17053 res = ec._Query_directiveObject(ctx, field) 17054 return res 17055 } 17056 17057 rrm := func(ctx context.Context) graphql.Marshaler { 17058 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17059 } 17060 17061 out.Concurrently(i, func() graphql.Marshaler { 17062 return rrm(innerCtx) 17063 }) 17064 case "directiveObjectWithCustomGoModel": 17065 field := field 17066 17067 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17068 defer func() { 17069 if r := recover(); r != nil { 17070 ec.Error(ctx, ec.Recover(ctx, r)) 17071 } 17072 }() 17073 res = ec._Query_directiveObjectWithCustomGoModel(ctx, field) 17074 return res 17075 } 17076 17077 rrm := func(ctx context.Context) graphql.Marshaler { 17078 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17079 } 17080 17081 out.Concurrently(i, func() graphql.Marshaler { 17082 return rrm(innerCtx) 17083 }) 17084 case "directiveFieldDef": 17085 field := field 17086 17087 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17088 defer func() { 17089 if r := recover(); r != nil { 17090 ec.Error(ctx, ec.Recover(ctx, r)) 17091 } 17092 }() 17093 res = ec._Query_directiveFieldDef(ctx, field) 17094 if res == graphql.Null { 17095 atomic.AddUint32(&invalids, 1) 17096 } 17097 return res 17098 } 17099 17100 rrm := func(ctx context.Context) graphql.Marshaler { 17101 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17102 } 17103 17104 out.Concurrently(i, func() graphql.Marshaler { 17105 return rrm(innerCtx) 17106 }) 17107 case "directiveField": 17108 field := field 17109 17110 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17111 defer func() { 17112 if r := recover(); r != nil { 17113 ec.Error(ctx, ec.Recover(ctx, r)) 17114 } 17115 }() 17116 res = ec._Query_directiveField(ctx, field) 17117 return res 17118 } 17119 17120 rrm := func(ctx context.Context) graphql.Marshaler { 17121 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17122 } 17123 17124 out.Concurrently(i, func() graphql.Marshaler { 17125 return rrm(innerCtx) 17126 }) 17127 case "directiveDouble": 17128 field := field 17129 17130 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17131 defer func() { 17132 if r := recover(); r != nil { 17133 ec.Error(ctx, ec.Recover(ctx, r)) 17134 } 17135 }() 17136 res = ec._Query_directiveDouble(ctx, field) 17137 return res 17138 } 17139 17140 rrm := func(ctx context.Context) graphql.Marshaler { 17141 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17142 } 17143 17144 out.Concurrently(i, func() graphql.Marshaler { 17145 return rrm(innerCtx) 17146 }) 17147 case "directiveUnimplemented": 17148 field := field 17149 17150 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17151 defer func() { 17152 if r := recover(); r != nil { 17153 ec.Error(ctx, ec.Recover(ctx, r)) 17154 } 17155 }() 17156 res = ec._Query_directiveUnimplemented(ctx, field) 17157 return res 17158 } 17159 17160 rrm := func(ctx context.Context) graphql.Marshaler { 17161 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17162 } 17163 17164 out.Concurrently(i, func() graphql.Marshaler { 17165 return rrm(innerCtx) 17166 }) 17167 case "embeddedCase1": 17168 field := field 17169 17170 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17171 defer func() { 17172 if r := recover(); r != nil { 17173 ec.Error(ctx, ec.Recover(ctx, r)) 17174 } 17175 }() 17176 res = ec._Query_embeddedCase1(ctx, field) 17177 return res 17178 } 17179 17180 rrm := func(ctx context.Context) graphql.Marshaler { 17181 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17182 } 17183 17184 out.Concurrently(i, func() graphql.Marshaler { 17185 return rrm(innerCtx) 17186 }) 17187 case "embeddedCase2": 17188 field := field 17189 17190 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17191 defer func() { 17192 if r := recover(); r != nil { 17193 ec.Error(ctx, ec.Recover(ctx, r)) 17194 } 17195 }() 17196 res = ec._Query_embeddedCase2(ctx, field) 17197 return res 17198 } 17199 17200 rrm := func(ctx context.Context) graphql.Marshaler { 17201 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17202 } 17203 17204 out.Concurrently(i, func() graphql.Marshaler { 17205 return rrm(innerCtx) 17206 }) 17207 case "embeddedCase3": 17208 field := field 17209 17210 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17211 defer func() { 17212 if r := recover(); r != nil { 17213 ec.Error(ctx, ec.Recover(ctx, r)) 17214 } 17215 }() 17216 res = ec._Query_embeddedCase3(ctx, field) 17217 return res 17218 } 17219 17220 rrm := func(ctx context.Context) graphql.Marshaler { 17221 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17222 } 17223 17224 out.Concurrently(i, func() graphql.Marshaler { 17225 return rrm(innerCtx) 17226 }) 17227 case "enumInInput": 17228 field := field 17229 17230 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17231 defer func() { 17232 if r := recover(); r != nil { 17233 ec.Error(ctx, ec.Recover(ctx, r)) 17234 } 17235 }() 17236 res = ec._Query_enumInInput(ctx, field) 17237 if res == graphql.Null { 17238 atomic.AddUint32(&invalids, 1) 17239 } 17240 return res 17241 } 17242 17243 rrm := func(ctx context.Context) graphql.Marshaler { 17244 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17245 } 17246 17247 out.Concurrently(i, func() graphql.Marshaler { 17248 return rrm(innerCtx) 17249 }) 17250 case "shapes": 17251 field := field 17252 17253 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17254 defer func() { 17255 if r := recover(); r != nil { 17256 ec.Error(ctx, ec.Recover(ctx, r)) 17257 } 17258 }() 17259 res = ec._Query_shapes(ctx, field) 17260 return res 17261 } 17262 17263 rrm := func(ctx context.Context) graphql.Marshaler { 17264 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17265 } 17266 17267 out.Concurrently(i, func() graphql.Marshaler { 17268 return rrm(innerCtx) 17269 }) 17270 case "noShape": 17271 field := field 17272 17273 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17274 defer func() { 17275 if r := recover(); r != nil { 17276 ec.Error(ctx, ec.Recover(ctx, r)) 17277 } 17278 }() 17279 res = ec._Query_noShape(ctx, field) 17280 return res 17281 } 17282 17283 rrm := func(ctx context.Context) graphql.Marshaler { 17284 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17285 } 17286 17287 out.Concurrently(i, func() graphql.Marshaler { 17288 return rrm(innerCtx) 17289 }) 17290 case "node": 17291 field := field 17292 17293 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17294 defer func() { 17295 if r := recover(); r != nil { 17296 ec.Error(ctx, ec.Recover(ctx, r)) 17297 } 17298 }() 17299 res = ec._Query_node(ctx, field) 17300 if res == graphql.Null { 17301 atomic.AddUint32(&invalids, 1) 17302 } 17303 return res 17304 } 17305 17306 rrm := func(ctx context.Context) graphql.Marshaler { 17307 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17308 } 17309 17310 out.Concurrently(i, func() graphql.Marshaler { 17311 return rrm(innerCtx) 17312 }) 17313 case "noShapeTypedNil": 17314 field := field 17315 17316 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17317 defer func() { 17318 if r := recover(); r != nil { 17319 ec.Error(ctx, ec.Recover(ctx, r)) 17320 } 17321 }() 17322 res = ec._Query_noShapeTypedNil(ctx, field) 17323 return res 17324 } 17325 17326 rrm := func(ctx context.Context) graphql.Marshaler { 17327 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17328 } 17329 17330 out.Concurrently(i, func() graphql.Marshaler { 17331 return rrm(innerCtx) 17332 }) 17333 case "animal": 17334 field := field 17335 17336 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17337 defer func() { 17338 if r := recover(); r != nil { 17339 ec.Error(ctx, ec.Recover(ctx, r)) 17340 } 17341 }() 17342 res = ec._Query_animal(ctx, field) 17343 return res 17344 } 17345 17346 rrm := func(ctx context.Context) graphql.Marshaler { 17347 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17348 } 17349 17350 out.Concurrently(i, func() graphql.Marshaler { 17351 return rrm(innerCtx) 17352 }) 17353 case "notAnInterface": 17354 field := field 17355 17356 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17357 defer func() { 17358 if r := recover(); r != nil { 17359 ec.Error(ctx, ec.Recover(ctx, r)) 17360 } 17361 }() 17362 res = ec._Query_notAnInterface(ctx, field) 17363 return res 17364 } 17365 17366 rrm := func(ctx context.Context) graphql.Marshaler { 17367 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17368 } 17369 17370 out.Concurrently(i, func() graphql.Marshaler { 17371 return rrm(innerCtx) 17372 }) 17373 case "issue896a": 17374 field := field 17375 17376 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17377 defer func() { 17378 if r := recover(); r != nil { 17379 ec.Error(ctx, ec.Recover(ctx, r)) 17380 } 17381 }() 17382 res = ec._Query_issue896a(ctx, field) 17383 return res 17384 } 17385 17386 rrm := func(ctx context.Context) graphql.Marshaler { 17387 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17388 } 17389 17390 out.Concurrently(i, func() graphql.Marshaler { 17391 return rrm(innerCtx) 17392 }) 17393 case "mapStringInterface": 17394 field := field 17395 17396 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17397 defer func() { 17398 if r := recover(); r != nil { 17399 ec.Error(ctx, ec.Recover(ctx, r)) 17400 } 17401 }() 17402 res = ec._Query_mapStringInterface(ctx, field) 17403 return res 17404 } 17405 17406 rrm := func(ctx context.Context) graphql.Marshaler { 17407 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17408 } 17409 17410 out.Concurrently(i, func() graphql.Marshaler { 17411 return rrm(innerCtx) 17412 }) 17413 case "mapNestedStringInterface": 17414 field := field 17415 17416 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17417 defer func() { 17418 if r := recover(); r != nil { 17419 ec.Error(ctx, ec.Recover(ctx, r)) 17420 } 17421 }() 17422 res = ec._Query_mapNestedStringInterface(ctx, field) 17423 return res 17424 } 17425 17426 rrm := func(ctx context.Context) graphql.Marshaler { 17427 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17428 } 17429 17430 out.Concurrently(i, func() graphql.Marshaler { 17431 return rrm(innerCtx) 17432 }) 17433 case "errorBubble": 17434 field := field 17435 17436 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17437 defer func() { 17438 if r := recover(); r != nil { 17439 ec.Error(ctx, ec.Recover(ctx, r)) 17440 } 17441 }() 17442 res = ec._Query_errorBubble(ctx, field) 17443 return res 17444 } 17445 17446 rrm := func(ctx context.Context) graphql.Marshaler { 17447 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17448 } 17449 17450 out.Concurrently(i, func() graphql.Marshaler { 17451 return rrm(innerCtx) 17452 }) 17453 case "errorBubbleList": 17454 field := field 17455 17456 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17457 defer func() { 17458 if r := recover(); r != nil { 17459 ec.Error(ctx, ec.Recover(ctx, r)) 17460 } 17461 }() 17462 res = ec._Query_errorBubbleList(ctx, field) 17463 return res 17464 } 17465 17466 rrm := func(ctx context.Context) graphql.Marshaler { 17467 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17468 } 17469 17470 out.Concurrently(i, func() graphql.Marshaler { 17471 return rrm(innerCtx) 17472 }) 17473 case "errorList": 17474 field := field 17475 17476 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17477 defer func() { 17478 if r := recover(); r != nil { 17479 ec.Error(ctx, ec.Recover(ctx, r)) 17480 } 17481 }() 17482 res = ec._Query_errorList(ctx, field) 17483 return res 17484 } 17485 17486 rrm := func(ctx context.Context) graphql.Marshaler { 17487 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17488 } 17489 17490 out.Concurrently(i, func() graphql.Marshaler { 17491 return rrm(innerCtx) 17492 }) 17493 case "errors": 17494 field := field 17495 17496 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17497 defer func() { 17498 if r := recover(); r != nil { 17499 ec.Error(ctx, ec.Recover(ctx, r)) 17500 } 17501 }() 17502 res = ec._Query_errors(ctx, field) 17503 return res 17504 } 17505 17506 rrm := func(ctx context.Context) graphql.Marshaler { 17507 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17508 } 17509 17510 out.Concurrently(i, func() graphql.Marshaler { 17511 return rrm(innerCtx) 17512 }) 17513 case "valid": 17514 field := field 17515 17516 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17517 defer func() { 17518 if r := recover(); r != nil { 17519 ec.Error(ctx, ec.Recover(ctx, r)) 17520 } 17521 }() 17522 res = ec._Query_valid(ctx, field) 17523 if res == graphql.Null { 17524 atomic.AddUint32(&invalids, 1) 17525 } 17526 return res 17527 } 17528 17529 rrm := func(ctx context.Context) graphql.Marshaler { 17530 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17531 } 17532 17533 out.Concurrently(i, func() graphql.Marshaler { 17534 return rrm(innerCtx) 17535 }) 17536 case "panics": 17537 field := field 17538 17539 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17540 defer func() { 17541 if r := recover(); r != nil { 17542 ec.Error(ctx, ec.Recover(ctx, r)) 17543 } 17544 }() 17545 res = ec._Query_panics(ctx, field) 17546 return res 17547 } 17548 17549 rrm := func(ctx context.Context) graphql.Marshaler { 17550 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17551 } 17552 17553 out.Concurrently(i, func() graphql.Marshaler { 17554 return rrm(innerCtx) 17555 }) 17556 case "primitiveObject": 17557 field := field 17558 17559 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17560 defer func() { 17561 if r := recover(); r != nil { 17562 ec.Error(ctx, ec.Recover(ctx, r)) 17563 } 17564 }() 17565 res = ec._Query_primitiveObject(ctx, field) 17566 if res == graphql.Null { 17567 atomic.AddUint32(&invalids, 1) 17568 } 17569 return res 17570 } 17571 17572 rrm := func(ctx context.Context) graphql.Marshaler { 17573 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17574 } 17575 17576 out.Concurrently(i, func() graphql.Marshaler { 17577 return rrm(innerCtx) 17578 }) 17579 case "primitiveStringObject": 17580 field := field 17581 17582 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17583 defer func() { 17584 if r := recover(); r != nil { 17585 ec.Error(ctx, ec.Recover(ctx, r)) 17586 } 17587 }() 17588 res = ec._Query_primitiveStringObject(ctx, field) 17589 if res == graphql.Null { 17590 atomic.AddUint32(&invalids, 1) 17591 } 17592 return res 17593 } 17594 17595 rrm := func(ctx context.Context) graphql.Marshaler { 17596 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17597 } 17598 17599 out.Concurrently(i, func() graphql.Marshaler { 17600 return rrm(innerCtx) 17601 }) 17602 case "ptrToSliceContainer": 17603 field := field 17604 17605 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17606 defer func() { 17607 if r := recover(); r != nil { 17608 ec.Error(ctx, ec.Recover(ctx, r)) 17609 } 17610 }() 17611 res = ec._Query_ptrToSliceContainer(ctx, field) 17612 if res == graphql.Null { 17613 atomic.AddUint32(&invalids, 1) 17614 } 17615 return res 17616 } 17617 17618 rrm := func(ctx context.Context) graphql.Marshaler { 17619 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17620 } 17621 17622 out.Concurrently(i, func() graphql.Marshaler { 17623 return rrm(innerCtx) 17624 }) 17625 case "infinity": 17626 field := field 17627 17628 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17629 defer func() { 17630 if r := recover(); r != nil { 17631 ec.Error(ctx, ec.Recover(ctx, r)) 17632 } 17633 }() 17634 res = ec._Query_infinity(ctx, field) 17635 if res == graphql.Null { 17636 atomic.AddUint32(&invalids, 1) 17637 } 17638 return res 17639 } 17640 17641 rrm := func(ctx context.Context) graphql.Marshaler { 17642 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17643 } 17644 17645 out.Concurrently(i, func() graphql.Marshaler { 17646 return rrm(innerCtx) 17647 }) 17648 case "stringFromContextInterface": 17649 field := field 17650 17651 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17652 defer func() { 17653 if r := recover(); r != nil { 17654 ec.Error(ctx, ec.Recover(ctx, r)) 17655 } 17656 }() 17657 res = ec._Query_stringFromContextInterface(ctx, field) 17658 if res == graphql.Null { 17659 atomic.AddUint32(&invalids, 1) 17660 } 17661 return res 17662 } 17663 17664 rrm := func(ctx context.Context) graphql.Marshaler { 17665 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17666 } 17667 17668 out.Concurrently(i, func() graphql.Marshaler { 17669 return rrm(innerCtx) 17670 }) 17671 case "stringFromContextFunction": 17672 field := field 17673 17674 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17675 defer func() { 17676 if r := recover(); r != nil { 17677 ec.Error(ctx, ec.Recover(ctx, r)) 17678 } 17679 }() 17680 res = ec._Query_stringFromContextFunction(ctx, field) 17681 if res == graphql.Null { 17682 atomic.AddUint32(&invalids, 1) 17683 } 17684 return res 17685 } 17686 17687 rrm := func(ctx context.Context) graphql.Marshaler { 17688 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17689 } 17690 17691 out.Concurrently(i, func() graphql.Marshaler { 17692 return rrm(innerCtx) 17693 }) 17694 case "defaultScalar": 17695 field := field 17696 17697 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17698 defer func() { 17699 if r := recover(); r != nil { 17700 ec.Error(ctx, ec.Recover(ctx, r)) 17701 } 17702 }() 17703 res = ec._Query_defaultScalar(ctx, field) 17704 if res == graphql.Null { 17705 atomic.AddUint32(&invalids, 1) 17706 } 17707 return res 17708 } 17709 17710 rrm := func(ctx context.Context) graphql.Marshaler { 17711 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17712 } 17713 17714 out.Concurrently(i, func() graphql.Marshaler { 17715 return rrm(innerCtx) 17716 }) 17717 case "slices": 17718 field := field 17719 17720 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17721 defer func() { 17722 if r := recover(); r != nil { 17723 ec.Error(ctx, ec.Recover(ctx, r)) 17724 } 17725 }() 17726 res = ec._Query_slices(ctx, field) 17727 return res 17728 } 17729 17730 rrm := func(ctx context.Context) graphql.Marshaler { 17731 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17732 } 17733 17734 out.Concurrently(i, func() graphql.Marshaler { 17735 return rrm(innerCtx) 17736 }) 17737 case "scalarSlice": 17738 field := field 17739 17740 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17741 defer func() { 17742 if r := recover(); r != nil { 17743 ec.Error(ctx, ec.Recover(ctx, r)) 17744 } 17745 }() 17746 res = ec._Query_scalarSlice(ctx, field) 17747 if res == graphql.Null { 17748 atomic.AddUint32(&invalids, 1) 17749 } 17750 return res 17751 } 17752 17753 rrm := func(ctx context.Context) graphql.Marshaler { 17754 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17755 } 17756 17757 out.Concurrently(i, func() graphql.Marshaler { 17758 return rrm(innerCtx) 17759 }) 17760 case "fallback": 17761 field := field 17762 17763 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17764 defer func() { 17765 if r := recover(); r != nil { 17766 ec.Error(ctx, ec.Recover(ctx, r)) 17767 } 17768 }() 17769 res = ec._Query_fallback(ctx, field) 17770 if res == graphql.Null { 17771 atomic.AddUint32(&invalids, 1) 17772 } 17773 return res 17774 } 17775 17776 rrm := func(ctx context.Context) graphql.Marshaler { 17777 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17778 } 17779 17780 out.Concurrently(i, func() graphql.Marshaler { 17781 return rrm(innerCtx) 17782 }) 17783 case "optionalUnion": 17784 field := field 17785 17786 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17787 defer func() { 17788 if r := recover(); r != nil { 17789 ec.Error(ctx, ec.Recover(ctx, r)) 17790 } 17791 }() 17792 res = ec._Query_optionalUnion(ctx, field) 17793 return res 17794 } 17795 17796 rrm := func(ctx context.Context) graphql.Marshaler { 17797 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17798 } 17799 17800 out.Concurrently(i, func() graphql.Marshaler { 17801 return rrm(innerCtx) 17802 }) 17803 case "vOkCaseValue": 17804 field := field 17805 17806 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17807 defer func() { 17808 if r := recover(); r != nil { 17809 ec.Error(ctx, ec.Recover(ctx, r)) 17810 } 17811 }() 17812 res = ec._Query_vOkCaseValue(ctx, field) 17813 return res 17814 } 17815 17816 rrm := func(ctx context.Context) graphql.Marshaler { 17817 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17818 } 17819 17820 out.Concurrently(i, func() graphql.Marshaler { 17821 return rrm(innerCtx) 17822 }) 17823 case "vOkCaseNil": 17824 field := field 17825 17826 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17827 defer func() { 17828 if r := recover(); r != nil { 17829 ec.Error(ctx, ec.Recover(ctx, r)) 17830 } 17831 }() 17832 res = ec._Query_vOkCaseNil(ctx, field) 17833 return res 17834 } 17835 17836 rrm := func(ctx context.Context) graphql.Marshaler { 17837 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17838 } 17839 17840 out.Concurrently(i, func() graphql.Marshaler { 17841 return rrm(innerCtx) 17842 }) 17843 case "validType": 17844 field := field 17845 17846 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17847 defer func() { 17848 if r := recover(); r != nil { 17849 ec.Error(ctx, ec.Recover(ctx, r)) 17850 } 17851 }() 17852 res = ec._Query_validType(ctx, field) 17853 return res 17854 } 17855 17856 rrm := func(ctx context.Context) graphql.Marshaler { 17857 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17858 } 17859 17860 out.Concurrently(i, func() graphql.Marshaler { 17861 return rrm(innerCtx) 17862 }) 17863 case "variadicModel": 17864 field := field 17865 17866 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17867 defer func() { 17868 if r := recover(); r != nil { 17869 ec.Error(ctx, ec.Recover(ctx, r)) 17870 } 17871 }() 17872 res = ec._Query_variadicModel(ctx, field) 17873 return res 17874 } 17875 17876 rrm := func(ctx context.Context) graphql.Marshaler { 17877 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17878 } 17879 17880 out.Concurrently(i, func() graphql.Marshaler { 17881 return rrm(innerCtx) 17882 }) 17883 case "wrappedStruct": 17884 field := field 17885 17886 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17887 defer func() { 17888 if r := recover(); r != nil { 17889 ec.Error(ctx, ec.Recover(ctx, r)) 17890 } 17891 }() 17892 res = ec._Query_wrappedStruct(ctx, field) 17893 if res == graphql.Null { 17894 atomic.AddUint32(&invalids, 1) 17895 } 17896 return res 17897 } 17898 17899 rrm := func(ctx context.Context) graphql.Marshaler { 17900 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17901 } 17902 17903 out.Concurrently(i, func() graphql.Marshaler { 17904 return rrm(innerCtx) 17905 }) 17906 case "wrappedScalar": 17907 field := field 17908 17909 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17910 defer func() { 17911 if r := recover(); r != nil { 17912 ec.Error(ctx, ec.Recover(ctx, r)) 17913 } 17914 }() 17915 res = ec._Query_wrappedScalar(ctx, field) 17916 if res == graphql.Null { 17917 atomic.AddUint32(&invalids, 1) 17918 } 17919 return res 17920 } 17921 17922 rrm := func(ctx context.Context) graphql.Marshaler { 17923 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17924 } 17925 17926 out.Concurrently(i, func() graphql.Marshaler { 17927 return rrm(innerCtx) 17928 }) 17929 case "wrappedMap": 17930 field := field 17931 17932 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17933 defer func() { 17934 if r := recover(); r != nil { 17935 ec.Error(ctx, ec.Recover(ctx, r)) 17936 } 17937 }() 17938 res = ec._Query_wrappedMap(ctx, field) 17939 if res == graphql.Null { 17940 atomic.AddUint32(&invalids, 1) 17941 } 17942 return res 17943 } 17944 17945 rrm := func(ctx context.Context) graphql.Marshaler { 17946 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17947 } 17948 17949 out.Concurrently(i, func() graphql.Marshaler { 17950 return rrm(innerCtx) 17951 }) 17952 case "wrappedSlice": 17953 field := field 17954 17955 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 17956 defer func() { 17957 if r := recover(); r != nil { 17958 ec.Error(ctx, ec.Recover(ctx, r)) 17959 } 17960 }() 17961 res = ec._Query_wrappedSlice(ctx, field) 17962 if res == graphql.Null { 17963 atomic.AddUint32(&invalids, 1) 17964 } 17965 return res 17966 } 17967 17968 rrm := func(ctx context.Context) graphql.Marshaler { 17969 return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) 17970 } 17971 17972 out.Concurrently(i, func() graphql.Marshaler { 17973 return rrm(innerCtx) 17974 }) 17975 case "__type": 17976 17977 out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { 17978 return ec._Query___type(ctx, field) 17979 }) 17980 17981 case "__schema": 17982 17983 out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { 17984 return ec._Query___schema(ctx, field) 17985 }) 17986 17987 default: 17988 panic("unknown field " + strconv.Quote(field.Name)) 17989 } 17990 } 17991 out.Dispatch() 17992 if invalids > 0 { 17993 return graphql.Null 17994 } 17995 return out 17996 } 17997 17998 var rectangleImplementors = []string{"Rectangle", "Shape", "ShapeUnion"} 17999 18000 func (ec *executionContext) _Rectangle(ctx context.Context, sel ast.SelectionSet, obj *Rectangle) graphql.Marshaler { 18001 fields := graphql.CollectFields(ec.OperationContext, sel, rectangleImplementors) 18002 out := graphql.NewFieldSet(fields) 18003 var invalids uint32 18004 for i, field := range fields { 18005 switch field.Name { 18006 case "__typename": 18007 out.Values[i] = graphql.MarshalString("Rectangle") 18008 case "length": 18009 18010 out.Values[i] = ec._Rectangle_length(ctx, field, obj) 18011 18012 case "width": 18013 18014 out.Values[i] = ec._Rectangle_width(ctx, field, obj) 18015 18016 case "area": 18017 18018 out.Values[i] = ec._Rectangle_area(ctx, field, obj) 18019 18020 case "coordinates": 18021 18022 out.Values[i] = ec._Rectangle_coordinates(ctx, field, obj) 18023 18024 default: 18025 panic("unknown field " + strconv.Quote(field.Name)) 18026 } 18027 } 18028 out.Dispatch() 18029 if invalids > 0 { 18030 return graphql.Null 18031 } 18032 return out 18033 } 18034 18035 var slicesImplementors = []string{"Slices"} 18036 18037 func (ec *executionContext) _Slices(ctx context.Context, sel ast.SelectionSet, obj *Slices) graphql.Marshaler { 18038 fields := graphql.CollectFields(ec.OperationContext, sel, slicesImplementors) 18039 out := graphql.NewFieldSet(fields) 18040 var invalids uint32 18041 for i, field := range fields { 18042 switch field.Name { 18043 case "__typename": 18044 out.Values[i] = graphql.MarshalString("Slices") 18045 case "test1": 18046 18047 out.Values[i] = ec._Slices_test1(ctx, field, obj) 18048 18049 case "test2": 18050 18051 out.Values[i] = ec._Slices_test2(ctx, field, obj) 18052 18053 case "test3": 18054 18055 out.Values[i] = ec._Slices_test3(ctx, field, obj) 18056 18057 if out.Values[i] == graphql.Null { 18058 invalids++ 18059 } 18060 case "test4": 18061 18062 out.Values[i] = ec._Slices_test4(ctx, field, obj) 18063 18064 if out.Values[i] == graphql.Null { 18065 invalids++ 18066 } 18067 default: 18068 panic("unknown field " + strconv.Quote(field.Name)) 18069 } 18070 } 18071 out.Dispatch() 18072 if invalids > 0 { 18073 return graphql.Null 18074 } 18075 return out 18076 } 18077 18078 var subscriptionImplementors = []string{"Subscription"} 18079 18080 func (ec *executionContext) _Subscription(ctx context.Context, sel ast.SelectionSet) func(ctx context.Context) graphql.Marshaler { 18081 fields := graphql.CollectFields(ec.OperationContext, sel, subscriptionImplementors) 18082 ctx = graphql.WithFieldContext(ctx, &graphql.FieldContext{ 18083 Object: "Subscription", 18084 }) 18085 if len(fields) != 1 { 18086 ec.Errorf(ctx, "must subscribe to exactly one stream") 18087 return nil 18088 } 18089 18090 switch fields[0].Name { 18091 case "updated": 18092 return ec._Subscription_updated(ctx, fields[0]) 18093 case "initPayload": 18094 return ec._Subscription_initPayload(ctx, fields[0]) 18095 case "directiveArg": 18096 return ec._Subscription_directiveArg(ctx, fields[0]) 18097 case "directiveNullableArg": 18098 return ec._Subscription_directiveNullableArg(ctx, fields[0]) 18099 case "directiveDouble": 18100 return ec._Subscription_directiveDouble(ctx, fields[0]) 18101 case "directiveUnimplemented": 18102 return ec._Subscription_directiveUnimplemented(ctx, fields[0]) 18103 case "issue896b": 18104 return ec._Subscription_issue896b(ctx, fields[0]) 18105 case "errorRequired": 18106 return ec._Subscription_errorRequired(ctx, fields[0]) 18107 default: 18108 panic("unknown field " + strconv.Quote(fields[0].Name)) 18109 } 18110 } 18111 18112 var userImplementors = []string{"User"} 18113 18114 func (ec *executionContext) _User(ctx context.Context, sel ast.SelectionSet, obj *User) graphql.Marshaler { 18115 fields := graphql.CollectFields(ec.OperationContext, sel, userImplementors) 18116 out := graphql.NewFieldSet(fields) 18117 var invalids uint32 18118 for i, field := range fields { 18119 switch field.Name { 18120 case "__typename": 18121 out.Values[i] = graphql.MarshalString("User") 18122 case "id": 18123 18124 out.Values[i] = ec._User_id(ctx, field, obj) 18125 18126 if out.Values[i] == graphql.Null { 18127 atomic.AddUint32(&invalids, 1) 18128 } 18129 case "friends": 18130 field := field 18131 18132 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 18133 defer func() { 18134 if r := recover(); r != nil { 18135 ec.Error(ctx, ec.Recover(ctx, r)) 18136 } 18137 }() 18138 res = ec._User_friends(ctx, field, obj) 18139 if res == graphql.Null { 18140 atomic.AddUint32(&invalids, 1) 18141 } 18142 return res 18143 } 18144 18145 out.Concurrently(i, func() graphql.Marshaler { 18146 return innerFunc(ctx) 18147 18148 }) 18149 case "created": 18150 18151 out.Values[i] = ec._User_created(ctx, field, obj) 18152 18153 if out.Values[i] == graphql.Null { 18154 atomic.AddUint32(&invalids, 1) 18155 } 18156 case "updated": 18157 18158 out.Values[i] = ec._User_updated(ctx, field, obj) 18159 18160 case "pets": 18161 field := field 18162 18163 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 18164 defer func() { 18165 if r := recover(); r != nil { 18166 ec.Error(ctx, ec.Recover(ctx, r)) 18167 } 18168 }() 18169 res = ec._User_pets(ctx, field, obj) 18170 return res 18171 } 18172 18173 out.Concurrently(i, func() graphql.Marshaler { 18174 return innerFunc(ctx) 18175 18176 }) 18177 default: 18178 panic("unknown field " + strconv.Quote(field.Name)) 18179 } 18180 } 18181 out.Dispatch() 18182 if invalids > 0 { 18183 return graphql.Null 18184 } 18185 return out 18186 } 18187 18188 var vOkCaseNilImplementors = []string{"VOkCaseNil"} 18189 18190 func (ec *executionContext) _VOkCaseNil(ctx context.Context, sel ast.SelectionSet, obj *VOkCaseNil) graphql.Marshaler { 18191 fields := graphql.CollectFields(ec.OperationContext, sel, vOkCaseNilImplementors) 18192 out := graphql.NewFieldSet(fields) 18193 var invalids uint32 18194 for i, field := range fields { 18195 switch field.Name { 18196 case "__typename": 18197 out.Values[i] = graphql.MarshalString("VOkCaseNil") 18198 case "value": 18199 18200 out.Values[i] = ec._VOkCaseNil_value(ctx, field, obj) 18201 18202 default: 18203 panic("unknown field " + strconv.Quote(field.Name)) 18204 } 18205 } 18206 out.Dispatch() 18207 if invalids > 0 { 18208 return graphql.Null 18209 } 18210 return out 18211 } 18212 18213 var vOkCaseValueImplementors = []string{"VOkCaseValue"} 18214 18215 func (ec *executionContext) _VOkCaseValue(ctx context.Context, sel ast.SelectionSet, obj *VOkCaseValue) graphql.Marshaler { 18216 fields := graphql.CollectFields(ec.OperationContext, sel, vOkCaseValueImplementors) 18217 out := graphql.NewFieldSet(fields) 18218 var invalids uint32 18219 for i, field := range fields { 18220 switch field.Name { 18221 case "__typename": 18222 out.Values[i] = graphql.MarshalString("VOkCaseValue") 18223 case "value": 18224 18225 out.Values[i] = ec._VOkCaseValue_value(ctx, field, obj) 18226 18227 default: 18228 panic("unknown field " + strconv.Quote(field.Name)) 18229 } 18230 } 18231 out.Dispatch() 18232 if invalids > 0 { 18233 return graphql.Null 18234 } 18235 return out 18236 } 18237 18238 var validTypeImplementors = []string{"ValidType"} 18239 18240 func (ec *executionContext) _ValidType(ctx context.Context, sel ast.SelectionSet, obj *ValidType) graphql.Marshaler { 18241 fields := graphql.CollectFields(ec.OperationContext, sel, validTypeImplementors) 18242 out := graphql.NewFieldSet(fields) 18243 var invalids uint32 18244 for i, field := range fields { 18245 switch field.Name { 18246 case "__typename": 18247 out.Values[i] = graphql.MarshalString("ValidType") 18248 case "differentCase": 18249 18250 out.Values[i] = ec._ValidType_differentCase(ctx, field, obj) 18251 18252 if out.Values[i] == graphql.Null { 18253 invalids++ 18254 } 18255 case "different_case": 18256 18257 out.Values[i] = ec._ValidType_different_case(ctx, field, obj) 18258 18259 if out.Values[i] == graphql.Null { 18260 invalids++ 18261 } 18262 case "validInputKeywords": 18263 18264 out.Values[i] = ec._ValidType_validInputKeywords(ctx, field, obj) 18265 18266 if out.Values[i] == graphql.Null { 18267 invalids++ 18268 } 18269 case "validArgs": 18270 18271 out.Values[i] = ec._ValidType_validArgs(ctx, field, obj) 18272 18273 if out.Values[i] == graphql.Null { 18274 invalids++ 18275 } 18276 default: 18277 panic("unknown field " + strconv.Quote(field.Name)) 18278 } 18279 } 18280 out.Dispatch() 18281 if invalids > 0 { 18282 return graphql.Null 18283 } 18284 return out 18285 } 18286 18287 var variadicModelImplementors = []string{"VariadicModel"} 18288 18289 func (ec *executionContext) _VariadicModel(ctx context.Context, sel ast.SelectionSet, obj *VariadicModel) graphql.Marshaler { 18290 fields := graphql.CollectFields(ec.OperationContext, sel, variadicModelImplementors) 18291 out := graphql.NewFieldSet(fields) 18292 var invalids uint32 18293 for i, field := range fields { 18294 switch field.Name { 18295 case "__typename": 18296 out.Values[i] = graphql.MarshalString("VariadicModel") 18297 case "value": 18298 field := field 18299 18300 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 18301 defer func() { 18302 if r := recover(); r != nil { 18303 ec.Error(ctx, ec.Recover(ctx, r)) 18304 } 18305 }() 18306 res = ec._VariadicModel_value(ctx, field, obj) 18307 return res 18308 } 18309 18310 out.Concurrently(i, func() graphql.Marshaler { 18311 return innerFunc(ctx) 18312 18313 }) 18314 default: 18315 panic("unknown field " + strconv.Quote(field.Name)) 18316 } 18317 } 18318 out.Dispatch() 18319 if invalids > 0 { 18320 return graphql.Null 18321 } 18322 return out 18323 } 18324 18325 var wrappedMapImplementors = []string{"WrappedMap"} 18326 18327 func (ec *executionContext) _WrappedMap(ctx context.Context, sel ast.SelectionSet, obj WrappedMap) graphql.Marshaler { 18328 fields := graphql.CollectFields(ec.OperationContext, sel, wrappedMapImplementors) 18329 out := graphql.NewFieldSet(fields) 18330 var invalids uint32 18331 for i, field := range fields { 18332 switch field.Name { 18333 case "__typename": 18334 out.Values[i] = graphql.MarshalString("WrappedMap") 18335 case "get": 18336 field := field 18337 18338 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 18339 defer func() { 18340 if r := recover(); r != nil { 18341 ec.Error(ctx, ec.Recover(ctx, r)) 18342 } 18343 }() 18344 res = ec._WrappedMap_get(ctx, field, obj) 18345 if res == graphql.Null { 18346 atomic.AddUint32(&invalids, 1) 18347 } 18348 return res 18349 } 18350 18351 out.Concurrently(i, func() graphql.Marshaler { 18352 return innerFunc(ctx) 18353 18354 }) 18355 default: 18356 panic("unknown field " + strconv.Quote(field.Name)) 18357 } 18358 } 18359 out.Dispatch() 18360 if invalids > 0 { 18361 return graphql.Null 18362 } 18363 return out 18364 } 18365 18366 var wrappedSliceImplementors = []string{"WrappedSlice"} 18367 18368 func (ec *executionContext) _WrappedSlice(ctx context.Context, sel ast.SelectionSet, obj WrappedSlice) graphql.Marshaler { 18369 fields := graphql.CollectFields(ec.OperationContext, sel, wrappedSliceImplementors) 18370 out := graphql.NewFieldSet(fields) 18371 var invalids uint32 18372 for i, field := range fields { 18373 switch field.Name { 18374 case "__typename": 18375 out.Values[i] = graphql.MarshalString("WrappedSlice") 18376 case "get": 18377 field := field 18378 18379 innerFunc := func(ctx context.Context) (res graphql.Marshaler) { 18380 defer func() { 18381 if r := recover(); r != nil { 18382 ec.Error(ctx, ec.Recover(ctx, r)) 18383 } 18384 }() 18385 res = ec._WrappedSlice_get(ctx, field, obj) 18386 if res == graphql.Null { 18387 atomic.AddUint32(&invalids, 1) 18388 } 18389 return res 18390 } 18391 18392 out.Concurrently(i, func() graphql.Marshaler { 18393 return innerFunc(ctx) 18394 18395 }) 18396 default: 18397 panic("unknown field " + strconv.Quote(field.Name)) 18398 } 18399 } 18400 out.Dispatch() 18401 if invalids > 0 { 18402 return graphql.Null 18403 } 18404 return out 18405 } 18406 18407 var wrappedStructImplementors = []string{"WrappedStruct"} 18408 18409 func (ec *executionContext) _WrappedStruct(ctx context.Context, sel ast.SelectionSet, obj *WrappedStruct) graphql.Marshaler { 18410 fields := graphql.CollectFields(ec.OperationContext, sel, wrappedStructImplementors) 18411 out := graphql.NewFieldSet(fields) 18412 var invalids uint32 18413 for i, field := range fields { 18414 switch field.Name { 18415 case "__typename": 18416 out.Values[i] = graphql.MarshalString("WrappedStruct") 18417 case "name": 18418 18419 out.Values[i] = ec._WrappedStruct_name(ctx, field, obj) 18420 18421 if out.Values[i] == graphql.Null { 18422 invalids++ 18423 } 18424 case "desc": 18425 18426 out.Values[i] = ec._WrappedStruct_desc(ctx, field, obj) 18427 18428 default: 18429 panic("unknown field " + strconv.Quote(field.Name)) 18430 } 18431 } 18432 out.Dispatch() 18433 if invalids > 0 { 18434 return graphql.Null 18435 } 18436 return out 18437 } 18438 18439 var xXItImplementors = []string{"XXIt"} 18440 18441 func (ec *executionContext) _XXIt(ctx context.Context, sel ast.SelectionSet, obj *XXIt) graphql.Marshaler { 18442 fields := graphql.CollectFields(ec.OperationContext, sel, xXItImplementors) 18443 out := graphql.NewFieldSet(fields) 18444 var invalids uint32 18445 for i, field := range fields { 18446 switch field.Name { 18447 case "__typename": 18448 out.Values[i] = graphql.MarshalString("XXIt") 18449 case "id": 18450 18451 out.Values[i] = ec._XXIt_id(ctx, field, obj) 18452 18453 if out.Values[i] == graphql.Null { 18454 invalids++ 18455 } 18456 default: 18457 panic("unknown field " + strconv.Quote(field.Name)) 18458 } 18459 } 18460 out.Dispatch() 18461 if invalids > 0 { 18462 return graphql.Null 18463 } 18464 return out 18465 } 18466 18467 var xxItImplementors = []string{"XxIt"} 18468 18469 func (ec *executionContext) _XxIt(ctx context.Context, sel ast.SelectionSet, obj *XxIt) graphql.Marshaler { 18470 fields := graphql.CollectFields(ec.OperationContext, sel, xxItImplementors) 18471 out := graphql.NewFieldSet(fields) 18472 var invalids uint32 18473 for i, field := range fields { 18474 switch field.Name { 18475 case "__typename": 18476 out.Values[i] = graphql.MarshalString("XxIt") 18477 case "id": 18478 18479 out.Values[i] = ec._XxIt_id(ctx, field, obj) 18480 18481 if out.Values[i] == graphql.Null { 18482 invalids++ 18483 } 18484 default: 18485 panic("unknown field " + strconv.Quote(field.Name)) 18486 } 18487 } 18488 out.Dispatch() 18489 if invalids > 0 { 18490 return graphql.Null 18491 } 18492 return out 18493 } 18494 18495 var __DirectiveImplementors = []string{"__Directive"} 18496 18497 func (ec *executionContext) ___Directive(ctx context.Context, sel ast.SelectionSet, obj *introspection.Directive) graphql.Marshaler { 18498 fields := graphql.CollectFields(ec.OperationContext, sel, __DirectiveImplementors) 18499 out := graphql.NewFieldSet(fields) 18500 var invalids uint32 18501 for i, field := range fields { 18502 switch field.Name { 18503 case "__typename": 18504 out.Values[i] = graphql.MarshalString("__Directive") 18505 case "name": 18506 18507 out.Values[i] = ec.___Directive_name(ctx, field, obj) 18508 18509 if out.Values[i] == graphql.Null { 18510 invalids++ 18511 } 18512 case "description": 18513 18514 out.Values[i] = ec.___Directive_description(ctx, field, obj) 18515 18516 case "locations": 18517 18518 out.Values[i] = ec.___Directive_locations(ctx, field, obj) 18519 18520 if out.Values[i] == graphql.Null { 18521 invalids++ 18522 } 18523 case "args": 18524 18525 out.Values[i] = ec.___Directive_args(ctx, field, obj) 18526 18527 if out.Values[i] == graphql.Null { 18528 invalids++ 18529 } 18530 case "isRepeatable": 18531 18532 out.Values[i] = ec.___Directive_isRepeatable(ctx, field, obj) 18533 18534 if out.Values[i] == graphql.Null { 18535 invalids++ 18536 } 18537 default: 18538 panic("unknown field " + strconv.Quote(field.Name)) 18539 } 18540 } 18541 out.Dispatch() 18542 if invalids > 0 { 18543 return graphql.Null 18544 } 18545 return out 18546 } 18547 18548 var __EnumValueImplementors = []string{"__EnumValue"} 18549 18550 func (ec *executionContext) ___EnumValue(ctx context.Context, sel ast.SelectionSet, obj *introspection.EnumValue) graphql.Marshaler { 18551 fields := graphql.CollectFields(ec.OperationContext, sel, __EnumValueImplementors) 18552 out := graphql.NewFieldSet(fields) 18553 var invalids uint32 18554 for i, field := range fields { 18555 switch field.Name { 18556 case "__typename": 18557 out.Values[i] = graphql.MarshalString("__EnumValue") 18558 case "name": 18559 18560 out.Values[i] = ec.___EnumValue_name(ctx, field, obj) 18561 18562 if out.Values[i] == graphql.Null { 18563 invalids++ 18564 } 18565 case "description": 18566 18567 out.Values[i] = ec.___EnumValue_description(ctx, field, obj) 18568 18569 case "isDeprecated": 18570 18571 out.Values[i] = ec.___EnumValue_isDeprecated(ctx, field, obj) 18572 18573 if out.Values[i] == graphql.Null { 18574 invalids++ 18575 } 18576 case "deprecationReason": 18577 18578 out.Values[i] = ec.___EnumValue_deprecationReason(ctx, field, obj) 18579 18580 default: 18581 panic("unknown field " + strconv.Quote(field.Name)) 18582 } 18583 } 18584 out.Dispatch() 18585 if invalids > 0 { 18586 return graphql.Null 18587 } 18588 return out 18589 } 18590 18591 var __FieldImplementors = []string{"__Field"} 18592 18593 func (ec *executionContext) ___Field(ctx context.Context, sel ast.SelectionSet, obj *introspection.Field) graphql.Marshaler { 18594 fields := graphql.CollectFields(ec.OperationContext, sel, __FieldImplementors) 18595 out := graphql.NewFieldSet(fields) 18596 var invalids uint32 18597 for i, field := range fields { 18598 switch field.Name { 18599 case "__typename": 18600 out.Values[i] = graphql.MarshalString("__Field") 18601 case "name": 18602 18603 out.Values[i] = ec.___Field_name(ctx, field, obj) 18604 18605 if out.Values[i] == graphql.Null { 18606 invalids++ 18607 } 18608 case "description": 18609 18610 out.Values[i] = ec.___Field_description(ctx, field, obj) 18611 18612 case "args": 18613 18614 out.Values[i] = ec.___Field_args(ctx, field, obj) 18615 18616 if out.Values[i] == graphql.Null { 18617 invalids++ 18618 } 18619 case "type": 18620 18621 out.Values[i] = ec.___Field_type(ctx, field, obj) 18622 18623 if out.Values[i] == graphql.Null { 18624 invalids++ 18625 } 18626 case "isDeprecated": 18627 18628 out.Values[i] = ec.___Field_isDeprecated(ctx, field, obj) 18629 18630 if out.Values[i] == graphql.Null { 18631 invalids++ 18632 } 18633 case "deprecationReason": 18634 18635 out.Values[i] = ec.___Field_deprecationReason(ctx, field, obj) 18636 18637 default: 18638 panic("unknown field " + strconv.Quote(field.Name)) 18639 } 18640 } 18641 out.Dispatch() 18642 if invalids > 0 { 18643 return graphql.Null 18644 } 18645 return out 18646 } 18647 18648 var __InputValueImplementors = []string{"__InputValue"} 18649 18650 func (ec *executionContext) ___InputValue(ctx context.Context, sel ast.SelectionSet, obj *introspection.InputValue) graphql.Marshaler { 18651 fields := graphql.CollectFields(ec.OperationContext, sel, __InputValueImplementors) 18652 out := graphql.NewFieldSet(fields) 18653 var invalids uint32 18654 for i, field := range fields { 18655 switch field.Name { 18656 case "__typename": 18657 out.Values[i] = graphql.MarshalString("__InputValue") 18658 case "name": 18659 18660 out.Values[i] = ec.___InputValue_name(ctx, field, obj) 18661 18662 if out.Values[i] == graphql.Null { 18663 invalids++ 18664 } 18665 case "description": 18666 18667 out.Values[i] = ec.___InputValue_description(ctx, field, obj) 18668 18669 case "type": 18670 18671 out.Values[i] = ec.___InputValue_type(ctx, field, obj) 18672 18673 if out.Values[i] == graphql.Null { 18674 invalids++ 18675 } 18676 case "defaultValue": 18677 18678 out.Values[i] = ec.___InputValue_defaultValue(ctx, field, obj) 18679 18680 default: 18681 panic("unknown field " + strconv.Quote(field.Name)) 18682 } 18683 } 18684 out.Dispatch() 18685 if invalids > 0 { 18686 return graphql.Null 18687 } 18688 return out 18689 } 18690 18691 var __SchemaImplementors = []string{"__Schema"} 18692 18693 func (ec *executionContext) ___Schema(ctx context.Context, sel ast.SelectionSet, obj *introspection.Schema) graphql.Marshaler { 18694 fields := graphql.CollectFields(ec.OperationContext, sel, __SchemaImplementors) 18695 out := graphql.NewFieldSet(fields) 18696 var invalids uint32 18697 for i, field := range fields { 18698 switch field.Name { 18699 case "__typename": 18700 out.Values[i] = graphql.MarshalString("__Schema") 18701 case "description": 18702 18703 out.Values[i] = ec.___Schema_description(ctx, field, obj) 18704 18705 case "types": 18706 18707 out.Values[i] = ec.___Schema_types(ctx, field, obj) 18708 18709 if out.Values[i] == graphql.Null { 18710 invalids++ 18711 } 18712 case "queryType": 18713 18714 out.Values[i] = ec.___Schema_queryType(ctx, field, obj) 18715 18716 if out.Values[i] == graphql.Null { 18717 invalids++ 18718 } 18719 case "mutationType": 18720 18721 out.Values[i] = ec.___Schema_mutationType(ctx, field, obj) 18722 18723 case "subscriptionType": 18724 18725 out.Values[i] = ec.___Schema_subscriptionType(ctx, field, obj) 18726 18727 case "directives": 18728 18729 out.Values[i] = ec.___Schema_directives(ctx, field, obj) 18730 18731 if out.Values[i] == graphql.Null { 18732 invalids++ 18733 } 18734 default: 18735 panic("unknown field " + strconv.Quote(field.Name)) 18736 } 18737 } 18738 out.Dispatch() 18739 if invalids > 0 { 18740 return graphql.Null 18741 } 18742 return out 18743 } 18744 18745 var __TypeImplementors = []string{"__Type"} 18746 18747 func (ec *executionContext) ___Type(ctx context.Context, sel ast.SelectionSet, obj *introspection.Type) graphql.Marshaler { 18748 fields := graphql.CollectFields(ec.OperationContext, sel, __TypeImplementors) 18749 out := graphql.NewFieldSet(fields) 18750 var invalids uint32 18751 for i, field := range fields { 18752 switch field.Name { 18753 case "__typename": 18754 out.Values[i] = graphql.MarshalString("__Type") 18755 case "kind": 18756 18757 out.Values[i] = ec.___Type_kind(ctx, field, obj) 18758 18759 if out.Values[i] == graphql.Null { 18760 invalids++ 18761 } 18762 case "name": 18763 18764 out.Values[i] = ec.___Type_name(ctx, field, obj) 18765 18766 case "description": 18767 18768 out.Values[i] = ec.___Type_description(ctx, field, obj) 18769 18770 case "fields": 18771 18772 out.Values[i] = ec.___Type_fields(ctx, field, obj) 18773 18774 case "interfaces": 18775 18776 out.Values[i] = ec.___Type_interfaces(ctx, field, obj) 18777 18778 case "possibleTypes": 18779 18780 out.Values[i] = ec.___Type_possibleTypes(ctx, field, obj) 18781 18782 case "enumValues": 18783 18784 out.Values[i] = ec.___Type_enumValues(ctx, field, obj) 18785 18786 case "inputFields": 18787 18788 out.Values[i] = ec.___Type_inputFields(ctx, field, obj) 18789 18790 case "ofType": 18791 18792 out.Values[i] = ec.___Type_ofType(ctx, field, obj) 18793 18794 case "specifiedByURL": 18795 18796 out.Values[i] = ec.___Type_specifiedByURL(ctx, field, obj) 18797 18798 default: 18799 panic("unknown field " + strconv.Quote(field.Name)) 18800 } 18801 } 18802 out.Dispatch() 18803 if invalids > 0 { 18804 return graphql.Null 18805 } 18806 return out 18807 } 18808 18809 var asdfItImplementors = []string{"asdfIt"} 18810 18811 func (ec *executionContext) _asdfIt(ctx context.Context, sel ast.SelectionSet, obj *AsdfIt) graphql.Marshaler { 18812 fields := graphql.CollectFields(ec.OperationContext, sel, asdfItImplementors) 18813 out := graphql.NewFieldSet(fields) 18814 var invalids uint32 18815 for i, field := range fields { 18816 switch field.Name { 18817 case "__typename": 18818 out.Values[i] = graphql.MarshalString("asdfIt") 18819 case "id": 18820 18821 out.Values[i] = ec._asdfIt_id(ctx, field, obj) 18822 18823 if out.Values[i] == graphql.Null { 18824 invalids++ 18825 } 18826 default: 18827 panic("unknown field " + strconv.Quote(field.Name)) 18828 } 18829 } 18830 out.Dispatch() 18831 if invalids > 0 { 18832 return graphql.Null 18833 } 18834 return out 18835 } 18836 18837 var iItImplementors = []string{"iIt"} 18838 18839 func (ec *executionContext) _iIt(ctx context.Context, sel ast.SelectionSet, obj *IIt) graphql.Marshaler { 18840 fields := graphql.CollectFields(ec.OperationContext, sel, iItImplementors) 18841 out := graphql.NewFieldSet(fields) 18842 var invalids uint32 18843 for i, field := range fields { 18844 switch field.Name { 18845 case "__typename": 18846 out.Values[i] = graphql.MarshalString("iIt") 18847 case "id": 18848 18849 out.Values[i] = ec._iIt_id(ctx, field, obj) 18850 18851 if out.Values[i] == graphql.Null { 18852 invalids++ 18853 } 18854 default: 18855 panic("unknown field " + strconv.Quote(field.Name)) 18856 } 18857 } 18858 out.Dispatch() 18859 if invalids > 0 { 18860 return graphql.Null 18861 } 18862 return out 18863 } 18864 18865 // endregion **************************** object.gotpl **************************** 18866 18867 // region ***************************** type.gotpl ***************************** 18868 18869 func (ec *executionContext) unmarshalNBoolean2bool(ctx context.Context, v interface{}) (bool, error) { 18870 res, err := graphql.UnmarshalBoolean(v) 18871 return res, graphql.ErrorOnPath(ctx, err) 18872 } 18873 18874 func (ec *executionContext) marshalNBoolean2bool(ctx context.Context, sel ast.SelectionSet, v bool) graphql.Marshaler { 18875 res := graphql.MarshalBoolean(v) 18876 if res == graphql.Null { 18877 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 18878 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 18879 } 18880 } 18881 return res 18882 } 18883 18884 func (ec *executionContext) unmarshalNBytes2ᚕbyte(ctx context.Context, v interface{}) ([]byte, error) { 18885 res, err := UnmarshalBytes(v) 18886 return res, graphql.ErrorOnPath(ctx, err) 18887 } 18888 18889 func (ec *executionContext) marshalNBytes2ᚕbyte(ctx context.Context, sel ast.SelectionSet, v []byte) graphql.Marshaler { 18890 if v == nil { 18891 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 18892 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 18893 } 18894 return graphql.Null 18895 } 18896 res := MarshalBytes(v) 18897 if res == graphql.Null { 18898 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 18899 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 18900 } 18901 } 18902 return res 18903 } 18904 18905 func (ec *executionContext) marshalNCheckIssue8962ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐCheckIssue896(ctx context.Context, sel ast.SelectionSet, v *CheckIssue896) graphql.Marshaler { 18906 if v == nil { 18907 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 18908 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 18909 } 18910 return graphql.Null 18911 } 18912 return ec._CheckIssue896(ctx, sel, v) 18913 } 18914 18915 func (ec *executionContext) unmarshalNDefaultInput2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐDefaultInput(ctx context.Context, v interface{}) (DefaultInput, error) { 18916 res, err := ec.unmarshalInputDefaultInput(ctx, v) 18917 return res, graphql.ErrorOnPath(ctx, err) 18918 } 18919 18920 func (ec *executionContext) marshalNDefaultParametersMirror2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐDefaultParametersMirror(ctx context.Context, sel ast.SelectionSet, v DefaultParametersMirror) graphql.Marshaler { 18921 return ec._DefaultParametersMirror(ctx, sel, &v) 18922 } 18923 18924 func (ec *executionContext) marshalNDefaultParametersMirror2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐDefaultParametersMirror(ctx context.Context, sel ast.SelectionSet, v *DefaultParametersMirror) graphql.Marshaler { 18925 if v == nil { 18926 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 18927 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 18928 } 18929 return graphql.Null 18930 } 18931 return ec._DefaultParametersMirror(ctx, sel, v) 18932 } 18933 18934 func (ec *executionContext) unmarshalNDefaultScalarImplementation2string(ctx context.Context, v interface{}) (string, error) { 18935 res, err := graphql.UnmarshalString(v) 18936 return res, graphql.ErrorOnPath(ctx, err) 18937 } 18938 18939 func (ec *executionContext) marshalNDefaultScalarImplementation2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler { 18940 res := graphql.MarshalString(v) 18941 if res == graphql.Null { 18942 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 18943 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 18944 } 18945 } 18946 return res 18947 } 18948 18949 func (ec *executionContext) unmarshalNEmail2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐEmail(ctx context.Context, v interface{}) (Email, error) { 18950 var res Email 18951 err := res.UnmarshalGQL(v) 18952 return res, graphql.ErrorOnPath(ctx, err) 18953 } 18954 18955 func (ec *executionContext) marshalNEmail2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐEmail(ctx context.Context, sel ast.SelectionSet, v Email) graphql.Marshaler { 18956 return v 18957 } 18958 18959 func (ec *executionContext) unmarshalNEnumTest2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐEnumTest(ctx context.Context, v interface{}) (EnumTest, error) { 18960 var res EnumTest 18961 err := res.UnmarshalGQL(v) 18962 return res, graphql.ErrorOnPath(ctx, err) 18963 } 18964 18965 func (ec *executionContext) marshalNEnumTest2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐEnumTest(ctx context.Context, sel ast.SelectionSet, v EnumTest) graphql.Marshaler { 18966 return v 18967 } 18968 18969 func (ec *executionContext) marshalNError2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐError(ctx context.Context, sel ast.SelectionSet, v Error) graphql.Marshaler { 18970 return ec._Error(ctx, sel, &v) 18971 } 18972 18973 func (ec *executionContext) marshalNError2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐError(ctx context.Context, sel ast.SelectionSet, v *Error) graphql.Marshaler { 18974 if v == nil { 18975 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 18976 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 18977 } 18978 return graphql.Null 18979 } 18980 return ec._Error(ctx, sel, v) 18981 } 18982 18983 func (ec *executionContext) unmarshalNFallbackToStringEncoding2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐFallbackToStringEncoding(ctx context.Context, v interface{}) (FallbackToStringEncoding, error) { 18984 tmp, err := graphql.UnmarshalString(v) 18985 res := FallbackToStringEncoding(tmp) 18986 return res, graphql.ErrorOnPath(ctx, err) 18987 } 18988 18989 func (ec *executionContext) marshalNFallbackToStringEncoding2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐFallbackToStringEncoding(ctx context.Context, sel ast.SelectionSet, v FallbackToStringEncoding) graphql.Marshaler { 18990 res := graphql.MarshalString(string(v)) 18991 if res == graphql.Null { 18992 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 18993 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 18994 } 18995 } 18996 return res 18997 } 18998 18999 func (ec *executionContext) unmarshalNFieldsOrderInput2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐFieldsOrderInput(ctx context.Context, v interface{}) (FieldsOrderInput, error) { 19000 res, err := ec.unmarshalInputFieldsOrderInput(ctx, v) 19001 return res, graphql.ErrorOnPath(ctx, err) 19002 } 19003 19004 func (ec *executionContext) marshalNFieldsOrderPayload2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐFieldsOrderPayload(ctx context.Context, sel ast.SelectionSet, v FieldsOrderPayload) graphql.Marshaler { 19005 return ec._FieldsOrderPayload(ctx, sel, &v) 19006 } 19007 19008 func (ec *executionContext) marshalNFieldsOrderPayload2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐFieldsOrderPayload(ctx context.Context, sel ast.SelectionSet, v *FieldsOrderPayload) graphql.Marshaler { 19009 if v == nil { 19010 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19011 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19012 } 19013 return graphql.Null 19014 } 19015 return ec._FieldsOrderPayload(ctx, sel, v) 19016 } 19017 19018 func (ec *executionContext) unmarshalNFloat2float64(ctx context.Context, v interface{}) (float64, error) { 19019 res, err := graphql.UnmarshalFloatContext(ctx, v) 19020 return res, graphql.ErrorOnPath(ctx, err) 19021 } 19022 19023 func (ec *executionContext) marshalNFloat2float64(ctx context.Context, sel ast.SelectionSet, v float64) graphql.Marshaler { 19024 res := graphql.MarshalFloatContext(v) 19025 if res == graphql.Null { 19026 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19027 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19028 } 19029 } 19030 return graphql.WrapContextMarshaler(ctx, res) 19031 } 19032 19033 func (ec *executionContext) unmarshalNID2int(ctx context.Context, v interface{}) (int, error) { 19034 res, err := graphql.UnmarshalIntID(v) 19035 return res, graphql.ErrorOnPath(ctx, err) 19036 } 19037 19038 func (ec *executionContext) marshalNID2int(ctx context.Context, sel ast.SelectionSet, v int) graphql.Marshaler { 19039 res := graphql.MarshalIntID(v) 19040 if res == graphql.Null { 19041 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19042 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19043 } 19044 } 19045 return res 19046 } 19047 19048 func (ec *executionContext) unmarshalNID2string(ctx context.Context, v interface{}) (string, error) { 19049 res, err := graphql.UnmarshalID(v) 19050 return res, graphql.ErrorOnPath(ctx, err) 19051 } 19052 19053 func (ec *executionContext) marshalNID2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler { 19054 res := graphql.MarshalID(v) 19055 if res == graphql.Null { 19056 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19057 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19058 } 19059 } 19060 return res 19061 } 19062 19063 func (ec *executionContext) unmarshalNInnerDirectives2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐInnerDirectives(ctx context.Context, v interface{}) (*InnerDirectives, error) { 19064 res, err := ec.unmarshalInputInnerDirectives(ctx, v) 19065 return &res, graphql.ErrorOnPath(ctx, err) 19066 } 19067 19068 func (ec *executionContext) unmarshalNInnerInput2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐInnerInput(ctx context.Context, v interface{}) (InnerInput, error) { 19069 res, err := ec.unmarshalInputInnerInput(ctx, v) 19070 return res, graphql.ErrorOnPath(ctx, err) 19071 } 19072 19073 func (ec *executionContext) unmarshalNInnerInput2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐInnerInput(ctx context.Context, v interface{}) (*InnerInput, error) { 19074 res, err := ec.unmarshalInputInnerInput(ctx, v) 19075 return &res, graphql.ErrorOnPath(ctx, err) 19076 } 19077 19078 func (ec *executionContext) marshalNInnerObject2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐInnerObject(ctx context.Context, sel ast.SelectionSet, v *InnerObject) graphql.Marshaler { 19079 if v == nil { 19080 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19081 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19082 } 19083 return graphql.Null 19084 } 19085 return ec._InnerObject(ctx, sel, v) 19086 } 19087 19088 func (ec *executionContext) unmarshalNInputDirectives2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐInputDirectives(ctx context.Context, v interface{}) (InputDirectives, error) { 19089 res, err := ec.unmarshalInputInputDirectives(ctx, v) 19090 return res, graphql.ErrorOnPath(ctx, err) 19091 } 19092 19093 func (ec *executionContext) unmarshalNInt2int(ctx context.Context, v interface{}) (int, error) { 19094 res, err := graphql.UnmarshalInt(v) 19095 return res, graphql.ErrorOnPath(ctx, err) 19096 } 19097 19098 func (ec *executionContext) marshalNInt2int(ctx context.Context, sel ast.SelectionSet, v int) graphql.Marshaler { 19099 res := graphql.MarshalInt(v) 19100 if res == graphql.Null { 19101 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19102 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19103 } 19104 } 19105 return res 19106 } 19107 19108 func (ec *executionContext) unmarshalNInt2int32(ctx context.Context, v interface{}) (int32, error) { 19109 res, err := graphql.UnmarshalInt32(v) 19110 return res, graphql.ErrorOnPath(ctx, err) 19111 } 19112 19113 func (ec *executionContext) marshalNInt2int32(ctx context.Context, sel ast.SelectionSet, v int32) graphql.Marshaler { 19114 res := graphql.MarshalInt32(v) 19115 if res == graphql.Null { 19116 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19117 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19118 } 19119 } 19120 return res 19121 } 19122 19123 func (ec *executionContext) unmarshalNInt2int64(ctx context.Context, v interface{}) (int64, error) { 19124 res, err := graphql.UnmarshalInt64(v) 19125 return res, graphql.ErrorOnPath(ctx, err) 19126 } 19127 19128 func (ec *executionContext) marshalNInt2int64(ctx context.Context, sel ast.SelectionSet, v int64) graphql.Marshaler { 19129 res := graphql.MarshalInt64(v) 19130 if res == graphql.Null { 19131 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19132 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19133 } 19134 } 19135 return res 19136 } 19137 19138 func (ec *executionContext) marshalNLoopA2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐLoopA(ctx context.Context, sel ast.SelectionSet, v *LoopA) graphql.Marshaler { 19139 if v == nil { 19140 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19141 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19142 } 19143 return graphql.Null 19144 } 19145 return ec._LoopA(ctx, sel, v) 19146 } 19147 19148 func (ec *executionContext) marshalNLoopB2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐLoopB(ctx context.Context, sel ast.SelectionSet, v *LoopB) graphql.Marshaler { 19149 if v == nil { 19150 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19151 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19152 } 19153 return graphql.Null 19154 } 19155 return ec._LoopB(ctx, sel, v) 19156 } 19157 19158 func (ec *executionContext) unmarshalNMarshalPanic2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐMarshalPanic(ctx context.Context, v interface{}) (MarshalPanic, error) { 19159 var res MarshalPanic 19160 err := res.UnmarshalGQL(v) 19161 return res, graphql.ErrorOnPath(ctx, err) 19162 } 19163 19164 func (ec *executionContext) marshalNMarshalPanic2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐMarshalPanic(ctx context.Context, sel ast.SelectionSet, v MarshalPanic) graphql.Marshaler { 19165 return v 19166 } 19167 19168 func (ec *executionContext) unmarshalNMarshalPanic2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐMarshalPanicᚄ(ctx context.Context, v interface{}) ([]MarshalPanic, error) { 19169 var vSlice []interface{} 19170 if v != nil { 19171 vSlice = graphql.CoerceList(v) 19172 } 19173 var err error 19174 res := make([]MarshalPanic, len(vSlice)) 19175 for i := range vSlice { 19176 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithIndex(i)) 19177 res[i], err = ec.unmarshalNMarshalPanic2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐMarshalPanic(ctx, vSlice[i]) 19178 if err != nil { 19179 return nil, err 19180 } 19181 } 19182 return res, nil 19183 } 19184 19185 func (ec *executionContext) marshalNMarshalPanic2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐMarshalPanicᚄ(ctx context.Context, sel ast.SelectionSet, v []MarshalPanic) graphql.Marshaler { 19186 ret := make(graphql.Array, len(v)) 19187 for i := range v { 19188 ret[i] = ec.marshalNMarshalPanic2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐMarshalPanic(ctx, sel, v[i]) 19189 } 19190 19191 for _, e := range ret { 19192 if e == graphql.Null { 19193 return graphql.Null 19194 } 19195 } 19196 19197 return ret 19198 } 19199 19200 func (ec *executionContext) unmarshalNNestedInput2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐNestedInput(ctx context.Context, v interface{}) (*NestedInput, error) { 19201 res, err := ec.unmarshalInputNestedInput(ctx, v) 19202 return &res, graphql.ErrorOnPath(ctx, err) 19203 } 19204 19205 func (ec *executionContext) marshalNNode2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐNode(ctx context.Context, sel ast.SelectionSet, v Node) graphql.Marshaler { 19206 if v == nil { 19207 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19208 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19209 } 19210 return graphql.Null 19211 } 19212 return ec._Node(ctx, sel, v) 19213 } 19214 19215 func (ec *executionContext) marshalNPet2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPet(ctx context.Context, sel ast.SelectionSet, v *Pet) graphql.Marshaler { 19216 if v == nil { 19217 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19218 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19219 } 19220 return graphql.Null 19221 } 19222 return ec._Pet(ctx, sel, v) 19223 } 19224 19225 func (ec *executionContext) marshalNPrimitive2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPrimitive(ctx context.Context, sel ast.SelectionSet, v Primitive) graphql.Marshaler { 19226 return ec._Primitive(ctx, sel, &v) 19227 } 19228 19229 func (ec *executionContext) marshalNPrimitive2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPrimitiveᚄ(ctx context.Context, sel ast.SelectionSet, v []Primitive) graphql.Marshaler { 19230 ret := make(graphql.Array, len(v)) 19231 var wg sync.WaitGroup 19232 isLen1 := len(v) == 1 19233 if !isLen1 { 19234 wg.Add(len(v)) 19235 } 19236 for i := range v { 19237 i := i 19238 fc := &graphql.FieldContext{ 19239 Index: &i, 19240 Result: &v[i], 19241 } 19242 ctx := graphql.WithFieldContext(ctx, fc) 19243 f := func(i int) { 19244 defer func() { 19245 if r := recover(); r != nil { 19246 ec.Error(ctx, ec.Recover(ctx, r)) 19247 ret = nil 19248 } 19249 }() 19250 if !isLen1 { 19251 defer wg.Done() 19252 } 19253 ret[i] = ec.marshalNPrimitive2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPrimitive(ctx, sel, v[i]) 19254 } 19255 if isLen1 { 19256 f(i) 19257 } else { 19258 go f(i) 19259 } 19260 19261 } 19262 wg.Wait() 19263 19264 for _, e := range ret { 19265 if e == graphql.Null { 19266 return graphql.Null 19267 } 19268 } 19269 19270 return ret 19271 } 19272 19273 func (ec *executionContext) marshalNPrimitiveString2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPrimitiveString(ctx context.Context, sel ast.SelectionSet, v PrimitiveString) graphql.Marshaler { 19274 return ec._PrimitiveString(ctx, sel, &v) 19275 } 19276 19277 func (ec *executionContext) marshalNPrimitiveString2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPrimitiveStringᚄ(ctx context.Context, sel ast.SelectionSet, v []PrimitiveString) graphql.Marshaler { 19278 ret := make(graphql.Array, len(v)) 19279 var wg sync.WaitGroup 19280 isLen1 := len(v) == 1 19281 if !isLen1 { 19282 wg.Add(len(v)) 19283 } 19284 for i := range v { 19285 i := i 19286 fc := &graphql.FieldContext{ 19287 Index: &i, 19288 Result: &v[i], 19289 } 19290 ctx := graphql.WithFieldContext(ctx, fc) 19291 f := func(i int) { 19292 defer func() { 19293 if r := recover(); r != nil { 19294 ec.Error(ctx, ec.Recover(ctx, r)) 19295 ret = nil 19296 } 19297 }() 19298 if !isLen1 { 19299 defer wg.Done() 19300 } 19301 ret[i] = ec.marshalNPrimitiveString2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPrimitiveString(ctx, sel, v[i]) 19302 } 19303 if isLen1 { 19304 f(i) 19305 } else { 19306 go f(i) 19307 } 19308 19309 } 19310 wg.Wait() 19311 19312 for _, e := range ret { 19313 if e == graphql.Null { 19314 return graphql.Null 19315 } 19316 } 19317 19318 return ret 19319 } 19320 19321 func (ec *executionContext) marshalNPtrToPtrOuter2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPtrToPtrOuter(ctx context.Context, sel ast.SelectionSet, v PtrToPtrOuter) graphql.Marshaler { 19322 return ec._PtrToPtrOuter(ctx, sel, &v) 19323 } 19324 19325 func (ec *executionContext) marshalNPtrToPtrOuter2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPtrToPtrOuter(ctx context.Context, sel ast.SelectionSet, v *PtrToPtrOuter) graphql.Marshaler { 19326 if v == nil { 19327 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19328 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19329 } 19330 return graphql.Null 19331 } 19332 return ec._PtrToPtrOuter(ctx, sel, v) 19333 } 19334 19335 func (ec *executionContext) marshalNPtrToSliceContainer2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPtrToSliceContainer(ctx context.Context, sel ast.SelectionSet, v PtrToSliceContainer) graphql.Marshaler { 19336 return ec._PtrToSliceContainer(ctx, sel, &v) 19337 } 19338 19339 func (ec *executionContext) marshalNPtrToSliceContainer2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPtrToSliceContainer(ctx context.Context, sel ast.SelectionSet, v *PtrToSliceContainer) graphql.Marshaler { 19340 if v == nil { 19341 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19342 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19343 } 19344 return graphql.Null 19345 } 19346 return ec._PtrToSliceContainer(ctx, sel, v) 19347 } 19348 19349 func (ec *executionContext) unmarshalNRecursiveInputSlice2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐRecursiveInputSlice(ctx context.Context, v interface{}) (RecursiveInputSlice, error) { 19350 res, err := ec.unmarshalInputRecursiveInputSlice(ctx, v) 19351 return res, graphql.ErrorOnPath(ctx, err) 19352 } 19353 19354 func (ec *executionContext) marshalNShapeUnion2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐShapeUnion(ctx context.Context, sel ast.SelectionSet, v ShapeUnion) graphql.Marshaler { 19355 if v == nil { 19356 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19357 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19358 } 19359 return graphql.Null 19360 } 19361 return ec._ShapeUnion(ctx, sel, v) 19362 } 19363 19364 func (ec *executionContext) unmarshalNSpecialInput2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐSpecialInput(ctx context.Context, v interface{}) (SpecialInput, error) { 19365 res, err := ec.unmarshalInputSpecialInput(ctx, v) 19366 return res, graphql.ErrorOnPath(ctx, err) 19367 } 19368 19369 func (ec *executionContext) unmarshalNString2string(ctx context.Context, v interface{}) (string, error) { 19370 res, err := graphql.UnmarshalString(v) 19371 return res, graphql.ErrorOnPath(ctx, err) 19372 } 19373 19374 func (ec *executionContext) marshalNString2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler { 19375 res := graphql.MarshalString(v) 19376 if res == graphql.Null { 19377 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19378 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19379 } 19380 } 19381 return res 19382 } 19383 19384 func (ec *executionContext) unmarshalNString2ᚕstringᚄ(ctx context.Context, v interface{}) ([]string, error) { 19385 var vSlice []interface{} 19386 if v != nil { 19387 vSlice = graphql.CoerceList(v) 19388 } 19389 var err error 19390 res := make([]string, len(vSlice)) 19391 for i := range vSlice { 19392 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithIndex(i)) 19393 res[i], err = ec.unmarshalNString2string(ctx, vSlice[i]) 19394 if err != nil { 19395 return nil, err 19396 } 19397 } 19398 return res, nil 19399 } 19400 19401 func (ec *executionContext) marshalNString2ᚕstringᚄ(ctx context.Context, sel ast.SelectionSet, v []string) graphql.Marshaler { 19402 ret := make(graphql.Array, len(v)) 19403 for i := range v { 19404 ret[i] = ec.marshalNString2string(ctx, sel, v[i]) 19405 } 19406 19407 for _, e := range ret { 19408 if e == graphql.Null { 19409 return graphql.Null 19410 } 19411 } 19412 19413 return ret 19414 } 19415 19416 func (ec *executionContext) unmarshalNString2ᚕᚖstring(ctx context.Context, v interface{}) ([]*string, error) { 19417 var vSlice []interface{} 19418 if v != nil { 19419 vSlice = graphql.CoerceList(v) 19420 } 19421 var err error 19422 res := make([]*string, len(vSlice)) 19423 for i := range vSlice { 19424 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithIndex(i)) 19425 res[i], err = ec.unmarshalOString2ᚖstring(ctx, vSlice[i]) 19426 if err != nil { 19427 return nil, err 19428 } 19429 } 19430 return res, nil 19431 } 19432 19433 func (ec *executionContext) marshalNString2ᚕᚖstring(ctx context.Context, sel ast.SelectionSet, v []*string) graphql.Marshaler { 19434 ret := make(graphql.Array, len(v)) 19435 for i := range v { 19436 ret[i] = ec.marshalOString2ᚖstring(ctx, sel, v[i]) 19437 } 19438 19439 return ret 19440 } 19441 19442 func (ec *executionContext) unmarshalNString2ᚖstring(ctx context.Context, v interface{}) (*string, error) { 19443 res, err := graphql.UnmarshalString(v) 19444 return &res, graphql.ErrorOnPath(ctx, err) 19445 } 19446 19447 func (ec *executionContext) marshalNString2ᚖstring(ctx context.Context, sel ast.SelectionSet, v *string) graphql.Marshaler { 19448 if v == nil { 19449 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19450 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19451 } 19452 return graphql.Null 19453 } 19454 res := graphql.MarshalString(*v) 19455 if res == graphql.Null { 19456 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19457 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19458 } 19459 } 19460 return res 19461 } 19462 19463 func (ec *executionContext) unmarshalNStringFromContextFunction2string(ctx context.Context, v interface{}) (string, error) { 19464 res, err := UnmarshalStringFromContextFunction(ctx, v) 19465 return res, graphql.ErrorOnPath(ctx, err) 19466 } 19467 19468 func (ec *executionContext) marshalNStringFromContextFunction2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler { 19469 res := MarshalStringFromContextFunction(v) 19470 if res == graphql.Null { 19471 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19472 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19473 } 19474 } 19475 return graphql.WrapContextMarshaler(ctx, res) 19476 } 19477 19478 func (ec *executionContext) unmarshalNStringFromContextInterface2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐStringFromContextInterface(ctx context.Context, v interface{}) (StringFromContextInterface, error) { 19479 var res StringFromContextInterface 19480 err := res.UnmarshalGQLContext(ctx, v) 19481 return res, graphql.ErrorOnPath(ctx, err) 19482 } 19483 19484 func (ec *executionContext) marshalNStringFromContextInterface2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐStringFromContextInterface(ctx context.Context, sel ast.SelectionSet, v StringFromContextInterface) graphql.Marshaler { 19485 return graphql.WrapContextMarshaler(ctx, v) 19486 } 19487 19488 func (ec *executionContext) unmarshalNStringFromContextInterface2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐStringFromContextInterface(ctx context.Context, v interface{}) (*StringFromContextInterface, error) { 19489 var res = new(StringFromContextInterface) 19490 err := res.UnmarshalGQLContext(ctx, v) 19491 return res, graphql.ErrorOnPath(ctx, err) 19492 } 19493 19494 func (ec *executionContext) marshalNStringFromContextInterface2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐStringFromContextInterface(ctx context.Context, sel ast.SelectionSet, v *StringFromContextInterface) graphql.Marshaler { 19495 if v == nil { 19496 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19497 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19498 } 19499 return graphql.Null 19500 } 19501 return graphql.WrapContextMarshaler(ctx, v) 19502 } 19503 19504 func (ec *executionContext) unmarshalNTime2timeᚐTime(ctx context.Context, v interface{}) (time.Time, error) { 19505 res, err := graphql.UnmarshalTime(v) 19506 return res, graphql.ErrorOnPath(ctx, err) 19507 } 19508 19509 func (ec *executionContext) marshalNTime2timeᚐTime(ctx context.Context, sel ast.SelectionSet, v time.Time) graphql.Marshaler { 19510 res := graphql.MarshalTime(v) 19511 if res == graphql.Null { 19512 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19513 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19514 } 19515 } 19516 return res 19517 } 19518 19519 func (ec *executionContext) unmarshalNUUID2string(ctx context.Context, v interface{}) (string, error) { 19520 res, err := graphql.UnmarshalString(v) 19521 return res, graphql.ErrorOnPath(ctx, err) 19522 } 19523 19524 func (ec *executionContext) marshalNUUID2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler { 19525 res := graphql.MarshalString(v) 19526 if res == graphql.Null { 19527 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19528 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19529 } 19530 } 19531 return res 19532 } 19533 19534 func (ec *executionContext) unmarshalNUpdatePtrToPtrOuter2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUpdatePtrToPtrOuter(ctx context.Context, v interface{}) (UpdatePtrToPtrOuter, error) { 19535 res, err := ec.unmarshalInputUpdatePtrToPtrOuter(ctx, v) 19536 return res, graphql.ErrorOnPath(ctx, err) 19537 } 19538 19539 func (ec *executionContext) marshalNUser2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUser(ctx context.Context, sel ast.SelectionSet, v User) graphql.Marshaler { 19540 return ec._User(ctx, sel, &v) 19541 } 19542 19543 func (ec *executionContext) marshalNUser2ᚕᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUserᚄ(ctx context.Context, sel ast.SelectionSet, v []*User) graphql.Marshaler { 19544 ret := make(graphql.Array, len(v)) 19545 var wg sync.WaitGroup 19546 isLen1 := len(v) == 1 19547 if !isLen1 { 19548 wg.Add(len(v)) 19549 } 19550 for i := range v { 19551 i := i 19552 fc := &graphql.FieldContext{ 19553 Index: &i, 19554 Result: &v[i], 19555 } 19556 ctx := graphql.WithFieldContext(ctx, fc) 19557 f := func(i int) { 19558 defer func() { 19559 if r := recover(); r != nil { 19560 ec.Error(ctx, ec.Recover(ctx, r)) 19561 ret = nil 19562 } 19563 }() 19564 if !isLen1 { 19565 defer wg.Done() 19566 } 19567 ret[i] = ec.marshalNUser2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUser(ctx, sel, v[i]) 19568 } 19569 if isLen1 { 19570 f(i) 19571 } else { 19572 go f(i) 19573 } 19574 19575 } 19576 wg.Wait() 19577 19578 for _, e := range ret { 19579 if e == graphql.Null { 19580 return graphql.Null 19581 } 19582 } 19583 19584 return ret 19585 } 19586 19587 func (ec *executionContext) marshalNUser2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUser(ctx context.Context, sel ast.SelectionSet, v *User) graphql.Marshaler { 19588 if v == nil { 19589 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19590 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19591 } 19592 return graphql.Null 19593 } 19594 return ec._User(ctx, sel, v) 19595 } 19596 19597 func (ec *executionContext) marshalNWrappedMap2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐWrappedMap(ctx context.Context, sel ast.SelectionSet, v WrappedMap) graphql.Marshaler { 19598 if v == nil { 19599 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19600 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19601 } 19602 return graphql.Null 19603 } 19604 return ec._WrappedMap(ctx, sel, v) 19605 } 19606 19607 func (ec *executionContext) unmarshalNWrappedScalar2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚋotherpkgᚐScalar(ctx context.Context, v interface{}) (otherpkg.Scalar, error) { 19608 tmp, err := graphql.UnmarshalString(v) 19609 res := otherpkg.Scalar(tmp) 19610 return res, graphql.ErrorOnPath(ctx, err) 19611 } 19612 19613 func (ec *executionContext) marshalNWrappedScalar2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚋotherpkgᚐScalar(ctx context.Context, sel ast.SelectionSet, v otherpkg.Scalar) graphql.Marshaler { 19614 res := graphql.MarshalString(string(v)) 19615 if res == graphql.Null { 19616 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19617 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19618 } 19619 } 19620 return res 19621 } 19622 19623 func (ec *executionContext) marshalNWrappedSlice2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐWrappedSlice(ctx context.Context, sel ast.SelectionSet, v WrappedSlice) graphql.Marshaler { 19624 if v == nil { 19625 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19626 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19627 } 19628 return graphql.Null 19629 } 19630 return ec._WrappedSlice(ctx, sel, v) 19631 } 19632 19633 func (ec *executionContext) marshalNWrappedStruct2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐWrappedStruct(ctx context.Context, sel ast.SelectionSet, v WrappedStruct) graphql.Marshaler { 19634 return ec._WrappedStruct(ctx, sel, &v) 19635 } 19636 19637 func (ec *executionContext) marshalNWrappedStruct2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐWrappedStruct(ctx context.Context, sel ast.SelectionSet, v *WrappedStruct) graphql.Marshaler { 19638 if v == nil { 19639 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19640 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19641 } 19642 return graphql.Null 19643 } 19644 return ec._WrappedStruct(ctx, sel, v) 19645 } 19646 19647 func (ec *executionContext) marshalN__Directive2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirective(ctx context.Context, sel ast.SelectionSet, v introspection.Directive) graphql.Marshaler { 19648 return ec.___Directive(ctx, sel, &v) 19649 } 19650 19651 func (ec *executionContext) marshalN__Directive2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirectiveᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.Directive) graphql.Marshaler { 19652 ret := make(graphql.Array, len(v)) 19653 var wg sync.WaitGroup 19654 isLen1 := len(v) == 1 19655 if !isLen1 { 19656 wg.Add(len(v)) 19657 } 19658 for i := range v { 19659 i := i 19660 fc := &graphql.FieldContext{ 19661 Index: &i, 19662 Result: &v[i], 19663 } 19664 ctx := graphql.WithFieldContext(ctx, fc) 19665 f := func(i int) { 19666 defer func() { 19667 if r := recover(); r != nil { 19668 ec.Error(ctx, ec.Recover(ctx, r)) 19669 ret = nil 19670 } 19671 }() 19672 if !isLen1 { 19673 defer wg.Done() 19674 } 19675 ret[i] = ec.marshalN__Directive2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirective(ctx, sel, v[i]) 19676 } 19677 if isLen1 { 19678 f(i) 19679 } else { 19680 go f(i) 19681 } 19682 19683 } 19684 wg.Wait() 19685 19686 for _, e := range ret { 19687 if e == graphql.Null { 19688 return graphql.Null 19689 } 19690 } 19691 19692 return ret 19693 } 19694 19695 func (ec *executionContext) unmarshalN__DirectiveLocation2string(ctx context.Context, v interface{}) (string, error) { 19696 res, err := graphql.UnmarshalString(v) 19697 return res, graphql.ErrorOnPath(ctx, err) 19698 } 19699 19700 func (ec *executionContext) marshalN__DirectiveLocation2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler { 19701 res := graphql.MarshalString(v) 19702 if res == graphql.Null { 19703 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19704 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19705 } 19706 } 19707 return res 19708 } 19709 19710 func (ec *executionContext) unmarshalN__DirectiveLocation2ᚕstringᚄ(ctx context.Context, v interface{}) ([]string, error) { 19711 var vSlice []interface{} 19712 if v != nil { 19713 vSlice = graphql.CoerceList(v) 19714 } 19715 var err error 19716 res := make([]string, len(vSlice)) 19717 for i := range vSlice { 19718 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithIndex(i)) 19719 res[i], err = ec.unmarshalN__DirectiveLocation2string(ctx, vSlice[i]) 19720 if err != nil { 19721 return nil, err 19722 } 19723 } 19724 return res, nil 19725 } 19726 19727 func (ec *executionContext) marshalN__DirectiveLocation2ᚕstringᚄ(ctx context.Context, sel ast.SelectionSet, v []string) graphql.Marshaler { 19728 ret := make(graphql.Array, len(v)) 19729 var wg sync.WaitGroup 19730 isLen1 := len(v) == 1 19731 if !isLen1 { 19732 wg.Add(len(v)) 19733 } 19734 for i := range v { 19735 i := i 19736 fc := &graphql.FieldContext{ 19737 Index: &i, 19738 Result: &v[i], 19739 } 19740 ctx := graphql.WithFieldContext(ctx, fc) 19741 f := func(i int) { 19742 defer func() { 19743 if r := recover(); r != nil { 19744 ec.Error(ctx, ec.Recover(ctx, r)) 19745 ret = nil 19746 } 19747 }() 19748 if !isLen1 { 19749 defer wg.Done() 19750 } 19751 ret[i] = ec.marshalN__DirectiveLocation2string(ctx, sel, v[i]) 19752 } 19753 if isLen1 { 19754 f(i) 19755 } else { 19756 go f(i) 19757 } 19758 19759 } 19760 wg.Wait() 19761 19762 for _, e := range ret { 19763 if e == graphql.Null { 19764 return graphql.Null 19765 } 19766 } 19767 19768 return ret 19769 } 19770 19771 func (ec *executionContext) marshalN__EnumValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValue(ctx context.Context, sel ast.SelectionSet, v introspection.EnumValue) graphql.Marshaler { 19772 return ec.___EnumValue(ctx, sel, &v) 19773 } 19774 19775 func (ec *executionContext) marshalN__Field2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐField(ctx context.Context, sel ast.SelectionSet, v introspection.Field) graphql.Marshaler { 19776 return ec.___Field(ctx, sel, &v) 19777 } 19778 19779 func (ec *executionContext) marshalN__InputValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx context.Context, sel ast.SelectionSet, v introspection.InputValue) graphql.Marshaler { 19780 return ec.___InputValue(ctx, sel, &v) 19781 } 19782 19783 func (ec *executionContext) marshalN__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.InputValue) graphql.Marshaler { 19784 ret := make(graphql.Array, len(v)) 19785 var wg sync.WaitGroup 19786 isLen1 := len(v) == 1 19787 if !isLen1 { 19788 wg.Add(len(v)) 19789 } 19790 for i := range v { 19791 i := i 19792 fc := &graphql.FieldContext{ 19793 Index: &i, 19794 Result: &v[i], 19795 } 19796 ctx := graphql.WithFieldContext(ctx, fc) 19797 f := func(i int) { 19798 defer func() { 19799 if r := recover(); r != nil { 19800 ec.Error(ctx, ec.Recover(ctx, r)) 19801 ret = nil 19802 } 19803 }() 19804 if !isLen1 { 19805 defer wg.Done() 19806 } 19807 ret[i] = ec.marshalN__InputValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx, sel, v[i]) 19808 } 19809 if isLen1 { 19810 f(i) 19811 } else { 19812 go f(i) 19813 } 19814 19815 } 19816 wg.Wait() 19817 19818 for _, e := range ret { 19819 if e == graphql.Null { 19820 return graphql.Null 19821 } 19822 } 19823 19824 return ret 19825 } 19826 19827 func (ec *executionContext) marshalN__Type2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v introspection.Type) graphql.Marshaler { 19828 return ec.___Type(ctx, sel, &v) 19829 } 19830 19831 func (ec *executionContext) marshalN__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.Type) graphql.Marshaler { 19832 ret := make(graphql.Array, len(v)) 19833 var wg sync.WaitGroup 19834 isLen1 := len(v) == 1 19835 if !isLen1 { 19836 wg.Add(len(v)) 19837 } 19838 for i := range v { 19839 i := i 19840 fc := &graphql.FieldContext{ 19841 Index: &i, 19842 Result: &v[i], 19843 } 19844 ctx := graphql.WithFieldContext(ctx, fc) 19845 f := func(i int) { 19846 defer func() { 19847 if r := recover(); r != nil { 19848 ec.Error(ctx, ec.Recover(ctx, r)) 19849 ret = nil 19850 } 19851 }() 19852 if !isLen1 { 19853 defer wg.Done() 19854 } 19855 ret[i] = ec.marshalN__Type2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, sel, v[i]) 19856 } 19857 if isLen1 { 19858 f(i) 19859 } else { 19860 go f(i) 19861 } 19862 19863 } 19864 wg.Wait() 19865 19866 for _, e := range ret { 19867 if e == graphql.Null { 19868 return graphql.Null 19869 } 19870 } 19871 19872 return ret 19873 } 19874 19875 func (ec *executionContext) marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v *introspection.Type) graphql.Marshaler { 19876 if v == nil { 19877 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19878 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19879 } 19880 return graphql.Null 19881 } 19882 return ec.___Type(ctx, sel, v) 19883 } 19884 19885 func (ec *executionContext) unmarshalN__TypeKind2string(ctx context.Context, v interface{}) (string, error) { 19886 res, err := graphql.UnmarshalString(v) 19887 return res, graphql.ErrorOnPath(ctx, err) 19888 } 19889 19890 func (ec *executionContext) marshalN__TypeKind2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler { 19891 res := graphql.MarshalString(v) 19892 if res == graphql.Null { 19893 if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 19894 ec.Errorf(ctx, "the requested element is null which the schema does not allow") 19895 } 19896 } 19897 return res 19898 } 19899 19900 func (ec *executionContext) marshalOAnimal2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐAnimal(ctx context.Context, sel ast.SelectionSet, v Animal) graphql.Marshaler { 19901 if v == nil { 19902 return graphql.Null 19903 } 19904 return ec._Animal(ctx, sel, v) 19905 } 19906 19907 func (ec *executionContext) marshalOAutobind2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐAutobind(ctx context.Context, sel ast.SelectionSet, v *Autobind) graphql.Marshaler { 19908 if v == nil { 19909 return graphql.Null 19910 } 19911 return ec._Autobind(ctx, sel, v) 19912 } 19913 19914 func (ec *executionContext) marshalOBackedByInterface2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐBackedByInterface(ctx context.Context, sel ast.SelectionSet, v BackedByInterface) graphql.Marshaler { 19915 if v == nil { 19916 return graphql.Null 19917 } 19918 return ec._BackedByInterface(ctx, sel, v) 19919 } 19920 19921 func (ec *executionContext) unmarshalOBoolean2bool(ctx context.Context, v interface{}) (bool, error) { 19922 res, err := graphql.UnmarshalBoolean(v) 19923 return res, graphql.ErrorOnPath(ctx, err) 19924 } 19925 19926 func (ec *executionContext) marshalOBoolean2bool(ctx context.Context, sel ast.SelectionSet, v bool) graphql.Marshaler { 19927 res := graphql.MarshalBoolean(v) 19928 return res 19929 } 19930 19931 func (ec *executionContext) unmarshalOBoolean2ᚖbool(ctx context.Context, v interface{}) (*bool, error) { 19932 if v == nil { 19933 return nil, nil 19934 } 19935 res, err := graphql.UnmarshalBoolean(v) 19936 return &res, graphql.ErrorOnPath(ctx, err) 19937 } 19938 19939 func (ec *executionContext) marshalOBoolean2ᚖbool(ctx context.Context, sel ast.SelectionSet, v *bool) graphql.Marshaler { 19940 if v == nil { 19941 return graphql.Null 19942 } 19943 res := graphql.MarshalBoolean(*v) 19944 return res 19945 } 19946 19947 func (ec *executionContext) unmarshalOChanges2map(ctx context.Context, v interface{}) (map[string]interface{}, error) { 19948 if v == nil { 19949 return nil, nil 19950 } 19951 return v.(map[string]interface{}), nil 19952 } 19953 19954 func (ec *executionContext) marshalOCheckIssue8962ᚕᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐCheckIssue896(ctx context.Context, sel ast.SelectionSet, v []*CheckIssue896) graphql.Marshaler { 19955 if v == nil { 19956 return graphql.Null 19957 } 19958 ret := make(graphql.Array, len(v)) 19959 var wg sync.WaitGroup 19960 isLen1 := len(v) == 1 19961 if !isLen1 { 19962 wg.Add(len(v)) 19963 } 19964 for i := range v { 19965 i := i 19966 fc := &graphql.FieldContext{ 19967 Index: &i, 19968 Result: &v[i], 19969 } 19970 ctx := graphql.WithFieldContext(ctx, fc) 19971 f := func(i int) { 19972 defer func() { 19973 if r := recover(); r != nil { 19974 ec.Error(ctx, ec.Recover(ctx, r)) 19975 ret = nil 19976 } 19977 }() 19978 if !isLen1 { 19979 defer wg.Done() 19980 } 19981 ret[i] = ec.marshalOCheckIssue8962ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐCheckIssue896(ctx, sel, v[i]) 19982 } 19983 if isLen1 { 19984 f(i) 19985 } else { 19986 go f(i) 19987 } 19988 19989 } 19990 wg.Wait() 19991 19992 return ret 19993 } 19994 19995 func (ec *executionContext) marshalOCheckIssue8962ᚕᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐCheckIssue896ᚄ(ctx context.Context, sel ast.SelectionSet, v []*CheckIssue896) graphql.Marshaler { 19996 if v == nil { 19997 return graphql.Null 19998 } 19999 ret := make(graphql.Array, len(v)) 20000 var wg sync.WaitGroup 20001 isLen1 := len(v) == 1 20002 if !isLen1 { 20003 wg.Add(len(v)) 20004 } 20005 for i := range v { 20006 i := i 20007 fc := &graphql.FieldContext{ 20008 Index: &i, 20009 Result: &v[i], 20010 } 20011 ctx := graphql.WithFieldContext(ctx, fc) 20012 f := func(i int) { 20013 defer func() { 20014 if r := recover(); r != nil { 20015 ec.Error(ctx, ec.Recover(ctx, r)) 20016 ret = nil 20017 } 20018 }() 20019 if !isLen1 { 20020 defer wg.Done() 20021 } 20022 ret[i] = ec.marshalNCheckIssue8962ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐCheckIssue896(ctx, sel, v[i]) 20023 } 20024 if isLen1 { 20025 f(i) 20026 } else { 20027 go f(i) 20028 } 20029 20030 } 20031 wg.Wait() 20032 20033 for _, e := range ret { 20034 if e == graphql.Null { 20035 return graphql.Null 20036 } 20037 } 20038 20039 return ret 20040 } 20041 20042 func (ec *executionContext) marshalOCheckIssue8962ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐCheckIssue896(ctx context.Context, sel ast.SelectionSet, v *CheckIssue896) graphql.Marshaler { 20043 if v == nil { 20044 return graphql.Null 20045 } 20046 return ec._CheckIssue896(ctx, sel, v) 20047 } 20048 20049 func (ec *executionContext) marshalOCircle2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐCircle(ctx context.Context, sel ast.SelectionSet, v *Circle) graphql.Marshaler { 20050 if v == nil { 20051 return graphql.Null 20052 } 20053 return ec._Circle(ctx, sel, v) 20054 } 20055 20056 func (ec *executionContext) marshalOCoordinates2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐCoordinates(ctx context.Context, sel ast.SelectionSet, v Coordinates) graphql.Marshaler { 20057 return ec._Coordinates(ctx, sel, &v) 20058 } 20059 20060 func (ec *executionContext) unmarshalODefaultScalarImplementation2ᚖstring(ctx context.Context, v interface{}) (*string, error) { 20061 if v == nil { 20062 return nil, nil 20063 } 20064 res, err := graphql.UnmarshalString(v) 20065 return &res, graphql.ErrorOnPath(ctx, err) 20066 } 20067 20068 func (ec *executionContext) marshalODefaultScalarImplementation2ᚖstring(ctx context.Context, sel ast.SelectionSet, v *string) graphql.Marshaler { 20069 if v == nil { 20070 return graphql.Null 20071 } 20072 res := graphql.MarshalString(*v) 20073 return res 20074 } 20075 20076 func (ec *executionContext) marshalOEmbeddedCase12ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐEmbeddedCase1(ctx context.Context, sel ast.SelectionSet, v *EmbeddedCase1) graphql.Marshaler { 20077 if v == nil { 20078 return graphql.Null 20079 } 20080 return ec._EmbeddedCase1(ctx, sel, v) 20081 } 20082 20083 func (ec *executionContext) marshalOEmbeddedCase22ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐEmbeddedCase2(ctx context.Context, sel ast.SelectionSet, v *EmbeddedCase2) graphql.Marshaler { 20084 if v == nil { 20085 return graphql.Null 20086 } 20087 return ec._EmbeddedCase2(ctx, sel, v) 20088 } 20089 20090 func (ec *executionContext) marshalOEmbeddedCase32ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐEmbeddedCase3(ctx context.Context, sel ast.SelectionSet, v *EmbeddedCase3) graphql.Marshaler { 20091 if v == nil { 20092 return graphql.Null 20093 } 20094 return ec._EmbeddedCase3(ctx, sel, v) 20095 } 20096 20097 func (ec *executionContext) marshalOError2ᚕᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐError(ctx context.Context, sel ast.SelectionSet, v []*Error) graphql.Marshaler { 20098 if v == nil { 20099 return graphql.Null 20100 } 20101 ret := make(graphql.Array, len(v)) 20102 var wg sync.WaitGroup 20103 isLen1 := len(v) == 1 20104 if !isLen1 { 20105 wg.Add(len(v)) 20106 } 20107 for i := range v { 20108 i := i 20109 fc := &graphql.FieldContext{ 20110 Index: &i, 20111 Result: &v[i], 20112 } 20113 ctx := graphql.WithFieldContext(ctx, fc) 20114 f := func(i int) { 20115 defer func() { 20116 if r := recover(); r != nil { 20117 ec.Error(ctx, ec.Recover(ctx, r)) 20118 ret = nil 20119 } 20120 }() 20121 if !isLen1 { 20122 defer wg.Done() 20123 } 20124 ret[i] = ec.marshalOError2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐError(ctx, sel, v[i]) 20125 } 20126 if isLen1 { 20127 f(i) 20128 } else { 20129 go f(i) 20130 } 20131 20132 } 20133 wg.Wait() 20134 20135 return ret 20136 } 20137 20138 func (ec *executionContext) marshalOError2ᚕᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐErrorᚄ(ctx context.Context, sel ast.SelectionSet, v []*Error) graphql.Marshaler { 20139 if v == nil { 20140 return graphql.Null 20141 } 20142 ret := make(graphql.Array, len(v)) 20143 var wg sync.WaitGroup 20144 isLen1 := len(v) == 1 20145 if !isLen1 { 20146 wg.Add(len(v)) 20147 } 20148 for i := range v { 20149 i := i 20150 fc := &graphql.FieldContext{ 20151 Index: &i, 20152 Result: &v[i], 20153 } 20154 ctx := graphql.WithFieldContext(ctx, fc) 20155 f := func(i int) { 20156 defer func() { 20157 if r := recover(); r != nil { 20158 ec.Error(ctx, ec.Recover(ctx, r)) 20159 ret = nil 20160 } 20161 }() 20162 if !isLen1 { 20163 defer wg.Done() 20164 } 20165 ret[i] = ec.marshalNError2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐError(ctx, sel, v[i]) 20166 } 20167 if isLen1 { 20168 f(i) 20169 } else { 20170 go f(i) 20171 } 20172 20173 } 20174 wg.Wait() 20175 20176 for _, e := range ret { 20177 if e == graphql.Null { 20178 return graphql.Null 20179 } 20180 } 20181 20182 return ret 20183 } 20184 20185 func (ec *executionContext) marshalOError2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐError(ctx context.Context, sel ast.SelectionSet, v *Error) graphql.Marshaler { 20186 if v == nil { 20187 return graphql.Null 20188 } 20189 return ec._Error(ctx, sel, v) 20190 } 20191 20192 func (ec *executionContext) marshalOErrors2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐErrors(ctx context.Context, sel ast.SelectionSet, v *Errors) graphql.Marshaler { 20193 if v == nil { 20194 return graphql.Null 20195 } 20196 return ec._Errors(ctx, sel, v) 20197 } 20198 20199 func (ec *executionContext) unmarshalOFloat2float64(ctx context.Context, v interface{}) (float64, error) { 20200 res, err := graphql.UnmarshalFloatContext(ctx, v) 20201 return res, graphql.ErrorOnPath(ctx, err) 20202 } 20203 20204 func (ec *executionContext) marshalOFloat2float64(ctx context.Context, sel ast.SelectionSet, v float64) graphql.Marshaler { 20205 res := graphql.MarshalFloatContext(v) 20206 return graphql.WrapContextMarshaler(ctx, res) 20207 } 20208 20209 func (ec *executionContext) unmarshalOInnerDirectives2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐInnerDirectives(ctx context.Context, v interface{}) (*InnerDirectives, error) { 20210 if v == nil { 20211 return nil, nil 20212 } 20213 res, err := ec.unmarshalInputInnerDirectives(ctx, v) 20214 return &res, graphql.ErrorOnPath(ctx, err) 20215 } 20216 20217 func (ec *executionContext) unmarshalOInputDirectives2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐInputDirectives(ctx context.Context, v interface{}) (*InputDirectives, error) { 20218 if v == nil { 20219 return nil, nil 20220 } 20221 res, err := ec.unmarshalInputInputDirectives(ctx, v) 20222 return &res, graphql.ErrorOnPath(ctx, err) 20223 } 20224 20225 func (ec *executionContext) unmarshalOInputWithEnumValue2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐInputWithEnumValue(ctx context.Context, v interface{}) (*InputWithEnumValue, error) { 20226 if v == nil { 20227 return nil, nil 20228 } 20229 res, err := ec.unmarshalInputInputWithEnumValue(ctx, v) 20230 return &res, graphql.ErrorOnPath(ctx, err) 20231 } 20232 20233 func (ec *executionContext) unmarshalOInt2ᚖint(ctx context.Context, v interface{}) (*int, error) { 20234 if v == nil { 20235 return nil, nil 20236 } 20237 res, err := graphql.UnmarshalInt(v) 20238 return &res, graphql.ErrorOnPath(ctx, err) 20239 } 20240 20241 func (ec *executionContext) marshalOInt2ᚖint(ctx context.Context, sel ast.SelectionSet, v *int) graphql.Marshaler { 20242 if v == nil { 20243 return graphql.Null 20244 } 20245 res := graphql.MarshalInt(*v) 20246 return res 20247 } 20248 20249 func (ec *executionContext) marshalOInvalidIdentifier2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚋinvalidᚑpackagenameᚐInvalidIdentifier(ctx context.Context, sel ast.SelectionSet, v *invalid_packagename.InvalidIdentifier) graphql.Marshaler { 20250 if v == nil { 20251 return graphql.Null 20252 } 20253 return ec._InvalidIdentifier(ctx, sel, v) 20254 } 20255 20256 func (ec *executionContext) marshalOIt2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚋintrospectionᚐIt(ctx context.Context, sel ast.SelectionSet, v *introspection1.It) graphql.Marshaler { 20257 if v == nil { 20258 return graphql.Null 20259 } 20260 return ec._It(ctx, sel, v) 20261 } 20262 20263 func (ec *executionContext) unmarshalOMapStringInterfaceInput2map(ctx context.Context, v interface{}) (map[string]interface{}, error) { 20264 if v == nil { 20265 return nil, nil 20266 } 20267 return v.(map[string]interface{}), nil 20268 } 20269 20270 func (ec *executionContext) marshalOMapStringInterfaceType2map(ctx context.Context, sel ast.SelectionSet, v map[string]interface{}) graphql.Marshaler { 20271 if v == nil { 20272 return graphql.Null 20273 } 20274 return ec._MapStringInterfaceType(ctx, sel, v) 20275 } 20276 20277 func (ec *executionContext) marshalOModelMethods2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐModelMethods(ctx context.Context, sel ast.SelectionSet, v *ModelMethods) graphql.Marshaler { 20278 if v == nil { 20279 return graphql.Null 20280 } 20281 return ec._ModelMethods(ctx, sel, v) 20282 } 20283 20284 func (ec *executionContext) unmarshalONestedMapInput2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐNestedMapInput(ctx context.Context, v interface{}) (*NestedMapInput, error) { 20285 if v == nil { 20286 return nil, nil 20287 } 20288 res, err := ec.unmarshalInputNestedMapInput(ctx, v) 20289 return &res, graphql.ErrorOnPath(ctx, err) 20290 } 20291 20292 func (ec *executionContext) marshalOObjectDirectives2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐObjectDirectives(ctx context.Context, sel ast.SelectionSet, v *ObjectDirectives) graphql.Marshaler { 20293 if v == nil { 20294 return graphql.Null 20295 } 20296 return ec._ObjectDirectives(ctx, sel, v) 20297 } 20298 20299 func (ec *executionContext) marshalOObjectDirectivesWithCustomGoModel2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐObjectDirectivesWithCustomGoModel(ctx context.Context, sel ast.SelectionSet, v *ObjectDirectivesWithCustomGoModel) graphql.Marshaler { 20300 if v == nil { 20301 return graphql.Null 20302 } 20303 return ec._ObjectDirectivesWithCustomGoModel(ctx, sel, v) 20304 } 20305 20306 func (ec *executionContext) unmarshalOOuterInput2ᚕᚕᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐOuterInput(ctx context.Context, v interface{}) ([][]*OuterInput, error) { 20307 if v == nil { 20308 return nil, nil 20309 } 20310 var vSlice []interface{} 20311 if v != nil { 20312 vSlice = graphql.CoerceList(v) 20313 } 20314 var err error 20315 res := make([][]*OuterInput, len(vSlice)) 20316 for i := range vSlice { 20317 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithIndex(i)) 20318 res[i], err = ec.unmarshalOOuterInput2ᚕᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐOuterInput(ctx, vSlice[i]) 20319 if err != nil { 20320 return nil, err 20321 } 20322 } 20323 return res, nil 20324 } 20325 20326 func (ec *executionContext) unmarshalOOuterInput2ᚕᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐOuterInput(ctx context.Context, v interface{}) ([]*OuterInput, error) { 20327 if v == nil { 20328 return nil, nil 20329 } 20330 var vSlice []interface{} 20331 if v != nil { 20332 vSlice = graphql.CoerceList(v) 20333 } 20334 var err error 20335 res := make([]*OuterInput, len(vSlice)) 20336 for i := range vSlice { 20337 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithIndex(i)) 20338 res[i], err = ec.unmarshalOOuterInput2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐOuterInput(ctx, vSlice[i]) 20339 if err != nil { 20340 return nil, err 20341 } 20342 } 20343 return res, nil 20344 } 20345 20346 func (ec *executionContext) unmarshalOOuterInput2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐOuterInput(ctx context.Context, v interface{}) (*OuterInput, error) { 20347 if v == nil { 20348 return nil, nil 20349 } 20350 res, err := ec.unmarshalInputOuterInput(ctx, v) 20351 return &res, graphql.ErrorOnPath(ctx, err) 20352 } 20353 20354 func (ec *executionContext) marshalOOuterObject2ᚕᚕᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐOuterObject(ctx context.Context, sel ast.SelectionSet, v [][]*OuterObject) graphql.Marshaler { 20355 if v == nil { 20356 return graphql.Null 20357 } 20358 ret := make(graphql.Array, len(v)) 20359 var wg sync.WaitGroup 20360 isLen1 := len(v) == 1 20361 if !isLen1 { 20362 wg.Add(len(v)) 20363 } 20364 for i := range v { 20365 i := i 20366 fc := &graphql.FieldContext{ 20367 Index: &i, 20368 Result: &v[i], 20369 } 20370 ctx := graphql.WithFieldContext(ctx, fc) 20371 f := func(i int) { 20372 defer func() { 20373 if r := recover(); r != nil { 20374 ec.Error(ctx, ec.Recover(ctx, r)) 20375 ret = nil 20376 } 20377 }() 20378 if !isLen1 { 20379 defer wg.Done() 20380 } 20381 ret[i] = ec.marshalOOuterObject2ᚕᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐOuterObject(ctx, sel, v[i]) 20382 } 20383 if isLen1 { 20384 f(i) 20385 } else { 20386 go f(i) 20387 } 20388 20389 } 20390 wg.Wait() 20391 20392 return ret 20393 } 20394 20395 func (ec *executionContext) marshalOOuterObject2ᚕᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐOuterObject(ctx context.Context, sel ast.SelectionSet, v []*OuterObject) graphql.Marshaler { 20396 if v == nil { 20397 return graphql.Null 20398 } 20399 ret := make(graphql.Array, len(v)) 20400 var wg sync.WaitGroup 20401 isLen1 := len(v) == 1 20402 if !isLen1 { 20403 wg.Add(len(v)) 20404 } 20405 for i := range v { 20406 i := i 20407 fc := &graphql.FieldContext{ 20408 Index: &i, 20409 Result: &v[i], 20410 } 20411 ctx := graphql.WithFieldContext(ctx, fc) 20412 f := func(i int) { 20413 defer func() { 20414 if r := recover(); r != nil { 20415 ec.Error(ctx, ec.Recover(ctx, r)) 20416 ret = nil 20417 } 20418 }() 20419 if !isLen1 { 20420 defer wg.Done() 20421 } 20422 ret[i] = ec.marshalOOuterObject2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐOuterObject(ctx, sel, v[i]) 20423 } 20424 if isLen1 { 20425 f(i) 20426 } else { 20427 go f(i) 20428 } 20429 20430 } 20431 wg.Wait() 20432 20433 return ret 20434 } 20435 20436 func (ec *executionContext) marshalOOuterObject2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐOuterObject(ctx context.Context, sel ast.SelectionSet, v *OuterObject) graphql.Marshaler { 20437 if v == nil { 20438 return graphql.Null 20439 } 20440 return ec._OuterObject(ctx, sel, v) 20441 } 20442 20443 func (ec *executionContext) marshalOOverlappingFields2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐOverlappingFields(ctx context.Context, sel ast.SelectionSet, v *OverlappingFields) graphql.Marshaler { 20444 if v == nil { 20445 return graphql.Null 20446 } 20447 return ec._OverlappingFields(ctx, sel, v) 20448 } 20449 20450 func (ec *executionContext) marshalOPanics2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPanics(ctx context.Context, sel ast.SelectionSet, v *Panics) graphql.Marshaler { 20451 if v == nil { 20452 return graphql.Null 20453 } 20454 return ec._Panics(ctx, sel, v) 20455 } 20456 20457 func (ec *executionContext) marshalOPet2ᚕᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPetᚄ(ctx context.Context, sel ast.SelectionSet, v []*Pet) graphql.Marshaler { 20458 if v == nil { 20459 return graphql.Null 20460 } 20461 ret := make(graphql.Array, len(v)) 20462 var wg sync.WaitGroup 20463 isLen1 := len(v) == 1 20464 if !isLen1 { 20465 wg.Add(len(v)) 20466 } 20467 for i := range v { 20468 i := i 20469 fc := &graphql.FieldContext{ 20470 Index: &i, 20471 Result: &v[i], 20472 } 20473 ctx := graphql.WithFieldContext(ctx, fc) 20474 f := func(i int) { 20475 defer func() { 20476 if r := recover(); r != nil { 20477 ec.Error(ctx, ec.Recover(ctx, r)) 20478 ret = nil 20479 } 20480 }() 20481 if !isLen1 { 20482 defer wg.Done() 20483 } 20484 ret[i] = ec.marshalNPet2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPet(ctx, sel, v[i]) 20485 } 20486 if isLen1 { 20487 f(i) 20488 } else { 20489 go f(i) 20490 } 20491 20492 } 20493 wg.Wait() 20494 20495 for _, e := range ret { 20496 if e == graphql.Null { 20497 return graphql.Null 20498 } 20499 } 20500 20501 return ret 20502 } 20503 20504 func (ec *executionContext) marshalOPtrToPtrInner2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPtrToPtrInner(ctx context.Context, sel ast.SelectionSet, v *PtrToPtrInner) graphql.Marshaler { 20505 if v == nil { 20506 return graphql.Null 20507 } 20508 return ec._PtrToPtrInner(ctx, sel, v) 20509 } 20510 20511 func (ec *executionContext) marshalOPtrToPtrInner2ᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPtrToPtrInner(ctx context.Context, sel ast.SelectionSet, v **PtrToPtrInner) graphql.Marshaler { 20512 if v == nil { 20513 return graphql.Null 20514 } 20515 return ec.marshalOPtrToPtrInner2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPtrToPtrInner(ctx, sel, *v) 20516 } 20517 20518 func (ec *executionContext) marshalOPtrToPtrInner2ᚖᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPtrToPtrInner(ctx context.Context, sel ast.SelectionSet, v ***PtrToPtrInner) graphql.Marshaler { 20519 if v == nil { 20520 return graphql.Null 20521 } 20522 return ec.marshalOPtrToPtrInner2ᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPtrToPtrInner(ctx, sel, *v) 20523 } 20524 20525 func (ec *executionContext) marshalOPtrToPtrInner2ᚖᚖᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPtrToPtrInner(ctx context.Context, sel ast.SelectionSet, v ****PtrToPtrInner) graphql.Marshaler { 20526 if v == nil { 20527 return graphql.Null 20528 } 20529 return ec.marshalOPtrToPtrInner2ᚖᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPtrToPtrInner(ctx, sel, *v) 20530 } 20531 20532 func (ec *executionContext) marshalOPtrToPtrInner2ᚖᚖᚖᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPtrToPtrInner(ctx context.Context, sel ast.SelectionSet, v *****PtrToPtrInner) graphql.Marshaler { 20533 if v == nil { 20534 return graphql.Null 20535 } 20536 return ec.marshalOPtrToPtrInner2ᚖᚖᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPtrToPtrInner(ctx, sel, *v) 20537 } 20538 20539 func (ec *executionContext) marshalOPtrToPtrInner2ᚖᚖᚖᚖᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPtrToPtrInner(ctx context.Context, sel ast.SelectionSet, v ******PtrToPtrInner) graphql.Marshaler { 20540 if v == nil { 20541 return graphql.Null 20542 } 20543 return ec.marshalOPtrToPtrInner2ᚖᚖᚖᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPtrToPtrInner(ctx, sel, *v) 20544 } 20545 20546 func (ec *executionContext) marshalOPtrToPtrInner2ᚖᚖᚖᚖᚖᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPtrToPtrInner(ctx context.Context, sel ast.SelectionSet, v *******PtrToPtrInner) graphql.Marshaler { 20547 if v == nil { 20548 return graphql.Null 20549 } 20550 return ec.marshalOPtrToPtrInner2ᚖᚖᚖᚖᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐPtrToPtrInner(ctx, sel, *v) 20551 } 20552 20553 func (ec *executionContext) unmarshalORecursiveInputSlice2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐRecursiveInputSliceᚄ(ctx context.Context, v interface{}) ([]RecursiveInputSlice, error) { 20554 if v == nil { 20555 return nil, nil 20556 } 20557 var vSlice []interface{} 20558 if v != nil { 20559 vSlice = graphql.CoerceList(v) 20560 } 20561 var err error 20562 res := make([]RecursiveInputSlice, len(vSlice)) 20563 for i := range vSlice { 20564 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithIndex(i)) 20565 res[i], err = ec.unmarshalNRecursiveInputSlice2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐRecursiveInputSlice(ctx, vSlice[i]) 20566 if err != nil { 20567 return nil, err 20568 } 20569 } 20570 return res, nil 20571 } 20572 20573 func (ec *executionContext) unmarshalORecursiveInputSlice2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐRecursiveInputSlice(ctx context.Context, v interface{}) (*RecursiveInputSlice, error) { 20574 if v == nil { 20575 return nil, nil 20576 } 20577 res, err := ec.unmarshalInputRecursiveInputSlice(ctx, v) 20578 return &res, graphql.ErrorOnPath(ctx, err) 20579 } 20580 20581 func (ec *executionContext) marshalOShape2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐShape(ctx context.Context, sel ast.SelectionSet, v Shape) graphql.Marshaler { 20582 if v == nil { 20583 return graphql.Null 20584 } 20585 return ec._Shape(ctx, sel, v) 20586 } 20587 20588 func (ec *executionContext) marshalOShape2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐShape(ctx context.Context, sel ast.SelectionSet, v []Shape) graphql.Marshaler { 20589 if v == nil { 20590 return graphql.Null 20591 } 20592 ret := make(graphql.Array, len(v)) 20593 var wg sync.WaitGroup 20594 isLen1 := len(v) == 1 20595 if !isLen1 { 20596 wg.Add(len(v)) 20597 } 20598 for i := range v { 20599 i := i 20600 fc := &graphql.FieldContext{ 20601 Index: &i, 20602 Result: &v[i], 20603 } 20604 ctx := graphql.WithFieldContext(ctx, fc) 20605 f := func(i int) { 20606 defer func() { 20607 if r := recover(); r != nil { 20608 ec.Error(ctx, ec.Recover(ctx, r)) 20609 ret = nil 20610 } 20611 }() 20612 if !isLen1 { 20613 defer wg.Done() 20614 } 20615 ret[i] = ec.marshalOShape2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐShape(ctx, sel, v[i]) 20616 } 20617 if isLen1 { 20618 f(i) 20619 } else { 20620 go f(i) 20621 } 20622 20623 } 20624 wg.Wait() 20625 20626 return ret 20627 } 20628 20629 func (ec *executionContext) marshalOSlices2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐSlices(ctx context.Context, sel ast.SelectionSet, v *Slices) graphql.Marshaler { 20630 if v == nil { 20631 return graphql.Null 20632 } 20633 return ec._Slices(ctx, sel, v) 20634 } 20635 20636 func (ec *executionContext) unmarshalOString2string(ctx context.Context, v interface{}) (string, error) { 20637 res, err := graphql.UnmarshalString(v) 20638 return res, graphql.ErrorOnPath(ctx, err) 20639 } 20640 20641 func (ec *executionContext) marshalOString2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler { 20642 res := graphql.MarshalString(v) 20643 return res 20644 } 20645 20646 func (ec *executionContext) unmarshalOString2ᚕstringᚄ(ctx context.Context, v interface{}) ([]string, error) { 20647 if v == nil { 20648 return nil, nil 20649 } 20650 var vSlice []interface{} 20651 if v != nil { 20652 vSlice = graphql.CoerceList(v) 20653 } 20654 var err error 20655 res := make([]string, len(vSlice)) 20656 for i := range vSlice { 20657 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithIndex(i)) 20658 res[i], err = ec.unmarshalNString2string(ctx, vSlice[i]) 20659 if err != nil { 20660 return nil, err 20661 } 20662 } 20663 return res, nil 20664 } 20665 20666 func (ec *executionContext) marshalOString2ᚕstringᚄ(ctx context.Context, sel ast.SelectionSet, v []string) graphql.Marshaler { 20667 if v == nil { 20668 return graphql.Null 20669 } 20670 ret := make(graphql.Array, len(v)) 20671 for i := range v { 20672 ret[i] = ec.marshalNString2string(ctx, sel, v[i]) 20673 } 20674 20675 for _, e := range ret { 20676 if e == graphql.Null { 20677 return graphql.Null 20678 } 20679 } 20680 20681 return ret 20682 } 20683 20684 func (ec *executionContext) unmarshalOString2ᚕᚖstring(ctx context.Context, v interface{}) ([]*string, error) { 20685 if v == nil { 20686 return nil, nil 20687 } 20688 var vSlice []interface{} 20689 if v != nil { 20690 vSlice = graphql.CoerceList(v) 20691 } 20692 var err error 20693 res := make([]*string, len(vSlice)) 20694 for i := range vSlice { 20695 ctx := graphql.WithPathContext(ctx, graphql.NewPathWithIndex(i)) 20696 res[i], err = ec.unmarshalOString2ᚖstring(ctx, vSlice[i]) 20697 if err != nil { 20698 return nil, err 20699 } 20700 } 20701 return res, nil 20702 } 20703 20704 func (ec *executionContext) marshalOString2ᚕᚖstring(ctx context.Context, sel ast.SelectionSet, v []*string) graphql.Marshaler { 20705 if v == nil { 20706 return graphql.Null 20707 } 20708 ret := make(graphql.Array, len(v)) 20709 for i := range v { 20710 ret[i] = ec.marshalOString2ᚖstring(ctx, sel, v[i]) 20711 } 20712 20713 return ret 20714 } 20715 20716 func (ec *executionContext) unmarshalOString2ᚖstring(ctx context.Context, v interface{}) (*string, error) { 20717 if v == nil { 20718 return nil, nil 20719 } 20720 res, err := graphql.UnmarshalString(v) 20721 return &res, graphql.ErrorOnPath(ctx, err) 20722 } 20723 20724 func (ec *executionContext) marshalOString2ᚖstring(ctx context.Context, sel ast.SelectionSet, v *string) graphql.Marshaler { 20725 if v == nil { 20726 return graphql.Null 20727 } 20728 res := graphql.MarshalString(*v) 20729 return res 20730 } 20731 20732 func (ec *executionContext) unmarshalOString2ᚖᚕstringᚄ(ctx context.Context, v interface{}) (*[]string, error) { 20733 if v == nil { 20734 return nil, nil 20735 } 20736 res, err := ec.unmarshalOString2ᚕstringᚄ(ctx, v) 20737 return &res, graphql.ErrorOnPath(ctx, err) 20738 } 20739 20740 func (ec *executionContext) marshalOString2ᚖᚕstringᚄ(ctx context.Context, sel ast.SelectionSet, v *[]string) graphql.Marshaler { 20741 return ec.marshalOString2ᚕstringᚄ(ctx, sel, *v) 20742 } 20743 20744 func (ec *executionContext) marshalOTestUnion2githubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐTestUnion(ctx context.Context, sel ast.SelectionSet, v TestUnion) graphql.Marshaler { 20745 if v == nil { 20746 return graphql.Null 20747 } 20748 return ec._TestUnion(ctx, sel, v) 20749 } 20750 20751 func (ec *executionContext) unmarshalOThirdParty2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐThirdParty(ctx context.Context, v interface{}) (*ThirdParty, error) { 20752 if v == nil { 20753 return nil, nil 20754 } 20755 res, err := UnmarshalThirdParty(v) 20756 return &res, graphql.ErrorOnPath(ctx, err) 20757 } 20758 20759 func (ec *executionContext) marshalOThirdParty2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐThirdParty(ctx context.Context, sel ast.SelectionSet, v *ThirdParty) graphql.Marshaler { 20760 if v == nil { 20761 return graphql.Null 20762 } 20763 res := MarshalThirdParty(*v) 20764 return res 20765 } 20766 20767 func (ec *executionContext) unmarshalOTime2ᚖtimeᚐTime(ctx context.Context, v interface{}) (*time.Time, error) { 20768 if v == nil { 20769 return nil, nil 20770 } 20771 res, err := graphql.UnmarshalTime(v) 20772 return &res, graphql.ErrorOnPath(ctx, err) 20773 } 20774 20775 func (ec *executionContext) marshalOTime2ᚖtimeᚐTime(ctx context.Context, sel ast.SelectionSet, v *time.Time) graphql.Marshaler { 20776 if v == nil { 20777 return graphql.Null 20778 } 20779 res := graphql.MarshalTime(*v) 20780 return res 20781 } 20782 20783 func (ec *executionContext) unmarshalOUpdatePtrToPtrInner2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUpdatePtrToPtrInner(ctx context.Context, v interface{}) (*UpdatePtrToPtrInner, error) { 20784 if v == nil { 20785 return nil, nil 20786 } 20787 res, err := ec.unmarshalInputUpdatePtrToPtrInner(ctx, v) 20788 return &res, graphql.ErrorOnPath(ctx, err) 20789 } 20790 20791 func (ec *executionContext) unmarshalOUpdatePtrToPtrInner2ᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUpdatePtrToPtrInner(ctx context.Context, v interface{}) (**UpdatePtrToPtrInner, error) { 20792 var pres *UpdatePtrToPtrInner 20793 if v != nil { 20794 res, err := ec.unmarshalOUpdatePtrToPtrInner2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUpdatePtrToPtrInner(ctx, v) 20795 if err != nil { 20796 return nil, graphql.ErrorOnPath(ctx, err) 20797 } 20798 pres = res 20799 } 20800 return &pres, nil 20801 } 20802 20803 func (ec *executionContext) unmarshalOUpdatePtrToPtrInner2ᚖᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUpdatePtrToPtrInner(ctx context.Context, v interface{}) (***UpdatePtrToPtrInner, error) { 20804 var pres **UpdatePtrToPtrInner 20805 if v != nil { 20806 res, err := ec.unmarshalOUpdatePtrToPtrInner2ᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUpdatePtrToPtrInner(ctx, v) 20807 if err != nil { 20808 return nil, graphql.ErrorOnPath(ctx, err) 20809 } 20810 pres = res 20811 } 20812 return &pres, nil 20813 } 20814 20815 func (ec *executionContext) unmarshalOUpdatePtrToPtrInner2ᚖᚖᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUpdatePtrToPtrInner(ctx context.Context, v interface{}) (****UpdatePtrToPtrInner, error) { 20816 var pres ***UpdatePtrToPtrInner 20817 if v != nil { 20818 res, err := ec.unmarshalOUpdatePtrToPtrInner2ᚖᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUpdatePtrToPtrInner(ctx, v) 20819 if err != nil { 20820 return nil, graphql.ErrorOnPath(ctx, err) 20821 } 20822 pres = res 20823 } 20824 return &pres, nil 20825 } 20826 20827 func (ec *executionContext) unmarshalOUpdatePtrToPtrInner2ᚖᚖᚖᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUpdatePtrToPtrInner(ctx context.Context, v interface{}) (*****UpdatePtrToPtrInner, error) { 20828 var pres ****UpdatePtrToPtrInner 20829 if v != nil { 20830 res, err := ec.unmarshalOUpdatePtrToPtrInner2ᚖᚖᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUpdatePtrToPtrInner(ctx, v) 20831 if err != nil { 20832 return nil, graphql.ErrorOnPath(ctx, err) 20833 } 20834 pres = res 20835 } 20836 return &pres, nil 20837 } 20838 20839 func (ec *executionContext) unmarshalOUpdatePtrToPtrInner2ᚖᚖᚖᚖᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUpdatePtrToPtrInner(ctx context.Context, v interface{}) (******UpdatePtrToPtrInner, error) { 20840 var pres *****UpdatePtrToPtrInner 20841 if v != nil { 20842 res, err := ec.unmarshalOUpdatePtrToPtrInner2ᚖᚖᚖᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUpdatePtrToPtrInner(ctx, v) 20843 if err != nil { 20844 return nil, graphql.ErrorOnPath(ctx, err) 20845 } 20846 pres = res 20847 } 20848 return &pres, nil 20849 } 20850 20851 func (ec *executionContext) unmarshalOUpdatePtrToPtrInner2ᚖᚖᚖᚖᚖᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUpdatePtrToPtrInner(ctx context.Context, v interface{}) (*******UpdatePtrToPtrInner, error) { 20852 var pres ******UpdatePtrToPtrInner 20853 if v != nil { 20854 res, err := ec.unmarshalOUpdatePtrToPtrInner2ᚖᚖᚖᚖᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUpdatePtrToPtrInner(ctx, v) 20855 if err != nil { 20856 return nil, graphql.ErrorOnPath(ctx, err) 20857 } 20858 pres = res 20859 } 20860 return &pres, nil 20861 } 20862 20863 func (ec *executionContext) unmarshalOUpdatePtrToPtrInner2ᚖᚖᚖᚖᚖᚖᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUpdatePtrToPtrInner(ctx context.Context, v interface{}) (********UpdatePtrToPtrInner, error) { 20864 var pres *******UpdatePtrToPtrInner 20865 if v != nil { 20866 res, err := ec.unmarshalOUpdatePtrToPtrInner2ᚖᚖᚖᚖᚖᚖᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐUpdatePtrToPtrInner(ctx, v) 20867 if err != nil { 20868 return nil, graphql.ErrorOnPath(ctx, err) 20869 } 20870 pres = res 20871 } 20872 return &pres, nil 20873 } 20874 20875 func (ec *executionContext) marshalOVOkCaseNil2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐVOkCaseNil(ctx context.Context, sel ast.SelectionSet, v *VOkCaseNil) graphql.Marshaler { 20876 if v == nil { 20877 return graphql.Null 20878 } 20879 return ec._VOkCaseNil(ctx, sel, v) 20880 } 20881 20882 func (ec *executionContext) marshalOVOkCaseValue2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐVOkCaseValue(ctx context.Context, sel ast.SelectionSet, v *VOkCaseValue) graphql.Marshaler { 20883 if v == nil { 20884 return graphql.Null 20885 } 20886 return ec._VOkCaseValue(ctx, sel, v) 20887 } 20888 20889 func (ec *executionContext) unmarshalOValidInput2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐValidInput(ctx context.Context, v interface{}) (*ValidInput, error) { 20890 if v == nil { 20891 return nil, nil 20892 } 20893 res, err := ec.unmarshalInputValidInput(ctx, v) 20894 return &res, graphql.ErrorOnPath(ctx, err) 20895 } 20896 20897 func (ec *executionContext) marshalOValidType2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐValidType(ctx context.Context, sel ast.SelectionSet, v *ValidType) graphql.Marshaler { 20898 if v == nil { 20899 return graphql.Null 20900 } 20901 return ec._ValidType(ctx, sel, v) 20902 } 20903 20904 func (ec *executionContext) marshalOVariadicModel2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚐVariadicModel(ctx context.Context, sel ast.SelectionSet, v *VariadicModel) graphql.Marshaler { 20905 if v == nil { 20906 return graphql.Null 20907 } 20908 return ec._VariadicModel(ctx, sel, v) 20909 } 20910 20911 func (ec *executionContext) unmarshalOWrappedScalar2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚋotherpkgᚐScalar(ctx context.Context, v interface{}) (*otherpkg.Scalar, error) { 20912 if v == nil { 20913 return nil, nil 20914 } 20915 tmp, err := graphql.UnmarshalString(v) 20916 res := otherpkg.Scalar(tmp) 20917 return &res, graphql.ErrorOnPath(ctx, err) 20918 } 20919 20920 func (ec *executionContext) marshalOWrappedScalar2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋcodegenᚋtestserverᚋsinglefileᚋotherpkgᚐScalar(ctx context.Context, sel ast.SelectionSet, v *otherpkg.Scalar) graphql.Marshaler { 20921 if v == nil { 20922 return graphql.Null 20923 } 20924 res := graphql.MarshalString(string(*v)) 20925 return res 20926 } 20927 20928 func (ec *executionContext) marshalO__EnumValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValueᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.EnumValue) graphql.Marshaler { 20929 if v == nil { 20930 return graphql.Null 20931 } 20932 ret := make(graphql.Array, len(v)) 20933 var wg sync.WaitGroup 20934 isLen1 := len(v) == 1 20935 if !isLen1 { 20936 wg.Add(len(v)) 20937 } 20938 for i := range v { 20939 i := i 20940 fc := &graphql.FieldContext{ 20941 Index: &i, 20942 Result: &v[i], 20943 } 20944 ctx := graphql.WithFieldContext(ctx, fc) 20945 f := func(i int) { 20946 defer func() { 20947 if r := recover(); r != nil { 20948 ec.Error(ctx, ec.Recover(ctx, r)) 20949 ret = nil 20950 } 20951 }() 20952 if !isLen1 { 20953 defer wg.Done() 20954 } 20955 ret[i] = ec.marshalN__EnumValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValue(ctx, sel, v[i]) 20956 } 20957 if isLen1 { 20958 f(i) 20959 } else { 20960 go f(i) 20961 } 20962 20963 } 20964 wg.Wait() 20965 20966 for _, e := range ret { 20967 if e == graphql.Null { 20968 return graphql.Null 20969 } 20970 } 20971 20972 return ret 20973 } 20974 20975 func (ec *executionContext) marshalO__Field2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐFieldᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.Field) graphql.Marshaler { 20976 if v == nil { 20977 return graphql.Null 20978 } 20979 ret := make(graphql.Array, len(v)) 20980 var wg sync.WaitGroup 20981 isLen1 := len(v) == 1 20982 if !isLen1 { 20983 wg.Add(len(v)) 20984 } 20985 for i := range v { 20986 i := i 20987 fc := &graphql.FieldContext{ 20988 Index: &i, 20989 Result: &v[i], 20990 } 20991 ctx := graphql.WithFieldContext(ctx, fc) 20992 f := func(i int) { 20993 defer func() { 20994 if r := recover(); r != nil { 20995 ec.Error(ctx, ec.Recover(ctx, r)) 20996 ret = nil 20997 } 20998 }() 20999 if !isLen1 { 21000 defer wg.Done() 21001 } 21002 ret[i] = ec.marshalN__Field2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐField(ctx, sel, v[i]) 21003 } 21004 if isLen1 { 21005 f(i) 21006 } else { 21007 go f(i) 21008 } 21009 21010 } 21011 wg.Wait() 21012 21013 for _, e := range ret { 21014 if e == graphql.Null { 21015 return graphql.Null 21016 } 21017 } 21018 21019 return ret 21020 } 21021 21022 func (ec *executionContext) marshalO__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.InputValue) graphql.Marshaler { 21023 if v == nil { 21024 return graphql.Null 21025 } 21026 ret := make(graphql.Array, len(v)) 21027 var wg sync.WaitGroup 21028 isLen1 := len(v) == 1 21029 if !isLen1 { 21030 wg.Add(len(v)) 21031 } 21032 for i := range v { 21033 i := i 21034 fc := &graphql.FieldContext{ 21035 Index: &i, 21036 Result: &v[i], 21037 } 21038 ctx := graphql.WithFieldContext(ctx, fc) 21039 f := func(i int) { 21040 defer func() { 21041 if r := recover(); r != nil { 21042 ec.Error(ctx, ec.Recover(ctx, r)) 21043 ret = nil 21044 } 21045 }() 21046 if !isLen1 { 21047 defer wg.Done() 21048 } 21049 ret[i] = ec.marshalN__InputValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx, sel, v[i]) 21050 } 21051 if isLen1 { 21052 f(i) 21053 } else { 21054 go f(i) 21055 } 21056 21057 } 21058 wg.Wait() 21059 21060 for _, e := range ret { 21061 if e == graphql.Null { 21062 return graphql.Null 21063 } 21064 } 21065 21066 return ret 21067 } 21068 21069 func (ec *executionContext) marshalO__Schema2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐSchema(ctx context.Context, sel ast.SelectionSet, v *introspection.Schema) graphql.Marshaler { 21070 if v == nil { 21071 return graphql.Null 21072 } 21073 return ec.___Schema(ctx, sel, v) 21074 } 21075 21076 func (ec *executionContext) marshalO__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.Type) graphql.Marshaler { 21077 if v == nil { 21078 return graphql.Null 21079 } 21080 ret := make(graphql.Array, len(v)) 21081 var wg sync.WaitGroup 21082 isLen1 := len(v) == 1 21083 if !isLen1 { 21084 wg.Add(len(v)) 21085 } 21086 for i := range v { 21087 i := i 21088 fc := &graphql.FieldContext{ 21089 Index: &i, 21090 Result: &v[i], 21091 } 21092 ctx := graphql.WithFieldContext(ctx, fc) 21093 f := func(i int) { 21094 defer func() { 21095 if r := recover(); r != nil { 21096 ec.Error(ctx, ec.Recover(ctx, r)) 21097 ret = nil 21098 } 21099 }() 21100 if !isLen1 { 21101 defer wg.Done() 21102 } 21103 ret[i] = ec.marshalN__Type2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, sel, v[i]) 21104 } 21105 if isLen1 { 21106 f(i) 21107 } else { 21108 go f(i) 21109 } 21110 21111 } 21112 wg.Wait() 21113 21114 for _, e := range ret { 21115 if e == graphql.Null { 21116 return graphql.Null 21117 } 21118 } 21119 21120 return ret 21121 } 21122 21123 func (ec *executionContext) marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v *introspection.Type) graphql.Marshaler { 21124 if v == nil { 21125 return graphql.Null 21126 } 21127 return ec.___Type(ctx, sel, v) 21128 } 21129 21130 // endregion ***************************** type.gotpl *****************************