Class EmptySPMM<I,O>
- java.lang.Object
-
- net.automatalib.automaton.procedural.EmptySPMM<I,O>
-
- Type Parameters:
I
- input symbol typeO
- output symbol type
- All Implemented Interfaces:
FiniteRepresentation
,InputAlphabetHolder<I>
,Output<I,Word<O>>
,SuffixOutput<I,Word<O>>
,TransitionOutput<Void,O>
,SPMM<Void,I,Void,O>
,GraphViewable
,DeterministicTransitionSystem<Void,I,Void>
,DeterministicOutputTS<Void,I,Void,O>
,DeterministicTransitionOutputTS<Void,I,Void,O>
,MealyTransitionSystem<Void,I,Void,O>
,SimpleDTS<Void,I>
,SimpleTS<Void,I>
,TransitionSystem<Void,I,Void>
,UniversalDTS<Void,I,Void,Void,O>
,UniversalTransitionSystem<Void,I,Void,Void,O>
public class EmptySPMM<I,O> extends Object implements SPMM<Void,I,Void,O>
A utility implementation of anSPMM
that transduces all input words to a sequence of the given erroneous output symbol.
-
-
Constructor Summary
Constructors Constructor Description EmptySPMM(ProceduralInputAlphabet<I> alphabet, O errorOutput)
-
Method Summary
All Methods Instance Methods Concrete Methods Default Methods Modifier and Type Method Description Word<O>
computeSuffixOutput(Iterable<? extends I> prefix, Iterable<? extends I> suffix)
O
getErrorOutput()
Returns the output symbol that identifies erroneous transitions.@Nullable I
getInitialProcedure()
@Nullable Void
getInitialState()
Retrieves the initial state of this transition system.ProceduralInputAlphabet<I>
getInputAlphabet()
default Collection<I>
getProceduralInputs()
Convenience method forgetProceduralInputs(Collection)
which uses theinput alphabet
ofthis
system asconstraints
.default @Nullable M
getProcedure(I callSymbol)
Convenience method forgetProcedures()
to quickly return the procedure of a given call symbol.Map<I,MealyMachine<?,I,?,O>>
getProcedures()
Void
getSuccessor(Void transition)
Retrieves the successor state of a given transition.Void
getTransition(Void state, I input)
Retrieves the transition triggered by the given input symbol.O
getTransitionOutput(Void transition)
default Graph<?,?>
graphView()
default int
size()
Returns the size ofthis
system which is given by the sum of the sizes of allprocedures
.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface net.automatalib.ts.output.DeterministicOutputTS
trace
-
Methods inherited from interface net.automatalib.ts.output.DeterministicTransitionOutputTS
getOutput, trace
-
Methods inherited from interface net.automatalib.ts.DeterministicTransitionSystem
getSuccessor, getSuccessors, getTransitions
-
Methods inherited from interface net.automatalib.ts.output.MealyTransitionSystem
getStateProperty, getTransitionProperty
-
Methods inherited from interface net.automatalib.ts.simple.SimpleDTS
getInitialStates, getState, getStates, getSuccessor, getSuccessors
-
Methods inherited from interface net.automatalib.ts.simple.SimpleTS
createDynamicStateMapping, createStaticStateMapping, getSuccessors
-
Methods inherited from interface net.automatalib.automaton.procedural.SPMM
getProceduralInputs, isErrorOutput
-
Methods inherited from interface net.automatalib.automaton.concept.SuffixOutput
computeOutput
-
Methods inherited from interface net.automatalib.ts.TransitionSystem
powersetView
-
Methods inherited from interface net.automatalib.ts.UniversalDTS
getTransitionProperty
-
-
-
-
Constructor Detail
-
EmptySPMM
public EmptySPMM(ProceduralInputAlphabet<I> alphabet, O errorOutput)
-
-
Method Detail
-
getInputAlphabet
public ProceduralInputAlphabet<I> getInputAlphabet()
- Specified by:
getInputAlphabet
in interfaceInputAlphabetHolder<I>
-
getErrorOutput
public O getErrorOutput()
Description copied from interface:SPMM
Returns the output symbol that identifies erroneous transitions. Note that for the validity of thisSPMM
, each transition labeled with this output symbol must lead into a sink state that continues to output this symbol.
-
getProcedures
public Map<I,MealyMachine<?,I,?,O>> getProcedures()
-
computeSuffixOutput
public Word<O> computeSuffixOutput(Iterable<? extends I> prefix, Iterable<? extends I> suffix)
- Specified by:
computeSuffixOutput
in interfaceSPMM<Void,I,Void,O>
- Specified by:
computeSuffixOutput
in interfaceSuffixOutput<I,O>
-
getTransition
public Void getTransition(Void state, I input)
Description copied from interface:DeterministicTransitionSystem
Retrieves the transition triggered by the given input symbol.- Specified by:
getTransition
in interfaceDeterministicTransitionSystem<Void,I,Void>
- Parameters:
state
- the source state.input
- the input symbol.- Returns:
- the transition triggered by the given input symbol, or
null
if no transition is triggered. - See Also:
TransitionSystem.getTransitions(Object, Object)
-
getInitialState
public @Nullable Void getInitialState()
Description copied from interface:SimpleDTS
Retrieves the initial state of this transition system.- Specified by:
getInitialState
in interfaceSimpleDTS<I,O>
- Returns:
- the initial state.
- See Also:
SimpleTS.getInitialStates()
-
getTransitionOutput
public O getTransitionOutput(Void transition)
- Specified by:
getTransitionOutput
in interfaceTransitionOutput<I,O>
-
getSuccessor
public Void getSuccessor(Void transition)
Description copied from interface:TransitionSystem
Retrieves the successor state of a given transition.- Specified by:
getSuccessor
in interfaceTransitionSystem<Void,I,Void>
- Parameters:
transition
- the transition.- Returns:
- the successor state.
-
getProceduralInputs
public default Collection<I> getProceduralInputs()
Convenience method forgetProceduralInputs(Collection)
which uses theinput alphabet
ofthis
system asconstraints
.- Returns:
- a collection of defined inputs for
this
system's procedures.
-
getProcedure
public default @Nullable M getProcedure(I callSymbol)
Convenience method forgetProcedures()
to quickly return the procedure of a given call symbol.- Parameters:
callSymbol
- the call symbol- Returns:
- the corresponding procedure. May be
null
ifthis
system does not have a procedure for the given call symbol. - See Also:
getProcedures()
-
size
public default int size()
Returns the size ofthis
system which is given by the sum of the sizes of allprocedures
. Note that this value does not necessarily correspond to the classical notion ofSimpleAutomaton.size()
, since semantically aProceduralSystem
may be infinite-sizedSimpleTS
.- Specified by:
size
in interfaceFiniteRepresentation
- Returns:
- the size of
this
system
-
graphView
public default Graph<?,?> graphView()
- Specified by:
graphView
in interfaceGraphViewable
-
-