if (pw != null) pw.close();
}
//Compiling the java code
try {
DotCompilationProblems problems = DotJdtCompiler.compileClass(javaFilePath, linkCode.getClassName(), buildFilePath);
//If java code compilation problems are found then a DotRuntime Exception is thrown with the compilation errors in it
if(problems.hasCompilationErrors()) {
throw new ChainLinkCodeCompilationException("A compilation error has ocurred when compiling your link code", problems);
}
} catch (FileNotFoundException e) {
throw new DotRuntimeException("Error ocurred trying to compile the link code." , e);
}