@@ -480,7 +480,9 @@ Scalar type extensions have the potential to be invalid if incorrectly defined.
480
480
481
481
ObjectTypeDefinition : Description? type Name ImplementsInterfaces? Directives[ Const] ? FieldsDefinition?
482
482
483
- ImplementsInterfaces : Description? implements NamedType+
483
+ ImplementsInterfaces :
484
+ - implements ` & ` ? NamedType
485
+ - ImplementsInterfaces & NamedType
484
486
485
487
FieldsDefinition : { FieldDefinition+ }
486
488
@@ -875,18 +877,26 @@ For example, an interface `NamedEntity` may describe a required field and types
875
877
such as `Person ` or `Business ` may then implement this interface to guarantee
876
878
this field will always exist .
877
879
880
+ Types may also implement multiple interfaces . For example , `Business ` implements
881
+ both the `NamedEntity ` and `ValuedEntity ` interfaces in the example below .
882
+
878
883
```graphql example
879
884
interface NamedEntity {
880
885
name : String
881
886
}
882
887
888
+ interface ValuedEntity {
889
+ value : Int
890
+ }
891
+
883
892
type Person implements NamedEntity {
884
893
name : String
885
894
age : Int
886
895
}
887
896
888
- type Business implements NamedEntity {
897
+ type Business implements NamedEntity & ValuedEntity {
889
898
name : String
899
+ value : Int
890
900
employeeCount : Int
891
901
}
892
902
```
@@ -1023,12 +1033,10 @@ Interface type extensions have the potential to be invalid if incorrectly define
1023
1033
1024
1034
## Unions
1025
1035
1026
- UnionTypeDefinition : Description ? union Name Directives [Const ]? MemberTypesDefinition ?
1027
-
1028
- MemberTypesDefinition : = MemberTypes
1036
+ UnionTypeDefinition : Description ? union Name Directives [Const ]? UnionMemberTypes ?
1029
1037
1030
- MemberTypes :
1031
- - `|`? NamedType
1038
+ UnionMemberTypes :
1039
+ - = `|`? NamedType
1032
1040
- MemberTypes | NamedType
1033
1041
1034
1042
GraphQL Unions represent an object that could be one of a list of GraphQL
@@ -1124,7 +1132,7 @@ Union types have the potential to be invalid if incorrectly defined.
1124
1132
### Union Extensions
1125
1133
1126
1134
UnionTypeExtension :
1127
- - extend union Name Directives[ Const] ? MemberTypesDefinition
1135
+ - extend union Name Directives[ Const] ? UnionMemberTypes
1128
1136
- extend union Name Directives[ Const]
1129
1137
1130
1138
Union type extensions are used to represent a union type which has been
0 commit comments