Package adams.parser.templatesuggestion
Class Parser
- java.lang.Object
-
- java_cup.runtime.lr_parser
-
- adams.parser.templatesuggestion.Parser
-
public class Parser extends java_cup.runtime.lr_parserCUP v0.11b 20160615 (GIT 4ac7450) generated parser.
-
-
Field Summary
Fields Modifier and Type Field Description protected static short[][]_action_tableParse-action table.protected static short[][]_production_tableProduction table.protected static short[][]_reduce_tablereduce_gototable.protected adams.parser.templatesuggestion.Parser.CUP$Parser$actionsaction_objInstance of action encapsulation class.protected Actor[]m_Actorsall the current nodes in which to insert/add to the proposed actor.protected ParserHelperm_Helperthe helper.protected Actorm_Parentthe parent of the where to suggest the template.protected Integerm_Positionthe position to add the proposed actor template at.protected AbstractActorTemplatem_Resultfor storing the result of the expression.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description short[][]action_table()Access to parse-action table.java_cup.runtime.Symboldo_action(int act_num, java_cup.runtime.lr_parser parser, Stack stack, int top)Invoke a user supplied parse action.intEOF_sym()EOFSymbol index.interror_sym()errorSymbol index.Actor[]getActors()Returns the actors in which to insert the proposed template.ParserHelpergetHelper()Returns the parser helper.ActorgetParent()Returns the parent of the proposed template.IntegergetPosition()Returns the position of the proposed template.AbstractActorTemplategetResult()Returns the result of the evaluation.ClassgetSymbolContainer()protected voidinit_actions()Action encapsulation object initializer.BooleanisClassname(boolean before, String classname)Checks whether the actor will get added before or after a specific actor (exact classname or interface classname).BooleanisFirst()Returns whether the proposed actor will get added at the first position.BooleanisLast()Returns whether the proposed actor will get added at the last position.BooleanisSink(boolean before)Checks whether the actor will get added before or after a sink actor.BooleanisSource(boolean before)Checks whether the actor will get added before or after a source actor.BooleanisStandalone(boolean before)Checks whether the actor will get added before or after a standalone actor.BooleanisTransformer(boolean before)Checks whether the actor will get added before or after a transformer actor.short[][]production_table()Access to production table.short[][]reduce_table()Access toreduce_gototable.voidsetActors(Actor[] value)Sets the actors in which to insert the proposed template.voidsetParent(Actor value)Sets the parent of the proposed template.voidsetPosition(Integer value)Sets the position of the proposed template.voidsetResult(AbstractActorTemplate value)Sets the result of the evaluation.intstart_production()Indicates start production.intstart_state()Indicates start state.-
Methods inherited from class java_cup.runtime.lr_parser
advance_lookahead, cur_err_token, debug_message, debug_parse, debug_reduce, debug_shift, debug_stack, done_parsing, dump_stack, error_recovery, error_sync_size, expected_token_ids, find_recovery_config, get_action, get_reduce, getScanner, getSymbolFactory, parse, parse_lookahead, read_lookahead, report_error, report_expected_token_ids, report_fatal_error, restart_lookahead, scan, setScanner, shift_under_error, symbl_name_from_id, syntax_error, try_parse_ahead, unpackFromStrings, unrecovered_syntax_error, user_init
-
-
-
-
Field Detail
-
_production_table
protected static final short[][] _production_table
Production table.
-
_action_table
protected static final short[][] _action_table
Parse-action table.
-
_reduce_table
protected static final short[][] _reduce_table
reduce_gototable.
-
action_obj
protected adams.parser.templatesuggestion.Parser.CUP$Parser$actions action_obj
Instance of action encapsulation class.
-
m_Helper
protected ParserHelper m_Helper
the helper.
-
m_Result
protected AbstractActorTemplate m_Result
for storing the result of the expression.
-
m_Parent
protected Actor m_Parent
the parent of the where to suggest the template.
-
m_Position
protected Integer m_Position
the position to add the proposed actor template at.
-
m_Actors
protected Actor[] m_Actors
all the current nodes in which to insert/add to the proposed actor.
-
-
Constructor Detail
-
Parser
@Deprecated public Parser()
Deprecated.Default constructor.
-
Parser
@Deprecated public Parser(java_cup.runtime.Scanner s)
Deprecated.Constructor which sets the default scanner.
-
Parser
public Parser(java_cup.runtime.Scanner s, java_cup.runtime.SymbolFactory sf)Constructor which sets the default scanner.
-
-
Method Detail
-
getSymbolContainer
public final Class getSymbolContainer()
- Overrides:
getSymbolContainerin classjava_cup.runtime.lr_parser
-
production_table
public short[][] production_table()
Access to production table.- Specified by:
production_tablein classjava_cup.runtime.lr_parser
-
action_table
public short[][] action_table()
Access to parse-action table.- Specified by:
action_tablein classjava_cup.runtime.lr_parser
-
reduce_table
public short[][] reduce_table()
Access toreduce_gototable.- Specified by:
reduce_tablein classjava_cup.runtime.lr_parser
-
init_actions
protected void init_actions()
Action encapsulation object initializer.- Specified by:
init_actionsin classjava_cup.runtime.lr_parser
-
do_action
public java_cup.runtime.Symbol do_action(int act_num, java_cup.runtime.lr_parser parser, Stack stack, int top) throws ExceptionInvoke a user supplied parse action.- Specified by:
do_actionin classjava_cup.runtime.lr_parser- Throws:
Exception
-
start_state
public int start_state()
Indicates start state.- Specified by:
start_statein classjava_cup.runtime.lr_parser
-
start_production
public int start_production()
Indicates start production.- Specified by:
start_productionin classjava_cup.runtime.lr_parser
-
EOF_sym
public int EOF_sym()
EOFSymbol index.- Specified by:
EOF_symin classjava_cup.runtime.lr_parser
-
error_sym
public int error_sym()
errorSymbol index.- Specified by:
error_symin classjava_cup.runtime.lr_parser
-
getHelper
public ParserHelper getHelper()
Returns the parser helper.- Returns:
- the helper
-
setResult
public void setResult(AbstractActorTemplate value)
Sets the result of the evaluation.- Parameters:
value- the result
-
getResult
public AbstractActorTemplate getResult()
Returns the result of the evaluation.- Returns:
- the result
-
setParent
public void setParent(Actor value)
Sets the parent of the proposed template.- Parameters:
value- the parent
-
getParent
public Actor getParent()
Returns the parent of the proposed template.- Returns:
- the parent
-
setPosition
public void setPosition(Integer value)
Sets the position of the proposed template.- Parameters:
value- the position
-
getPosition
public Integer getPosition()
Returns the position of the proposed template.- Returns:
- the position
-
setActors
public void setActors(Actor[] value)
Sets the actors in which to insert the proposed template.- Parameters:
value- the actors
-
getActors
public Actor[] getActors()
Returns the actors in which to insert the proposed template.- Returns:
- the actors
-
isFirst
public Boolean isFirst()
Returns whether the proposed actor will get added at the first position.- Returns:
- true if the actor gets added at the first position
-
isLast
public Boolean isLast()
Returns whether the proposed actor will get added at the last position.- Returns:
- true if the actor gets added at the last position
-
isStandalone
public Boolean isStandalone(boolean before)
Checks whether the actor will get added before or after a standalone actor.- Parameters:
before- whether the actor gets added before or after- Returns:
- true if the actor gets added before/after a standalone one
-
isSource
public Boolean isSource(boolean before)
Checks whether the actor will get added before or after a source actor.- Parameters:
before- whether the actor gets added before or after- Returns:
- true if the actor gets added before/after a source one
-
isTransformer
public Boolean isTransformer(boolean before)
Checks whether the actor will get added before or after a transformer actor.- Parameters:
before- whether the actor gets added before or after- Returns:
- true if the actor gets added before/after a transformer one
-
isSink
public Boolean isSink(boolean before)
Checks whether the actor will get added before or after a sink actor.- Parameters:
before- whether the actor gets added before or after- Returns:
- true if the actor gets added before/after a sink one
-
isClassname
public Boolean isClassname(boolean before, String classname)
Checks whether the actor will get added before or after a specific actor (exact classname or interface classname).- Parameters:
before- whether the actor gets added before or afterclassname- the name of the actor to check against- Returns:
- true if the actor gets added before/after a specific one
-
-