83 bw.append(contents); |
83 bw.append(contents); |
84 bw.close(); |
84 bw.close(); |
85 } |
85 } |
86 |
86 |
87 SimpleJavaFileObject asJFO(java.io.File dir) { |
87 SimpleJavaFileObject asJFO(java.io.File dir) { |
88 return new SimpleJavaFileObject(URI.create(dir.getAbsolutePath() + "/" + filename), JavaFileObject.Kind.SOURCE) { |
88 return new SimpleJavaFileObject(new java.io.File(dir, filename).toURI(), JavaFileObject.Kind.SOURCE) { |
89 @Override |
89 @Override |
90 public CharSequence getCharContent(boolean ignoreEncodingErrors) throws IOException { |
90 public CharSequence getCharContent(boolean ignoreEncodingErrors) throws IOException { |
91 return contents; |
91 return contents; |
92 } |
92 } |
93 }; |
93 }; |