Module net.automatalib.util
Class MooreBuilder<S,I,T,O,A extends MutableMooreMachine<S,? super I,T,? super O>>
- java.lang.Object
-
- net.automatalib.util.automaton.builder.MooreBuilder<S,I,T,O,A>
-
- Type Parameters:
S
- state typeI
- input symbol typeT
- transition typeO
- output symbol typeA
- concrete automaton type
public class MooreBuilder<S,I,T,O,A extends MutableMooreMachine<S,? super I,T,? super O>> extends Object
A fluent builder forMooreMachine
s.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description class
MooreBuilder.MooreBuilder0
A state (-class) of the enclosing fluent interface.class
MooreBuilder.MooreBuilder1
A state (-class) of the enclosing fluent interface.class
MooreBuilder.MooreBuilder2
A state (-class) of the enclosing fluent interface.class
MooreBuilder.MooreBuilder3
A state (-class) of the enclosing fluent interface.class
MooreBuilder.MooreBuilder4
A state (-class) of the enclosing fluent interface.class
MooreBuilder.MooreBuilder5
A state (-class) of the enclosing fluent interface.class
MooreBuilder.MooreBuilder6
A state (-class) of the enclosing fluent interface.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description MooreBuilder.MooreBuilder1
from(Object stateId)
Starts a definition of transition(s) from a given source state.MooreBuilder.MooreBuilder1
from(Object firstStateId, Object... otherStateIds)
Starts a definition of transition(s) from multiple given source states.MooreBuilder.MooreBuilder0
withInitial(Object stateId)
Marks the given state as initial.MooreBuilder.MooreBuilder0
withInitial(Object stateId, O output)
Marks the given state as initial and allows to set its output.MooreBuilder<S,I,T,O,A>
withOutput(Object stateId, O output)
Associates with the given state the given output symbol.
-
-
-
Method Detail
-
withInitial
public MooreBuilder.MooreBuilder0 withInitial(Object stateId)
Marks the given state as initial.- Parameters:
stateId
- the object to identify the state- Returns:
- the next fluent state
-
withInitial
public MooreBuilder.MooreBuilder0 withInitial(Object stateId, O output)
Marks the given state as initial and allows to set its output.- Parameters:
stateId
- the object to identify the stateoutput
- the output of the state- Returns:
- the next fluent state
-
from
public MooreBuilder.MooreBuilder1 from(Object stateId)
Starts a definition of transition(s) from a given source state.- Parameters:
stateId
- the object to identify the state- Returns:
- the next fluent state
-
from
public MooreBuilder.MooreBuilder1 from(Object firstStateId, Object... otherStateIds)
Starts a definition of transition(s) from multiple given source states.- Parameters:
firstStateId
- the mandatory object to identify the first stateotherStateIds
- the optional objects to identify additional states- Returns:
- the next fluent state
-
-