Class QaCorpusLoader
java.lang.Object
org.ek9lang.compiler.fuzz.QaCorpusLoader
Loads Q&A example sources and file-targeted mutation metadata from the classpath.
Used by
FuzzRunner to feed Strand 3 (Q&A examples) and Strand 4 (targeted mutations).-
Nested Class Summary
Nested ClassesModifier and TypeClassDescription(package private) static final recordA Q&A file paired with its original source and the typical-error mutations to apply. -
Method Summary
Modifier and TypeMethodDescription(package private) static List<QaCorpusLoader.FileTargetedMutations> loadFileTargetedMutations(List<NamedSource> qaExampleSources) Load targeted mutations by joining Q&A typicalErrors with raw source strings.(package private) static List<NamedSource> Load all qaExample sources from the manifest as raw NamedSources.(package private) static StringloadResourceAsString(String resourcePath) Load a classpath resource as a UTF-8 string, returning null if absent or unreadable.
-
Method Details
-
loadQaExampleSources
Load all qaExample sources from the manifest as raw NamedSources. These are loaded once at FuzzRunner construction and shared across all workers. -
loadResourceAsString
-
loadFileTargetedMutations
static List<QaCorpusLoader.FileTargetedMutations> loadFileTargetedMutations(List<NamedSource> qaExampleSources) Load targeted mutations by joining Q&A typicalErrors with raw source strings.
-