All Downloads are FREE. Search and download functionalities are using the official Maven repository.

Alachisoft.NCache.Parser.LRAction Maven / Gradle / Ivy

There is a newer version: 5.3.3
Show newest version
package Alachisoft.NCache.Parser;

// C# Translation of GoldParser, by Marcus Klimstra .
// Based on GOLDParser by Devin Cook .

/**
 * This class represents an action in a LALR State.
 * There is one and only one action for any given symbol.
 */
public class LRAction {
    private Symbol m_symbol;
    private Action m_action = getAction().values()[0];
    private int m_value;

    /* properties */

    public final Symbol getSymbol() {
        return m_symbol;
    }

    public final void setSymbol(Symbol value) {
        m_symbol = value;
    }

    public final Action getAction() {
        return m_action;
    }

    public final void setAction(Action value) {
        m_action = value;
    }

    public final int getValue() {
        return m_value;
    }

    public final void setValue(int value) {
        m_value = value;
    }

    /* public methods */

    @Override
    public String toString() {
        return "LALR action [symbol=" + m_symbol + ",action=" + m_action + ",value=" + m_value + "]";
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy