Class GraphQLDocumentParser
java.lang.Object
io.github.besi97.graphql.codegen.parser.GraphQLDocumentParser
Provides methods for extended document generation
-
Method Summary
Modifier and TypeMethodDescriptionstatic graphql.parser.MultiSourceReadercreateMultiSourceReader(List<String> schemaPaths) static ExtendedDocumentgetDocumentFromIntrospectionResult(MappingConfig mappingConfig, String introspectionResult) Generate an extended document from introspection result filestatic ExtendedDocumentgetDocumentFromSchemas(MappingConfig mappingConfig, List<String> schemaPaths) Generate an extended document from schema files
-
Method Details
-
getDocumentFromSchemas
public static ExtendedDocument getDocumentFromSchemas(MappingConfig mappingConfig, List<String> schemaPaths) throws IOException Generate an extended document from schema files- Parameters:
mappingConfig- Global mapping configschemaPaths- Paths to GraphQL schema files- Returns:
- extended document definition
- Throws:
IOException- in case unable to read the file content
-
getDocumentFromIntrospectionResult
public static ExtendedDocument getDocumentFromIntrospectionResult(MappingConfig mappingConfig, String introspectionResult) throws IOException Generate an extended document from introspection result file- Parameters:
mappingConfig- Global mapping configintrospectionResult- Path to introspection result file- Returns:
- extended document definition
- Throws:
IOException- in case unable to read the file content
-
createMultiSourceReader
public static graphql.parser.MultiSourceReader createMultiSourceReader(List<String> schemaPaths) throws IOException - Throws:
IOException
-