-
Notifications
You must be signed in to change notification settings - Fork 428
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
199 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
schema{ | ||
query: UserQuery, | ||
mutation: UserMutation | ||
} | ||
|
||
directive @protected on FIELD_DEFINITION | OBJECT | INTERFACE | ||
|
||
type UserQuery{ | ||
field: String | ||
protectedField: String @protected | ||
interface: Interface | ||
union: UnionT | ||
obj: Object | ||
protectedObj: ProtectedObject | ||
protInterface: ProtectedInterface | ||
objProtInterface: ObjectImplProtInt | ||
} | ||
|
||
type UserMutation @protected{ | ||
field: String | ||
} | ||
|
||
interface Interface{ | ||
name: String | ||
otherName: String | ||
protectedName: String @protected | ||
} | ||
|
||
interface ProtectedInterface @protected{ | ||
name: String | ||
} | ||
|
||
type Object implements Interface{ | ||
name: String | ||
otherName: String @protected | ||
protectedName: String | ||
protectedField: String @protected | ||
field: String | ||
} | ||
|
||
type ProtectedObject implements Interface @protected{ | ||
name: String | ||
otherName: String | ||
protectedName: String | ||
type: String | ||
} | ||
|
||
type ObjectImplProtInt implements ProtectedInterface{ | ||
name: String | ||
field: String | ||
} | ||
|
||
type O1{ | ||
field1: Int | ||
field1Protected: Int @protected | ||
} | ||
|
||
type O2 @protected{ | ||
field2: Int | ||
} | ||
|
||
union UnionT = O1 | O2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters