310 |
310 |
311 protected Context context; |
311 protected Context context; |
312 |
312 |
313 /** Construct a new compiler using a shared context. |
313 /** Construct a new compiler using a shared context. |
314 */ |
314 */ |
315 public JavaCompiler(final Context context) { |
315 public JavaCompiler(Context context) { |
316 this.context = context; |
316 this.context = context; |
317 context.put(compilerKey, this); |
317 context.put(compilerKey, this); |
318 |
318 |
319 // if fileManager not already set, register the JavacFileManager to be used |
319 // if fileManager not already set, register the JavacFileManager to be used |
320 if (context.get(JavaFileManager.class) == null) |
320 if (context.get(JavaFileManager.class) == null) |