this.context = builder.build(); this.parser = new Parser(context);
this.context = builder.build(); this.parser = new Parser(context);
ParsingContext.Builder builder = new ParsingContext.Builder(); builder.logger(logger); ParsingContext pc = builder.build(); parser = new Parser(pc);
ParsingContext parsingContext = new ParsingContext.Builder().logger(logger).executorService(getExecutorService()).build(); parser = new Parser(parsingContext);
ParsingContext parsingContext = new ParsingContext.Builder().logger(context.getLogger()).executorService(executorService).build(); Parser parser = new Parser(parsingContext); ReadableArchiveScannerAdapter scannerAdapter = new ReadableArchiveScannerAdapter(parser, context.getSource());
ParsingContext parsingContext = new ParsingContext.Builder().logger(context.getLogger()).executorService(executorService).build(); Parser parser = new Parser(parsingContext); ReadableArchiveScannerAdapter scannerAdapter = new ReadableArchiveScannerAdapter(parser, context.getSource());
@Override public void process(ReadableArchive archive, ApplicationClientDescriptor bundleDesc, ClassLoader classLoader, Parser parser) throws IOException { /* * This essentially duplicates */ if (parser!=null) { classParser = parser; } else { ParsingContext.Builder builder = new ParsingContext.Builder(); builder.logger(logger); ParsingContext pc = builder.build(); classParser = new Parser(pc); } doProcess(archive, bundleDesc, classLoader); completeProcess(bundleDesc, archive); calculateResults(); }
public void process(ReadableArchive archiveFile, T bundleDesc, ClassLoader classLoader, Parser parser) throws IOException { File file = new File(archiveFile.getURI()); if (parser!=null) { classParser = parser; } else { ParsingContext.Builder builder = new ParsingContext.Builder(); builder.logger(logger); ParsingContext pc = builder.build(); classParser = new Parser(pc); } process(file, bundleDesc, classLoader); completeProcess(bundleDesc, archiveFile); calculateResults(); }
protected void initTypes(File file) throws IOException { ParsingContext context = new ParsingContext.Builder().build(); Parser cp = new Parser(context); cp.parse(file, null); try { cp.awaitTermination(); } catch (InterruptedException e) { throw new IOException(e); } types = cp.getContext().getTypes(); }
protected void initTypes(File file) throws IOException { ParsingContext context = new ParsingContext.Builder().build(); Parser cp = new Parser(context); cp.parse(file, null); try { cp.awaitTermination(); } catch (InterruptedException e) { throw new IOException(e); } types = cp.getContext().getTypes(); }
protected void setParser(Parser parser) { if (parser == null) { // if the passed in parser is null, it means no annotation scanning // has been done yet, we need to construct a new parser // and do the annotation scanning here ParsingContext pc = new ParsingContext.Builder().logger(deplLogger).executorService(getExecutorService()).build(); parser = new Parser(pc); needScanAnnotation = true; } classParser = parser; } }