Class: MODL::Parser::MODLParser
- Inherits:
-
Antlr4::Runtime::Parser
- Object
- Antlr4::Runtime::Parser
- MODL::Parser::MODLParser
- Defined in:
- lib/modl/parser/MODLParser.rb
Defined Under Namespace
Classes: ModlContext, Modl_arrayContext, Modl_array_conditionalContext, Modl_array_conditional_returnContext, Modl_array_itemContext, Modl_array_value_itemContext, Modl_conditionContext, Modl_condition_groupContext, Modl_condition_testContext, Modl_mapContext, Modl_map_conditionalContext, Modl_map_conditional_returnContext, Modl_map_itemContext, Modl_nb_arrayContext, Modl_operatorContext, Modl_pairContext, Modl_primitiveContext, Modl_structureContext, Modl_top_level_conditionalContext, Modl_top_level_conditional_returnContext, Modl_valueContext, Modl_value_conditionalContext, Modl_value_conditional_returnContext, Modl_value_itemContext
Constant Summary collapse
- WS =
1
- NULL =
2
- TRUE =
3
- FALSE =
4
- COLON =
5
- EQUALS =
6
- STRUCT_SEP =
7
- ARR_SEP =
8
- LBRAC =
9
- RBRAC =
10
- LSBRAC =
11
- RSBRAC =
12
- NUMBER =
13
- COMMENT =
14
- QUOTED =
15
- STRING =
16
- HASH_PREFIX =
17
- LCBRAC =
18
- CWS =
19
- QMARK =
20
- FSLASH =
21
- GTHAN =
22
- LTHAN =
23
- ASTERISK =
24
- AMP =
25
- PIPE =
26
- EXCLAM =
27
- CCOMMENT =
28
- RCBRAC =
29
- RULE_modl =
0
- RULE_modl_structure =
1
- RULE_modl_map =
2
- RULE_modl_array =
3
- RULE_modl_nb_array =
4
- RULE_modl_pair =
5
- RULE_modl_value_item =
6
- RULE_modl_top_level_conditional =
7
- RULE_modl_top_level_conditional_return =
8
- RULE_modl_map_conditional =
9
- RULE_modl_map_conditional_return =
10
- RULE_modl_map_item =
11
- RULE_modl_array_conditional =
12
- RULE_modl_array_conditional_return =
13
- RULE_modl_array_item =
14
- RULE_modl_value_conditional =
15
- RULE_modl_value_conditional_return =
16
- RULE_modl_condition_test =
17
- RULE_modl_operator =
18
- RULE_modl_condition =
19
- RULE_modl_condition_group =
20
- RULE_modl_value =
21
- RULE_modl_array_value_item =
22
- RULE_modl_primitive =
23
- @@_decisionToDFA =
[]
Antlr4::Runtime::PredictionContextCache.new()
- @@ruleNames =
[ "modl", "modl_structure", "modl_map", "modl_array", "modl_nb_array", "modl_pair", "modl_value_item", "modl_top_level_conditional", "modl_top_level_conditional_return", "modl_map_conditional", "modl_map_conditional_return", "modl_map_item", "modl_array_conditional", "modl_array_conditional_return", "modl_array_item", "modl_value_conditional", "modl_value_conditional_return", "modl_condition_test", "modl_operator", "modl_condition", "modl_condition_group", "modl_value", "modl_array_value_item", "modl_primitive" ]
- @@_LITERAL_NAMES =
[ nil, nil, nil, nil, nil, nil, nil, nil, "','", nil, nil, nil, nil, nil, nil, nil, nil, nil, "'{'", nil, "'?'", "'/'", "'>'", "'<'", "'*'", "'&'", "'|'", "'!'", nil, "'}'" ]
- @@_SYMBOLIC_NAMES =
[ nil, "WS", "NULL", "TRUE", "FALSE", "COLON", "EQUALS", "STRUCT_SEP", "ARR_SEP", "LBRAC", "RBRAC", "LSBRAC", "RSBRAC", "NUMBER", "COMMENT", "QUOTED", "STRING", "HASH_PREFIX", "LCBRAC", "CWS", "QMARK", "FSLASH", "GTHAN", "LTHAN", "ASTERISK", "AMP", "PIPE", "EXCLAM", "CCOMMENT", "RCBRAC" ]
- @@VOCABULARY =
Antlr4::Runtime::VocabularyImpl.new(@@_LITERAL_NAMES, @@_SYMBOLIC_NAMES)
- @@_serializedATN =
["\3\u608b\ua72a\u8133\ub9ed\u417c\u3be7\u7786\u5964", "\3\37\u0145\4\2\t\2\4\3\t\3\4\4\t\4\4\5\t\5\4\6\t\6\4\7\t\7\4\b\t\b", "\4\t\t\t\4\n\t\n\4\13\t\13\4\f\t\f\4\r\t\r\4\16\t\16\4\17\t\17\4\20", "\t\20\4\21\t\21\4\22\t\22\4\23\t\23\4\24\t\24\4\25\t\25\4\26\t\26\4", "\27\t\27\4\30\t\30\4\31\t\31\3\2\5\2\64\n\2\3\2\3\2\3\2\7\29\n\2\f", "\2\16\2<\13\2\3\2\5\2?\n\2\5\2A\n\2\3\2\3\2\3\3\3\3\3\3\3\3\5\3I\n", "\3\3\4\3\4\3\4\3\4\7\4O\n\4\f\4\16\4R\13\4\5\4T\n\4\3\4\3\4\3\5\3\5", "\3\5\5\5[\n\5\3\5\6\5^\n\5\r\5\16\5_\3\5\3\5\5\5d\n\5\3\5\7\5g\n\5", "\f\5\16\5j\13\5\7\5l\n\5\f\5\16\5o\13\5\5\5q\n\5\3\5\3\5\3\6\3\6\6", "\6w\n\6\r\6\16\6x\6\6{\n\6\r\6\16\6|\3\6\7\6\u0080\n\6\f\6\16\6\u0083", "\13\6\3\6\5\6\u0086\n\6\3\7\3\7\3\7\3\7\3\7\3\7\3\7\5\7\u008f\n\7\3", "\b\3\b\5\b\u0093\n\b\3\t\3\t\3\t\3\t\3\t\3\t\5\t\u009b\n\t\3\t\3\t", "\7\t\u009f\n\t\f\t\16\t\u00a2\13\t\3\t\3\t\3\n\7\n\u00a7\n\n\f\n\16", "\n\u00aa\13\n\3\13\3\13\3\13\3\13\3\13\3\13\5\13\u00b2\n\13\3\13\3", "\13\7\13\u00b6\n\13\f\13\16\13\u00b9\13\13\3\13\3\13\3\f\6\f\u00be", "\n\f\r\f\16\f\u00bf\3\r\3\r\5\r\u00c4\n\r\3\16\3\16\3\16\3\16\3\16", "\3\16\5\16\u00cc\n\16\3\16\3\16\7\16\u00d0\n\16\f\16\16\16\u00d3\13", "\16\3\16\3\16\3\17\6\17\u00d8\n\17\r\17\16\17\u00d9\3\20\3\20\5\20", "\u00de\n\20\3\21\3\21\3\21\3\21\3\21\3\21\3\21\3\21\3\21\7\21\u00e9", "\n\21\f\21\16\21\u00ec\13\21\3\21\3\21\3\21\3\21\5\21\u00f2\n\21\3", "\21\3\21\3\22\3\22\3\22\7\22\u00f9\n\22\f\22\16\22\u00fc\13\22\3\23", "\5\23\u00ff\n\23\3\23\3\23\5\23\u0103\n\23\3\23\3\23\5\23\u0107\n\23", "\3\23\3\23\5\23\u010b\n\23\7\23\u010d\n\23\f\23\16\23\u0110\13\23\3", "\24\3\24\3\24\3\24\3\24\3\24\3\24\3\24\3\24\5\24\u011b\n\24\3\25\5", "\25\u011e\n\25\3\25\5\25\u0121\n\25\3\25\3\25\3\25\7\25\u0126\n\25", "\f\25\16\25\u0129\13\25\3\26\3\26\3\26\3\26\7\26\u012f\n\26\f\26\16", "\26\u0132\13\26\3\26\3\26\3\27\3\27\3\27\3\27\3\27\5\27\u013b\n\27", "\3\30\3\30\3\30\3\30\5\30\u0141\n\30\3\31\3\31\3\31\2\2\32\2\4\6\b", "\n\f\16\20\22\24\26\30\32\34\36 \"$&(*,.\60\2\5\3\2\21\22\3\2\33\34", "\5\2\4\6\17\17\21\22\2\u0165\2@\3\2\2\2\4H\3\2\2\2\6J\3\2\2\2\bW\3", "\2\2\2\nz\3\2\2\2\f\u008e\3\2\2\2\16\u0092\3\2\2\2\20\u0094\3\2\2\2", "\22\u00a8\3\2\2\2\24\u00ab\3\2\2\2\26\u00bd\3\2\2\2\30\u00c3\3\2\2", "\2\32\u00c5\3\2\2\2\34\u00d7\3\2\2\2\36\u00dd\3\2\2\2 \u00df\3\2\2", "\2\"\u00f5\3\2\2\2$\u00fe\3\2\2\2&\u011a\3\2\2\2(\u011d\3\2\2\2*\u012a", "\3\2\2\2,\u013a\3\2\2\2.\u0140\3\2\2\2\60\u0142\3\2\2\2\62\64\5\4\3", "\2\63\62\3\2\2\2\63\64\3\2\2\2\64A\3\2\2\2\65:\5\4\3\2\66\67\7\t\2", "\2\679\5\4\3\28\66\3\2\2\29<\3\2\2\2:8\3\2\2\2:;\3\2\2\2;>\3\2\2\2", "<:\3\2\2\2=?\7\t\2\2>=\3\2\2\2>?\3\2\2\2?A\3\2\2\2@\63\3\2\2\2@\65", "\3\2\2\2AB\3\2\2\2BC\7\2\2\3C\3\3\2\2\2DI\5\6\4\2EI\5\b\5\2FI\5\20", "\t\2GI\5\f\7\2HD\3\2\2\2HE\3\2\2\2HF\3\2\2\2HG\3\2\2\2I\5\3\2\2\2J", "S\7\13\2\2KP\5\30\r\2LM\7\t\2\2MO\5\30\r\2NL\3\2\2\2OR\3\2\2\2PN\3", "\2\2\2PQ\3\2\2\2QT\3\2\2\2RP\3\2\2\2SK\3\2\2\2ST\3\2\2\2TU\3\2\2\2", "UV\7\f\2\2V\7\3\2\2\2Wp\7\r\2\2X[\5\36\20\2Y[\5\n\6\2ZX\3\2\2\2ZY\3", "\2\2\2[m\3\2\2\2\\^\7\t\2\2]\\\3\2\2\2^_\3\2\2\2_]\3\2\2\2_`\3\2\2", "\2`c\3\2\2\2ad\5\36\20\2bd\5\n\6\2ca\3\2\2\2cb\3\2\2\2dh\3\2\2\2eg", "\7\t\2\2fe\3\2\2\2gj\3\2\2\2hf\3\2\2\2hi\3\2\2\2il\3\2\2\2jh\3\2\2", "\2k]\3\2\2\2lo\3\2\2\2mk\3\2\2\2mn\3\2\2\2nq\3\2\2\2om\3\2\2\2pZ\3", "\2\2\2pq\3\2\2\2qr\3\2\2\2rs\7\16\2\2s\t\3\2\2\2tv\5\36\20\2uw\7\7", "\2\2vu\3\2\2\2wx\3\2\2\2xv\3\2\2\2xy\3\2\2\2y{\3\2\2\2zt\3\2\2\2{|", "\3\2\2\2|z\3\2\2\2|}\3\2\2\2}\u0081\3\2\2\2~\u0080\5\36\20\2\177~\3", "\2\2\2\u0080\u0083\3\2\2\2\u0081\177\3\2\2\2\u0081\u0082\3\2\2\2\u0082", "\u0085\3\2\2\2\u0083\u0081\3\2\2\2\u0084\u0086\7\7\2\2\u0085\u0084", "\3\2\2\2\u0085\u0086\3\2\2\2\u0086\13\3\2\2\2\u0087\u0088\t\2\2\2\u0088", "\u0089\7\b\2\2\u0089\u008f\5\16\b\2\u008a\u008b\7\22\2\2\u008b\u008f", "\5\6\4\2\u008c\u008d\7\22\2\2\u008d\u008f\5\b\5\2\u008e\u0087\3\2\2", "\2\u008e\u008a\3\2\2\2\u008e\u008c\3\2\2\2\u008f\r\3\2\2\2\u0090\u0093", "\5,\27\2\u0091\u0093\5 \21\2\u0092\u0090\3\2\2\2\u0092\u0091\3\2\2", "\2\u0093\17\3\2\2\2\u0094\u0095\7\24\2\2\u0095\u0096\5$\23\2\u0096", "\u0097\7\26\2\2\u0097\u00a0\5\22\n\2\u0098\u009a\7\27\2\2\u0099\u009b", "\5$\23\2\u009a\u0099\3\2\2\2\u009a\u009b\3\2\2\2\u009b\u009c\3\2\2", "\2\u009c\u009d\7\26\2\2\u009d\u009f\5\22\n\2\u009e\u0098\3\2\2\2\u009f", "\u00a2\3\2\2\2\u00a0\u009e\3\2\2\2\u00a0\u00a1\3\2\2\2\u00a1\u00a3", "\3\2\2\2\u00a2\u00a0\3\2\2\2\u00a3\u00a4\7\37\2\2\u00a4\21\3\2\2\2", "\u00a5\u00a7\5\4\3\2\u00a6\u00a5\3\2\2\2\u00a7\u00aa\3\2\2\2\u00a8", "\u00a6\3\2\2\2\u00a8\u00a9\3\2\2\2\u00a9\23\3\2\2\2\u00aa\u00a8\3\2", "\2\2\u00ab\u00ac\7\24\2\2\u00ac\u00ad\5$\23\2\u00ad\u00ae\7\26\2\2", "\u00ae\u00b7\5\26\f\2\u00af\u00b1\7\27\2\2\u00b0\u00b2\5$\23\2\u00b1", "\u00b0\3\2\2\2\u00b1\u00b2\3\2\2\2\u00b2\u00b3\3\2\2\2\u00b3\u00b4", "\7\26\2\2\u00b4\u00b6\5\26\f\2\u00b5\u00af\3\2\2\2\u00b6\u00b9\3\2", "\2\2\u00b7\u00b5\3\2\2\2\u00b7\u00b8\3\2\2\2\u00b8\u00ba\3\2\2\2\u00b9", "\u00b7\3\2\2\2\u00ba\u00bb\7\37\2\2\u00bb\25\3\2\2\2\u00bc\u00be\5", "\30\r\2\u00bd\u00bc\3\2\2\2\u00be\u00bf\3\2\2\2\u00bf\u00bd\3\2\2\2", "\u00bf\u00c0\3\2\2\2\u00c0\27\3\2\2\2\u00c1\u00c4\5\f\7\2\u00c2\u00c4", "\5\24\13\2\u00c3\u00c1\3\2\2\2\u00c3\u00c2\3\2\2\2\u00c4\31\3\2\2\2", "\u00c5\u00c6\7\24\2\2\u00c6\u00c7\5$\23\2\u00c7\u00c8\7\26\2\2\u00c8", "\u00d1\5\34\17\2\u00c9\u00cb\7\27\2\2\u00ca\u00cc\5$\23\2\u00cb\u00ca", "\3\2\2\2\u00cb\u00cc\3\2\2\2\u00cc\u00cd\3\2\2\2\u00cd\u00ce\7\26\2", "\2\u00ce\u00d0\5\34\17\2\u00cf\u00c9\3\2\2\2\u00d0\u00d3\3\2\2\2\u00d1", "\u00cf\3\2\2\2\u00d1\u00d2\3\2\2\2\u00d2\u00d4\3\2\2\2\u00d3\u00d1", "\3\2\2\2\u00d4\u00d5\7\37\2\2\u00d5\33\3\2\2\2\u00d6\u00d8\5\36\20", "\2\u00d7\u00d6\3\2\2\2\u00d8\u00d9\3\2\2\2\u00d9\u00d7\3\2\2\2\u00d9", "\u00da\3\2\2\2\u00da\35\3\2\2\2\u00db\u00de\5.\30\2\u00dc\u00de\5\32", "\16\2\u00dd\u00db\3\2\2\2\u00dd\u00dc\3\2\2\2\u00de\37\3\2\2\2\u00df", "\u00e0\7\24\2\2\u00e0\u00e1\5$\23\2\u00e1\u00f1\7\26\2\2\u00e2\u00ea", "\5\"\22\2\u00e3\u00e4\7\27\2\2\u00e4\u00e5\5$\23\2\u00e5\u00e6\7\26", "\2\2\u00e6\u00e7\5\"\22\2\u00e7\u00e9\3\2\2\2\u00e8\u00e3\3\2\2\2\u00e9", "\u00ec\3\2\2\2\u00ea\u00e8\3\2\2\2\u00ea\u00eb\3\2\2\2\u00eb\u00ed", "\3\2\2\2\u00ec\u00ea\3\2\2\2\u00ed\u00ee\7\27\2\2\u00ee\u00ef\7\26", "\2\2\u00ef\u00f0\5\"\22\2\u00f0\u00f2\3\2\2\2\u00f1\u00e2\3\2\2\2\u00f1", "\u00f2\3\2\2\2\u00f2\u00f3\3\2\2\2\u00f3\u00f4\7\37\2\2\u00f4!\3\2", "\2\2\u00f5\u00fa\5\16\b\2\u00f6\u00f7\7\7\2\2\u00f7\u00f9\5\16\b\2", "\u00f8\u00f6\3\2\2\2\u00f9\u00fc\3\2\2\2\u00fa\u00f8\3\2\2\2\u00fa", "\u00fb\3\2\2\2\u00fb#\3\2\2\2\u00fc\u00fa\3\2\2\2\u00fd\u00ff\7\35", "\2\2\u00fe\u00fd\3\2\2\2\u00fe\u00ff\3\2\2\2\u00ff\u0102\3\2\2\2\u0100", "\u0103\5(\25\2\u0101\u0103\5*\26\2\u0102\u0100\3\2\2\2\u0102\u0101", "\3\2\2\2\u0103\u010e\3\2\2\2\u0104\u0106\t\3\2\2\u0105\u0107\7\35\2", "\2\u0106\u0105\3\2\2\2\u0106\u0107\3\2\2\2\u0107\u010a\3\2\2\2\u0108", "\u010b\5(\25\2\u0109\u010b\5*\26\2\u010a\u0108\3\2\2\2\u010a\u0109", "\3\2\2\2\u010b\u010d\3\2\2\2\u010c\u0104\3\2\2\2\u010d\u0110\3\2\2", "\2\u010e\u010c\3\2\2\2\u010e\u010f\3\2\2\2\u010f%\3\2\2\2\u0110\u010e", "\3\2\2\2\u0111\u011b\7\b\2\2\u0112\u011b\7\30\2\2\u0113\u0114\7\30", "\2\2\u0114\u011b\7\b\2\2\u0115\u011b\7\31\2\2\u0116\u0117\7\31\2\2", "\u0117\u011b\7\b\2\2\u0118\u0119\7\35\2\2\u0119\u011b\7\b\2\2\u011a", "\u0111\3\2\2\2\u011a\u0112\3\2\2\2\u011a\u0113\3\2\2\2\u011a\u0115", "\3\2\2\2\u011a\u0116\3\2\2\2\u011a\u0118\3\2\2\2\u011b\'\3\2\2\2\u011c", "\u011e\7\22\2\2\u011d\u011c\3\2\2\2\u011d\u011e\3\2\2\2\u011e\u0120", "\3\2\2\2\u011f\u0121\5&\24\2\u0120\u011f\3\2\2\2\u0120\u0121\3\2\2", "\2\u0121\u0122\3\2\2\2\u0122\u0127\5,\27\2\u0123\u0124\7\27\2\2\u0124", "\u0126\5,\27\2\u0125\u0123\3\2\2\2\u0126\u0129\3\2\2\2\u0127\u0125", "\3\2\2\2\u0127\u0128\3\2\2\2\u0128)\3\2\2\2\u0129\u0127\3\2\2\2\u012a", "\u012b\7\24\2\2\u012b\u0130\5$\23\2\u012c\u012d\t\3\2\2\u012d\u012f", "\5$\23\2\u012e\u012c\3\2\2\2\u012f\u0132\3\2\2\2\u0130\u012e\3\2\2", "\2\u0130\u0131\3\2\2\2\u0131\u0133\3\2\2\2\u0132\u0130\3\2\2\2\u0133", "\u0134\7\37\2\2\u0134+\3\2\2\2\u0135\u013b\5\6\4\2\u0136\u013b\5\b", "\5\2\u0137\u013b\5\n\6\2\u0138\u013b\5\f\7\2\u0139\u013b\5\60\31\2", "\u013a\u0135\3\2\2\2\u013a\u0136\3\2\2\2\u013a\u0137\3\2\2\2\u013a", "\u0138\3\2\2\2\u013a\u0139\3\2\2\2\u013b-\3\2\2\2\u013c\u0141\5\6\4", "\2\u013d\u0141\5\f\7\2\u013e\u0141\5\b\5\2\u013f\u0141\5\60\31\2\u0140", "\u013c\3\2\2\2\u0140\u013d\3\2\2\2\u0140\u013e\3\2\2\2\u0140\u013f", "\3\2\2\2\u0141/\3\2\2\2\u0142\u0143\t\4\2\2\u0143\61\3\2\2\2/\63:>", "@HPSZ_chmpx|\u0081\u0085\u008e\u0092\u009a\u00a0\u00a8\u00b1\u00b7", "\u00bf\u00c3\u00cb\u00d1\u00d9\u00dd\u00ea\u00f1\u00fa\u00fe\u0102", "\u0106\u010a\u010e\u011a\u011d\u0120\u0127\u0130\u013a\u0140"].join("")
- @@_ATN =
Antlr4::Runtime::ATNDeserializer.new().deserialize(@@_serializedATN)
Instance Method Summary collapse
- #atn ⇒ Object
- #get_vocabulary ⇒ Object
- #getGrammarFileName ⇒ Object
-
#initialize(input) ⇒ MODLParser
constructor
A new instance of MODLParser.
- #modl ⇒ Object
- #modl_array ⇒ Object
- #modl_array_conditional ⇒ Object
- #modl_array_conditional_return ⇒ Object
- #modl_array_item ⇒ Object
- #modl_array_value_item ⇒ Object
- #modl_condition ⇒ Object
- #modl_condition_group ⇒ Object
- #modl_condition_test ⇒ Object
- #modl_map ⇒ Object
- #modl_map_conditional ⇒ Object
- #modl_map_conditional_return ⇒ Object
- #modl_map_item ⇒ Object
- #modl_nb_array ⇒ Object
- #modl_operator ⇒ Object
- #modl_pair ⇒ Object
- #modl_primitive ⇒ Object
- #modl_structure ⇒ Object
- #modl_top_level_conditional ⇒ Object
- #modl_top_level_conditional_return ⇒ Object
- #modl_value ⇒ Object
- #modl_value_conditional ⇒ Object
- #modl_value_conditional_return ⇒ Object
- #modl_value_item ⇒ Object
- #rule_names ⇒ Object
- #serialized_atn ⇒ Object
Constructor Details
#initialize(input) ⇒ MODLParser
Returns a new instance of MODLParser.
117 118 119 120 121 122 123 124 125 126 |
# File 'lib/modl/parser/MODLParser.rb', line 117 def initialize( input) super(input) i = 0 while i < @@_ATN.number_of_decisions() @@_decisionToDFA[i] = Antlr4::Runtime::DFA.new(@@_ATN.decision_state(i), i) i+=1 end @_interp = Antlr4::Runtime::ParserATNSimulator.new(self,@@_ATN,@@_decisionToDFA,@@_sharedContextCache) end |
Instance Method Details
#atn ⇒ Object
113 114 115 |
# File 'lib/modl/parser/MODLParser.rb', line 113 def atn() return @@_ATN end |
#get_vocabulary ⇒ Object
97 98 99 |
# File 'lib/modl/parser/MODLParser.rb', line 97 def get_vocabulary @@VOCABULARY end |
#getGrammarFileName ⇒ Object
101 102 103 |
# File 'lib/modl/parser/MODLParser.rb', line 101 def getGrammarFileName() return "MODLParser.g4" end |
#modl ⇒ Object
170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 |
# File 'lib/modl/parser/MODLParser.rb', line 170 def modl() _localctx = ModlContext.new(@_ctx, @_state_number) enter_rule(_localctx, 0, RULE_modl) _la = 0 begin _alt = 0 enter_outer_alt(_localctx, 1) @_state_number = 62 @_err_handler.sync(self) case ( @_interp.adaptive_predict(@_input,3,@_ctx) ) when 1 @_state_number = 49 @_err_handler.sync(self) _la = @_input.la(1) if ((((_la) & ~0x3f) == 0 && ((1 << _la) & ((1 << LBRAC) | (1 << LSBRAC) | (1 << QUOTED) | (1 << STRING) | (1 << LCBRAC))) != 0)) @_state_number = 48 modl_structure() end when 2 @_state_number = 51 modl_structure() @_state_number = 56 @_err_handler.sync(self); _alt = @_interp.adaptive_predict(@_input,1,@_ctx) while ( _alt!=2 && _alt!=Antlr4::Runtime::ATN::INVALID_ALT_NUMBER ) if ( _alt==1 ) @_state_number = 52 match(STRUCT_SEP) @_state_number = 53 modl_structure() end @_state_number = 58 @_err_handler.sync(self) _alt = @_interp.adaptive_predict(@_input,1,@_ctx) end @_state_number = 60 @_err_handler.sync(self) _la = @_input.la(1) if (_la==STRUCT_SEP) @_state_number = 59 match(STRUCT_SEP) end end @_state_number = 64 match(EOF) rescue Antlr4::Runtime::RecognitionException => re _localctx.exception = re @_err_handler.report_error(self, re) @_err_handler.recover(self, re) ensure exit_rule() end return _localctx end |
#modl_array ⇒ Object
460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 |
# File 'lib/modl/parser/MODLParser.rb', line 460 def modl_array() _localctx = Modl_arrayContext.new(@_ctx, @_state_number) enter_rule(_localctx, 6, RULE_modl_array) _la = 0 begin _alt = 0 enter_outer_alt(_localctx, 1) @_state_number = 85 match(LSBRAC) @_state_number = 110 @_err_handler.sync(self) _la = @_input.la(1) if ((((_la) & ~0x3f) == 0 && ((1 << _la) & ((1 << NULL) | (1 << TRUE) | (1 << FALSE) | (1 << LBRAC) | (1 << LSBRAC) | (1 << NUMBER) | (1 << QUOTED) | (1 << STRING) | (1 << LCBRAC))) != 0)) @_state_number = 88 @_err_handler.sync(self) case ( @_interp.adaptive_predict(@_input,7,@_ctx) ) when 1 @_state_number = 86 modl_array_item() when 2 @_state_number = 87 modl_nb_array() end @_state_number = 107 @_err_handler.sync(self) _la = @_input.la(1) while (_la==STRUCT_SEP) @_state_number = 91 @_err_handler.sync(self) _la = @_input.la(1) loop do @_state_number = 90 match(STRUCT_SEP) @_state_number = 93 @_err_handler.sync(self) _la = @_input.la(1) break if (!( _la==STRUCT_SEP) ) end @_state_number = 97 @_err_handler.sync(self) case ( @_interp.adaptive_predict(@_input,9,@_ctx) ) when 1 @_state_number = 95 modl_array_item() when 2 @_state_number = 96 modl_nb_array() end @_state_number = 102 @_err_handler.sync(self); _alt = @_interp.adaptive_predict(@_input,10,@_ctx) while ( _alt!=2 && _alt!=Antlr4::Runtime::ATN::INVALID_ALT_NUMBER ) if ( _alt==1 ) @_state_number = 99 match(STRUCT_SEP) end @_state_number = 104 @_err_handler.sync(self) _alt = @_interp.adaptive_predict(@_input,10,@_ctx) end @_state_number = 109 @_err_handler.sync(self) _la = @_input.la(1) end end @_state_number = 112 match(RSBRAC) rescue Antlr4::Runtime::RecognitionException => re _localctx.exception = re @_err_handler.report_error(self, re) @_err_handler.recover(self, re) ensure exit_rule() end return _localctx end |
#modl_array_conditional ⇒ Object
1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 |
# File 'lib/modl/parser/MODLParser.rb', line 1298 def modl_array_conditional() _localctx = Modl_array_conditionalContext.new(@_ctx, @_state_number) enter_rule(_localctx, 24, RULE_modl_array_conditional) _la = 0 begin enter_outer_alt(_localctx, 1) @_state_number = 195 match(LCBRAC) @_state_number = 196 modl_condition_test() @_state_number = 197 match(QMARK) @_state_number = 198 modl_array_conditional_return() @_state_number = 207 @_err_handler.sync(self) _la = @_input.la(1) while (_la==FSLASH) @_state_number = 199 match(FSLASH) @_state_number = 201 @_err_handler.sync(self) _la = @_input.la(1) if ((((_la) & ~0x3f) == 0 && ((1 << _la) & ((1 << NULL) | (1 << TRUE) | (1 << FALSE) | (1 << EQUALS) | (1 << LBRAC) | (1 << LSBRAC) | (1 << NUMBER) | (1 << QUOTED) | (1 << STRING) | (1 << LCBRAC) | (1 << GTHAN) | (1 << LTHAN) | (1 << EXCLAM))) != 0)) @_state_number = 200 modl_condition_test() end @_state_number = 203 match(QMARK) @_state_number = 204 modl_array_conditional_return() @_state_number = 209 @_err_handler.sync(self) _la = @_input.la(1) end @_state_number = 210 match(RCBRAC) rescue Antlr4::Runtime::RecognitionException => re _localctx.exception = re @_err_handler.report_error(self, re) @_err_handler.recover(self, re) ensure exit_rule() end return _localctx end |
#modl_array_conditional_return ⇒ Object
1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 |
# File 'lib/modl/parser/MODLParser.rb', line 1383 def modl_array_conditional_return() _localctx = Modl_array_conditional_returnContext.new(@_ctx, @_state_number) enter_rule(_localctx, 26, RULE_modl_array_conditional_return) _la = 0 begin enter_outer_alt(_localctx, 1) @_state_number = 213 @_err_handler.sync(self) _la = @_input.la(1) loop do @_state_number = 212 modl_array_item() @_state_number = 215 @_err_handler.sync(self) _la = @_input.la(1) break if (!((((_la) & ~0x3f) == 0 && ((1 << _la) & ((1 << NULL) | (1 << TRUE) | (1 << FALSE) | (1 << LBRAC) | (1 << LSBRAC) | (1 << NUMBER) | (1 << QUOTED) | (1 << STRING) | (1 << LCBRAC))) != 0))) end rescue Antlr4::Runtime::RecognitionException => re _localctx.exception = re @_err_handler.report_error(self, re) @_err_handler.recover(self, re) ensure exit_rule() end return _localctx end |
#modl_array_item ⇒ Object
1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 |
# File 'lib/modl/parser/MODLParser.rb', line 1446 def modl_array_item() _localctx = Modl_array_itemContext.new(@_ctx, @_state_number) enter_rule(_localctx, 28, RULE_modl_array_item) begin @_state_number = 219 @_err_handler.sync(self) case (@_input.la(1)) when MODLParser::NULL, MODLParser::TRUE, MODLParser::FALSE, MODLParser::LBRAC, MODLParser::LSBRAC, MODLParser::NUMBER, MODLParser::QUOTED, MODLParser::STRING enter_outer_alt(_localctx, 1) @_state_number = 217 modl_array_value_item() when MODLParser::LCBRAC enter_outer_alt(_localctx, 2) @_state_number = 218 modl_array_conditional() else raise Antlr4::Runtime::NoViableAltException, self end rescue Antlr4::Runtime::RecognitionException => re _localctx.exception = re @_err_handler.report_error(self, re) @_err_handler.recover(self, re) ensure exit_rule() end return _localctx end |
#modl_array_value_item ⇒ Object
2235 2236 2237 2238 2239 2240 2241 2242 2243 2244 2245 2246 2247 2248 2249 2250 2251 2252 2253 2254 2255 2256 2257 2258 2259 2260 2261 2262 2263 2264 2265 2266 2267 2268 2269 2270 2271 2272 2273 2274 2275 |
# File 'lib/modl/parser/MODLParser.rb', line 2235 def modl_array_value_item() _localctx = Modl_array_value_itemContext.new(@_ctx, @_state_number) enter_rule(_localctx, 44, RULE_modl_array_value_item) begin @_state_number = 318 @_err_handler.sync(self) case ( @_interp.adaptive_predict(@_input,44,@_ctx) ) when 1 enter_outer_alt(_localctx, 1) @_state_number = 314 modl_map() when 2 enter_outer_alt(_localctx, 2) @_state_number = 315 modl_pair() when 3 enter_outer_alt(_localctx, 3) @_state_number = 316 modl_array() when 4 enter_outer_alt(_localctx, 4) @_state_number = 317 modl_primitive() end rescue Antlr4::Runtime::RecognitionException => re _localctx.exception = re @_err_handler.report_error(self, re) @_err_handler.recover(self, re) ensure exit_rule() end return _localctx end |
#modl_condition ⇒ Object
1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971 1972 1973 1974 1975 1976 1977 1978 1979 1980 1981 1982 1983 1984 1985 1986 1987 1988 1989 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 |
# File 'lib/modl/parser/MODLParser.rb', line 1957 def modl_condition() _localctx = Modl_conditionContext.new(@_ctx, @_state_number) enter_rule(_localctx, 38, RULE_modl_condition) _la = 0 begin enter_outer_alt(_localctx, 1) @_state_number = 283 @_err_handler.sync(self) case ( @_interp.adaptive_predict(@_input,39,@_ctx) ) when 1 @_state_number = 282 match(STRING) end @_state_number = 286 @_err_handler.sync(self) _la = @_input.la(1) if ((((_la) & ~0x3f) == 0 && ((1 << _la) & ((1 << EQUALS) | (1 << GTHAN) | (1 << LTHAN) | (1 << EXCLAM))) != 0)) @_state_number = 285 modl_operator() end @_state_number = 288 modl_value() @_state_number = 293 @_err_handler.sync(self) _la = @_input.la(1) while (_la==FSLASH) @_state_number = 289 match(FSLASH) @_state_number = 290 modl_value() @_state_number = 295 @_err_handler.sync(self) _la = @_input.la(1) end rescue Antlr4::Runtime::RecognitionException => re _localctx.exception = re @_err_handler.report_error(self, re) @_err_handler.recover(self, re) ensure exit_rule() end return _localctx end |
#modl_condition_group ⇒ Object
2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 2088 2089 2090 2091 2092 2093 2094 2095 2096 2097 2098 2099 2100 2101 2102 2103 2104 |
# File 'lib/modl/parser/MODLParser.rb', line 2059 def modl_condition_group() _localctx = Modl_condition_groupContext.new(@_ctx, @_state_number) enter_rule(_localctx, 40, RULE_modl_condition_group) _la = 0 begin enter_outer_alt(_localctx, 1) @_state_number = 296 match(LCBRAC) @_state_number = 297 modl_condition_test() @_state_number = 302 @_err_handler.sync(self) _la = @_input.la(1) while (_la==AMP || _la==PIPE) @_state_number = 298 _la = @_input.la(1) if ( !(_la==AMP || _la==PIPE) ) @_err_handler.recover_in_line(self) else if ( @_input.la(1)==Antlr4::Runtime::Token::EOF ) @matchedEOF = true end @_err_handler.report_match(self) consume() end @_state_number = 299 modl_condition_test() @_state_number = 304 @_err_handler.sync(self) _la = @_input.la(1) end @_state_number = 305 match(RCBRAC) rescue Antlr4::Runtime::RecognitionException => re _localctx.exception = re @_err_handler.report_error(self, re) @_err_handler.recover(self, re) ensure exit_rule() end return _localctx end |
#modl_condition_test ⇒ Object
1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 |
# File 'lib/modl/parser/MODLParser.rb', line 1725 def modl_condition_test() _localctx = Modl_condition_testContext.new(@_ctx, @_state_number) enter_rule(_localctx, 34, RULE_modl_condition_test) _la = 0 begin _alt = 0 enter_outer_alt(_localctx, 1) @_state_number = 252 @_err_handler.sync(self) case ( @_interp.adaptive_predict(@_input,33,@_ctx) ) when 1 @_state_number = 251 match(EXCLAM) end @_state_number = 256 @_err_handler.sync(self) case ( @_interp.adaptive_predict(@_input,34,@_ctx) ) when 1 @_state_number = 254 modl_condition() when 2 @_state_number = 255 modl_condition_group() end @_state_number = 268 @_err_handler.sync(self); _alt = @_interp.adaptive_predict(@_input,37,@_ctx) while ( _alt!=2 && _alt!=Antlr4::Runtime::ATN::INVALID_ALT_NUMBER ) if ( _alt==1 ) @_state_number = 258 _la = @_input.la(1) if ( !(_la==AMP || _la==PIPE) ) @_err_handler.recover_in_line(self) else if ( @_input.la(1)==Antlr4::Runtime::Token::EOF ) @matchedEOF = true end @_err_handler.report_match(self) consume() end @_state_number = 260 @_err_handler.sync(self) case ( @_interp.adaptive_predict(@_input,35,@_ctx) ) when 1 @_state_number = 259 match(EXCLAM) end @_state_number = 264 @_err_handler.sync(self) case ( @_interp.adaptive_predict(@_input,36,@_ctx) ) when 1 @_state_number = 262 modl_condition() when 2 @_state_number = 263 modl_condition_group() end end @_state_number = 270 @_err_handler.sync(self) _alt = @_interp.adaptive_predict(@_input,37,@_ctx) end rescue Antlr4::Runtime::RecognitionException => re _localctx.exception = re @_err_handler.report_error(self, re) @_err_handler.recover(self, re) ensure exit_rule() end return _localctx end |
#modl_map ⇒ Object
365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 |
# File 'lib/modl/parser/MODLParser.rb', line 365 def modl_map() _localctx = Modl_mapContext.new(@_ctx, @_state_number) enter_rule(_localctx, 4, RULE_modl_map) _la = 0 begin enter_outer_alt(_localctx, 1) @_state_number = 72 match(LBRAC) @_state_number = 81 @_err_handler.sync(self) _la = @_input.la(1) if ((((_la) & ~0x3f) == 0 && ((1 << _la) & ((1 << QUOTED) | (1 << STRING) | (1 << LCBRAC))) != 0)) @_state_number = 73 modl_map_item() @_state_number = 78 @_err_handler.sync(self) _la = @_input.la(1) while (_la==STRUCT_SEP) @_state_number = 74 match(STRUCT_SEP) @_state_number = 75 modl_map_item() @_state_number = 80 @_err_handler.sync(self) _la = @_input.la(1) end end @_state_number = 83 match(RBRAC) rescue Antlr4::Runtime::RecognitionException => re _localctx.exception = re @_err_handler.report_error(self, re) @_err_handler.recover(self, re) ensure exit_rule() end return _localctx end |
#modl_map_conditional ⇒ Object
1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 |
# File 'lib/modl/parser/MODLParser.rb', line 1062 def modl_map_conditional() _localctx = Modl_map_conditionalContext.new(@_ctx, @_state_number) enter_rule(_localctx, 18, RULE_modl_map_conditional) _la = 0 begin enter_outer_alt(_localctx, 1) @_state_number = 169 match(LCBRAC) @_state_number = 170 modl_condition_test() @_state_number = 171 match(QMARK) @_state_number = 172 modl_map_conditional_return() @_state_number = 181 @_err_handler.sync(self) _la = @_input.la(1) while (_la==FSLASH) @_state_number = 173 match(FSLASH) @_state_number = 175 @_err_handler.sync(self) _la = @_input.la(1) if ((((_la) & ~0x3f) == 0 && ((1 << _la) & ((1 << NULL) | (1 << TRUE) | (1 << FALSE) | (1 << EQUALS) | (1 << LBRAC) | (1 << LSBRAC) | (1 << NUMBER) | (1 << QUOTED) | (1 << STRING) | (1 << LCBRAC) | (1 << GTHAN) | (1 << LTHAN) | (1 << EXCLAM))) != 0)) @_state_number = 174 modl_condition_test() end @_state_number = 177 match(QMARK) @_state_number = 178 modl_map_conditional_return() @_state_number = 183 @_err_handler.sync(self) _la = @_input.la(1) end @_state_number = 184 match(RCBRAC) rescue Antlr4::Runtime::RecognitionException => re _localctx.exception = re @_err_handler.report_error(self, re) @_err_handler.recover(self, re) ensure exit_rule() end return _localctx end |
#modl_map_conditional_return ⇒ Object
1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 |
# File 'lib/modl/parser/MODLParser.rb', line 1147 def modl_map_conditional_return() _localctx = Modl_map_conditional_returnContext.new(@_ctx, @_state_number) enter_rule(_localctx, 20, RULE_modl_map_conditional_return) _la = 0 begin enter_outer_alt(_localctx, 1) @_state_number = 187 @_err_handler.sync(self) _la = @_input.la(1) loop do @_state_number = 186 modl_map_item() @_state_number = 189 @_err_handler.sync(self) _la = @_input.la(1) break if (!((((_la) & ~0x3f) == 0 && ((1 << _la) & ((1 << QUOTED) | (1 << STRING) | (1 << LCBRAC))) != 0))) end rescue Antlr4::Runtime::RecognitionException => re _localctx.exception = re @_err_handler.report_error(self, re) @_err_handler.recover(self, re) ensure exit_rule() end return _localctx end |
#modl_map_item ⇒ Object
1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 |
# File 'lib/modl/parser/MODLParser.rb', line 1210 def modl_map_item() _localctx = Modl_map_itemContext.new(@_ctx, @_state_number) enter_rule(_localctx, 22, RULE_modl_map_item) begin @_state_number = 193 @_err_handler.sync(self) case (@_input.la(1)) when MODLParser::QUOTED, MODLParser::STRING enter_outer_alt(_localctx, 1) @_state_number = 191 modl_pair() when MODLParser::LCBRAC enter_outer_alt(_localctx, 2) @_state_number = 192 modl_map_conditional() else raise Antlr4::Runtime::NoViableAltException, self end rescue Antlr4::Runtime::RecognitionException => re _localctx.exception = re @_err_handler.report_error(self, re) @_err_handler.recover(self, re) ensure exit_rule() end return _localctx end |
#modl_nb_array ⇒ Object
593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 |
# File 'lib/modl/parser/MODLParser.rb', line 593 def modl_nb_array() _localctx = Modl_nb_arrayContext.new(@_ctx, @_state_number) enter_rule(_localctx, 8, RULE_modl_nb_array) begin _alt = 0 enter_outer_alt(_localctx, 1) @_state_number = 120 @_err_handler.sync(self) _alt = 1 loop do case (_alt) when 1 @_state_number = 114 modl_array_item() @_state_number = 116 @_err_handler.sync(self) _alt = 1 loop do case (_alt) when 1 @_state_number = 115 match(COLON) else raise Antlr4::Runtime::NoViableAltException, self end @_state_number = 118 @_err_handler.sync(self) _alt = @_interp.adaptive_predict(@_input,13,@_ctx) break if !( _alt!=2 && _alt!=Antlr4::Runtime::ATN::INVALID_ALT_NUMBER ) end else raise Antlr4::Runtime::NoViableAltException, self end @_state_number = 122 @_err_handler.sync(self) _alt = @_interp.adaptive_predict(@_input,14,@_ctx) break if !( _alt!=2 && _alt!=Antlr4::Runtime::ATN::INVALID_ALT_NUMBER ) end @_state_number = 127 @_err_handler.sync(self); _alt = @_interp.adaptive_predict(@_input,15,@_ctx) while ( _alt!=2 && _alt!=Antlr4::Runtime::ATN::INVALID_ALT_NUMBER ) if ( _alt==1 ) @_state_number = 124 modl_array_item() end @_state_number = 129 @_err_handler.sync(self) _alt = @_interp.adaptive_predict(@_input,15,@_ctx) end @_state_number = 131 @_err_handler.sync(self) case ( @_interp.adaptive_predict(@_input,16,@_ctx) ) when 1 @_state_number = 130 match(COLON) end rescue Antlr4::Runtime::RecognitionException => re _localctx.exception = re @_err_handler.report_error(self, re) @_err_handler.recover(self, re) ensure exit_rule() end return _localctx end |
#modl_operator ⇒ Object
1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 |
# File 'lib/modl/parser/MODLParser.rb', line 1852 def modl_operator() _localctx = Modl_operatorContext.new(@_ctx, @_state_number) enter_rule(_localctx, 36, RULE_modl_operator) begin @_state_number = 280 @_err_handler.sync(self) case ( @_interp.adaptive_predict(@_input,38,@_ctx) ) when 1 enter_outer_alt(_localctx, 1) @_state_number = 271 match(EQUALS) when 2 enter_outer_alt(_localctx, 2) @_state_number = 272 match(GTHAN) when 3 enter_outer_alt(_localctx, 3) @_state_number = 273 match(GTHAN) @_state_number = 274 match(EQUALS) when 4 enter_outer_alt(_localctx, 4) @_state_number = 275 match(LTHAN) when 5 enter_outer_alt(_localctx, 5) @_state_number = 276 match(LTHAN) @_state_number = 277 match(EQUALS) when 6 enter_outer_alt(_localctx, 6) @_state_number = 278 match(EXCLAM) @_state_number = 279 match(EQUALS) end rescue Antlr4::Runtime::RecognitionException => re _localctx.exception = re @_err_handler.report_error(self, re) @_err_handler.recover(self, re) ensure exit_rule() end return _localctx end |
#modl_pair ⇒ Object
716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 |
# File 'lib/modl/parser/MODLParser.rb', line 716 def modl_pair() _localctx = Modl_pairContext.new(@_ctx, @_state_number) enter_rule(_localctx, 10, RULE_modl_pair) _la = 0 begin @_state_number = 140 @_err_handler.sync(self) case ( @_interp.adaptive_predict(@_input,17,@_ctx) ) when 1 enter_outer_alt(_localctx, 1) @_state_number = 133 _la = @_input.la(1) if (!(_la == QUOTED || _la == STRING)) @_err_handler.recover_in_line(self) else if ( @_input.la(1)==Antlr4::Runtime::Token::EOF ) @matchedEOF = true end @_err_handler.report_match(self) consume() end @_state_number = 134 match(EQUALS) @_state_number = 135 modl_value_item() when 2 enter_outer_alt(_localctx, 2) @_state_number = 136 match(STRING) @_state_number = 137 modl_map() when 3 enter_outer_alt(_localctx, 3) @_state_number = 138 match(STRING) @_state_number = 139 modl_array() end rescue Antlr4::Runtime::RecognitionException => re _localctx.exception = re @_err_handler.report_error(self, re) @_err_handler.recover(self, re) ensure exit_rule() end return _localctx end |
#modl_primitive ⇒ Object
2322 2323 2324 2325 2326 2327 2328 2329 2330 2331 2332 2333 2334 2335 2336 2337 2338 2339 2340 2341 2342 2343 2344 2345 2346 2347 2348 2349 |
# File 'lib/modl/parser/MODLParser.rb', line 2322 def modl_primitive() _localctx = Modl_primitiveContext.new(@_ctx, @_state_number) enter_rule(_localctx, 46, RULE_modl_primitive) _la = 0 begin enter_outer_alt(_localctx, 1) @_state_number = 320 _la = @_input.la(1) if (!((((_la) & ~0x3f) == 0 && ((1 << _la) & ((1 << NULL) | (1 << TRUE) | (1 << FALSE) | (1 << NUMBER) | (1 << QUOTED) | (1 << STRING))) != 0))) @_err_handler.recover_in_line(self) else if ( @_input.la(1)==Antlr4::Runtime::Token::EOF ) @matchedEOF = true end @_err_handler.report_match(self) consume() end rescue Antlr4::Runtime::RecognitionException => re _localctx.exception = re @_err_handler.report_error(self, re) @_err_handler.recover(self, re) ensure exit_rule() end return _localctx end |
#modl_structure ⇒ Object
277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 |
# File 'lib/modl/parser/MODLParser.rb', line 277 def modl_structure() _localctx = Modl_structureContext.new(@_ctx, @_state_number) enter_rule(_localctx, 2, RULE_modl_structure) begin @_state_number = 70 @_err_handler.sync(self) case (@_input.la(1)) when MODLParser::LBRAC enter_outer_alt(_localctx, 1) @_state_number = 66 modl_map() when MODLParser::LSBRAC enter_outer_alt(_localctx, 2) @_state_number = 67 modl_array() when MODLParser::LCBRAC enter_outer_alt(_localctx, 3) @_state_number = 68 modl_top_level_conditional() when MODLParser::QUOTED, MODLParser::STRING enter_outer_alt(_localctx, 4) @_state_number = 69 modl_pair() else raise Antlr4::Runtime::NoViableAltException, self end rescue Antlr4::Runtime::RecognitionException => re _localctx.exception = re @_err_handler.report_error(self, re) @_err_handler.recover(self, re) ensure exit_rule() end return _localctx end |
#modl_top_level_conditional ⇒ Object
891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 |
# File 'lib/modl/parser/MODLParser.rb', line 891 def modl_top_level_conditional() _localctx = Modl_top_level_conditionalContext.new(@_ctx, @_state_number) enter_rule(_localctx, 14, RULE_modl_top_level_conditional) _la = 0 begin enter_outer_alt(_localctx, 1) @_state_number = 146 match(LCBRAC) @_state_number = 147 modl_condition_test() @_state_number = 148 match(QMARK) @_state_number = 149 modl_top_level_conditional_return() @_state_number = 158 @_err_handler.sync(self) _la = @_input.la(1) while (_la==FSLASH) @_state_number = 150 match(FSLASH) @_state_number = 152 @_err_handler.sync(self) _la = @_input.la(1) if ((((_la) & ~0x3f) == 0 && ((1 << _la) & ((1 << NULL) | (1 << TRUE) | (1 << FALSE) | (1 << EQUALS) | (1 << LBRAC) | (1 << LSBRAC) | (1 << NUMBER) | (1 << QUOTED) | (1 << STRING) | (1 << LCBRAC) | (1 << GTHAN) | (1 << LTHAN) | (1 << EXCLAM))) != 0)) @_state_number = 151 modl_condition_test() end @_state_number = 154 match(QMARK) @_state_number = 155 modl_top_level_conditional_return() @_state_number = 160 @_err_handler.sync(self) _la = @_input.la(1) end @_state_number = 161 match(RCBRAC) rescue Antlr4::Runtime::RecognitionException => re _localctx.exception = re @_err_handler.report_error(self, re) @_err_handler.recover(self, re) ensure exit_rule() end return _localctx end |
#modl_top_level_conditional_return ⇒ Object
976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 |
# File 'lib/modl/parser/MODLParser.rb', line 976 def modl_top_level_conditional_return() _localctx = Modl_top_level_conditional_returnContext.new(@_ctx, @_state_number) enter_rule(_localctx, 16, RULE_modl_top_level_conditional_return) _la = 0 begin enter_outer_alt(_localctx, 1) @_state_number = 166 @_err_handler.sync(self) _la = @_input.la(1) while ((((_la) & ~0x3f) == 0 && ((1 << _la) & ((1 << LBRAC) | (1 << LSBRAC) | (1 << QUOTED) | (1 << STRING) | (1 << LCBRAC))) != 0)) @_state_number = 163 modl_structure() @_state_number = 168 @_err_handler.sync(self) _la = @_input.la(1) end rescue Antlr4::Runtime::RecognitionException => re _localctx.exception = re @_err_handler.report_error(self, re) @_err_handler.recover(self, re) ensure exit_rule() end return _localctx end |
#modl_value ⇒ Object
2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 |
# File 'lib/modl/parser/MODLParser.rb', line 2148 def modl_value() _localctx = Modl_valueContext.new(@_ctx, @_state_number) enter_rule(_localctx, 42, RULE_modl_value) begin @_state_number = 312 @_err_handler.sync(self) case ( @_interp.adaptive_predict(@_input,43,@_ctx) ) when 1 enter_outer_alt(_localctx, 1) @_state_number = 307 modl_map() when 2 enter_outer_alt(_localctx, 2) @_state_number = 308 modl_array() when 3 enter_outer_alt(_localctx, 3) @_state_number = 309 modl_nb_array() when 4 enter_outer_alt(_localctx, 4) @_state_number = 310 modl_pair() when 5 enter_outer_alt(_localctx, 5) @_state_number = 311 modl_primitive() end rescue Antlr4::Runtime::RecognitionException => re _localctx.exception = re @_err_handler.report_error(self, re) @_err_handler.recover(self, re) ensure exit_rule() end return _localctx end |
#modl_value_conditional ⇒ Object
1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 |
# File 'lib/modl/parser/MODLParser.rb', line 1534 def modl_value_conditional() _localctx = Modl_value_conditionalContext.new(@_ctx, @_state_number) enter_rule(_localctx, 30, RULE_modl_value_conditional) _la = 0 begin _alt = 0 enter_outer_alt(_localctx, 1) @_state_number = 221 match(LCBRAC) @_state_number = 222 modl_condition_test() @_state_number = 223 match(QMARK) @_state_number = 239 @_err_handler.sync(self) _la = @_input.la(1) if ((((_la) & ~0x3f) == 0 && ((1 << _la) & ((1 << NULL) | (1 << TRUE) | (1 << FALSE) | (1 << LBRAC) | (1 << LSBRAC) | (1 << NUMBER) | (1 << QUOTED) | (1 << STRING) | (1 << LCBRAC))) != 0)) @_state_number = 224 modl_value_conditional_return() @_state_number = 232 @_err_handler.sync(self); _alt = @_interp.adaptive_predict(@_input,30,@_ctx) while ( _alt!=2 && _alt!=Antlr4::Runtime::ATN::INVALID_ALT_NUMBER ) if ( _alt==1 ) @_state_number = 225 match(FSLASH) @_state_number = 226 modl_condition_test() @_state_number = 227 match(QMARK) @_state_number = 228 modl_value_conditional_return() end @_state_number = 234 @_err_handler.sync(self) _alt = @_interp.adaptive_predict(@_input,30,@_ctx) end @_state_number = 235 match(FSLASH) @_state_number = 236 match(QMARK) @_state_number = 237 modl_value_conditional_return() end @_state_number = 241 match(RCBRAC) rescue Antlr4::Runtime::RecognitionException => re _localctx.exception = re @_err_handler.report_error(self, re) @_err_handler.recover(self, re) ensure exit_rule() end return _localctx end |
#modl_value_conditional_return ⇒ Object
1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 |
# File 'lib/modl/parser/MODLParser.rb', line 1635 def modl_value_conditional_return() _localctx = Modl_value_conditional_returnContext.new(@_ctx, @_state_number) enter_rule(_localctx, 32, RULE_modl_value_conditional_return) _la = 0 begin enter_outer_alt(_localctx, 1) @_state_number = 243 modl_value_item() @_state_number = 248 @_err_handler.sync(self) _la = @_input.la(1) while (_la==COLON) @_state_number = 244 match(COLON) @_state_number = 245 modl_value_item() @_state_number = 250 @_err_handler.sync(self) _la = @_input.la(1) end rescue Antlr4::Runtime::RecognitionException => re _localctx.exception = re @_err_handler.report_error(self, re) @_err_handler.recover(self, re) ensure exit_rule() end return _localctx end |
#modl_value_item ⇒ Object
804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 |
# File 'lib/modl/parser/MODLParser.rb', line 804 def modl_value_item() _localctx = Modl_value_itemContext.new(@_ctx, @_state_number) enter_rule(_localctx, 12, RULE_modl_value_item) begin enter_outer_alt(_localctx, 1) @_state_number = 144 @_err_handler.sync(self) case ( @_interp.adaptive_predict(@_input,18,@_ctx) ) when 1 @_state_number = 142 modl_value() when 2 @_state_number = 143 modl_value_conditional() end rescue Antlr4::Runtime::RecognitionException => re _localctx.exception = re @_err_handler.report_error(self, re) @_err_handler.recover(self, re) ensure exit_rule() end return _localctx end |
#rule_names ⇒ Object
105 106 107 |
# File 'lib/modl/parser/MODLParser.rb', line 105 def rule_names() return @@ruleNames end |
#serialized_atn ⇒ Object
109 110 111 |
# File 'lib/modl/parser/MODLParser.rb', line 109 def serialized_atn() return @@_serializedATN end |