Skip to content

Commit 783d64d

Browse files
committed
Fixes #213
1 parent fabc0ce commit 783d64d

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/main/kotlin/com/coxautodev/graphql/tools/SchemaParserBuilder.kt

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,13 @@ class SchemaParserBuilder constructor(private val dictionary: SchemaParserDictio
8989
this.scalars.addAll(scalars)
9090
}
9191

92+
/**
93+
* Add scalars to the parser's dictionary.
94+
*/
95+
fun scalars(scalars: List<GraphQLScalarType>) = this.apply {
96+
this.scalars.addAll(scalars)
97+
}
98+
9299
fun directive(name: String, directive: SchemaDirectiveWiring) = this.apply {
93100
this.runtimeWiringBuilder.directive(name, directive)
94101
}

0 commit comments

Comments
 (0)