Package eu.bandm.tools.d2d2.base
Class StackPrinter.FollowSet
java.lang.Object
eu.bandm.tools.umod.runtime.OptimizingVisitor
eu.bandm.tools.d2d2.rt.MATCH_ONLY_00
eu.bandm.tools.d2d2.rt.SinglePhase_rt
eu.bandm.tools.d2d2.base.StackPrinter.FollowSet
- Enclosing class:
- StackPrinter
Single-use tool to find all sub-expressions of the current content model which
are allowed to enter as next input in the current parsing situation.
Operates for a certain State_singleton, which represents an
element definition and its contents model.
The total parsing state is realized by the stack frames "above" this
State_singleton: (a) by index positions in a State_sequ,
(b) by the "check list" in a State_perm.
The collected set is used for highlighting in error message
stack frame prints. It can be used to show the correct alternatives
to some erroneous input.
-
Nested Class Summary
Modifier and TypeClassDescriptionprotected class
Put all reached references into the global setresult
and stop after a non-epsilon sequence element.protected class
Is thrown to signal the end of the search for possible input tags in a sequence state.Nested classes/interfaces inherited from class eu.bandm.tools.umod.runtime.OptimizingVisitor
OptimizingVisitor.DataByName
-
Field Summary
Modifier and TypeFieldDescriptionstatic final Set<Expression>
Empty result setstatic final Reference
Pseudo-reference to mark empty content.protected Set<Expression>
The result to return.Fields inherited from class eu.bandm.tools.d2d2.rt.MATCH_ONLY_00
_visitor_debug_stream, partial
Fields inherited from class eu.bandm.tools.umod.runtime.OptimizingVisitor
affectedClasses, fieldFlags, hasdescend, haspost, haspre, methodname_action, METHODNAME_allFields2codeNumber, METHODNAMEPREFIX_DESCEND, SUFFIX_FILENAME_SCC_DATA
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
action
(State_perm permstate) Extract all first-tags of all sub-expresions, which have not been used yet.void
Add the allowed input for this parsing state to the result set.void
action
(State_sequ state) Extract all first-tags of the suffix of the sequence, starting after the current position.Central service method: calculate the result.Methods inherited from class eu.bandm.tools.d2d2.rt.SinglePhase_rt
action, action, action, action, action, action, action, action, action, action, action, action, collectFlags, follow_assoc, follow_consumed, follow_obligates, follow_sequ, follow_subs, follow_subs, getKey, getLowestGeneratedClass
Methods inherited from class eu.bandm.tools.d2d2.rt.MATCH_ONLY_00
_visitor_trace, action, action, action, action, action, action, action, action, action, action, action, allFields2codeNumber, compile, followAll_assoc, followAll_consumed, followAll_obligates, followAll_sequ, followAll_subs, followAll_subs, foreignObject, get_class2reachedSccs, get_class2scc, get_field2sccs, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, nomatch
Methods inherited from class eu.bandm.tools.umod.runtime.OptimizingVisitor
calculateFlags, collectFlags_action, collectFlags_actionPreDescendPost, collectFlags_actionRewritefields, collectMethods, readSccData
-
Field Details
-
result
The result to return. -
epsilonRefence
Pseudo-reference to mark empty content. -
empty
Empty result set
-
-
Constructor Details
-
FollowSet
protected FollowSet()
-
-
Method Details
-
calculate
Central service method: calculate the result. -
action
Add the allowed input for this parsing state to the result set.- Overrides:
action
in classSinglePhase_rt
-
action
Extract all first-tags of the suffix of the sequence, starting after the current position.- Overrides:
action
in classSinglePhase_rt
-
action
Extract all first-tags of all sub-expresions, which have not been used yet.- Overrides:
action
in classSinglePhase_rt
-