Class MealyFixedSetEQOracle

java.lang.Object
de.learnlib.oracle.equivalence.AbstractTestWordEQOracle<net.automatalib.automaton.transducer.MealyMachine<?,String,?,String>,String,net.automatalib.word.Word<String>>
net.maswag.falcaun.oracle.MealyFixedSetEQOracle
All Implemented Interfaces:
EquivalenceOracle<net.automatalib.automaton.transducer.MealyMachine<?,String,?,String>,String,net.automatalib.word.Word<String>>, EquivalenceOracle.MealyEquivalenceOracle<String,String>, TestWordGenerator<net.automatalib.automaton.transducer.MealyMachine<?,String,?,String>,String>, EvaluationCountable, EvaluationCountable.MealyEquivalenceOracle<String,String>

public class MealyFixedSetEQOracle extends AbstractTestWordEQOracle<net.automatalib.automaton.transducer.MealyMachine<?,String,?,String>,String,net.automatalib.word.Word<String>> implements EquivalenceOracle.MealyEquivalenceOracle<String,String>, EvaluationCountable.MealyEquivalenceOracle<String,String>
Equivalence oracle that tests a fixed list of input words in the order of their addition.

Each word is answered by the membership oracle when a hypothesis is tested, i.e., the outputs are not fixed when the words are added. The membership queries, the comparison with the hypothesis, and the termination at the first counterexample are by AbstractTestWordEQOracle.

This oracle does not check whether the properties are already disproved. BlackBoxVerifier.addEqOracle(de.learnlib.oracle.EquivalenceOracle.MealyEquivalenceOracle<java.lang.String, java.lang.String>) wraps it with StopDisprovedEQOracle for that.

  • Field Details

    • fixedSamples

      private final List<net.automatalib.word.Word<String>> fixedSamples
    • evaluateCount

      private int evaluateCount
      The number of the words evaluated by this oracle, including the ones answered by a cache of the membership oracle. A word is counted each time it is evaluated.
  • Constructor Details

  • Method Details

    • add

      public void add(net.automatalib.word.Word<String> sample)
    • addAll

      public void addAll(Collection<net.automatalib.word.Word<String>> samples)
    • generateTestWords

      public Stream<net.automatalib.word.Word<String>> generateTestWords(net.automatalib.automaton.transducer.MealyMachine<?,String,?,String> hypothesis, Collection<? extends String> inputs)

      Without batching, AbstractTestWordEQOracle consumes the stream one word at a time and stops at the first counterexample. Thus, counting the words when they are consumed counts exactly the evaluated words.

      Specified by:
      generateTestWords in interface TestWordGenerator<net.automatalib.automaton.transducer.MealyMachine<?,String,?,String>,String>