com.hadii.clarpse.compiler.CompilerFactory Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of clarpse Show documentation
Show all versions of clarpse Show documentation
Clarpse is a lightweight polyglot source code analysis tool.
package com.hadii.clarpse.compiler;
/**
* Factory to retrieve appropriate parsing tool for our projects.
*/
public class CompilerFactory {
public static final ClarpseCompiler getParsingTool(final String parseType) throws Exception {
switch (parseType.toLowerCase()) {
case "java":
return new ClarpseJavaCompiler();
case "javascript":
return new ClarpseJSCompiler();
case "go":
return new ClarpseGoCompiler();
default:
throw new Exception("Could not find parsing tool for: " + parseType);
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy