Changeset 70 in default for v2/trunk/de.ugoe.cs.swe.bnftools.ebnf
- Timestamp:
- 05/28/14 09:25:14 (11 years ago)
- Location:
- v2/trunk/de.ugoe.cs.swe.bnftools.ebnf
- Files:
-
- 1 added
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
v2/trunk/de.ugoe.cs.swe.bnftools.ebnf/META-INF/MANIFEST.MF
r61 r70 19 19 org.eclipse.xtext.common.types 20 20 Import-Package: org.apache.log4j, 21 org.eclipse.core.resources, 22 org.eclipse.core.runtime;version="3.4.0", 21 23 org.eclipse.xtext.xbase.lib 22 24 Bundle-RequiredExecutionEnvironment: J2SE-1.5 -
v2/trunk/de.ugoe.cs.swe.bnftools.ebnf/src/de/ugoe/cs/swe/bnftools/generator/EbnfGenerator.xtend
r69 r70 22 22 import org.eclipse.xtext.generator.IFileSystemAccessExtension2 23 23 import org.eclipse.emf.common.util.URI; 24 24 import org.eclipse.xtext.generator.IFileSystemAccessExtension 25 import java.io.PrintWriter 25 26 /** 26 27 * Generates code from your model files on save. … … 31 32 //generation of the xsl-file 32 33 override void doGenerate(Resource resource, IFileSystemAccess fsa) { 34 var String workspacePath =WorkspaceResolver.getWorkspace(); 33 35 for (e : resource.allContents.toIterable.filter(EtsiBnf)) { 34 36 if (e.bnfEntry.size!=0) { … … 36 38 37 39 //generate pdf 38 // var uri = (fsa as IFileSystemAccessExtension2).getURI(e.name+".fo"); 39 // (fsa as IFileSystemAccessExtension2). 40 // 41 // System.out.println(uri.hasAbsolutePath()); 42 // System.out.println(uri.path.substring(0,uri.path.length-3)); 43 // System.out.println(uri.file); 40 var uri = (fsa as IFileSystemAccessExtension2).getURI(e.name+".fo"); 41 var String fullUri = workspacePath+uri.path.substring(10,uri.path.length); 42 System.out.println(workspacePath+uri.path.substring(10,uri.path.length)); 43 var File file = new File(fullUri); 44 System.out.println(file.exists); 44 45 // System.out.println(uri.toString()); 45 // var File file = new File(uri.path).absoluteFile; 46 47 46 48 // System.out.println(file.exists); 47 // var String aPath = file.absolutePath; 48 // 49 49 50 // foToPdf.createPdfFromFo(file,aPath.substring(0,aPath.length-3)); 50 51 } -
v2/trunk/de.ugoe.cs.swe.bnftools.ebnf/src/de/ugoe/cs/swe/bnftools/generator/foToPdf.java
r69 r70 22 22 public class foToPdf { 23 23 24 //public static void main(String args[]) throws IOException, FOPException,25 //TransformerException {26 // 27 //createfoFromPdf("test1","test1");28 //}24 public static void main(String args[]) throws IOException, FOPException, 25 TransformerException { 26 27 createfoFromPdf("test1","test1"); 28 } 29 29 30 30 public static void createPdfFromFo(String fileName) throws IOException, FOPException,
Note: See TracChangeset
for help on using the changeset viewer.