use of antlr.NoViableAltException in project cxf by apache.
the class IDLParser method specification.
public void specification() throws RecognitionException, TokenStreamException {
returnAST = null;
ASTPair currentAST = new ASTPair();
AST specification_AST = null;
try {
// for error handling
{
_loop3: do {
if ((LA(1) == LITERAL_import)) {
import_dcl();
astFactory.addASTChild(currentAST, returnAST);
} else {
break _loop3;
}
} while (true);
}
{
int _cnt5 = 0;
_loop5: do {
if ((_tokenSet_0.member(LA(1)))) {
definition();
astFactory.addASTChild(currentAST, returnAST);
} else {
if (_cnt5 >= 1) {
break _loop5;
} else {
throw new NoViableAltException(LT(1), getFilename());
}
}
_cnt5++;
} while (true);
}
specification_AST = (AST) currentAST.root;
} catch (RecognitionException ex) {
if (inputState.guessing == 0) {
reportError(ex);
consume();
consumeUntil(_tokenSet_1);
} else {
throw ex;
}
}
returnAST = specification_AST;
}
use of antlr.NoViableAltException in project cxf by apache.
the class IDLParser method component_export.
public final void component_export() throws RecognitionException, TokenStreamException {
returnAST = null;
ASTPair currentAST = new ASTPair();
AST component_export_AST = null;
try {
// for error handling
{
switch(LA(1)) {
case LITERAL_provides:
{
provides_dcl();
astFactory.addASTChild(currentAST, returnAST);
match(SEMI);
break;
}
case LITERAL_uses:
{
uses_dcl();
astFactory.addASTChild(currentAST, returnAST);
match(SEMI);
break;
}
case LITERAL_emits:
{
emits_dcl();
astFactory.addASTChild(currentAST, returnAST);
match(SEMI);
break;
}
case LITERAL_publishes:
{
publishes_dcl();
astFactory.addASTChild(currentAST, returnAST);
match(SEMI);
break;
}
case LITERAL_consumes:
{
consumes_dcl();
astFactory.addASTChild(currentAST, returnAST);
match(SEMI);
break;
}
case LITERAL_readonly:
case LITERAL_attribute:
{
attr_dcl();
astFactory.addASTChild(currentAST, returnAST);
match(SEMI);
break;
}
default:
{
throw new NoViableAltException(LT(1), getFilename());
}
}
}
component_export_AST = (AST) currentAST.root;
} catch (RecognitionException ex) {
if (inputState.guessing == 0) {
reportError(ex);
consume();
consumeUntil(_tokenSet_67);
} else {
throw ex;
}
}
returnAST = component_export_AST;
}
use of antlr.NoViableAltException in project cxf by apache.
the class IDLParser method template_type_spec.
public final void template_type_spec() throws RecognitionException, TokenStreamException {
returnAST = null;
ASTPair currentAST = new ASTPair();
AST template_type_spec_AST = null;
try {
// for error handling
switch(LA(1)) {
case LITERAL_sequence:
{
sequence_type();
astFactory.addASTChild(currentAST, returnAST);
template_type_spec_AST = (AST) currentAST.root;
break;
}
case LITERAL_string:
{
string_type();
astFactory.addASTChild(currentAST, returnAST);
template_type_spec_AST = (AST) currentAST.root;
break;
}
case LITERAL_wstring:
{
wide_string_type();
astFactory.addASTChild(currentAST, returnAST);
template_type_spec_AST = (AST) currentAST.root;
break;
}
case LITERAL_fixed:
{
fixed_pt_type();
astFactory.addASTChild(currentAST, returnAST);
template_type_spec_AST = (AST) currentAST.root;
break;
}
default:
{
throw new NoViableAltException(LT(1), getFilename());
}
}
} catch (RecognitionException ex) {
if (inputState.guessing == 0) {
reportError(ex);
consume();
consumeUntil(_tokenSet_36);
} else {
throw ex;
}
}
returnAST = template_type_spec_AST;
}
use of antlr.NoViableAltException in project cxf by apache.
the class IDLParser method definition_list.
public final void definition_list() throws RecognitionException, TokenStreamException {
returnAST = null;
ASTPair currentAST = new ASTPair();
AST definition_list_AST = null;
try {
// for error handling
{
int _cnt20 = 0;
_loop20: do {
if ((_tokenSet_0.member(LA(1)))) {
definition();
astFactory.addASTChild(currentAST, returnAST);
} else {
if (_cnt20 >= 1) {
break _loop20;
} else {
throw new NoViableAltException(LT(1), getFilename());
}
}
_cnt20++;
} while (true);
}
definition_list_AST = (AST) currentAST.root;
} catch (RecognitionException ex) {
if (inputState.guessing == 0) {
reportError(ex);
consume();
consumeUntil(_tokenSet_15);
} else {
throw ex;
}
}
returnAST = definition_list_AST;
}
use of antlr.NoViableAltException in project cxf by apache.
the class IDLParser method value_inheritance_spec.
public final void value_inheritance_spec() throws RecognitionException, TokenStreamException {
returnAST = null;
ASTPair currentAST = new ASTPair();
AST value_inheritance_spec_AST = null;
try {
// for error handling
{
switch(LA(1)) {
case COLON:
{
value_value_inheritance_spec();
astFactory.addASTChild(currentAST, returnAST);
break;
}
case LCURLY:
case LITERAL_supports:
{
break;
}
default:
{
throw new NoViableAltException(LT(1), getFilename());
}
}
}
{
switch(LA(1)) {
case LITERAL_supports:
{
value_interface_inheritance_spec();
astFactory.addASTChild(currentAST, returnAST);
break;
}
case LCURLY:
{
break;
}
default:
{
throw new NoViableAltException(LT(1), getFilename());
}
}
}
value_inheritance_spec_AST = (AST) currentAST.root;
} catch (RecognitionException ex) {
if (inputState.guessing == 0) {
reportError(ex);
consume();
consumeUntil(_tokenSet_16);
} else {
throw ex;
}
}
returnAST = value_inheritance_spec_AST;
}
Aggregations