use of antlr.RecognitionException in project cxf by apache.
the class IDLParser method param_dcl.
public final void param_dcl() throws RecognitionException, TokenStreamException {
returnAST = null;
ASTPair currentAST = new ASTPair();
AST param_dcl_AST = null;
try {
// for error handling
{
switch(LA(1)) {
case LITERAL_in:
{
AST tmp174_AST = null;
tmp174_AST = astFactory.create(LT(1));
astFactory.makeASTRoot(currentAST, tmp174_AST);
match(LITERAL_in);
break;
}
case LITERAL_out:
{
AST tmp175_AST = null;
tmp175_AST = astFactory.create(LT(1));
astFactory.makeASTRoot(currentAST, tmp175_AST);
match(LITERAL_out);
break;
}
case LITERAL_inout:
{
AST tmp176_AST = null;
tmp176_AST = astFactory.create(LT(1));
astFactory.makeASTRoot(currentAST, tmp176_AST);
match(LITERAL_inout);
break;
}
default:
{
throw new NoViableAltException(LT(1), getFilename());
}
}
}
param_type_spec();
astFactory.addASTChild(currentAST, returnAST);
simple_declarator();
astFactory.addASTChild(currentAST, returnAST);
param_dcl_AST = (AST) currentAST.root;
} catch (RecognitionException ex) {
if (inputState.guessing == 0) {
reportError(ex);
consume();
consumeUntil(_tokenSet_29);
} else {
throw ex;
}
}
returnAST = param_dcl_AST;
}
use of antlr.RecognitionException in project cxf by apache.
the class IDLParser method type_prefix_dcl.
public final void type_prefix_dcl() throws RecognitionException, TokenStreamException {
returnAST = null;
ASTPair currentAST = new ASTPair();
AST type_prefix_dcl_AST = null;
try {
// for error handling
AST tmp25_AST = null;
tmp25_AST = astFactory.create(LT(1));
astFactory.makeASTRoot(currentAST, tmp25_AST);
match(LITERAL_typeprefix);
scoped_name();
astFactory.addASTChild(currentAST, returnAST);
string_literal();
astFactory.addASTChild(currentAST, returnAST);
type_prefix_dcl_AST = (AST) currentAST.root;
} catch (RecognitionException ex) {
if (inputState.guessing == 0) {
reportError(ex);
consume();
consumeUntil(_tokenSet_10);
} else {
throw ex;
}
}
returnAST = type_prefix_dcl_AST;
}
use of antlr.RecognitionException in project cxf by apache.
the class IDLParser method consumes_dcl.
public final void consumes_dcl() throws RecognitionException, TokenStreamException {
returnAST = null;
ASTPair currentAST = new ASTPair();
AST consumes_dcl_AST = null;
try {
// for error handling
AST tmp201_AST = null;
tmp201_AST = astFactory.create(LT(1));
astFactory.makeASTRoot(currentAST, tmp201_AST);
match(LITERAL_consumes);
scoped_name();
astFactory.addASTChild(currentAST, returnAST);
identifier();
astFactory.addASTChild(currentAST, returnAST);
consumes_dcl_AST = (AST) currentAST.root;
} catch (RecognitionException ex) {
if (inputState.guessing == 0) {
reportError(ex);
consume();
consumeUntil(_tokenSet_10);
} else {
throw ex;
}
}
returnAST = consumes_dcl_AST;
}
use of antlr.RecognitionException in project cxf by apache.
the class IDLParser method emits_dcl.
public final void emits_dcl() throws RecognitionException, TokenStreamException {
returnAST = null;
ASTPair currentAST = new ASTPair();
AST emits_dcl_AST = null;
try {
// for error handling
AST tmp199_AST = null;
tmp199_AST = astFactory.create(LT(1));
astFactory.makeASTRoot(currentAST, tmp199_AST);
match(LITERAL_emits);
scoped_name();
astFactory.addASTChild(currentAST, returnAST);
identifier();
astFactory.addASTChild(currentAST, returnAST);
emits_dcl_AST = (AST) currentAST.root;
} catch (RecognitionException ex) {
if (inputState.guessing == 0) {
reportError(ex);
consume();
consumeUntil(_tokenSet_10);
} else {
throw ex;
}
}
returnAST = emits_dcl_AST;
}
use of antlr.RecognitionException in project cxf by apache.
the class IDLParser method string_literal.
public final void string_literal() throws RecognitionException, TokenStreamException {
returnAST = null;
ASTPair currentAST = new ASTPair();
AST string_literal_AST = null;
try {
// for error handling
{
int _cnt285 = 0;
_loop285: do {
if ((LA(1) == STRING_LITERAL)) {
AST tmp110_AST = null;
tmp110_AST = astFactory.create(LT(1));
astFactory.addASTChild(currentAST, tmp110_AST);
match(STRING_LITERAL);
} else {
if (_cnt285 >= 1) {
break _loop285;
} else {
throw new NoViableAltException(LT(1), getFilename());
}
}
_cnt285++;
} while (true);
}
string_literal_AST = (AST) currentAST.root;
} catch (RecognitionException ex) {
if (inputState.guessing == 0) {
reportError(ex);
consume();
consumeUntil(_tokenSet_42);
} else {
throw ex;
}
}
returnAST = string_literal_AST;
}
Aggregations