001package jmri.jmrit.logixng;
002
003import jmri.JmriException;
004import jmri.NamedBean;
005import jmri.jmrit.logixng.SymbolTable.InitialValueType;
006
007/**
008 * LogixNG Global Variable.
009 *
010 * @author Daniel Bergqvist Copyright 2022
011 */
012public interface GlobalVariable extends Base, NamedBean {
013
014    /**
015     * Initialize this global variable to the initial value.
016     * @throws jmri.JmriException in case of an error
017     */
018    void initialize() throws JmriException;
019
020    /**
021     * Set the value.
022     * @param value the value
023     */
024    void setValue(Object value);
025
026    /**
027     * Get the value.
028     * @return the value
029     */
030    Object getValue();
031
032    /**
033     * Set the initial value type.
034     * @param value the type
035     */
036    void setInitialValueType(InitialValueType value);
037
038    /**
039     * Get the initial value type.
040     * @return the type
041     */
042    InitialValueType getInitialValueType();
043
044    /**
045     * Set the initial value.
046     * @param value the value
047     */
048    void setInitialValueData(String value);
049
050    /**
051     * Get the initial value.
052     * @return the value
053     */
054    String getInitialValueData();
055
056}