bitmark-grammar
Version:
1,085 lines • 455 kB
JavaScript
// Generated from ./Flashcard/flashcardParser.g4 by ANTLR 4.9.0-SNAPSHOT
import { ATN } from "antlr4ts/atn/ATN";
import { ATNDeserializer } from "antlr4ts/atn/ATNDeserializer";
import { FailedPredicateException } from "antlr4ts/FailedPredicateException";
import { NoViableAltException } from "antlr4ts/NoViableAltException";
import { Parser } from "antlr4ts/Parser";
import { ParserRuleContext } from "antlr4ts/ParserRuleContext";
import { ParserATNSimulator } from "antlr4ts/atn/ParserATNSimulator";
import { RecognitionException } from "antlr4ts/RecognitionException";
import { Token } from "antlr4ts/Token";
import { VocabularyImpl } from "antlr4ts/VocabularyImpl";
import * as Utils from "antlr4ts/misc/Utils";
export class flashcardParser extends Parser {
constructor(input) {
super(input);
this._interp = new ParserATNSimulator(flashcardParser._ATN, this);
}
// @Override
// @NotNull
get vocabulary() {
return flashcardParser.VOCABULARY;
}
// tslint:enable:no-trailing-whitespace
// @Override
get grammarFileName() { return "flashcardParser.g4"; }
// @Override
get ruleNames() { return flashcardParser.ruleNames; }
// @Override
get serializedATN() { return flashcardParser._serializedATN; }
createFailedPredicateException(predicate, message) {
return new FailedPredicateException(this, predicate, message);
}
// @RuleVersion(0)
bitmark() {
let _localctx = new BitmarkContext(this._ctx, this.state);
this.enterRule(_localctx, 0, flashcardParser.RULE_bitmark);
let _la;
try {
let _alt;
this.enterOuterAlt(_localctx, 1);
{
this.state = 185;
this._errHandler.sync(this);
_la = this._input.LA(1);
do {
{
{
this.state = 172;
this.bitmark_();
this.state = 182;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 1, this._ctx);
while (_alt !== 2 && _alt !== ATN.INVALID_ALT_NUMBER) {
if (_alt === 1) {
{
{
this.state = 176;
this._errHandler.sync(this);
_la = this._input.LA(1);
while (_la === flashcardParser.S) {
{
{
this.state = 173;
this.match(flashcardParser.S);
}
}
this.state = 178;
this._errHandler.sync(this);
_la = this._input.LA(1);
}
this.state = 179;
this.match(flashcardParser.NL);
}
}
}
this.state = 184;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 1, this._ctx);
}
}
}
this.state = 187;
this._errHandler.sync(this);
_la = this._input.LA(1);
} while ((((_la) & ~0x1F) === 0 && ((1 << _la) & ((1 << flashcardParser.BitFlash1) | (1 << flashcardParser.BitFlash) | (1 << flashcardParser.BitFlashcardset) | (1 << flashcardParser.BitFlashcardlangset) | (1 << flashcardParser.BitFlashcardlang1) | (1 << flashcardParser.BitVocabulary) | (1 << flashcardParser.BitVocabulary_1))) !== 0));
this.state = 192;
this._errHandler.sync(this);
_la = this._input.LA(1);
while (_la === flashcardParser.NL) {
{
{
this.state = 189;
this.match(flashcardParser.NL);
}
}
this.state = 194;
this._errHandler.sync(this);
_la = this._input.LA(1);
}
this.state = 195;
this.match(flashcardParser.EOF);
}
}
catch (re) {
if (re instanceof RecognitionException) {
_localctx.exception = re;
this._errHandler.reportError(this, re);
this._errHandler.recover(this, re);
}
else {
throw re;
}
}
finally {
this.exitRule();
}
return _localctx;
}
// @RuleVersion(0)
bitmark_() {
let _localctx = new Bitmark_Context(this._ctx, this.state);
this.enterRule(_localctx, 2, flashcardParser.RULE_bitmark_);
try {
this.state = 200;
this._errHandler.sync(this);
switch (this._input.LA(1)) {
case flashcardParser.BitFlash1:
case flashcardParser.BitFlash:
case flashcardParser.BitFlashcardset:
case flashcardParser.BitFlashcardlangset:
case flashcardParser.BitFlashcardlang1:
this.enterOuterAlt(_localctx, 1);
{
this.state = 197;
this.flashcards();
}
break;
case flashcardParser.BitVocabulary:
this.enterOuterAlt(_localctx, 2);
{
this.state = 198;
this.vocab();
}
break;
case flashcardParser.BitVocabulary_1:
this.enterOuterAlt(_localctx, 3);
{
this.state = 199;
this.vocab_1();
}
break;
default:
throw new NoViableAltException(this);
}
}
catch (re) {
if (re instanceof RecognitionException) {
_localctx.exception = re;
this._errHandler.reportError(this, re);
this._errHandler.recover(this, re);
}
else {
throw re;
}
}
finally {
this.exitRule();
}
return _localctx;
}
// @RuleVersion(0)
flashcards() {
let _localctx = new FlashcardsContext(this._ctx, this.state);
this.enterRule(_localctx, 4, flashcardParser.RULE_flashcards);
try {
this.state = 207;
this._errHandler.sync(this);
switch (this._input.LA(1)) {
case flashcardParser.BitFlash:
this.enterOuterAlt(_localctx, 1);
{
this.state = 202;
this.flashcard();
}
break;
case flashcardParser.BitFlash1:
this.enterOuterAlt(_localctx, 2);
{
this.state = 203;
this.flashcard_1();
}
break;
case flashcardParser.BitFlashcardset:
this.enterOuterAlt(_localctx, 3);
{
this.state = 204;
this.flashcard_set();
}
break;
case flashcardParser.BitFlashcardlangset:
this.enterOuterAlt(_localctx, 4);
{
this.state = 205;
this.flashcard_language_set();
}
break;
case flashcardParser.BitFlashcardlang1:
this.enterOuterAlt(_localctx, 5);
{
this.state = 206;
this.flashcard_language_1();
}
break;
default:
throw new NoViableAltException(this);
}
}
catch (re) {
if (re instanceof RecognitionException) {
_localctx.exception = re;
this._errHandler.reportError(this, re);
this._errHandler.recover(this, re);
}
else {
throw re;
}
}
finally {
this.exitRule();
}
return _localctx;
}
// @RuleVersion(0)
flashcard_1() {
let _localctx = new Flashcard_1Context(this._ctx, this.state);
this.enterRule(_localctx, 6, flashcardParser.RULE_flashcard_1);
let _la;
try {
let _alt;
this.enterOuterAlt(_localctx, 1);
{
this.state = 209;
this.match(flashcardParser.BitFlash1);
this.state = 210;
this.format();
this.state = 211;
this.match(flashcardParser.CL);
this.state = 212;
this.match(flashcardParser.NL);
this.state = 213;
this.side();
this.state = 214;
_la = this._input.LA(1);
if (!(_la === flashcardParser.EQ || _la === flashcardParser.EQ2)) {
this._errHandler.recoverInline(this);
}
else {
if (this._input.LA(1) === Token.EOF) {
this.matchedEOF = true;
}
this._errHandler.reportMatch(this);
this.consume();
}
this.state = 215;
this.side();
this.state = 219;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 6, this._ctx);
while (_alt !== 2 && _alt !== ATN.INVALID_ALT_NUMBER) {
if (_alt === 1) {
{
{
this.state = 216;
this.match(flashcardParser.NL);
}
}
}
this.state = 221;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 6, this._ctx);
}
this.state = 235;
this._errHandler.sync(this);
switch (this.interpreter.adaptivePredict(this._input, 9, this._ctx)) {
case 1:
{
this.state = 222;
this.resource();
this.state = 232;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 8, this._ctx);
while (_alt !== 2 && _alt !== ATN.INVALID_ALT_NUMBER) {
if (_alt === 1) {
{
{
this.state = 226;
this._errHandler.sync(this);
_la = this._input.LA(1);
while (_la === flashcardParser.NL) {
{
{
this.state = 223;
this.match(flashcardParser.NL);
}
}
this.state = 228;
this._errHandler.sync(this);
_la = this._input.LA(1);
}
this.state = 229;
this.resource();
}
}
}
this.state = 234;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 8, this._ctx);
}
}
break;
}
}
}
catch (re) {
if (re instanceof RecognitionException) {
_localctx.exception = re;
this._errHandler.reportError(this, re);
this._errHandler.recover(this, re);
}
else {
throw re;
}
}
finally {
this.exitRule();
}
return _localctx;
}
// @RuleVersion(0)
flashcard() {
let _localctx = new FlashcardContext(this._ctx, this.state);
this.enterRule(_localctx, 8, flashcardParser.RULE_flashcard);
let _la;
try {
let _alt;
this.enterOuterAlt(_localctx, 1);
{
this.state = 237;
this.match(flashcardParser.BitFlash);
this.state = 238;
this.format();
this.state = 239;
this.match(flashcardParser.CL);
this.state = 243;
this._errHandler.sync(this);
_la = this._input.LA(1);
while (_la === flashcardParser.NL) {
{
{
this.state = 240;
this.match(flashcardParser.NL);
}
}
this.state = 245;
this._errHandler.sync(this);
_la = this._input.LA(1);
}
this.state = 246;
_la = this._input.LA(1);
if (!(_la === flashcardParser.HSPL || _la === flashcardParser.HSPL2)) {
this._errHandler.recoverInline(this);
}
else {
if (this._input.LA(1) === Token.EOF) {
this.matchedEOF = true;
}
this._errHandler.reportMatch(this);
this.consume();
}
this.state = 247;
this.side();
this.state = 248;
_la = this._input.LA(1);
if (!(_la === flashcardParser.EQ || _la === flashcardParser.EQ2)) {
this._errHandler.recoverInline(this);
}
else {
if (this._input.LA(1) === Token.EOF) {
this.matchedEOF = true;
}
this._errHandler.reportMatch(this);
this.consume();
}
this.state = 249;
this.side();
this.state = 257;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 11, this._ctx);
while (_alt !== 2 && _alt !== ATN.INVALID_ALT_NUMBER) {
if (_alt === 1) {
{
{
this.state = 250;
_la = this._input.LA(1);
if (!(_la === flashcardParser.HSPL || _la === flashcardParser.HSPL2)) {
this._errHandler.recoverInline(this);
}
else {
if (this._input.LA(1) === Token.EOF) {
this.matchedEOF = true;
}
this._errHandler.reportMatch(this);
this.consume();
}
this.state = 251;
this.side();
this.state = 252;
_la = this._input.LA(1);
if (!(_la === flashcardParser.EQ || _la === flashcardParser.EQ2)) {
this._errHandler.recoverInline(this);
}
else {
if (this._input.LA(1) === Token.EOF) {
this.matchedEOF = true;
}
this._errHandler.reportMatch(this);
this.consume();
}
this.state = 253;
this.side();
}
}
}
this.state = 259;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 11, this._ctx);
}
this.state = 260;
_la = this._input.LA(1);
if (!(_la === flashcardParser.HSPL || _la === flashcardParser.HSPL2)) {
this._errHandler.recoverInline(this);
}
else {
if (this._input.LA(1) === Token.EOF) {
this.matchedEOF = true;
}
this._errHandler.reportMatch(this);
this.consume();
}
this.state = 264;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 12, this._ctx);
while (_alt !== 2 && _alt !== ATN.INVALID_ALT_NUMBER) {
if (_alt === 1) {
{
{
this.state = 261;
this.match(flashcardParser.NL);
}
}
}
this.state = 266;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 12, this._ctx);
}
this.state = 280;
this._errHandler.sync(this);
switch (this.interpreter.adaptivePredict(this._input, 15, this._ctx)) {
case 1:
{
this.state = 267;
this.resource();
this.state = 277;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 14, this._ctx);
while (_alt !== 2 && _alt !== ATN.INVALID_ALT_NUMBER) {
if (_alt === 1) {
{
{
this.state = 271;
this._errHandler.sync(this);
_la = this._input.LA(1);
while (_la === flashcardParser.NL) {
{
{
this.state = 268;
this.match(flashcardParser.NL);
}
}
this.state = 273;
this._errHandler.sync(this);
_la = this._input.LA(1);
}
this.state = 274;
this.resource();
}
}
}
this.state = 279;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 14, this._ctx);
}
}
break;
}
}
}
catch (re) {
if (re instanceof RecognitionException) {
_localctx.exception = re;
this._errHandler.reportError(this, re);
this._errHandler.recover(this, re);
}
else {
throw re;
}
}
finally {
this.exitRule();
}
return _localctx;
}
// @RuleVersion(0)
flashcard_set() {
let _localctx = new Flashcard_setContext(this._ctx, this.state);
this.enterRule(_localctx, 10, flashcardParser.RULE_flashcard_set);
let _la;
try {
let _alt;
this.enterOuterAlt(_localctx, 1);
{
this.state = 282;
this.match(flashcardParser.BitFlashcardset);
this.state = 283;
this.format();
this.state = 284;
this.match(flashcardParser.CL);
this.state = 288;
this._errHandler.sync(this);
_la = this._input.LA(1);
while (_la === flashcardParser.NL) {
{
{
this.state = 285;
this.match(flashcardParser.NL);
}
}
this.state = 290;
this._errHandler.sync(this);
_la = this._input.LA(1);
}
this.state = 296;
this._errHandler.sync(this);
switch (this.interpreter.adaptivePredict(this._input, 17, this._ctx)) {
case 1:
{
this.state = 291;
_la = this._input.LA(1);
if (!(_la === flashcardParser.HSPL || _la === flashcardParser.HSPL2)) {
this._errHandler.recoverInline(this);
}
else {
if (this._input.LA(1) === Token.EOF) {
this.matchedEOF = true;
}
this._errHandler.reportMatch(this);
this.consume();
}
this.state = 292;
this.side();
this.state = 293;
_la = this._input.LA(1);
if (!(_la === flashcardParser.EQ || _la === flashcardParser.EQ2)) {
this._errHandler.recoverInline(this);
}
else {
if (this._input.LA(1) === Token.EOF) {
this.matchedEOF = true;
}
this._errHandler.reportMatch(this);
this.consume();
}
this.state = 294;
this.side();
}
break;
}
this.state = 312;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 19, this._ctx);
while (_alt !== 2 && _alt !== ATN.INVALID_ALT_NUMBER) {
if (_alt === 1) {
{
{
this.state = 298;
_la = this._input.LA(1);
if (!(_la === flashcardParser.HSPL || _la === flashcardParser.HSPL2)) {
this._errHandler.recoverInline(this);
}
else {
if (this._input.LA(1) === Token.EOF) {
this.matchedEOF = true;
}
this._errHandler.reportMatch(this);
this.consume();
}
this.state = 299;
this.side();
this.state = 300;
_la = this._input.LA(1);
if (!(_la === flashcardParser.EQ || _la === flashcardParser.EQ2)) {
this._errHandler.recoverInline(this);
}
else {
if (this._input.LA(1) === Token.EOF) {
this.matchedEOF = true;
}
this._errHandler.reportMatch(this);
this.consume();
}
this.state = 301;
this.side();
this.state = 307;
this._errHandler.sync(this);
_la = this._input.LA(1);
while (_la === flashcardParser.NL) {
{
{
this.state = 302;
this.match(flashcardParser.NL);
this.state = 303;
this.match(flashcardParser.OR);
this.state = 304;
this.side();
}
}
this.state = 309;
this._errHandler.sync(this);
_la = this._input.LA(1);
}
}
}
}
this.state = 314;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 19, this._ctx);
}
this.state = 315;
_la = this._input.LA(1);
if (!(_la === flashcardParser.HSPL || _la === flashcardParser.HSPL2)) {
this._errHandler.recoverInline(this);
}
else {
if (this._input.LA(1) === Token.EOF) {
this.matchedEOF = true;
}
this._errHandler.reportMatch(this);
this.consume();
}
this.state = 319;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 20, this._ctx);
while (_alt !== 2 && _alt !== ATN.INVALID_ALT_NUMBER) {
if (_alt === 1) {
{
{
this.state = 316;
this.match(flashcardParser.NL);
}
}
}
this.state = 321;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 20, this._ctx);
}
this.state = 335;
this._errHandler.sync(this);
switch (this.interpreter.adaptivePredict(this._input, 23, this._ctx)) {
case 1:
{
this.state = 322;
this.resource();
this.state = 332;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 22, this._ctx);
while (_alt !== 2 && _alt !== ATN.INVALID_ALT_NUMBER) {
if (_alt === 1) {
{
{
this.state = 326;
this._errHandler.sync(this);
_la = this._input.LA(1);
while (_la === flashcardParser.NL) {
{
{
this.state = 323;
this.match(flashcardParser.NL);
}
}
this.state = 328;
this._errHandler.sync(this);
_la = this._input.LA(1);
}
this.state = 329;
this.resource();
}
}
}
this.state = 334;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 22, this._ctx);
}
}
break;
}
}
}
catch (re) {
if (re instanceof RecognitionException) {
_localctx.exception = re;
this._errHandler.reportError(this, re);
this._errHandler.recover(this, re);
}
else {
throw re;
}
}
finally {
this.exitRule();
}
return _localctx;
}
// @RuleVersion(0)
flashcard_language_set() {
let _localctx = new Flashcard_language_setContext(this._ctx, this.state);
this.enterRule(_localctx, 12, flashcardParser.RULE_flashcard_language_set);
let _la;
try {
let _alt;
this.enterOuterAlt(_localctx, 1);
{
this.state = 337;
this.match(flashcardParser.BitFlashcardlangset);
this.state = 338;
this.format();
this.state = 339;
this.match(flashcardParser.CL);
this.state = 343;
this._errHandler.sync(this);
_la = this._input.LA(1);
while (_la === flashcardParser.NL) {
{
{
this.state = 340;
this.match(flashcardParser.NL);
}
}
this.state = 345;
this._errHandler.sync(this);
_la = this._input.LA(1);
}
this.state = 346;
this.sidex_NL();
this.state = 358;
this._errHandler.sync(this);
_alt = 1;
do {
switch (_alt) {
case 1:
{
{
this.state = 347;
_la = this._input.LA(1);
if (!(_la === flashcardParser.HSPL || _la === flashcardParser.HSPL2)) {
this._errHandler.recoverInline(this);
}
else {
if (this._input.LA(1) === Token.EOF) {
this.matchedEOF = true;
}
this._errHandler.reportMatch(this);
this.consume();
}
this.state = 348;
this.sidex();
{
this.state = 349;
this.match(flashcardParser.NL);
this.state = 350;
this.sidex_NL();
}
this.state = 354;
this._errHandler.sync(this);
_la = this._input.LA(1);
do {
{
{
this.state = 352;
_la = this._input.LA(1);
if (!(_la === flashcardParser.EQ || _la === flashcardParser.EQ2)) {
this._errHandler.recoverInline(this);
}
else {
if (this._input.LA(1) === Token.EOF) {
this.matchedEOF = true;
}
this._errHandler.reportMatch(this);
this.consume();
}
this.state = 353;
this.sidex_NL();
}
}
this.state = 356;
this._errHandler.sync(this);
_la = this._input.LA(1);
} while (_la === flashcardParser.EQ || _la === flashcardParser.EQ2);
}
}
break;
default:
throw new NoViableAltException(this);
}
this.state = 360;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 26, this._ctx);
} while (_alt !== 2 && _alt !== ATN.INVALID_ALT_NUMBER);
this.state = 362;
_la = this._input.LA(1);
if (!(_la === flashcardParser.HSPL || _la === flashcardParser.HSPL2)) {
this._errHandler.recoverInline(this);
}
else {
if (this._input.LA(1) === Token.EOF) {
this.matchedEOF = true;
}
this._errHandler.reportMatch(this);
this.consume();
}
this.state = 366;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 27, this._ctx);
while (_alt !== 2 && _alt !== ATN.INVALID_ALT_NUMBER) {
if (_alt === 1) {
{
{
this.state = 363;
this.match(flashcardParser.NL);
}
}
}
this.state = 368;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 27, this._ctx);
}
this.state = 382;
this._errHandler.sync(this);
switch (this.interpreter.adaptivePredict(this._input, 30, this._ctx)) {
case 1:
{
this.state = 369;
this.resource();
this.state = 379;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 29, this._ctx);
while (_alt !== 2 && _alt !== ATN.INVALID_ALT_NUMBER) {
if (_alt === 1) {
{
{
this.state = 373;
this._errHandler.sync(this);
_la = this._input.LA(1);
while (_la === flashcardParser.NL) {
{
{
this.state = 370;
this.match(flashcardParser.NL);
}
}
this.state = 375;
this._errHandler.sync(this);
_la = this._input.LA(1);
}
this.state = 376;
this.resource();
}
}
}
this.state = 381;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 29, this._ctx);
}
}
break;
}
}
}
catch (re) {
if (re instanceof RecognitionException) {
_localctx.exception = re;
this._errHandler.reportError(this, re);
this._errHandler.recover(this, re);
}
else {
throw re;
}
}
finally {
this.exitRule();
}
return _localctx;
}
// @RuleVersion(0)
flashcard_language_1() {
let _localctx = new Flashcard_language_1Context(this._ctx, this.state);
this.enterRule(_localctx, 14, flashcardParser.RULE_flashcard_language_1);
let _la;
try {
let _alt;
this.enterOuterAlt(_localctx, 1);
{
this.state = 384;
this.match(flashcardParser.BitFlashcardlang1);
this.state = 385;
this.format();
this.state = 386;
this.match(flashcardParser.CL);
this.state = 390;
this._errHandler.sync(this);
_la = this._input.LA(1);
while (_la === flashcardParser.NL) {
{
{
this.state = 387;
this.match(flashcardParser.NL);
}
}
this.state = 392;
this._errHandler.sync(this);
_la = this._input.LA(1);
}
this.state = 393;
this.sidex_NL();
this.state = 394;
_la = this._input.LA(1);
if (!(_la === flashcardParser.EQ || _la === flashcardParser.EQ2)) {
this._errHandler.recoverInline(this);
}
else {
if (this._input.LA(1) === Token.EOF) {
this.matchedEOF = true;
}
this._errHandler.reportMatch(this);
this.consume();
}
this.state = 395;
this.sidex();
{
this.state = 396;
this.match(flashcardParser.NL);
this.state = 397;
this.sidex_NL();
}
this.state = 401;
this._errHandler.sync(this);
_la = this._input.LA(1);
do {
{
{
this.state = 399;
this.match(flashcardParser.OR);
this.state = 400;
this.sidex_NL();
}
}
this.state = 403;
this._errHandler.sync(this);
_la = this._input.LA(1);
} while (_la === flashcardParser.OR);
this.state = 408;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 33, this._ctx);
while (_alt !== 2 && _alt !== ATN.INVALID_ALT_NUMBER) {
if (_alt === 1) {
{
{
this.state = 405;
this.match(flashcardParser.NL);
}
}
}
this.state = 410;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 33, this._ctx);
}
this.state = 424;
this._errHandler.sync(this);
switch (this.interpreter.adaptivePredict(this._input, 36, this._ctx)) {
case 1:
{
this.state = 411;
this.resource();
this.state = 421;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 35, this._ctx);
while (_alt !== 2 && _alt !== ATN.INVALID_ALT_NUMBER) {
if (_alt === 1) {
{
{
this.state = 415;
this._errHandler.sync(this);
_la = this._input.LA(1);
while (_la === flashcardParser.NL) {
{
{
this.state = 412;
this.match(flashcardParser.NL);
}
}
this.state = 417;
this._errHandler.sync(this);
_la = this._input.LA(1);
}
this.state = 418;
this.resource();
}
}
}
this.state = 423;
this._errHandler.sync(this);
_alt = this.interpreter.adaptivePredict(this._input, 35, this._ctx);
}
}
break;
}
}
}
catch (re) {
if (re instanceof RecognitionException) {
_localctx.exception = re;
this._errHandler.reportError(this, re);
this._errHandler.recover(this, re);
}
else {
throw re;
}
}
finally {
this.exitRule();
}
return _localctx;
}
// @RuleVersion(0)
vocab() {
let _localctx = new VocabContext(this._ctx, this.state);
this.enterRule(_localctx, 16, flashcardParser.RULE_vocab);
let _la;
try {
let _alt;
this.enterOuterAlt(_localctx, 1);
{
this.state = 426;
this.match(flashcardParser.BitVocabulary);
this.state = 427;
this.format();
this.state = 428;
this.match(flashcardParser.CL);
this.state = 432;
this._errHandler.sync(this);
_la = this._input.LA(1);
while (_la === flashcardParser.NL) {
{
{
this.state = 429;
this.match(flashcardParser.NL);
}
}
this.state = 434;
this._errHandler.sync(this);
_la = this._input.LA(1);
}
this.state = 444;
this._errHandler.sync(this);
_la = this._input.LA(1);
while ((((_la) & ~0x1F) === 0 && ((1 << _la) & ((1 << flashcardParser.S) | (1 << flashcardParser.OPRANGLES) | (1 << flashcardParser.OPRANGLEL) | (1 << flashcardParser.OPDANGLE) | (1 << flashcardParser.OPU) | (1 << flashcardParser.OPB) | (1 << flashcardParser.OPQ) | (1 << flashcardParser.OPA) | (1 << flashcardParser.OPS) | (1 << flashcardParser.OPC) | (1 << flashcardParser.OPHASH) | (1 << flashcardParser.COLON) | (1 << flashcardParser.AMP))) !== 0) || ((((_la - 32)) & ~0x1F) === 0 && ((1 << (_la - 32)) & ((1 << (flashcardParser.Greater - 32)) | (1 << (flashcardParser.Less - 32)) | (1 << (flashcardParser.RightAngle - 32)) | (1 << (flashcardParser.RightArrow - 32)) | (1 << (flashcardParser.ArticleText - 32)) | (1 << (flashcardParser.NUMERIC - 32)) | (1 << (flashcardParser.STRING - 32)) | (1 << (flashcardParser.NOTBITMARK - 32)) | (1 << (flashcardParser.SENTENCE - 32)) | (1 << (flashcardParser.BARSTRING - 32)) | (1 << (flashcardParser.AtReference - 32)))) !== 0) || ((((_la - 65)) & ~0x1F) === 0 && ((1 << (_la - 65)) & ((1 << (flashcardParser.AtExampleWithStr - 65)) | (1 << (flashcardParser.AtExamplecol - 65)) | (1 << (flashcardParser.AtExamplecl - 65)) | (1 << (flashcardParser.AtLabeltrue - 65)) | (1 << (flashcardParser.AtLabelfalse - 65)) | (1 << (flashcardParser.OpAtCopyright - 65)))) !== 0) || ((((_la - 99)) & ~0x1F) === 0 && ((1 << (_la - 99)) & ((1 << (flashcardParser.OpAmpAudio - 99)) | (1 << (flashcardParser.OpAmpImage - 99)) | (1 << (flashcardParser.OpAmpImageZoom - 99)) | (1 << (flashcardParser.OpAmpImageWAudio - 99)) | (1 << (flashcardParser.OpAmpVideo - 99)) | (1 << (flashcardParser.OpAmpArticle - 99)) | (1 << (flashcardParser.OpAmpDocument - 99)) | (1 << (flashcardParser.OpAmpApp - 99)) | (1 << (flashcardParser.OpAmpWebsite - 99)) | (1 << (flashcardParser.OpAmpStillImageFilm - 99)) | (1 << (flashcardParser.OpAmpAudioLink - 99)) | (1 << (flashcardParser.OpAmpImageLink - 99)) | (1 << (flashcardParser.OpAmpVideoLink - 99)) | (1 << (flashcardParser.OpAmpArticleLink - 99)) | (1 << (flashcardParser.OpAmpDocumentLink - 99)) | (1 << (flashcardParser.OpAmpDocumentDownload - 99)) | (1 << (flashcardParser.OpAmpAppLink - 99)) | (1 << (flashcardParser.OpAmpWebsiteLink - 99)) | (1 << (flashcardParser.OpAmpStillImageFilmLink - 99)))) !== 0) || ((((_la - 135)) & ~0x1F) === 0 && ((1 << (_la - 135)) & ((1 << (flashcardParser.OpAmpVideoEmbed - 135)) | (1 << (flashcardParser.OpAmpAudioEmbed - 135)