Class: PredPrediction
Overview
Map a predicate to a predicted alternative.
Instance Attribute Summary collapse
-
#alt ⇒ Object
Returns the value of attribute alt.
-
#pred ⇒ Object
Returns the value of attribute pred.
Instance Method Summary collapse
-
#initialize(pred, alt) ⇒ PredPrediction
constructor
A new instance of PredPrediction.
- #to_s ⇒ Object
Constructor Details
#initialize(pred, alt) ⇒ PredPrediction
Returns a new instance of PredPrediction.
5 6 7 8 |
# File 'lib/antlr4/dfa/DFAState.rb', line 5 def initialize(pred, alt) @alt = alt @pred = pred end |
Instance Attribute Details
#alt ⇒ Object
Returns the value of attribute alt.
4 5 6 |
# File 'lib/antlr4/dfa/DFAState.rb', line 4 def alt @alt end |
#pred ⇒ Object
Returns the value of attribute pred.
4 5 6 |
# File 'lib/antlr4/dfa/DFAState.rb', line 4 def pred @pred end |
Instance Method Details
#to_s ⇒ Object
10 11 12 |
# File 'lib/antlr4/dfa/DFAState.rb', line 10 def to_s "(#{self.pred}, #{self.alt})" end |