Interface StochasticDeterministicFiniteAutomaton
-
- All Superinterfaces:
java.lang.Cloneable
- All Known Subinterfaces:
StochasticDeterministicFiniteAutomatonMapped
- All Known Implementing Classes:
StochasticDeterministicFiniteAutomatonImpl,StochasticDeterministicFiniteAutomatonMappedImpl
public interface StochasticDeterministicFiniteAutomaton extends java.lang.Cloneable
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interfaceStochasticDeterministicFiniteAutomaton.EdgeIterablestatic interfaceStochasticDeterministicFiniteAutomaton.EdgeIterableIncomingstatic interfaceStochasticDeterministicFiniteAutomaton.EdgeIterableOutgoing
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description intaddEdge(int source, short activity, double probability)Add an edge to the graph.voidaddEdge(int source, short activity, int target, double probability)Adds an edge to the graph.intaddState()StochasticDeterministicFiniteAutomatonclone()booleancontainsEdge(int stateFrom, short activity)StochasticDeterministicFiniteAutomaton.EdgeIterablegetEdgesIterator()StochasticDeterministicFiniteAutomaton.EdgeIterableIncominggetIncomingEdgesIterator(int state)intgetInitialState()intgetNumberOfStates()StochasticDeterministicFiniteAutomaton.EdgeIterableOutgoinggetOutgoingEdgesIterator(int state)
-
-
-
Method Detail
-
getInitialState
int getInitialState()
-
getNumberOfStates
int getNumberOfStates()
- Returns:
- The highest index of any state in the automaton + 1. Does not necessarily count the number of states, but gives an upper bound.
-
containsEdge
boolean containsEdge(int stateFrom, short activity)
-
getEdgesIterator
StochasticDeterministicFiniteAutomaton.EdgeIterable getEdgesIterator()
-
getOutgoingEdgesIterator
StochasticDeterministicFiniteAutomaton.EdgeIterableOutgoing getOutgoingEdgesIterator(int state)
-
getIncomingEdgesIterator
StochasticDeterministicFiniteAutomaton.EdgeIterableIncoming getIncomingEdgesIterator(int state)
-
addEdge
int addEdge(int source, short activity, double probability)Add an edge to the graph. If there is already an activity-edge outgoing of source, its target is replaced by the given target. The probability is always replaced.- Parameters:
source-activity-target-probability-- Returns:
- The index of the target state (which may be newly created).
-
addEdge
void addEdge(int source, short activity, int target, double probability)Adds an edge to the graph. Returns the (possibly new) target state. If the edge was already present, the probability is added to the existing edge.- Parameters:
source-activity-probability-
-
addState
int addState()
-
clone
StochasticDeterministicFiniteAutomaton clone() throws java.lang.CloneNotSupportedException
- Throws:
java.lang.CloneNotSupportedException
-
-