
com.incapture.rapgen.TTreeDotNet_TTreeShared Maven / Gradle / Ivy
The newest version!
// $ANTLR 3.5.2 TTreeShared.g 2016-05-03 11:47:52
package com.incapture.rapgen;
import java.util.Collection;
import java.util.Map;
import java.util.HashMap;
import java.util.Set;
import java.util.HashSet;
import com.incapture.rapgen.annotations.*;
import org.antlr.runtime.*;
import org.antlr.runtime.tree.*;
import java.util.Stack;
import java.util.List;
import java.util.ArrayList;
import org.antlr.stringtemplate.*;
import org.antlr.stringtemplate.language.*;
import java.util.HashMap;
@SuppressWarnings("all")
public class TTreeDotNet_TTreeShared extends AbstractTTreeDotNet {
public static final int EOF=-1;
public static final int ADDRESSABLE=4;
public static final int API=5;
public static final int AT=6;
public static final int BANG=7;
public static final int BEAN=8;
public static final int BOOLTYPE=9;
public static final int BYTEARRAYTYPE=10;
public static final int CACHEABLE=11;
public static final int CLOSESQUARE=12;
public static final int COLUMN=13;
public static final int COMMA=14;
public static final int COMMENT=15;
public static final int CRUDTYPED=16;
public static final int DATA=17;
public static final int DATETYPE=18;
public static final int DEPRECATED=19;
public static final int DOC=20;
public static final int DOT=21;
public static final int DOUBLETYPE=22;
public static final int DYNENT=23;
public static final int ENTITLE=24;
public static final int EQUAL=25;
public static final int EXTENDS=26;
public static final int FALSE=27;
public static final int FTS=28;
public static final int G_THAN=29;
public static final int ID=30;
public static final int INCLUDE=31;
public static final int INDEXED=32;
public static final int INT=33;
public static final int INTTYPE=34;
public static final int LBRAC=35;
public static final int LISTTYPE=36;
public static final int LONGCTYPE=37;
public static final int LONGTYPE=38;
public static final int LPAREN=39;
public static final int L_THAN=40;
public static final int MAPTYPE=41;
public static final int MINUS=42;
public static final int NEW=43;
public static final int OBJECTTYPE=44;
public static final int OPENSQUARE=45;
public static final int PACKAGE=46;
public static final int PACKAGENAME=47;
public static final int PRIVATE=48;
public static final int PUBLIC=49;
public static final int RBRAC=50;
public static final int REGULARENTITLE=51;
public static final int RPAREN=52;
public static final int SCHEME=53;
public static final int SDKNAME=54;
public static final int SEARCHABLE=55;
public static final int SEMI=56;
public static final int SETTYPE=57;
public static final int SQUOTE=58;
public static final int STORABLE=59;
public static final int STORAGE_PATH=60;
public static final int STREAMING=61;
public static final int STRING=62;
public static final int STRINGTYPE=63;
public static final int TRUE=64;
public static final int TYPED=65;
public static final int VOIDTYPE=66;
public static final int WS=67;
public static final int APIENTRY=68;
public static final int APISEC=69;
public static final int CLASSTYPE=70;
public static final int COMPLEX=71;
public static final int CRUDINFO=72;
public static final int CRUDINFOENTRY=73;
public static final int CRUDPACKAGEANNOTATION=74;
public static final int CRUDTYPEDEF=75;
public static final int ENTITLEASPECT=76;
public static final int ENUM=77;
public static final int EXPR=78;
public static final int FIELD_CONSTRUCTOR=79;
public static final int FNNAME=80;
public static final int INDEX_COMPONENT=81;
public static final int INDEX_NAME=82;
public static final int INNERA=83;
public static final int INNERC=84;
public static final int INNERT=85;
public static final int MAIN=86;
public static final int MEMBER=87;
public static final int MEMBERS=88;
public static final int MINVERSIONDEF=89;
public static final int NAME=90;
public static final int PARAM=91;
public static final int PARAMS=92;
public static final int PRIVATEVIS=93;
public static final int PUBLICVIS=94;
public static final int RAW=95;
public static final int RETTYPE=96;
public static final int SCRIPT=97;
public static final int SDKDEF=98;
public static final int STATEMENT=99;
public static final int STORABLE_ENCODING=100;
public static final int STORABLE_PREFIX=101;
public static final int STORABLE_REPO_NAME=102;
public static final int STORABLE_SEPARATOR=103;
public static final int STORABLE_TTL_DAYS=104;
public static final int STORAGE_PATH_ADDER=105;
public static final int STREAMINGASPECT=106;
public static final int TYPE=107;
public static final int TYPEASPECT=108;
public static final int TYPEDEF=109;
public static final int TYPEFIELDS=110;
public static final int TYPEMEMBER=111;
public static final int VERSIONDEF=112;
public static final int VISIBILITY=113;
// delegates
public AbstractTTreeDotNet[] getDelegates() {
return new AbstractTTreeDotNet[] {};
}
// delegators
public TTreeDotNet gTTreeDotNet;
public TTreeDotNet gParent;
public TTreeDotNet_TTreeShared(TreeNodeStream input, TTreeDotNet gTTreeDotNet) {
this(input, new RecognizerSharedState(), gTTreeDotNet);
}
public TTreeDotNet_TTreeShared(TreeNodeStream input, RecognizerSharedState state, TTreeDotNet gTTreeDotNet) {
super(input, state);
this.gTTreeDotNet = gTTreeDotNet;
gParent = gTTreeDotNet;
}
protected StringTemplateGroup templateLib =
new StringTemplateGroup("TTreeDotNet_TTreeSharedTemplates", AngleBracketTemplateLexer.class);
public void setTemplateLib(StringTemplateGroup templateLib) {
this.templateLib = templateLib;
}
public StringTemplateGroup getTemplateLib() {
return templateLib;
}
/** allows convenient multi-value initialization:
* "new STAttrMap().put(...).put(...)"
*/
@SuppressWarnings("serial")
public static class STAttrMap extends HashMap {
public STAttrMap put(String attrName, Object value) {
super.put(attrName, value);
return this;
}
}
@Override public String[] getTokenNames() { return TTreeDotNet.tokenNames; }
@Override public String getGrammarFileName() { return "TTreeShared.g"; }
public static class versionExpr_return extends TreeRuleReturnScope {
public int major;
public int minor;
public int micro;
public StringTemplate st;
public Object getTemplate() { return st; }
public String toString() { return st==null?null:st.toString(); }
};
// $ANTLR start "versionExpr"
// TTreeShared.g:13:1: versionExpr returns [int major, int minor, int micro] : ^(def= VERSIONDEF majorLocal= INT minorLocal= INT (microLocal= INT )? ) ;
public final TTreeDotNet_TTreeShared.versionExpr_return versionExpr() throws RecognitionException {
TTreeDotNet_TTreeShared.versionExpr_return retval = new TTreeDotNet_TTreeShared.versionExpr_return();
retval.start = input.LT(1);
CommonTree def=null;
CommonTree majorLocal=null;
CommonTree minorLocal=null;
CommonTree microLocal=null;
try {
// TTreeShared.g:13:54: ( ^(def= VERSIONDEF majorLocal= INT minorLocal= INT (microLocal= INT )? ) )
// TTreeShared.g:13:56: ^(def= VERSIONDEF majorLocal= INT minorLocal= INT (microLocal= INT )? )
{
def=(CommonTree)match(input,VERSIONDEF,FOLLOW_VERSIONDEF_in_versionExpr51);
match(input, Token.DOWN, null);
majorLocal=(CommonTree)match(input,INT,FOLLOW_INT_in_versionExpr55);
minorLocal=(CommonTree)match(input,INT,FOLLOW_INT_in_versionExpr59);
// TTreeShared.g:13:102: (microLocal= INT )?
int alt1=2;
int LA1_0 = input.LA(1);
if ( (LA1_0==INT) ) {
alt1=1;
}
switch (alt1) {
case 1 :
// TTreeShared.g:13:104: microLocal= INT
{
microLocal=(CommonTree)match(input,INT,FOLLOW_INT_in_versionExpr64);
}
break;
}
match(input, Token.UP, null);
retval.major = Integer.parseInt((majorLocal!=null?majorLocal.getText():null));
retval.minor = Integer.parseInt((minorLocal!=null?minorLocal.getText():null));
if (microLocal != null && (microLocal!=null?microLocal.getText():null).length() > 0) {
retval.micro = Integer.parseInt((microLocal!=null?microLocal.getText():null));
}
else {
retval.micro = 0; //assume 0 if no macro specified
}
}
}
catch (RecognitionException re) {
reportError(re);
recover(input,re);
}
finally {
// do for sure before leaving
}
return retval;
}
// $ANTLR end "versionExpr"
public static class minVerExpr_return extends TreeRuleReturnScope {
public int major;
public int minor;
public int micro;
public StringTemplate st;
public Object getTemplate() { return st; }
public String toString() { return st==null?null:st.toString(); }
};
// $ANTLR start "minVerExpr"
// TTreeShared.g:24:1: minVerExpr returns [int major, int minor, int micro] : ^(def= MINVERSIONDEF majorLocal= INT minorLocal= INT (microLocal= INT )? ) ;
public final TTreeDotNet_TTreeShared.minVerExpr_return minVerExpr() throws RecognitionException {
TTreeDotNet_TTreeShared.minVerExpr_return retval = new TTreeDotNet_TTreeShared.minVerExpr_return();
retval.start = input.LT(1);
CommonTree def=null;
CommonTree majorLocal=null;
CommonTree minorLocal=null;
CommonTree microLocal=null;
try {
// TTreeShared.g:24:53: ( ^(def= MINVERSIONDEF majorLocal= INT minorLocal= INT (microLocal= INT )? ) )
// TTreeShared.g:24:55: ^(def= MINVERSIONDEF majorLocal= INT minorLocal= INT (microLocal= INT )? )
{
def=(CommonTree)match(input,MINVERSIONDEF,FOLLOW_MINVERSIONDEF_in_minVerExpr83);
match(input, Token.DOWN, null);
majorLocal=(CommonTree)match(input,INT,FOLLOW_INT_in_minVerExpr87);
minorLocal=(CommonTree)match(input,INT,FOLLOW_INT_in_minVerExpr91);
// TTreeShared.g:24:104: (microLocal= INT )?
int alt2=2;
int LA2_0 = input.LA(1);
if ( (LA2_0==INT) ) {
alt2=1;
}
switch (alt2) {
case 1 :
// TTreeShared.g:24:106: microLocal= INT
{
microLocal=(CommonTree)match(input,INT,FOLLOW_INT_in_minVerExpr96);
}
break;
}
match(input, Token.UP, null);
retval.major = Integer.parseInt((majorLocal!=null?majorLocal.getText():null));
retval.minor = Integer.parseInt((minorLocal!=null?minorLocal.getText():null));
if (microLocal != null && (microLocal!=null?microLocal.getText():null).length() > 0) {
retval.micro = Integer.parseInt((microLocal!=null?microLocal.getText():null));
}
else {
retval.micro = 0; //assume 0 if no macro specified
}
}
}
catch (RecognitionException re) {
reportError(re);
recover(input,re);
}
finally {
// do for sure before leaving
}
return retval;
}
// $ANTLR end "minVerExpr"
public static class beanAnnotation_return extends TreeRuleReturnScope {
public BeanAnnotation result;
public StringTemplate st;
public Object getTemplate() { return st; }
public String toString() { return st==null?null:st.toString(); }
};
// $ANTLR start "beanAnnotation"
// TTreeShared.g:36:1: beanAnnotation returns [BeanAnnotation result] : BEAN ;
public final TTreeDotNet_TTreeShared.beanAnnotation_return beanAnnotation() throws RecognitionException {
TTreeDotNet_TTreeShared.beanAnnotation_return retval = new TTreeDotNet_TTreeShared.beanAnnotation_return();
retval.start = input.LT(1);
try {
// TTreeShared.g:38:5: ( BEAN )
// TTreeShared.g:38:7: BEAN
{
match(input,BEAN,FOLLOW_BEAN_in_beanAnnotation119);
retval.result = new BeanAnnotation();
}
}
catch (RecognitionException re) {
reportError(re);
recover(input,re);
}
finally {
// do for sure before leaving
}
return retval;
}
// $ANTLR end "beanAnnotation"
public static class ftsAnnotation_return extends TreeRuleReturnScope {
public FTSAnnotation result;
public StringTemplate st;
public Object getTemplate() { return st; }
public String toString() { return st==null?null:st.toString(); }
};
// $ANTLR start "ftsAnnotation"
// TTreeShared.g:41:1: ftsAnnotation returns [FTSAnnotation result] : FTS ;
public final TTreeDotNet_TTreeShared.ftsAnnotation_return ftsAnnotation() throws RecognitionException {
TTreeDotNet_TTreeShared.ftsAnnotation_return retval = new TTreeDotNet_TTreeShared.ftsAnnotation_return();
retval.start = input.LT(1);
try {
// TTreeShared.g:42:2: ( FTS )
// TTreeShared.g:42:4: FTS
{
match(input,FTS,FOLLOW_FTS_in_ftsAnnotation139);
retval.result = new FTSAnnotation();
}
}
catch (RecognitionException re) {
reportError(re);
recover(input,re);
}
finally {
// do for sure before leaving
}
return retval;
}
// $ANTLR end "ftsAnnotation"
public static class searchableAnnotation_return extends TreeRuleReturnScope {
public SearchableAnnotation result;
public StringTemplate st;
public Object getTemplate() { return st; }
public String toString() { return st==null?null:st.toString(); }
};
// $ANTLR start "searchableAnnotation"
// TTreeShared.g:45:1: searchableAnnotation returns [SearchableAnnotation result] : SEARCHABLE ;
public final TTreeDotNet_TTreeShared.searchableAnnotation_return searchableAnnotation() throws RecognitionException {
TTreeDotNet_TTreeShared.searchableAnnotation_return retval = new TTreeDotNet_TTreeShared.searchableAnnotation_return();
retval.start = input.LT(1);
try {
// TTreeShared.g:47:5: ( SEARCHABLE )
// TTreeShared.g:47:7: SEARCHABLE
{
match(input,SEARCHABLE,FOLLOW_SEARCHABLE_in_searchableAnnotation161);
retval.result = new SearchableAnnotation();
}
}
catch (RecognitionException re) {
reportError(re);
recover(input,re);
}
finally {
// do for sure before leaving
}
return retval;
}
// $ANTLR end "searchableAnnotation"
public static class cacheableAnnotation_return extends TreeRuleReturnScope {
public CacheableAnnotation result;
public StringTemplate st;
public Object getTemplate() { return st; }
public String toString() { return st==null?null:st.toString(); }
};
// $ANTLR start "cacheableAnnotation"
// TTreeShared.g:50:1: cacheableAnnotation returns [CacheableAnnotation result] : CACHEABLE ( LBRAC ID EQUAL ( TRUE | FALSE ) RBRAC )? ;
public final TTreeDotNet_TTreeShared.cacheableAnnotation_return cacheableAnnotation() throws RecognitionException {
TTreeDotNet_TTreeShared.cacheableAnnotation_return retval = new TTreeDotNet_TTreeShared.cacheableAnnotation_return();
retval.start = input.LT(1);
try {
// TTreeShared.g:51:5: ( CACHEABLE ( LBRAC ID EQUAL ( TRUE | FALSE ) RBRAC )? )
// TTreeShared.g:51:7: CACHEABLE ( LBRAC ID EQUAL ( TRUE | FALSE ) RBRAC )?
{
match(input,CACHEABLE,FOLLOW_CACHEABLE_in_cacheableAnnotation188);
retval.result = new CacheableAnnotation();
// TTreeShared.g:51:58: ( LBRAC ID EQUAL ( TRUE | FALSE ) RBRAC )?
int alt4=2;
int LA4_0 = input.LA(1);
if ( (LA4_0==LBRAC) ) {
alt4=1;
}
switch (alt4) {
case 1 :
// TTreeShared.g:51:59: LBRAC ID EQUAL ( TRUE | FALSE ) RBRAC
{
match(input,LBRAC,FOLLOW_LBRAC_in_cacheableAnnotation193);
match(input,ID,FOLLOW_ID_in_cacheableAnnotation195);
match(input,EQUAL,FOLLOW_EQUAL_in_cacheableAnnotation197);
// TTreeShared.g:51:74: ( TRUE | FALSE )
int alt3=2;
int LA3_0 = input.LA(1);
if ( (LA3_0==TRUE) ) {
alt3=1;
}
else if ( (LA3_0==FALSE) ) {
alt3=2;
}
else {
NoViableAltException nvae =
new NoViableAltException("", 3, 0, input);
throw nvae;
}
switch (alt3) {
case 1 :
// TTreeShared.g:51:75: TRUE
{
match(input,TRUE,FOLLOW_TRUE_in_cacheableAnnotation200);
retval.result.setShouldCacheNulls(true);
}
break;
case 2 :
// TTreeShared.g:51:121: FALSE
{
match(input,FALSE,FOLLOW_FALSE_in_cacheableAnnotation206);
}
break;
}
match(input,RBRAC,FOLLOW_RBRAC_in_cacheableAnnotation209);
}
break;
}
}
}
catch (RecognitionException re) {
reportError(re);
recover(input,re);
}
finally {
// do for sure before leaving
}
return retval;
}
// $ANTLR end "cacheableAnnotation"
protected static class addressableAnnotation_scope {
boolean isPrimitive;
}
protected Stack addressableAnnotation_stack = new Stack();
public static class addressableAnnotation_return extends TreeRuleReturnScope {
public AddressableAnnotation result;
public StringTemplate st;
public Object getTemplate() { return st; }
public String toString() { return st==null?null:st.toString(); }
};
// $ANTLR start "addressableAnnotation"
// TTreeShared.g:54:1: addressableAnnotation returns [AddressableAnnotation result] : ADDRESSABLE ID ( TRUE | FALSE )? ;
public final TTreeDotNet_TTreeShared.addressableAnnotation_return addressableAnnotation() throws RecognitionException {
addressableAnnotation_stack.push(new addressableAnnotation_scope());
TTreeDotNet_TTreeShared.addressableAnnotation_return retval = new TTreeDotNet_TTreeShared.addressableAnnotation_return();
retval.start = input.LT(1);
CommonTree ID1=null;
addressableAnnotation_stack.peek().isPrimitive = false;
try {
// TTreeShared.g:62:5: ( ADDRESSABLE ID ( TRUE | FALSE )? )
// TTreeShared.g:62:7: ADDRESSABLE ID ( TRUE | FALSE )?
{
match(input,ADDRESSABLE,FOLLOW_ADDRESSABLE_in_addressableAnnotation246);
ID1=(CommonTree)match(input,ID,FOLLOW_ID_in_addressableAnnotation248);
// TTreeShared.g:63:9: ( TRUE | FALSE )?
int alt5=3;
int LA5_0 = input.LA(1);
if ( (LA5_0==TRUE) ) {
alt5=1;
}
else if ( (LA5_0==FALSE) ) {
alt5=2;
}
switch (alt5) {
case 1 :
// TTreeShared.g:63:10: TRUE
{
match(input,TRUE,FOLLOW_TRUE_in_addressableAnnotation260);
addressableAnnotation_stack.peek().isPrimitive = true;
}
break;
case 2 :
// TTreeShared.g:64:11: FALSE
{
match(input,FALSE,FOLLOW_FALSE_in_addressableAnnotation275);
addressableAnnotation_stack.peek().isPrimitive = false;
}
break;
}
retval.result = new AddressableAnnotation((ID1!=null?ID1.getText():null), addressableAnnotation_stack.peek().isPrimitive);
}
}
catch (RecognitionException re) {
reportError(re);
recover(input,re);
}
finally {
// do for sure before leaving
addressableAnnotation_stack.pop();
}
return retval;
}
// $ANTLR end "addressableAnnotation"
protected static class storableAnnotation_scope {
StorableAnnotation annotation;
}
protected Stack storableAnnotation_stack = new Stack();
public static class storableAnnotation_return extends TreeRuleReturnScope {
public StorableAnnotation result;
public StringTemplate st;
public Object getTemplate() { return st; }
public String toString() { return st==null?null:st.toString(); }
};
// $ANTLR start "storableAnnotation"
// TTreeShared.g:68:1: storableAnnotation returns [StorableAnnotation result] : STORABLE ( ^( STORAGE_PATH_ADDER (s1= STRING |field= ID ) ) )+ ( ^( STORABLE_SEPARATOR separator= STRING ) )? ( ^( STORABLE_ENCODING encoding= STRING ) )? ( ^( STORABLE_TTL_DAYS ttlValue= INT ) )? ( ^( STORABLE_PREFIX prefix= STRING ) )? ( ^( STORABLE_REPO_NAME repoConstant= ID ) )? ( ^( STORABLE_REPO_NAME repoName= STRING ) )? ;
public final TTreeDotNet_TTreeShared.storableAnnotation_return storableAnnotation() throws RecognitionException {
storableAnnotation_stack.push(new storableAnnotation_scope());
TTreeDotNet_TTreeShared.storableAnnotation_return retval = new TTreeDotNet_TTreeShared.storableAnnotation_return();
retval.start = input.LT(1);
CommonTree s1=null;
CommonTree field=null;
CommonTree separator=null;
CommonTree encoding=null;
CommonTree ttlValue=null;
CommonTree prefix=null;
CommonTree repoConstant=null;
CommonTree repoName=null;
storableAnnotation_stack.peek().annotation = new StorableAnnotation();
try {
// TTreeShared.g:76:5: ( STORABLE ( ^( STORAGE_PATH_ADDER (s1= STRING |field= ID ) ) )+ ( ^( STORABLE_SEPARATOR separator= STRING ) )? ( ^( STORABLE_ENCODING encoding= STRING ) )? ( ^( STORABLE_TTL_DAYS ttlValue= INT ) )? ( ^( STORABLE_PREFIX prefix= STRING ) )? ( ^( STORABLE_REPO_NAME repoConstant= ID ) )? ( ^( STORABLE_REPO_NAME repoName= STRING ) )? )
// TTreeShared.g:76:7: STORABLE ( ^( STORAGE_PATH_ADDER (s1= STRING |field= ID ) ) )+ ( ^( STORABLE_SEPARATOR separator= STRING ) )? ( ^( STORABLE_ENCODING encoding= STRING ) )? ( ^( STORABLE_TTL_DAYS ttlValue= INT ) )? ( ^( STORABLE_PREFIX prefix= STRING ) )? ( ^( STORABLE_REPO_NAME repoConstant= ID ) )? ( ^( STORABLE_REPO_NAME repoName= STRING ) )?
{
match(input,STORABLE,FOLLOW_STORABLE_in_storableAnnotation328);
// TTreeShared.g:77:7: ( ^( STORAGE_PATH_ADDER (s1= STRING |field= ID ) ) )+
int cnt7=0;
loop7:
while (true) {
int alt7=2;
int LA7_0 = input.LA(1);
if ( (LA7_0==STORAGE_PATH_ADDER) ) {
alt7=1;
}
switch (alt7) {
case 1 :
// TTreeShared.g:77:8: ^( STORAGE_PATH_ADDER (s1= STRING |field= ID ) )
{
match(input,STORAGE_PATH_ADDER,FOLLOW_STORAGE_PATH_ADDER_in_storableAnnotation339);
match(input, Token.DOWN, null);
// TTreeShared.g:78:8: (s1= STRING |field= ID )
int alt6=2;
int LA6_0 = input.LA(1);
if ( (LA6_0==STRING) ) {
alt6=1;
}
else if ( (LA6_0==ID) ) {
alt6=2;
}
else {
NoViableAltException nvae =
new NoViableAltException("", 6, 0, input);
throw nvae;
}
switch (alt6) {
case 1 :
// TTreeShared.g:78:9: s1= STRING
{
s1=(CommonTree)match(input,STRING,FOLLOW_STRING_in_storableAnnotation352);
storableAnnotation_stack.peek().annotation.addField((s1!=null?s1.getText():null), com.incapture.rapgen.annotations.storable.StorableFieldType.STRING);
}
break;
case 2 :
// TTreeShared.g:79:10: field= ID
{
field=(CommonTree)match(input,ID,FOLLOW_ID_in_storableAnnotation367);
storableAnnotation_stack.peek().annotation.addField((field!=null?field.getText():null), com.incapture.rapgen.annotations.storable.StorableFieldType.ID);
}
break;
}
match(input, Token.UP, null);
}
break;
default :
if ( cnt7 >= 1 ) break loop7;
EarlyExitException eee = new EarlyExitException(7, input);
throw eee;
}
cnt7++;
}
// TTreeShared.g:81:7: ( ^( STORABLE_SEPARATOR separator= STRING ) )?
int alt8=2;
int LA8_0 = input.LA(1);
if ( (LA8_0==STORABLE_SEPARATOR) ) {
alt8=1;
}
switch (alt8) {
case 1 :
// TTreeShared.g:81:8: ^( STORABLE_SEPARATOR separator= STRING )
{
match(input,STORABLE_SEPARATOR,FOLLOW_STORABLE_SEPARATOR_in_storableAnnotation390);
match(input, Token.DOWN, null);
separator=(CommonTree)match(input,STRING,FOLLOW_STRING_in_storableAnnotation394);
storableAnnotation_stack.peek().annotation.setSeparator((separator!=null?separator.getText():null));
match(input, Token.UP, null);
}
break;
}
// TTreeShared.g:82:7: ( ^( STORABLE_ENCODING encoding= STRING ) )?
int alt9=2;
int LA9_0 = input.LA(1);
if ( (LA9_0==STORABLE_ENCODING) ) {
alt9=1;
}
switch (alt9) {
case 1 :
// TTreeShared.g:82:8: ^( STORABLE_ENCODING encoding= STRING )
{
match(input,STORABLE_ENCODING,FOLLOW_STORABLE_ENCODING_in_storableAnnotation410);
match(input, Token.DOWN, null);
encoding=(CommonTree)match(input,STRING,FOLLOW_STRING_in_storableAnnotation414);
storableAnnotation_stack.peek().annotation.setEncodingType((encoding!=null?encoding.getText():null));
match(input, Token.UP, null);
}
break;
}
// TTreeShared.g:83:7: ( ^( STORABLE_TTL_DAYS ttlValue= INT ) )?
int alt10=2;
int LA10_0 = input.LA(1);
if ( (LA10_0==STORABLE_TTL_DAYS) ) {
alt10=1;
}
switch (alt10) {
case 1 :
// TTreeShared.g:83:8: ^( STORABLE_TTL_DAYS ttlValue= INT )
{
match(input,STORABLE_TTL_DAYS,FOLLOW_STORABLE_TTL_DAYS_in_storableAnnotation430);
match(input, Token.DOWN, null);
ttlValue=(CommonTree)match(input,INT,FOLLOW_INT_in_storableAnnotation434);
storableAnnotation_stack.peek().annotation.setTtlDays(ttlValue);
match(input, Token.UP, null);
}
break;
}
// TTreeShared.g:84:7: ( ^( STORABLE_PREFIX prefix= STRING ) )?
int alt11=2;
int LA11_0 = input.LA(1);
if ( (LA11_0==STORABLE_PREFIX) ) {
alt11=1;
}
switch (alt11) {
case 1 :
// TTreeShared.g:84:8: ^( STORABLE_PREFIX prefix= STRING )
{
match(input,STORABLE_PREFIX,FOLLOW_STORABLE_PREFIX_in_storableAnnotation450);
match(input, Token.DOWN, null);
prefix=(CommonTree)match(input,STRING,FOLLOW_STRING_in_storableAnnotation454);
storableAnnotation_stack.peek().annotation.setPrefix((prefix!=null?prefix.getText():null));
match(input, Token.UP, null);
}
break;
}
// TTreeShared.g:85:7: ( ^( STORABLE_REPO_NAME repoConstant= ID ) )?
int alt12=2;
int LA12_0 = input.LA(1);
if ( (LA12_0==STORABLE_REPO_NAME) ) {
int LA12_1 = input.LA(2);
if ( (LA12_1==DOWN) ) {
int LA12_3 = input.LA(3);
if ( (LA12_3==ID) ) {
alt12=1;
}
}
}
switch (alt12) {
case 1 :
// TTreeShared.g:85:8: ^( STORABLE_REPO_NAME repoConstant= ID )
{
match(input,STORABLE_REPO_NAME,FOLLOW_STORABLE_REPO_NAME_in_storableAnnotation470);
match(input, Token.DOWN, null);
repoConstant=(CommonTree)match(input,ID,FOLLOW_ID_in_storableAnnotation474);
storableAnnotation_stack.peek().annotation.setRepoConstant((repoConstant!=null?repoConstant.getText():null));
match(input, Token.UP, null);
}
break;
}
// TTreeShared.g:86:7: ( ^( STORABLE_REPO_NAME repoName= STRING ) )?
int alt13=2;
int LA13_0 = input.LA(1);
if ( (LA13_0==STORABLE_REPO_NAME) ) {
alt13=1;
}
switch (alt13) {
case 1 :
// TTreeShared.g:86:8: ^( STORABLE_REPO_NAME repoName= STRING )
{
match(input,STORABLE_REPO_NAME,FOLLOW_STORABLE_REPO_NAME_in_storableAnnotation490);
match(input, Token.DOWN, null);
repoName=(CommonTree)match(input,STRING,FOLLOW_STRING_in_storableAnnotation494);
storableAnnotation_stack.peek().annotation.setRepoName((repoName!=null?repoName.getText():null));
match(input, Token.UP, null);
}
break;
}
retval.result = storableAnnotation_stack.peek().annotation;
}
}
catch (RecognitionException re) {
reportError(re);
recover(input,re);
}
finally {
// do for sure before leaving
storableAnnotation_stack.pop();
}
return retval;
}
// $ANTLR end "storableAnnotation"
public static class deprecatedAnnotation_return extends TreeRuleReturnScope {
public DeprecatedAnnotation result;
public StringTemplate st;
public Object getTemplate() { return st; }
public String toString() { return st==null?null:st.toString(); }
};
// $ANTLR start "deprecatedAnnotation"
// TTreeShared.g:90:1: deprecatedAnnotation returns [DeprecatedAnnotation result] : ( ( DEPRECATED ID ) | ( DEPRECATED STRING ) );
public final TTreeDotNet_TTreeShared.deprecatedAnnotation_return deprecatedAnnotation() throws RecognitionException {
TTreeDotNet_TTreeShared.deprecatedAnnotation_return retval = new TTreeDotNet_TTreeShared.deprecatedAnnotation_return();
retval.start = input.LT(1);
CommonTree ID2=null;
CommonTree STRING3=null;
try {
// TTreeShared.g:92:5: ( ( DEPRECATED ID ) | ( DEPRECATED STRING ) )
int alt14=2;
int LA14_0 = input.LA(1);
if ( (LA14_0==DEPRECATED) ) {
int LA14_1 = input.LA(2);
if ( (LA14_1==ID) ) {
alt14=1;
}
else if ( (LA14_1==STRING) ) {
alt14=2;
}
else {
int nvaeMark = input.mark();
try {
input.consume();
NoViableAltException nvae =
new NoViableAltException("", 14, 1, input);
throw nvae;
} finally {
input.rewind(nvaeMark);
}
}
}
else {
NoViableAltException nvae =
new NoViableAltException("", 14, 0, input);
throw nvae;
}
switch (alt14) {
case 1 :
// TTreeShared.g:92:7: ( DEPRECATED ID )
{
// TTreeShared.g:92:7: ( DEPRECATED ID )
// TTreeShared.g:92:9: DEPRECATED ID
{
match(input,DEPRECATED,FOLLOW_DEPRECATED_in_deprecatedAnnotation533);
ID2=(CommonTree)match(input,ID,FOLLOW_ID_in_deprecatedAnnotation535);
retval.result = new DeprecatedAnnotation((ID2!=null?ID2.getText():null));
}
}
break;
case 2 :
// TTreeShared.g:93:7: ( DEPRECATED STRING )
{
// TTreeShared.g:93:7: ( DEPRECATED STRING )
// TTreeShared.g:93:9: DEPRECATED STRING
{
match(input,DEPRECATED,FOLLOW_DEPRECATED_in_deprecatedAnnotation550);
STRING3=(CommonTree)match(input,STRING,FOLLOW_STRING_in_deprecatedAnnotation552);
retval.result = new DeprecatedAnnotation((STRING3!=null?STRING3.getText():null).substring(1, (STRING3!=null?STRING3.getText():null).length() -1));
}
}
break;
}
}
catch (RecognitionException re) {
reportError(re);
recover(input,re);
}
finally {
// do for sure before leaving
}
return retval;
}
// $ANTLR end "deprecatedAnnotation"
protected static class indexedAnnotation_scope {
IndexedAnnotation annotation;
}
protected Stack indexedAnnotation_stack = new Stack();
public static class indexedAnnotation_return extends TreeRuleReturnScope {
public IndexedAnnotation result;
public StringTemplate st;
public Object getTemplate() { return st; }
public String toString() { return st==null?null:st.toString(); }
};
// $ANTLR start "indexedAnnotation"
// TTreeShared.g:96:1: indexedAnnotation returns [IndexedAnnotation result] : INDEXED ^( INDEX_NAME ( STRING ) ) ( ^( INDEX_COMPONENT ( ID ) ) )+ ;
public final TTreeDotNet_TTreeShared.indexedAnnotation_return indexedAnnotation() throws RecognitionException {
indexedAnnotation_stack.push(new indexedAnnotation_scope());
TTreeDotNet_TTreeShared.indexedAnnotation_return retval = new TTreeDotNet_TTreeShared.indexedAnnotation_return();
retval.start = input.LT(1);
CommonTree STRING4=null;
CommonTree ID5=null;
indexedAnnotation_stack.peek().annotation = new IndexedAnnotation();
try {
// TTreeShared.g:104:5: ( INDEXED ^( INDEX_NAME ( STRING ) ) ( ^( INDEX_COMPONENT ( ID ) ) )+ )
// TTreeShared.g:104:7: INDEXED ^( INDEX_NAME ( STRING ) ) ( ^( INDEX_COMPONENT ( ID ) ) )+
{
match(input,INDEXED,FOLLOW_INDEXED_in_indexedAnnotation596);
match(input,INDEX_NAME,FOLLOW_INDEX_NAME_in_indexedAnnotation599);
match(input, Token.DOWN, null);
// TTreeShared.g:104:27: ( STRING )
// TTreeShared.g:104:28: STRING
{
STRING4=(CommonTree)match(input,STRING,FOLLOW_STRING_in_indexedAnnotation601);
indexedAnnotation_stack.peek().annotation.setName((STRING4!=null?STRING4.getText():null).substring(1, (STRING4!=null?STRING4.getText():null).length() - 1));
}
match(input, Token.UP, null);
// TTreeShared.g:105:7: ( ^( INDEX_COMPONENT ( ID ) ) )+
int cnt15=0;
loop15:
while (true) {
int alt15=2;
int LA15_0 = input.LA(1);
if ( (LA15_0==INDEX_COMPONENT) ) {
alt15=1;
}
switch (alt15) {
case 1 :
// TTreeShared.g:105:8: ^( INDEX_COMPONENT ( ID ) )
{
match(input,INDEX_COMPONENT,FOLLOW_INDEX_COMPONENT_in_indexedAnnotation616);
match(input, Token.DOWN, null);
// TTreeShared.g:105:25: ( ID )
// TTreeShared.g:105:26: ID
{
ID5=(CommonTree)match(input,ID,FOLLOW_ID_in_indexedAnnotation618);
indexedAnnotation_stack.peek().annotation.addField((ID5!=null?ID5.getText():null));
}
match(input, Token.UP, null);
}
break;
default :
if ( cnt15 >= 1 ) break loop15;
EarlyExitException eee = new EarlyExitException(15, input);
throw eee;
}
cnt15++;
}
retval.result = indexedAnnotation_stack.peek().annotation;
}
}
catch (RecognitionException re) {
reportError(re);
recover(input,re);
}
finally {
// do for sure before leaving
indexedAnnotation_stack.pop();
}
return retval;
}
// $ANTLR end "indexedAnnotation"
protected static class extendsAnnotation_scope {
StringBuilder sb;
}
protected Stack extendsAnnotation_stack = new Stack();
public static class extendsAnnotation_return extends TreeRuleReturnScope {
public ExtendsAnnotation result;
public StringTemplate st;
public Object getTemplate() { return st; }
public String toString() { return st==null?null:st.toString(); }
};
// $ANTLR start "extendsAnnotation"
// TTreeShared.g:109:1: extendsAnnotation returns [ExtendsAnnotation result] : EXTENDS PACKAGENAME ID ;
public final TTreeDotNet_TTreeShared.extendsAnnotation_return extendsAnnotation() throws RecognitionException {
extendsAnnotation_stack.push(new extendsAnnotation_scope());
TTreeDotNet_TTreeShared.extendsAnnotation_return retval = new TTreeDotNet_TTreeShared.extendsAnnotation_return();
retval.start = input.LT(1);
CommonTree PACKAGENAME6=null;
CommonTree ID7=null;
extendsAnnotation_stack.peek().sb = new StringBuilder();
try {
// TTreeShared.g:117:5: ( EXTENDS PACKAGENAME ID )
// TTreeShared.g:117:7: EXTENDS PACKAGENAME ID
{
match(input,EXTENDS,FOLLOW_EXTENDS_in_extendsAnnotation664);
PACKAGENAME6=(CommonTree)match(input,PACKAGENAME,FOLLOW_PACKAGENAME_in_extendsAnnotation666);
ID7=(CommonTree)match(input,ID,FOLLOW_ID_in_extendsAnnotation668);
retval.result = new ExtendsAnnotation((PACKAGENAME6!=null?PACKAGENAME6.getText():null) + "." + (ID7!=null?ID7.getText():null));
}
}
catch (RecognitionException re) {
reportError(re);
recover(input,re);
}
finally {
// do for sure before leaving
extendsAnnotation_stack.pop();
}
return retval;
}
// $ANTLR end "extendsAnnotation"
protected static class fieldConstructor_scope {
StringBuilder sb;
}
protected Stack fieldConstructor_stack = new Stack();
public static class fieldConstructor_return extends TreeRuleReturnScope {
public String constructor;
public StringTemplate st;
public Object getTemplate() { return st; }
public String toString() { return st==null?null:st.toString(); }
};
// $ANTLR start "fieldConstructor"
// TTreeShared.g:121:1: fieldConstructor returns [String constructor] : (val= NEW )? (val= (~ NEW ) )+ ;
public final TTreeDotNet_TTreeShared.fieldConstructor_return fieldConstructor() throws RecognitionException {
fieldConstructor_stack.push(new fieldConstructor_scope());
TTreeDotNet_TTreeShared.fieldConstructor_return retval = new TTreeDotNet_TTreeShared.fieldConstructor_return();
retval.start = input.LT(1);
CommonTree val=null;
fieldConstructor_stack.peek().sb = new StringBuilder();
try {
// TTreeShared.g:128:5: ( (val= NEW )? (val= (~ NEW ) )+ )
// TTreeShared.g:129:7: (val= NEW )? (val= (~ NEW ) )+
{
// TTreeShared.g:129:7: (val= NEW )?
int alt16=2;
int LA16_0 = input.LA(1);
if ( (LA16_0==NEW) ) {
alt16=1;
}
switch (alt16) {
case 1 :
// TTreeShared.g:129:8: val= NEW
{
val=(CommonTree)match(input,NEW,FOLLOW_NEW_in_fieldConstructor714);
fieldConstructor_stack.peek().sb.append(val).append(" ");
}
break;
}
// TTreeShared.g:130:7: (val= (~ NEW ) )+
int cnt17=0;
loop17:
while (true) {
int alt17=2;
int LA17_0 = input.LA(1);
if ( ((LA17_0 >= ADDRESSABLE && LA17_0 <= MINUS)||(LA17_0 >= OBJECTTYPE && LA17_0 <= 143)) ) {
alt17=1;
}
switch (alt17) {
case 1 :
// TTreeShared.g:130:8: val= (~ NEW )
{
val=(CommonTree)input.LT(1);
if ( (input.LA(1) >= ADDRESSABLE && input.LA(1) <= MINUS)||(input.LA(1) >= OBJECTTYPE && input.LA(1) <= 143) ) {
input.consume();
state.errorRecovery=false;
}
else {
MismatchedSetException mse = new MismatchedSetException(null,input);
throw mse;
}
fieldConstructor_stack.peek().sb.append(val);
}
break;
default :
if ( cnt17 >= 1 ) break loop17;
EarlyExitException eee = new EarlyExitException(17, input);
throw eee;
}
cnt17++;
}
retval.constructor = fieldConstructor_stack.peek().sb.toString();
}
}
catch (RecognitionException re) {
reportError(re);
recover(input,re);
}
finally {
// do for sure before leaving
fieldConstructor_stack.pop();
}
return retval;
}
// $ANTLR end "fieldConstructor"
// Delegated rules
public static final BitSet FOLLOW_VERSIONDEF_in_versionExpr51 = new BitSet(new long[]{0x0000000000000004L});
public static final BitSet FOLLOW_INT_in_versionExpr55 = new BitSet(new long[]{0x0000000200000000L});
public static final BitSet FOLLOW_INT_in_versionExpr59 = new BitSet(new long[]{0x0000000200000008L});
public static final BitSet FOLLOW_INT_in_versionExpr64 = new BitSet(new long[]{0x0000000000000008L});
public static final BitSet FOLLOW_MINVERSIONDEF_in_minVerExpr83 = new BitSet(new long[]{0x0000000000000004L});
public static final BitSet FOLLOW_INT_in_minVerExpr87 = new BitSet(new long[]{0x0000000200000000L});
public static final BitSet FOLLOW_INT_in_minVerExpr91 = new BitSet(new long[]{0x0000000200000008L});
public static final BitSet FOLLOW_INT_in_minVerExpr96 = new BitSet(new long[]{0x0000000000000008L});
public static final BitSet FOLLOW_BEAN_in_beanAnnotation119 = new BitSet(new long[]{0x0000000000000002L});
public static final BitSet FOLLOW_FTS_in_ftsAnnotation139 = new BitSet(new long[]{0x0000000000000002L});
public static final BitSet FOLLOW_SEARCHABLE_in_searchableAnnotation161 = new BitSet(new long[]{0x0000000000000002L});
public static final BitSet FOLLOW_CACHEABLE_in_cacheableAnnotation188 = new BitSet(new long[]{0x0000000800000002L});
public static final BitSet FOLLOW_LBRAC_in_cacheableAnnotation193 = new BitSet(new long[]{0x0000000040000000L});
public static final BitSet FOLLOW_ID_in_cacheableAnnotation195 = new BitSet(new long[]{0x0000000002000000L});
public static final BitSet FOLLOW_EQUAL_in_cacheableAnnotation197 = new BitSet(new long[]{0x0000000008000000L,0x0000000000000001L});
public static final BitSet FOLLOW_TRUE_in_cacheableAnnotation200 = new BitSet(new long[]{0x0004000000000000L});
public static final BitSet FOLLOW_FALSE_in_cacheableAnnotation206 = new BitSet(new long[]{0x0004000000000000L});
public static final BitSet FOLLOW_RBRAC_in_cacheableAnnotation209 = new BitSet(new long[]{0x0000000000000002L});
public static final BitSet FOLLOW_ADDRESSABLE_in_addressableAnnotation246 = new BitSet(new long[]{0x0000000040000000L});
public static final BitSet FOLLOW_ID_in_addressableAnnotation248 = new BitSet(new long[]{0x0000000008000002L,0x0000000000000001L});
public static final BitSet FOLLOW_TRUE_in_addressableAnnotation260 = new BitSet(new long[]{0x0000000000000002L});
public static final BitSet FOLLOW_FALSE_in_addressableAnnotation275 = new BitSet(new long[]{0x0000000000000002L});
public static final BitSet FOLLOW_STORABLE_in_storableAnnotation328 = new BitSet(new long[]{0x0000000000000000L,0x0000020000000000L});
public static final BitSet FOLLOW_STORAGE_PATH_ADDER_in_storableAnnotation339 = new BitSet(new long[]{0x0000000000000004L});
public static final BitSet FOLLOW_STRING_in_storableAnnotation352 = new BitSet(new long[]{0x0000000000000008L});
public static final BitSet FOLLOW_ID_in_storableAnnotation367 = new BitSet(new long[]{0x0000000000000008L});
public static final BitSet FOLLOW_STORABLE_SEPARATOR_in_storableAnnotation390 = new BitSet(new long[]{0x0000000000000004L});
public static final BitSet FOLLOW_STRING_in_storableAnnotation394 = new BitSet(new long[]{0x0000000000000008L});
public static final BitSet FOLLOW_STORABLE_ENCODING_in_storableAnnotation410 = new BitSet(new long[]{0x0000000000000004L});
public static final BitSet FOLLOW_STRING_in_storableAnnotation414 = new BitSet(new long[]{0x0000000000000008L});
public static final BitSet FOLLOW_STORABLE_TTL_DAYS_in_storableAnnotation430 = new BitSet(new long[]{0x0000000000000004L});
public static final BitSet FOLLOW_INT_in_storableAnnotation434 = new BitSet(new long[]{0x0000000000000008L});
public static final BitSet FOLLOW_STORABLE_PREFIX_in_storableAnnotation450 = new BitSet(new long[]{0x0000000000000004L});
public static final BitSet FOLLOW_STRING_in_storableAnnotation454 = new BitSet(new long[]{0x0000000000000008L});
public static final BitSet FOLLOW_STORABLE_REPO_NAME_in_storableAnnotation470 = new BitSet(new long[]{0x0000000000000004L});
public static final BitSet FOLLOW_ID_in_storableAnnotation474 = new BitSet(new long[]{0x0000000000000008L});
public static final BitSet FOLLOW_STORABLE_REPO_NAME_in_storableAnnotation490 = new BitSet(new long[]{0x0000000000000004L});
public static final BitSet FOLLOW_STRING_in_storableAnnotation494 = new BitSet(new long[]{0x0000000000000008L});
public static final BitSet FOLLOW_DEPRECATED_in_deprecatedAnnotation533 = new BitSet(new long[]{0x0000000040000000L});
public static final BitSet FOLLOW_ID_in_deprecatedAnnotation535 = new BitSet(new long[]{0x0000000000000002L});
public static final BitSet FOLLOW_DEPRECATED_in_deprecatedAnnotation550 = new BitSet(new long[]{0x4000000000000000L});
public static final BitSet FOLLOW_STRING_in_deprecatedAnnotation552 = new BitSet(new long[]{0x0000000000000002L});
public static final BitSet FOLLOW_INDEXED_in_indexedAnnotation596 = new BitSet(new long[]{0x0000000000000000L,0x0000000000040000L});
public static final BitSet FOLLOW_INDEX_NAME_in_indexedAnnotation599 = new BitSet(new long[]{0x0000000000000004L});
public static final BitSet FOLLOW_STRING_in_indexedAnnotation601 = new BitSet(new long[]{0x0000000000000008L});
public static final BitSet FOLLOW_INDEX_COMPONENT_in_indexedAnnotation616 = new BitSet(new long[]{0x0000000000000004L});
public static final BitSet FOLLOW_ID_in_indexedAnnotation618 = new BitSet(new long[]{0x0000000000000008L});
public static final BitSet FOLLOW_EXTENDS_in_extendsAnnotation664 = new BitSet(new long[]{0x0000800000000000L});
public static final BitSet FOLLOW_PACKAGENAME_in_extendsAnnotation666 = new BitSet(new long[]{0x0000000040000000L});
public static final BitSet FOLLOW_ID_in_extendsAnnotation668 = new BitSet(new long[]{0x0000000000000002L});
public static final BitSet FOLLOW_NEW_in_fieldConstructor714 = new BitSet(new long[]{0xFFFFF7FFFFFFFFF0L,0xFFFFFFFFFFFFFFFFL,0x000000000000FFFFL});
public static final BitSet FOLLOW_set_in_fieldConstructor730 = new BitSet(new long[]{0xFFFFF7FFFFFFFFF2L,0xFFFFFFFFFFFFFFFFL,0x000000000000FFFFL});
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy