Class AbstractAutomaton

java.lang.Object
org.eu.autogex.core.AbstractAutomaton
All Implemented Interfaces:
Automaton
Direct Known Subclasses:
DFA, ENFA, NFA

public abstract class AbstractAutomaton extends Object implements Automaton
Abstract base class for all automata models. Centralizes the management of states and their respective getters.
  • Method Details

    • getStates

      public Set<State> getStates()
      Description copied from interface: Automaton
      Retrieves all the states within the automaton.
      Specified by:
      getStates in interface Automaton
      Returns:
      A set containing all states.
    • getInitialState

      public State getInitialState()
      Description copied from interface: Automaton
      Retrieves the starting state of the automaton.
      Specified by:
      getInitialState in interface Automaton
      Returns:
      The initial state.
    • getFinalStates

      public Set<State> getFinalStates()
      Description copied from interface: Automaton
      Retrieves all the accepting (final) states of the automaton.
      Specified by:
      getFinalStates in interface Automaton
      Returns:
      A set containing all final states.