com.karneim.util.collection.automaton
Class Automaton.State

java.lang.Object
  |
  +--com.karneim.util.collection.automaton.Automaton.State
All Implemented Interfaces:
Automaton.IState, java.lang.Cloneable
Direct Known Subclasses:
AutomatonSet_String.SState
Enclosing class:
Automaton

public class Automaton.State
extends java.lang.Object
implements Automaton.IState


Inner Class Summary
 class Automaton.State.Transition
           
 
Field Summary
 Automaton.State.Transition eTransitions
           
 int stateNr
           
 Automaton.State.Transition transitions
           
 
Method Summary
 void addChangedListener(Automaton.IStateChangedListener listener)
           
 void addVisitedListener(Automaton.IStateVisitedListener listener)
           
 java.lang.Object clone()
           
 Automaton.LinkedSet_State getAllReachableStates()
          returns all states that are reachable from this states transitions.
 boolean isDeterministic()
           
 Automaton.IState next(char ch)
           
 boolean removeChangedListener(Automaton.IStateChangedListener listener)
           
 boolean removeVisitedListener(Automaton.IStateVisitedListener listener)
           
 java.lang.String toString()
           
 Automaton.IState visit()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

stateNr

public transient int stateNr

transitions

public Automaton.State.Transition transitions

eTransitions

public Automaton.State.Transition eTransitions
Method Detail

addVisitedListener

public void addVisitedListener(Automaton.IStateVisitedListener listener)

removeVisitedListener

public boolean removeVisitedListener(Automaton.IStateVisitedListener listener)

addChangedListener

public void addChangedListener(Automaton.IStateChangedListener listener)

removeChangedListener

public boolean removeChangedListener(Automaton.IStateChangedListener listener)

visit

public final Automaton.IState visit()

isDeterministic

public final boolean isDeterministic()

next

public final Automaton.IState next(char ch)
Specified by:
next in interface Automaton.IState

getAllReachableStates

public Automaton.LinkedSet_State getAllReachableStates()
returns all states that are reachable from this states transitions. Note: this state is only element of the returned array, if it is reachable through one of it's transitions
Specified by:
getAllReachableStates in interface Automaton.IState

clone

public final java.lang.Object clone()
Specified by:
clone in interface Automaton.IState

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object