Class StackSPMM<S,I,T,O>
- java.lang.Object
-
- net.automatalib.automaton.procedural.StackSPMM<S,I,T,O>
-
- Type Parameters:
S
- procedural state typeI
- input symbol typeT
- transition typeO
- output symbol type
- All Implemented Interfaces:
FiniteRepresentation
,InputAlphabetHolder<I>
,Output<I,Word<O>>
,SuffixOutput<I,Word<O>>
,TransitionOutput<MealyTransition<StackState<S,I,MealyMachine<S,I,T,O>>,O>,O>
,SPMM<StackState<S,I,MealyMachine<S,I,T,O>>,I,MealyTransition<StackState<S,I,MealyMachine<S,I,T,O>>,O>,O>
,GraphViewable
,DeterministicTransitionSystem<StackState<S,I,MealyMachine<S,I,T,O>>,I,MealyTransition<StackState<S,I,MealyMachine<S,I,T,O>>,O>>
,DeterministicOutputTS<StackState<S,I,MealyMachine<S,I,T,O>>,I,MealyTransition<StackState<S,I,MealyMachine<S,I,T,O>>,O>,O>
,DeterministicTransitionOutputTS<StackState<S,I,MealyMachine<S,I,T,O>>,I,MealyTransition<StackState<S,I,MealyMachine<S,I,T,O>>,O>,O>
,MealyTransitionSystem<StackState<S,I,MealyMachine<S,I,T,O>>,I,MealyTransition<StackState<S,I,MealyMachine<S,I,T,O>>,O>,O>
,SimpleDTS<StackState<S,I,MealyMachine<S,I,T,O>>,I>
,SimpleTS<StackState<S,I,MealyMachine<S,I,T,O>>,I>
,TransitionSystem<StackState<S,I,MealyMachine<S,I,T,O>>,I,MealyTransition<StackState<S,I,MealyMachine<S,I,T,O>>,O>>
,UniversalDTS<StackState<S,I,MealyMachine<S,I,T,O>>,I,MealyTransition<StackState<S,I,MealyMachine<S,I,T,O>>,O>,Void,O>
,UniversalTransitionSystem<StackState<S,I,MealyMachine<S,I,T,O>>,I,MealyTransition<StackState<S,I,MealyMachine<S,I,T,O>>,O>,Void,O>
public class StackSPMM<S,I,T,O> extends Object implements SPMM<StackState<S,I,MealyMachine<S,I,T,O>>,I,MealyTransition<StackState<S,I,MealyMachine<S,I,T,O>>,O>,O>
A stack-based implementation for the (instrumented) transductions of anSPMM
.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Default Methods Modifier and Type Method Description O
getErrorOutput()
Returns the output symbol that identifies erroneous transitions.@Nullable I
getInitialProcedure()
StackState<S,I,MealyMachine<S,I,T,O>>
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()
StackState<S,I,MealyMachine<S,I,T,O>>
getSuccessor(MealyTransition<StackState<S,I,MealyMachine<S,I,T,O>>,O> transition)
Retrieves the successor state of a given transition.MealyTransition<StackState<S,I,MealyMachine<S,I,T,O>>,O>
getTransition(StackState<S,I,MealyMachine<S,I,T,O>> state, I input)
Retrieves the transition triggered by the given input symbol.O
getTransitionOutput(MealyTransition<StackState<S,I,MealyMachine<S,I,T,O>>,O> 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
computeSuffixOutput, 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
-
-
-
-
Method Detail
-
getTransition
public MealyTransition<StackState<S,I,MealyMachine<S,I,T,O>>,O> getTransition(StackState<S,I,MealyMachine<S,I,T,O>> state, I input)
Description copied from interface:DeterministicTransitionSystem
Retrieves the transition triggered by the given input symbol.- Specified by:
getTransition
in interfaceDeterministicTransitionSystem<S,I,T>
- 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 StackState<S,I,MealyMachine<S,I,T,O>> getInitialState()
Description copied from interface:SimpleDTS
Retrieves the initial state of this transition system.- Specified by:
getInitialState
in interfaceSimpleDTS<S,I>
- Returns:
- the initial state.
- See Also:
SimpleTS.getInitialStates()
-
getInputAlphabet
public ProceduralInputAlphabet<I> getInputAlphabet()
- Specified by:
getInputAlphabet
in interfaceInputAlphabetHolder<S>
-
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()
-
getTransitionOutput
public O getTransitionOutput(MealyTransition<StackState<S,I,MealyMachine<S,I,T,O>>,O> transition)
- Specified by:
getTransitionOutput
in interfaceTransitionOutput<S,I>
-
getSuccessor
public StackState<S,I,MealyMachine<S,I,T,O>> getSuccessor(MealyTransition<StackState<S,I,MealyMachine<S,I,T,O>>,O> transition)
Description copied from interface:TransitionSystem
Retrieves the successor state of a given transition.- Specified by:
getSuccessor
in interfaceTransitionSystem<S,I,T>
- 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
-
-