@@ -52,25 +52,25 @@ query foo(
52
52
nullableIntIdGivenNull: nullableIntId(id: $nullIntId)
53
53
optionalIntId(id: $intId)
54
54
optionalIntIdGivenNothing: optionalIntId
55
- intIdList(id : [$intId])
56
- nullableIntIdList(id : [$intId, $nullIntId])
57
- optionalIntIdList(id : [$intId])
55
+ intIdList(ids : [$intId])
56
+ nullableIntIdList(ids : [$intId, $nullIntId])
57
+ optionalIntIdList(ids : [$intId])
58
58
stringId(id: $stringId)
59
59
nullableStringId(id: $stringId)
60
60
nullableStringIdGivenNull: nullableStringId(id: $nullStringId)
61
61
optionalStringId(id: $stringId)
62
62
optionalStringIdGivenNothing: optionalStringId
63
- stringIdList(id : [$stringId])
64
- nullableStringIdList(id : [$stringId, $nullStringId])
65
- optionalStringIdList(id : [$stringId])
63
+ stringIdList(ids : [$stringId])
64
+ nullableStringIdList(ids : [$stringId, $nullStringId])
65
+ optionalStringIdList(ids : [$stringId])
66
66
guidId(id: $guidId)
67
67
nullableGuidId(id: $guidId)
68
68
nullableGuidIdGivenNull: nullableGuidId(id: $nullGuidId)
69
69
optionalGuidId(id: $guidId)
70
70
optionalGuidIdGivenNothing: optionalGuidId
71
- guidIdList(id : [$guidId $guidId])
72
- nullableGuidIdList(id : [$guidId $nullGuidId $guidId])
73
- optionalGuidIdList(id : [$guidId $guidId])
71
+ guidIdList(ids : [$guidId $guidId])
72
+ nullableGuidIdList(ids : [$guidId $nullGuidId $guidId])
73
+ optionalGuidIdList(ids : [$guidId $guidId])
74
74
customId(id: $customId)
75
75
nullableCustomId(id: $customId)
76
76
nullableCustomIdGivenNull: nullableCustomId(id: $nullCustomId)
@@ -107,7 +107,7 @@ public async Task InterceptedId_On_Arguments()
107
107
OperationRequestBuilder . New ( )
108
108
. SetDocument ( @"query foo {
109
109
interceptedId(id: 1)
110
- interceptedIds(id : [1, 2])
110
+ interceptedIds(ids : [1, 2])
111
111
}" )
112
112
. Build ( ) ) ;
113
113
@@ -465,56 +465,53 @@ public async Task EnsureIdIsOnlyAppliedOnce()
465
465
[ SuppressMessage ( "Performance" , "CA1822:Mark members as static" ) ]
466
466
public class Query
467
467
{
468
- public string IntId ( [ ID ] int id ) => id . ToString ( ) ;
469
- public string IntIdList ( [ ID ] int [ ] id ) =>
470
- string . Join ( ", " , id . Select ( t => t . ToString ( ) ) ) ;
468
+ public int IntId ( [ ID ] int id ) => id ;
471
469
472
- public string NullableIntId ( [ ID ] int ? id ) => id ? . ToString ( ) ?? "null" ;
473
- public string NullableIntIdList ( [ ID ] int ? [ ] id ) =>
474
- string . Join ( ", " , id . Select ( t => t ? . ToString ( ) ?? "null" ) ) ;
470
+ public int [ ] IntIdList ( [ ID ] int [ ] ids ) => ids ;
475
471
476
- public string OptionalIntId ( [ DefaultValue ( "UXVlcnk6MA==" ) ] [ ID ] Optional < int > id ) =>
477
- id . HasValue ? id . Value . ToString ( ) : "NO VALUE" ;
478
- public string OptionalIntIdList ( [ DefaultValue ( new int [ ] { } ) ] [ ID ] Optional < int [ ] > id ) =>
479
- id . HasValue ? string . Join ( ", " , id . Value . Select ( t => t . ToString ( ) ) ) : "NO VALUE" ;
472
+ public int ? NullableIntId ( [ ID ] int ? id ) => id ;
473
+
474
+ public int ? [ ] NullableIntIdList ( [ ID ] int ? [ ] ids ) => ids ;
475
+
476
+ public int ? OptionalIntId ( [ DefaultValue ( "UXVlcnk6MA==" ) ] [ ID ] Optional < int > id )
477
+ => id . HasValue ? id . Value : null ;
478
+
479
+ public int [ ] ? OptionalIntIdList ( [ DefaultValue ( new int [ ] { } ) ] [ ID ] Optional < int [ ] > ids )
480
+ => ids . HasValue ? ids . Value : null ;
480
481
481
482
public string StringId ( [ ID ] string id ) => id ;
482
- public string StringIdList ( [ ID ] string [ ] id ) =>
483
- string . Join ( ", " , id . Select ( t => t . ToString ( ) ) ) ;
484
-
485
- public string NullableStringId ( [ ID ] string ? id ) => id ?? "null" ;
486
- public string NullableStringIdList ( [ ID ] string ? [ ] id ) =>
487
- string . Join ( ", " , id . Select ( t => t ? . ToString ( ) ?? "null" ) ) ;
488
-
489
- public string OptionalStringId (
490
- [ DefaultValue ( "UXVlcnk6" ) ] [ ID ] Optional < string > id ) =>
491
- id . HasValue ? id . Value : "NO VALUE" ;
492
- public string OptionalStringIdList (
493
- [ DefaultValue ( new string [ ] { } ) ] [ ID ] Optional < string [ ] > id ) =>
494
- id . HasValue ? string . Join ( ", " , id . Value ) : "NO VALUE" ;
495
-
496
- public string GuidId ( [ ID ] Guid id ) => id . ToString ( ) ;
497
- public string GuidIdList ( [ ID ] IReadOnlyList < Guid > id ) =>
498
- string . Join ( ", " , id . Select ( t => t . ToString ( ) ) ) ;
499
-
500
- public string NullableGuidId ( [ ID ] Guid ? id ) => id ? . ToString ( ) ?? "null" ;
501
- public string NullableGuidIdList ( [ ID ] IReadOnlyList < Guid ? > id ) =>
502
- string . Join ( ", " , id . Select ( t => t ? . ToString ( ) ?? "null" ) ) ;
503
-
504
- public string OptionalGuidId (
505
- [ DefaultValue ( "UXVlcnk6AAAAAAAAAAAAAAAAAAAAAA==" ) ] [ ID ] Optional < Guid > id ) =>
506
- id . HasValue ? id . Value . ToString ( ) : "NO VALUE" ;
507
- public string OptionalGuidIdList (
508
- [ DefaultValue ( new object [ ] { } ) ] [ ID ] Optional < Guid [ ] > id ) =>
509
- id . HasValue ? string . Join ( ", " , id . Value . Select ( t => t . ToString ( ) ) ) : "NO VALUE" ;
510
-
511
- public string InterceptedId ( [ InterceptedID ( "Query" ) ] [ ID ] int id ) => id . ToString ( ) ;
512
-
513
- public string InterceptedIds ( [ InterceptedID ( "Query" ) ] [ ID ] int [ ] id ) =>
514
- string . Join ( ", " , id . Select ( t => t . ToString ( ) ) ) ;
515
-
516
- public string CustomId ( [ ID ] StronglyTypedId id ) =>
517
- id . ToString ( ) ;
483
+
484
+ public string [ ] StringIdList ( [ ID ] string [ ] ids ) => ids ;
485
+
486
+ public string ? NullableStringId ( [ ID ] string ? id ) => id ;
487
+
488
+ public string ? [ ] NullableStringIdList ( [ ID ] string ? [ ] ids ) => ids ;
489
+
490
+ public string ? OptionalStringId ( [ DefaultValue ( "UXVlcnk6" ) ] [ ID ] Optional < string > id )
491
+ => id . HasValue ? id . Value : null ;
492
+
493
+ public string [ ] ? OptionalStringIdList ( [ DefaultValue ( new string [ ] { } ) ] [ ID ] Optional < string [ ] > ids )
494
+ => ids . HasValue ? ids . Value : null ;
495
+
496
+ public Guid GuidId ( [ ID ] Guid id ) => id ;
497
+
498
+ public IReadOnlyList < Guid > GuidIdList ( [ ID ] IReadOnlyList < Guid > ids ) => ids ;
499
+
500
+ public Guid ? NullableGuidId ( [ ID ] Guid ? id ) => id ;
501
+
502
+ public IReadOnlyList < Guid ? > NullableGuidIdList ( [ ID ] IReadOnlyList < Guid ? > ids ) => ids ;
503
+
504
+ public Guid ? OptionalGuidId ( [ DefaultValue ( "UXVlcnk6AAAAAAAAAAAAAAAAAAAAAA==" ) ] [ ID ] Optional < Guid > id )
505
+ => id . HasValue ? id . Value : null ;
506
+
507
+ public Guid [ ] ? OptionalGuidIdList ( [ DefaultValue ( new object [ ] { } ) ] [ ID ] Optional < Guid [ ] > ids )
508
+ => ids . HasValue ? ids . Value : null ;
509
+
510
+ public int InterceptedId ( [ InterceptedID ( "Query" ) ] [ ID ] int id ) => id ;
511
+
512
+ public int [ ] InterceptedIds ( [ InterceptedID ( "Query" ) ] [ ID ] int [ ] ids ) => ids ;
513
+
514
+ public string CustomId ( [ ID ] StronglyTypedId id ) => id . ToString ( ) ;
518
515
519
516
public string NullableCustomId ( [ ID ] StronglyTypedId ? id ) =>
520
517
id ? . ToString ( ) ?? "null" ;
0 commit comments