token.getText(), ex);
}
}
}
else if (ex instanceof NoViableAltException) {
NoViableAltException noviable = (NoViableAltException)ex;
Token token = noviable.token;
if (token != null) {
if (token.getType() == Token.EOF_TYPE) {
result = EJBQLException.unexpectedEOF(getQueryInfo(),
noviable.getLine(), noviable.getColumn(), ex);
}
else {
result = EJBQLException.unexpectedToken(getQueryInfo(),
noviable.getLine(), noviable.getColumn(),
token.getText(), ex);
}
}
}
else if (ex instanceof NoViableAltForCharException) {