*/
public String generate(IProgressMonitor monitor, final Vector<IClasspathEntry>
dependencyClasspaths, String errorMessage) throws CoreException {
String generatedTemplateContent = new String();
try {
JETEmitter emitter = new JETEmitter(getTemplateFilePath(),
getClass().getClassLoader()) {
/* (non-Javadoc)
* @see org.eclipse.emf.codegen.jet.JETEmitter#getClasspathEntries()
*/
@Override
public List<IClasspathEntry> getClasspathEntries() {
List<IClasspathEntry> entries = super.getClasspathEntries();
entries.addAll(dependencyClasspaths);
return entries;
}
};
emitter.setProjectName(projectName);
emitter.addVariable("Google Data Plugin", Activator.PLUGIN_ID);
generatedTemplateContent = emitter.generate(monitor,
new Object[]{templateConfig, errorMessage});
} catch(JETException e) {
e.printStackTrace();
throw DiagnosticException.toCoreException(e);
}