sdr 0.7

net.cscott.sdr.calls.parser
Class AstParser

java.lang.Object
  extended by org.antlr.runtime.BaseRecognizer
      extended by org.antlr.runtime.Parser
          extended by net.cscott.sdr.calls.parser.AstParser

public class AstParser
extends org.antlr.runtime.Parser

Simple lisp-like grammar for printing/scanning AstNode trees. If this were simpler and more lisp-like, I wouldn't need ANTLR to parse it!

Tests:
Simple conversion:
js> new AstParser("(Seq (Prim -1, in 1, none, 1))").ast()
(Seq (Prim -1, in 1, none, 1))
js> new AstParser("(If 'BEFORE (Expr true) (Seq (Apply 'nothing)))").ast()
(If 'BEFORE (Expr true) (Seq (Apply 'nothing)))
js> new AstParser("(Expr multiple words (Expr arg 1) (Expr arg 2))").ast()
  (Expr multiple words (Expr arg 1) (Expr arg 2))
White space is ignored:
js> new AstParser("( Seq\n (Prim\tin\r-1 ,  1 , out  1  / 4  ,1 ) ) ").ast()
(Seq (Prim in -1, 1, in -1/4, 1))
Call names, predicates, formations, etc can be quoted:
js> new AstParser("(Expr \"Expr\" (Expr \"If\") (Expr \"Prim\"))").ast()
(Expr Expr (Expr If) (Expr Prim))
js> new AstParser('(If \'AFTER (Expr true) (Seq (Apply \'nothing)) "Message!" 1/2)').ast()
(If 'AFTER (Expr true) (Seq (Apply 'nothing)) "Message!" 1/2)
js> new AstParser('(If \'BEFORE (Expr true) (Seq (Apply \'nothing)) "Message!")').ast()
(If 'BEFORE (Expr true) (Seq (Apply 'nothing)) "Message!")
Keywords ought to be ignored in call names, etc.
js> new AstParser("(Expr Expr (Expr If) (Expr Prim))").ast()
(Expr Expr (Expr If) (Expr Prim))
Parsing complicated Prims:
js> new AstParser("(Seq (Prim 1 1/2, 1/2, left, 1, PASS_LEFT, FORCE_ARC, FORCE_ROLL_RIGHT))").ast()
(Seq (Prim 1 1/2, 1/2, left, 1, PASS_LEFT, FORCE_ARC, FORCE_ROLL_RIGHT))
Parsing OptCall and ParCall:
js> new AstParser("(Opt (From 'CIRCLE ADJUST (Seq (Apply 'nothing))))").ast()
(Opt (From 'CIRCLE ADJUST (Seq (Apply 'nothing))))
js> new AstParser("(Par (Select 'BOY (Seq (Apply 'nothing))))").ast()
(Par (Select 'BOY (Seq (Apply 'nothing))))

Nested Class Summary
static class AstParser.in_out_dir_return
           
static class AstParser.in_out_num_return
           
static class AstParser.in_out_return
           
static class AstParser.rotation_return
           
 
Field Summary
static int EOF
           
static org.antlr.runtime.BitSet FOLLOW_10_in_divisibility543
           
static org.antlr.runtime.BitSet FOLLOW_10_in_divisibility565
           
static org.antlr.runtime.BitSet FOLLOW_10_in_divisibility587
           
static org.antlr.runtime.BitSet FOLLOW_10_in_expr397
           
static org.antlr.runtime.BitSet FOLLOW_10_in_ifwhen844
           
static org.antlr.runtime.BitSet FOLLOW_10_in_ifwhen866
           
static org.antlr.runtime.BitSet FOLLOW_11_in_prim_flags704
           
static org.antlr.runtime.BitSet FOLLOW_11_in_prim635
           
static org.antlr.runtime.BitSet FOLLOW_11_in_prim641
           
static org.antlr.runtime.BitSet FOLLOW_11_in_prim647
           
static org.antlr.runtime.BitSet FOLLOW_11_in_string_list1136
           
static org.antlr.runtime.BitSet FOLLOW_12_in_string_list1118
           
static org.antlr.runtime.BitSet FOLLOW_13_in_string_list1147
           
static org.antlr.runtime.BitSet FOLLOW_14_in_opt_sign1291
           
static org.antlr.runtime.BitSet FOLLOW_15_in_opt_sign1301
           
static org.antlr.runtime.BitSet FOLLOW_16_in_fraction1339
           
static org.antlr.runtime.BitSet FOLLOW_16_in_synpred1_Ast1216
           
static org.antlr.runtime.BitSet FOLLOW_8_in_apply441
           
static org.antlr.runtime.BitSet FOLLOW_8_in_expr362
           
static org.antlr.runtime.BitSet FOLLOW_8_in_if_776
           
static org.antlr.runtime.BitSet FOLLOW_8_in_in900
           
static org.antlr.runtime.BitSet FOLLOW_8_in_opt957
           
static org.antlr.runtime.BitSet FOLLOW_8_in_optcall213
           
static org.antlr.runtime.BitSet FOLLOW_8_in_par1013
           
static org.antlr.runtime.BitSet FOLLOW_8_in_parcall263
           
static org.antlr.runtime.BitSet FOLLOW_8_in_part487
           
static org.antlr.runtime.BitSet FOLLOW_8_in_prim627
           
static org.antlr.runtime.BitSet FOLLOW_8_in_seq1069
           
static org.antlr.runtime.BitSet FOLLOW_9_in_apply447
           
static org.antlr.runtime.BitSet FOLLOW_9_in_expr379
           
static org.antlr.runtime.BitSet FOLLOW_9_in_if_802
           
static org.antlr.runtime.BitSet FOLLOW_9_in_in912
           
static org.antlr.runtime.BitSet FOLLOW_9_in_opt968
           
static org.antlr.runtime.BitSet FOLLOW_9_in_optcall223
           
static org.antlr.runtime.BitSet FOLLOW_9_in_par1024
           
static org.antlr.runtime.BitSet FOLLOW_9_in_parcall273
           
static org.antlr.runtime.BitSet FOLLOW_9_in_part501
           
static org.antlr.runtime.BitSet FOLLOW_9_in_prim665
           
static org.antlr.runtime.BitSet FOLLOW_9_in_seq1080
           
static org.antlr.runtime.BitSet FOLLOW_apply_in_seqcall303
           
static org.antlr.runtime.BitSet FOLLOW_ast_in_start54
           
static org.antlr.runtime.BitSet FOLLOW_comp_in_ast79
           
static org.antlr.runtime.BitSet FOLLOW_comp_in_if_786
           
static org.antlr.runtime.BitSet FOLLOW_comp_in_in910
           
static org.antlr.runtime.BitSet FOLLOW_comp_in_optcall221
           
static org.antlr.runtime.BitSet FOLLOW_comp_in_parcall271
           
static org.antlr.runtime.BitSet FOLLOW_comp_in_part499
           
static org.antlr.runtime.BitSet FOLLOW_divisibility_in_part491
           
static org.antlr.runtime.BitSet FOLLOW_EOF_in_start56
           
static org.antlr.runtime.BitSet FOLLOW_expr_in_apply445
           
static org.antlr.runtime.BitSet FOLLOW_expr_in_ast119
           
static org.antlr.runtime.BitSet FOLLOW_expr_in_expr373
           
static org.antlr.runtime.BitSet FOLLOW_expr_in_if_782
           
static org.antlr.runtime.BitSet FOLLOW_expr_in_in906
           
static org.antlr.runtime.BitSet FOLLOW_expr_in_optcall217
           
static org.antlr.runtime.BitSet FOLLOW_expr_in_parcall267
           
static org.antlr.runtime.BitSet FOLLOW_expr_in_part495
           
static org.antlr.runtime.BitSet FOLLOW_fraction_in_number1239
           
static org.antlr.runtime.BitSet FOLLOW_fraction_in_rotation1492
           
static org.antlr.runtime.BitSet FOLLOW_IDENT_in_apply443
           
static org.antlr.runtime.BitSet FOLLOW_IDENT_in_divisibility545
           
static org.antlr.runtime.BitSet FOLLOW_IDENT_in_divisibility567
           
static org.antlr.runtime.BitSet FOLLOW_IDENT_in_divisibility589
           
static org.antlr.runtime.BitSet FOLLOW_IDENT_in_expr364
           
static org.antlr.runtime.BitSet FOLLOW_IDENT_in_if_778
           
static org.antlr.runtime.BitSet FOLLOW_IDENT_in_ifwhen846
           
static org.antlr.runtime.BitSet FOLLOW_IDENT_in_ifwhen868
           
static org.antlr.runtime.BitSet FOLLOW_IDENT_in_in_out1530
           
static org.antlr.runtime.BitSet FOLLOW_IDENT_in_in_out1550
           
static org.antlr.runtime.BitSet FOLLOW_IDENT_in_in902
           
static org.antlr.runtime.BitSet FOLLOW_IDENT_in_opt959
           
static org.antlr.runtime.BitSet FOLLOW_IDENT_in_optcall215
           
static org.antlr.runtime.BitSet FOLLOW_IDENT_in_par1015
           
static org.antlr.runtime.BitSet FOLLOW_IDENT_in_parcall265
           
static org.antlr.runtime.BitSet FOLLOW_IDENT_in_part489
           
static org.antlr.runtime.BitSet FOLLOW_IDENT_in_prim_flag743
           
static org.antlr.runtime.BitSet FOLLOW_IDENT_in_prim629
           
static org.antlr.runtime.BitSet FOLLOW_IDENT_in_rotation1482
           
static org.antlr.runtime.BitSet FOLLOW_IDENT_in_seq1071
           
static org.antlr.runtime.BitSet FOLLOW_IDENT_in_simple_word1574
           
static org.antlr.runtime.BitSet FOLLOW_if__in_comp141
           
static org.antlr.runtime.BitSet FOLLOW_ifwhen_in_if_780
           
static org.antlr.runtime.BitSet FOLLOW_in_in_comp151
           
static org.antlr.runtime.BitSet FOLLOW_in_out_dir_in_prim645
           
static org.antlr.runtime.BitSet FOLLOW_in_out_in_in_out_dir1441
           
static org.antlr.runtime.BitSet FOLLOW_in_out_in_in_out_num1407
           
static org.antlr.runtime.BitSet FOLLOW_in_out_num_in_prim633
           
static org.antlr.runtime.BitSet FOLLOW_in_out_num_in_prim639
           
static org.antlr.runtime.BitSet FOLLOW_INT_in_integer1375
           
static org.antlr.runtime.BitSet FOLLOW_INT_in_synpred1_Ast1210
           
static org.antlr.runtime.BitSet FOLLOW_INT_in_synpred1_Ast1214
           
static org.antlr.runtime.BitSet FOLLOW_INT_in_synpred1_Ast1218
           
static org.antlr.runtime.BitSet FOLLOW_integer_in_fraction1337
           
static org.antlr.runtime.BitSet FOLLOW_integer_in_fraction1343
           
static org.antlr.runtime.BitSet FOLLOW_integer_in_number1235
           
static org.antlr.runtime.BitSet FOLLOW_integer_in_number1259
           
static org.antlr.runtime.BitSet FOLLOW_list_elem_in_expr368
           
static org.antlr.runtime.BitSet FOLLOW_list_elem_in_expr401
           
static org.antlr.runtime.BitSet FOLLOW_list_elem_in_string_list1122
           
static org.antlr.runtime.BitSet FOLLOW_list_elem_in_string_list1140
           
static org.antlr.runtime.BitSet FOLLOW_number_in_if_796
           
static org.antlr.runtime.BitSet FOLLOW_number_in_in_out_num1410
           
static org.antlr.runtime.BitSet FOLLOW_number_in_prim659
           
static org.antlr.runtime.BitSet FOLLOW_number_in_simple_word1584
           
static org.antlr.runtime.BitSet FOLLOW_opt_in_comp161
           
static org.antlr.runtime.BitSet FOLLOW_opt_sign_in_number1230
           
static org.antlr.runtime.BitSet FOLLOW_opt_sign_in_number1257
           
static org.antlr.runtime.BitSet FOLLOW_opt_sign_in_rotation1490
           
static org.antlr.runtime.BitSet FOLLOW_opt_sign_in_synpred1_Ast1207
           
static org.antlr.runtime.BitSet FOLLOW_optcall_in_ast89
           
static org.antlr.runtime.BitSet FOLLOW_optcall_in_opt962
           
static org.antlr.runtime.BitSet FOLLOW_par_in_comp171
           
static org.antlr.runtime.BitSet FOLLOW_parcall_in_ast99
           
static org.antlr.runtime.BitSet FOLLOW_parcall_in_par1018
           
static org.antlr.runtime.BitSet FOLLOW_part_in_seqcall313
           
static org.antlr.runtime.BitSet FOLLOW_prim_flag_in_prim_flags706
           
static org.antlr.runtime.BitSet FOLLOW_prim_flags_in_prim663
           
static org.antlr.runtime.BitSet FOLLOW_prim_in_seqcall324
           
static org.antlr.runtime.BitSet FOLLOW_rotation_in_in_out_dir1444
           
static org.antlr.runtime.BitSet FOLLOW_seq_in_comp181
           
static org.antlr.runtime.BitSet FOLLOW_seqcall_in_ast109
           
static org.antlr.runtime.BitSet FOLLOW_seqcall_in_seq1074
           
static org.antlr.runtime.BitSet FOLLOW_simple_word_in_simple_words1615
           
static org.antlr.runtime.BitSet FOLLOW_simple_word_in_simple_words1630
           
static org.antlr.runtime.BitSet FOLLOW_simple_words_in_list_elem1169
           
static org.antlr.runtime.BitSet FOLLOW_STRING_in_if_791
           
static org.antlr.runtime.BitSet FOLLOW_STRING_in_list_elem1179
           
static int IDENT
           
static int INT
           
static int STRING
           
static int T__10
           
static int T__11
           
static int T__12
           
static int T__13
           
static int T__14
           
static int T__15
           
static int T__16
           
static int T__8
           
static int T__9
           
static String[] tokenNames
           
static int WS
           
 
Fields inherited from class org.antlr.runtime.Parser
input
 
Fields inherited from class org.antlr.runtime.BaseRecognizer
DEFAULT_TOKEN_CHANNEL, HIDDEN, INITIAL_FOLLOW_STACK_SIZE, MEMO_RULE_FAILED, MEMO_RULE_UNKNOWN, NEXT_TOKEN_RULE_NAME, state
 
Constructor Summary
AstParser(String s)
           
AstParser(org.antlr.runtime.TokenStream input)
           
AstParser(org.antlr.runtime.TokenStream input, org.antlr.runtime.RecognizerSharedState state)
           
 
Method Summary
 Apply apply()
           
 AstNode ast()
           
 Comp comp()
           
 Part.Divisibility divisibility()
           
 Expr expr()
           
 Fraction fraction()
           
 String getGrammarFileName()
           
 String[] getTokenNames()
           
 If if_()
           
 If.When ifwhen()
           
 AstParser.in_out_dir_return in_out_dir()
           
 AstParser.in_out_num_return in_out_num()
           
 AstParser.in_out_return in_out()
           
 In in()
           
 Integer integer()
           
 String list_elem()
           
 Fraction number()
           
 boolean opt_sign()
           
 Opt opt()
           
 OptCall optcall()
           
 Par par()
           
 ParCall parcall()
           
 Part part()
           
 Prim.Flag prim_flag()
           
 Set<Prim.Flag> prim_flags()
           
 Prim prim()
           
 AstParser.rotation_return rotation()
           
 Seq seq()
           
 SeqCall seqcall()
           
 String simple_word()
           
 String simple_words()
           
 AstNode start()
           
 List<String> string_list()
           
 void synpred1_Ast_fragment()
           
 boolean synpred1_Ast()
           
 
Methods inherited from class org.antlr.runtime.Parser
getCurrentInputSymbol, getMissingSymbol, getSourceName, getTokenStream, reset, setTokenStream, traceIn, traceOut
 
Methods inherited from class org.antlr.runtime.BaseRecognizer
alreadyParsedRule, beginResync, combineFollows, computeContextSensitiveRuleFOLLOW, computeErrorRecoverySet, consumeUntil, consumeUntil, displayRecognitionError, emitErrorMessage, endResync, failed, getBacktrackingLevel, getErrorHeader, getErrorMessage, getNumberOfSyntaxErrors, getRuleInvocationStack, getRuleInvocationStack, getRuleMemoization, getRuleMemoizationCacheSize, getTokenErrorDisplay, match, matchAny, memoize, mismatchIsMissingToken, mismatchIsUnwantedToken, pushFollow, recover, recoverFromMismatchedSet, recoverFromMismatchedToken, reportError, setBacktrackingLevel, toStrings, traceIn, traceOut
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

tokenNames

public static final String[] tokenNames

WS

public static final int WS
See Also:
Constant Field Values

T__16

public static final int T__16
See Also:
Constant Field Values

T__15

public static final int T__15
See Also:
Constant Field Values

T__12

public static final int T__12
See Also:
Constant Field Values

T__11

public static final int T__11
See Also:
Constant Field Values

T__14

public static final int T__14
See Also:
Constant Field Values

T__13

public static final int T__13
See Also:
Constant Field Values

T__10

public static final int T__10
See Also:
Constant Field Values

IDENT

public static final int IDENT
See Also:
Constant Field Values

INT

public static final int INT
See Also:
Constant Field Values

EOF

public static final int EOF
See Also:
Constant Field Values

T__9

public static final int T__9
See Also:
Constant Field Values

T__8

public static final int T__8
See Also:
Constant Field Values

STRING

public static final int STRING
See Also:
Constant Field Values

FOLLOW_ast_in_start54

public static final org.antlr.runtime.BitSet FOLLOW_ast_in_start54

FOLLOW_EOF_in_start56

public static final org.antlr.runtime.BitSet FOLLOW_EOF_in_start56

FOLLOW_comp_in_ast79

public static final org.antlr.runtime.BitSet FOLLOW_comp_in_ast79

FOLLOW_optcall_in_ast89

public static final org.antlr.runtime.BitSet FOLLOW_optcall_in_ast89

FOLLOW_parcall_in_ast99

public static final org.antlr.runtime.BitSet FOLLOW_parcall_in_ast99

FOLLOW_seqcall_in_ast109

public static final org.antlr.runtime.BitSet FOLLOW_seqcall_in_ast109

FOLLOW_expr_in_ast119

public static final org.antlr.runtime.BitSet FOLLOW_expr_in_ast119

FOLLOW_if__in_comp141

public static final org.antlr.runtime.BitSet FOLLOW_if__in_comp141

FOLLOW_in_in_comp151

public static final org.antlr.runtime.BitSet FOLLOW_in_in_comp151

FOLLOW_opt_in_comp161

public static final org.antlr.runtime.BitSet FOLLOW_opt_in_comp161

FOLLOW_par_in_comp171

public static final org.antlr.runtime.BitSet FOLLOW_par_in_comp171

FOLLOW_seq_in_comp181

public static final org.antlr.runtime.BitSet FOLLOW_seq_in_comp181

FOLLOW_8_in_optcall213

public static final org.antlr.runtime.BitSet FOLLOW_8_in_optcall213

FOLLOW_IDENT_in_optcall215

public static final org.antlr.runtime.BitSet FOLLOW_IDENT_in_optcall215

FOLLOW_expr_in_optcall217

public static final org.antlr.runtime.BitSet FOLLOW_expr_in_optcall217

FOLLOW_comp_in_optcall221

public static final org.antlr.runtime.BitSet FOLLOW_comp_in_optcall221

FOLLOW_9_in_optcall223

public static final org.antlr.runtime.BitSet FOLLOW_9_in_optcall223

FOLLOW_8_in_parcall263

public static final org.antlr.runtime.BitSet FOLLOW_8_in_parcall263

FOLLOW_IDENT_in_parcall265

public static final org.antlr.runtime.BitSet FOLLOW_IDENT_in_parcall265

FOLLOW_expr_in_parcall267

public static final org.antlr.runtime.BitSet FOLLOW_expr_in_parcall267

FOLLOW_comp_in_parcall271

public static final org.antlr.runtime.BitSet FOLLOW_comp_in_parcall271

FOLLOW_9_in_parcall273

public static final org.antlr.runtime.BitSet FOLLOW_9_in_parcall273

FOLLOW_apply_in_seqcall303

public static final org.antlr.runtime.BitSet FOLLOW_apply_in_seqcall303

FOLLOW_part_in_seqcall313

public static final org.antlr.runtime.BitSet FOLLOW_part_in_seqcall313

FOLLOW_prim_in_seqcall324

public static final org.antlr.runtime.BitSet FOLLOW_prim_in_seqcall324

FOLLOW_8_in_expr362

public static final org.antlr.runtime.BitSet FOLLOW_8_in_expr362

FOLLOW_IDENT_in_expr364

public static final org.antlr.runtime.BitSet FOLLOW_IDENT_in_expr364

FOLLOW_list_elem_in_expr368

public static final org.antlr.runtime.BitSet FOLLOW_list_elem_in_expr368

FOLLOW_expr_in_expr373

public static final org.antlr.runtime.BitSet FOLLOW_expr_in_expr373

FOLLOW_9_in_expr379

public static final org.antlr.runtime.BitSet FOLLOW_9_in_expr379

FOLLOW_10_in_expr397

public static final org.antlr.runtime.BitSet FOLLOW_10_in_expr397

FOLLOW_list_elem_in_expr401

public static final org.antlr.runtime.BitSet FOLLOW_list_elem_in_expr401

FOLLOW_8_in_apply441

public static final org.antlr.runtime.BitSet FOLLOW_8_in_apply441

FOLLOW_IDENT_in_apply443

public static final org.antlr.runtime.BitSet FOLLOW_IDENT_in_apply443

FOLLOW_expr_in_apply445

public static final org.antlr.runtime.BitSet FOLLOW_expr_in_apply445

FOLLOW_9_in_apply447

public static final org.antlr.runtime.BitSet FOLLOW_9_in_apply447

FOLLOW_8_in_part487

public static final org.antlr.runtime.BitSet FOLLOW_8_in_part487

FOLLOW_IDENT_in_part489

public static final org.antlr.runtime.BitSet FOLLOW_IDENT_in_part489

FOLLOW_divisibility_in_part491

public static final org.antlr.runtime.BitSet FOLLOW_divisibility_in_part491

FOLLOW_expr_in_part495

public static final org.antlr.runtime.BitSet FOLLOW_expr_in_part495

FOLLOW_comp_in_part499

public static final org.antlr.runtime.BitSet FOLLOW_comp_in_part499

FOLLOW_9_in_part501

public static final org.antlr.runtime.BitSet FOLLOW_9_in_part501

FOLLOW_10_in_divisibility543

public static final org.antlr.runtime.BitSet FOLLOW_10_in_divisibility543

FOLLOW_IDENT_in_divisibility545

public static final org.antlr.runtime.BitSet FOLLOW_IDENT_in_divisibility545

FOLLOW_10_in_divisibility565

public static final org.antlr.runtime.BitSet FOLLOW_10_in_divisibility565

FOLLOW_IDENT_in_divisibility567

public static final org.antlr.runtime.BitSet FOLLOW_IDENT_in_divisibility567

FOLLOW_10_in_divisibility587

public static final org.antlr.runtime.BitSet FOLLOW_10_in_divisibility587

FOLLOW_IDENT_in_divisibility589

public static final org.antlr.runtime.BitSet FOLLOW_IDENT_in_divisibility589

FOLLOW_8_in_prim627

public static final org.antlr.runtime.BitSet FOLLOW_8_in_prim627

FOLLOW_IDENT_in_prim629

public static final org.antlr.runtime.BitSet FOLLOW_IDENT_in_prim629

FOLLOW_in_out_num_in_prim633

public static final org.antlr.runtime.BitSet FOLLOW_in_out_num_in_prim633

FOLLOW_11_in_prim635

public static final org.antlr.runtime.BitSet FOLLOW_11_in_prim635

FOLLOW_in_out_num_in_prim639

public static final org.antlr.runtime.BitSet FOLLOW_in_out_num_in_prim639

FOLLOW_11_in_prim641

public static final org.antlr.runtime.BitSet FOLLOW_11_in_prim641

FOLLOW_in_out_dir_in_prim645

public static final org.antlr.runtime.BitSet FOLLOW_in_out_dir_in_prim645

FOLLOW_11_in_prim647

public static final org.antlr.runtime.BitSet FOLLOW_11_in_prim647

FOLLOW_number_in_prim659

public static final org.antlr.runtime.BitSet FOLLOW_number_in_prim659

FOLLOW_prim_flags_in_prim663

public static final org.antlr.runtime.BitSet FOLLOW_prim_flags_in_prim663

FOLLOW_9_in_prim665

public static final org.antlr.runtime.BitSet FOLLOW_9_in_prim665

FOLLOW_11_in_prim_flags704

public static final org.antlr.runtime.BitSet FOLLOW_11_in_prim_flags704

FOLLOW_prim_flag_in_prim_flags706

public static final org.antlr.runtime.BitSet FOLLOW_prim_flag_in_prim_flags706

FOLLOW_IDENT_in_prim_flag743

public static final org.antlr.runtime.BitSet FOLLOW_IDENT_in_prim_flag743

FOLLOW_8_in_if_776

public static final org.antlr.runtime.BitSet FOLLOW_8_in_if_776

FOLLOW_IDENT_in_if_778

public static final org.antlr.runtime.BitSet FOLLOW_IDENT_in_if_778

FOLLOW_ifwhen_in_if_780

public static final org.antlr.runtime.BitSet FOLLOW_ifwhen_in_if_780

FOLLOW_expr_in_if_782

public static final org.antlr.runtime.BitSet FOLLOW_expr_in_if_782

FOLLOW_comp_in_if_786

public static final org.antlr.runtime.BitSet FOLLOW_comp_in_if_786

FOLLOW_STRING_in_if_791

public static final org.antlr.runtime.BitSet FOLLOW_STRING_in_if_791

FOLLOW_number_in_if_796

public static final org.antlr.runtime.BitSet FOLLOW_number_in_if_796

FOLLOW_9_in_if_802

public static final org.antlr.runtime.BitSet FOLLOW_9_in_if_802

FOLLOW_10_in_ifwhen844

public static final org.antlr.runtime.BitSet FOLLOW_10_in_ifwhen844

FOLLOW_IDENT_in_ifwhen846

public static final org.antlr.runtime.BitSet FOLLOW_IDENT_in_ifwhen846

FOLLOW_10_in_ifwhen866

public static final org.antlr.runtime.BitSet FOLLOW_10_in_ifwhen866

FOLLOW_IDENT_in_ifwhen868

public static final org.antlr.runtime.BitSet FOLLOW_IDENT_in_ifwhen868

FOLLOW_8_in_in900

public static final org.antlr.runtime.BitSet FOLLOW_8_in_in900

FOLLOW_IDENT_in_in902

public static final org.antlr.runtime.BitSet FOLLOW_IDENT_in_in902

FOLLOW_expr_in_in906

public static final org.antlr.runtime.BitSet FOLLOW_expr_in_in906

FOLLOW_comp_in_in910

public static final org.antlr.runtime.BitSet FOLLOW_comp_in_in910

FOLLOW_9_in_in912

public static final org.antlr.runtime.BitSet FOLLOW_9_in_in912

FOLLOW_8_in_opt957

public static final org.antlr.runtime.BitSet FOLLOW_8_in_opt957

FOLLOW_IDENT_in_opt959

public static final org.antlr.runtime.BitSet FOLLOW_IDENT_in_opt959

FOLLOW_optcall_in_opt962

public static final org.antlr.runtime.BitSet FOLLOW_optcall_in_opt962

FOLLOW_9_in_opt968

public static final org.antlr.runtime.BitSet FOLLOW_9_in_opt968

FOLLOW_8_in_par1013

public static final org.antlr.runtime.BitSet FOLLOW_8_in_par1013

FOLLOW_IDENT_in_par1015

public static final org.antlr.runtime.BitSet FOLLOW_IDENT_in_par1015

FOLLOW_parcall_in_par1018

public static final org.antlr.runtime.BitSet FOLLOW_parcall_in_par1018

FOLLOW_9_in_par1024

public static final org.antlr.runtime.BitSet FOLLOW_9_in_par1024

FOLLOW_8_in_seq1069

public static final org.antlr.runtime.BitSet FOLLOW_8_in_seq1069

FOLLOW_IDENT_in_seq1071

public static final org.antlr.runtime.BitSet FOLLOW_IDENT_in_seq1071

FOLLOW_seqcall_in_seq1074

public static final org.antlr.runtime.BitSet FOLLOW_seqcall_in_seq1074

FOLLOW_9_in_seq1080

public static final org.antlr.runtime.BitSet FOLLOW_9_in_seq1080

FOLLOW_12_in_string_list1118

public static final org.antlr.runtime.BitSet FOLLOW_12_in_string_list1118

FOLLOW_list_elem_in_string_list1122

public static final org.antlr.runtime.BitSet FOLLOW_list_elem_in_string_list1122

FOLLOW_11_in_string_list1136

public static final org.antlr.runtime.BitSet FOLLOW_11_in_string_list1136

FOLLOW_list_elem_in_string_list1140

public static final org.antlr.runtime.BitSet FOLLOW_list_elem_in_string_list1140

FOLLOW_13_in_string_list1147

public static final org.antlr.runtime.BitSet FOLLOW_13_in_string_list1147

FOLLOW_simple_words_in_list_elem1169

public static final org.antlr.runtime.BitSet FOLLOW_simple_words_in_list_elem1169

FOLLOW_STRING_in_list_elem1179

public static final org.antlr.runtime.BitSet FOLLOW_STRING_in_list_elem1179

FOLLOW_opt_sign_in_number1230

public static final org.antlr.runtime.BitSet FOLLOW_opt_sign_in_number1230

FOLLOW_integer_in_number1235

public static final org.antlr.runtime.BitSet FOLLOW_integer_in_number1235

FOLLOW_fraction_in_number1239

public static final org.antlr.runtime.BitSet FOLLOW_fraction_in_number1239

FOLLOW_opt_sign_in_number1257

public static final org.antlr.runtime.BitSet FOLLOW_opt_sign_in_number1257

FOLLOW_integer_in_number1259

public static final org.antlr.runtime.BitSet FOLLOW_integer_in_number1259

FOLLOW_14_in_opt_sign1291

public static final org.antlr.runtime.BitSet FOLLOW_14_in_opt_sign1291

FOLLOW_15_in_opt_sign1301

public static final org.antlr.runtime.BitSet FOLLOW_15_in_opt_sign1301

FOLLOW_integer_in_fraction1337

public static final org.antlr.runtime.BitSet FOLLOW_integer_in_fraction1337

FOLLOW_16_in_fraction1339

public static final org.antlr.runtime.BitSet FOLLOW_16_in_fraction1339

FOLLOW_integer_in_fraction1343

public static final org.antlr.runtime.BitSet FOLLOW_integer_in_fraction1343

FOLLOW_INT_in_integer1375

public static final org.antlr.runtime.BitSet FOLLOW_INT_in_integer1375

FOLLOW_in_out_in_in_out_num1407

public static final org.antlr.runtime.BitSet FOLLOW_in_out_in_in_out_num1407

FOLLOW_number_in_in_out_num1410

public static final org.antlr.runtime.BitSet FOLLOW_number_in_in_out_num1410

FOLLOW_in_out_in_in_out_dir1441

public static final org.antlr.runtime.BitSet FOLLOW_in_out_in_in_out_dir1441

FOLLOW_rotation_in_in_out_dir1444

public static final org.antlr.runtime.BitSet FOLLOW_rotation_in_in_out_dir1444

FOLLOW_IDENT_in_rotation1482

public static final org.antlr.runtime.BitSet FOLLOW_IDENT_in_rotation1482

FOLLOW_opt_sign_in_rotation1490

public static final org.antlr.runtime.BitSet FOLLOW_opt_sign_in_rotation1490

FOLLOW_fraction_in_rotation1492

public static final org.antlr.runtime.BitSet FOLLOW_fraction_in_rotation1492

FOLLOW_IDENT_in_in_out1530

public static final org.antlr.runtime.BitSet FOLLOW_IDENT_in_in_out1530

FOLLOW_IDENT_in_in_out1550

public static final org.antlr.runtime.BitSet FOLLOW_IDENT_in_in_out1550

FOLLOW_IDENT_in_simple_word1574

public static final org.antlr.runtime.BitSet FOLLOW_IDENT_in_simple_word1574

FOLLOW_number_in_simple_word1584

public static final org.antlr.runtime.BitSet FOLLOW_number_in_simple_word1584

FOLLOW_simple_word_in_simple_words1615

public static final org.antlr.runtime.BitSet FOLLOW_simple_word_in_simple_words1615

FOLLOW_simple_word_in_simple_words1630

public static final org.antlr.runtime.BitSet FOLLOW_simple_word_in_simple_words1630

FOLLOW_opt_sign_in_synpred1_Ast1207

public static final org.antlr.runtime.BitSet FOLLOW_opt_sign_in_synpred1_Ast1207

FOLLOW_INT_in_synpred1_Ast1210

public static final org.antlr.runtime.BitSet FOLLOW_INT_in_synpred1_Ast1210

FOLLOW_INT_in_synpred1_Ast1214

public static final org.antlr.runtime.BitSet FOLLOW_INT_in_synpred1_Ast1214

FOLLOW_16_in_synpred1_Ast1216

public static final org.antlr.runtime.BitSet FOLLOW_16_in_synpred1_Ast1216

FOLLOW_INT_in_synpred1_Ast1218

public static final org.antlr.runtime.BitSet FOLLOW_INT_in_synpred1_Ast1218
Constructor Detail

AstParser

public AstParser(org.antlr.runtime.TokenStream input)

AstParser

public AstParser(org.antlr.runtime.TokenStream input,
                 org.antlr.runtime.RecognizerSharedState state)

AstParser

public AstParser(String s)
Method Detail

getTokenNames

public String[] getTokenNames()
Overrides:
getTokenNames in class org.antlr.runtime.BaseRecognizer

getGrammarFileName

public String getGrammarFileName()
Overrides:
getGrammarFileName in class org.antlr.runtime.BaseRecognizer

start

public final AstNode start()
                    throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

ast

public final AstNode ast()
                  throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

comp

public final Comp comp()
                throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

optcall

public final OptCall optcall()
                      throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

parcall

public final ParCall parcall()
                      throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

seqcall

public final SeqCall seqcall()
                      throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

expr

public final Expr expr()
                throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

apply

public final Apply apply()
                  throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

part

public final Part part()
                throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

divisibility

public final Part.Divisibility divisibility()
                                     throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

prim

public final Prim prim()
                throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

prim_flags

public final Set<Prim.Flag> prim_flags()
                                throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

prim_flag

public final Prim.Flag prim_flag()
                          throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

if_

public final If if_()
             throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

ifwhen

public final If.When ifwhen()
                     throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

in

public final In in()
            throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

opt

public final Opt opt()
              throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

par

public final Par par()
              throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

seq

public final Seq seq()
              throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

string_list

public final List<String> string_list()
                               throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

list_elem

public final String list_elem()
                       throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

number

public final Fraction number()
                      throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

opt_sign

public final boolean opt_sign()
                       throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

fraction

public final Fraction fraction()
                        throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

integer

public final Integer integer()
                      throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

in_out_num

public final AstParser.in_out_num_return in_out_num()
                                             throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

in_out_dir

public final AstParser.in_out_dir_return in_out_dir()
                                             throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

rotation

public final AstParser.rotation_return rotation()
                                         throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

in_out

public final AstParser.in_out_return in_out()
                                     throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

simple_word

public final String simple_word()
                         throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

simple_words

public final String simple_words()
                          throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

synpred1_Ast_fragment

public final void synpred1_Ast_fragment()
                                 throws org.antlr.runtime.RecognitionException
Throws:
org.antlr.runtime.RecognitionException

synpred1_Ast

public final boolean synpred1_Ast()

sdr 0.7

Copyright © 2006-2009 C. Scott Ananian