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