public Class compileAndSave(String sourceCode) throws DynamicClassCompileException {
Forger<Object> forger;
try {
forger = forgerFactory.compile(sourceCode);
} catch (CompilationFailedException e) {
throw new DynamicClassCompileException(e.getMessage(),e);
}
String className = forger.getClazz().getCanonicalName();
DynamicClass dynamicClass = new DynamicClass();
dynamicClass.setClassName(className);
dynamicClass.setSourceCode(sourceCode);