class CompilationUnitGenerator extends Generator {

	protected CompilationUnitGenerator(SourceRoot sourceRoot) {
		super(sourceRoot);
	}

	@Override
	public void generate() throws Exception {<FILL_FUNCTION_BODY>}

	protected abstract void generateCompilationUnit(CompilationUnit compilationUnit);

}

		List<ParseResult<CompilationUnit>> parsedCus = sourceRoot.tryToParse();
		for (ParseResult<CompilationUnit> cu : parsedCus) {
			cu.ifSuccessful(this::generateCompilationUnit);
		}
	
<methods>public abstract void generate() throws java.lang.Exception<variables>protected final non-sealed com.github.javaparser.utils.SourceRoot sourceRoot