log.debug("ignored due to RecognitionException: " + filename + " [" + e.getMessage() + "]", e); } catch (TokenStreamException e) { log.error("ignored due to TokenStreamException: " + filename + " [" + e.getMessage() + "]"); log.debug("ignored due to TokenStreamException: " + filename + " [" + e.getMessage() + "]", e);
m_log.debug(e.getMessage(), e); m_reporter.reportTokenStreamError(resourceLocation, e.getMessage()); } catch (RecognitionException e) { m_log.debug(e.getMessage(), e);
public Message next() throws ParseException { try { return internalParser.next(); } catch (RecognitionException e) { throw new ParseException(e.getMessage(), e, e.getLine()); } catch (TokenStreamException e) { throw new ParseException(e.getMessage(), e, -1); } }
String msg = I18n.err( I18n.ERR_04247, matchingRuleUseDescription, tse.getMessage() ); LOG.error( msg ); throw new ParseException( msg, 0 );
String msg = I18n.err( I18n.ERR_04253, normalizerDescription, tse.getMessage() ); LOG.error( msg ); throw new ParseException( msg, 0 );
String msg = I18n.err( I18n.ERR_04250, nameFormDescription, tse.getMessage() ); LOG.error( msg ); throw new ParseException( msg, 0 );
String msg = I18n.err( I18n.ERR_04241, ldapSyntaxDescription, tse.getMessage() ); LOG.error( msg ); throw new ParseException( msg, 0 );
String msg = I18n.err( I18n.ERR_04232, ditContentRuleDescription, tse.getMessage() ); LOG.error( msg ); throw new ParseException( msg, 0 );
private void processFile(String filename, File srcFile) throws IOException { String src = DefaultGroovyMethods.getText(srcFile); String packagePath = tool.getPath(filename).replace('\\', FS); String file = tool.getFile(filename); SimpleGroovyPackageDoc packageDoc = (SimpleGroovyPackageDoc) rootDoc.packageNamed(packagePath); if (packageDoc == null) { packageDoc = new SimpleGroovyPackageDoc(packagePath); } if (filename.endsWith("package.html") || filename.endsWith("package-info.java") || filename.endsWith("package-info.groovy")) { processPackageInfo(src, filename, packageDoc); rootDoc.put(packagePath, packageDoc); return; } try { Map<String, GroovyClassDoc> classDocs = getClassDocsFromSingleSource(packagePath, file, src); rootDoc.putAllClasses(classDocs); packageDoc.putAll(classDocs); rootDoc.put(packagePath, packageDoc); } catch (RecognitionException e) { System.err.println("ignored due to RecognitionException: " + filename + " [" + e.getMessage() + "]"); } catch (TokenStreamException e) { System.err.println("ignored due to TokenStreamException: " + filename + " [" + e.getMessage() + "]"); } }
private Catalog parseCatalog(ExtendedCatalogParser parser) throws ParseException { try { parser.catalog(); } catch (RecognitionException e) { throw new UnexpectedTokenException(e.getMessage(), e, e.getLine()); } catch (TokenStreamException e) { throw new ParseException(e.getMessage(), e, -1); } return parser.getCatalog(); }
private void processFile(String filename, File srcFile) throws IOException { String src = DefaultGroovyMethods.getText(srcFile); String packagePath = tool.getPath(filename).replace('\\', FS); String file = tool.getFile(filename); SimpleGroovyPackageDoc packageDoc = (SimpleGroovyPackageDoc) rootDoc.packageNamed(packagePath); if (packageDoc == null) { packageDoc = new SimpleGroovyPackageDoc(packagePath); } if (filename.endsWith("package.html")) { processHtmlPackage(src, packageDoc); return; } try { Map<String, GroovyClassDoc> classDocs = getClassDocsFromSingleSource(packagePath, file, src); rootDoc.putAllClasses(classDocs); packageDoc.putAll(classDocs); rootDoc.put(packagePath, packageDoc); } catch (RecognitionException e) { System.err.println("ignored due to RecognitionException: " + filename + " [" + e.getMessage() + "]"); } catch (TokenStreamException e) { System.err.println("ignored due to TokenStreamException: " + filename + " [" + e.getMessage() + "]"); } }
} catch (antlr.TokenStreamException e) { new antlr.DumpASTVisitor().visit(ast); IllegalArgumentException e2 = new IllegalArgumentException(e.getMessage() + " while parsing " + expression); e2.initCause(e);
log.debug("ignored due to RecognitionException: " + filename + " [" + e.getMessage() + "]", e); } catch (TokenStreamException e) { log.error("ignored due to TokenStreamException: " + filename + " [" + e.getMessage() + "]"); log.debug("ignored due to TokenStreamException: " + filename + " [" + e.getMessage() + "]", e);
} catch (antlr.TokenStreamException e) { new antlr.DumpASTVisitor().visit(ast); IllegalArgumentException e2 = new IllegalArgumentException(e.getMessage() + " while parsing " + expression); e2.initCause(e);
public ParseContextIF parseDeclarations(String decls) throws InvalidQueryException { try { ParseContextIF ctxt = new LocalParseContext(context); RealTologParser parser = makeParser(new StringReader(decls)); parser.setContext(ctxt); parser.declarations(); return ctxt; } catch (AntlrWrapException ex) { Exception e = ex.getException(); if (e instanceof InvalidQueryException) throw (InvalidQueryException)e; else throw new InvalidQueryException(e); } catch (RecognitionException ex) { throw new InvalidQueryException(MSG_LEXICAL_ERROR_AT /*+ getBaseAddress().getAddress() + ":"*/ + ex.line + ":" + ex.column + ": "+ ex.getMessage()); } catch (TokenStreamRecognitionException e) { RecognitionException ex = e.recog; throw new InvalidQueryException(MSG_LEXICAL_ERROR_AT /*+ getBaseAddress().getAddress() + ":"*/ + ex.line + ":" + ex.column + ": "+ ex.getMessage()); } catch (TokenStreamIOException ex) { throw new InvalidQueryException(ex.io.toString()); } catch (TokenStreamException ex) { throw new InvalidQueryException(MSG_LEXICAL_ERROR + ex.getMessage()); } }
public void load(Reader reader) throws InvalidQueryException { try { RealTologParser parser = makeParser(reader); parser.setContext(context); parser.ruleset(); } catch (AntlrWrapException ex) { Exception e = ex.getException(); if (e instanceof InvalidQueryException) throw (InvalidQueryException)e; else throw new InvalidQueryException(e); } catch (RecognitionException ex) { throw new InvalidQueryException(MSG_LEXICAL_ERROR_AT /*+ getBaseAddress().getAddress() + ":"*/ + ex.line + ":" + ex.column + ": "+ ex.getMessage()); } catch (TokenStreamRecognitionException e) { RecognitionException ex = e.recog; throw new InvalidQueryException(MSG_LEXICAL_ERROR_AT /*+ getBaseAddress().getAddress() + ":"*/ + ex.line + ":" + ex.column + ": "+ ex.getMessage()); } catch (TokenStreamIOException ex) { throw new InvalidQueryException(ex.io.toString()); } catch (TokenStreamException ex) { throw new InvalidQueryException(MSG_LEXICAL_ERROR + ex.getMessage()); } }
throw ex.io; } catch (TokenStreamException ex) { throw new IOException("Lexical error: " + ex.getMessage()); } catch (java.io.CharConversionException e) { throw new IOException("Problem decoding character encoding."
throw new InvalidQueryException(MSG_LEXICAL_ERROR + ex.getMessage());
throw ex.io; } catch (TokenStreamException ex) { throw new IOException("Lexical error: " + ex.getMessage()); } catch (java.io.CharConversionException e) { throw new IOException("Problem decoding character encoding."
throw new InvalidQueryException(MSG_LEXICAL_ERROR + ex.getMessage());