Examples of JETEmitter


Examples of org.eclipse.emf.codegen.jet.JETEmitter

   */
  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);
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.