Package net.maswag.falcaun.verification
Record Class VerificationResult.Counterexample<I>
java.lang.Object
java.lang.Record
net.maswag.falcaun.verification.VerificationResult.Counterexample<I>
- Type Parameters:
I- the type of the input at each step of the specification- Record Components:
property- the target specification violated by the learned Mealy machineabstractInput- the abstract input wordhypothesisOutput- the abstract output word of the learned Mealy machinesutOutput- the abstract output word observed by executing the SULconfirmed- whether the observed trace of the SUL violatespropertywitness- the Mealy machine witnessing the violation by the learned Mealy machine
- Enclosing class:
VerificationResult<I>
public static record VerificationResult.Counterexample<I>(TemporalLogic<I> property, net.automatalib.word.Word<String> abstractInput, net.automatalib.word.Word<String> hypothesisOutput, net.automatalib.word.Word<String> sutOutput, boolean confirmed, net.automatalib.automaton.transducer.MealyMachine<?,String,?,String> witness)
extends Record
A counterexample candidate of a target specification.
The candidate is found by model checking of the learned Mealy machine. Its input is executed on the SUL, and
the specification is checked on the observed abstract trace, i.e., the pair of abstractInput and
sutOutput, by the same model checker. The candidate is confirmed if the observed trace violates
the specification. The observed output may differ from the output of the learned Mealy machine even if the
candidate is confirmed (see agreesWithHypothesis()).
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final net.automatalib.word.Word<String> The field for theabstractInputrecord component.private final booleanThe field for theconfirmedrecord component.private final net.automatalib.word.Word<String> The field for thehypothesisOutputrecord component.private final TemporalLogic<I> The field for thepropertyrecord component.private final net.automatalib.word.Word<String> The field for thesutOutputrecord component.The field for thewitnessrecord component. -
Constructor Summary
ConstructorsConstructorDescriptionCounterexample(TemporalLogic<I> property, net.automatalib.word.Word<String> abstractInput, net.automatalib.word.Word<String> hypothesisOutput, net.automatalib.word.Word<String> sutOutput, boolean confirmed, net.automatalib.automaton.transducer.MealyMachine<?, String, ?, String> witness) Creates an instance of aCounterexamplerecord class. -
Method Summary
Modifier and TypeMethodDescriptionnet.automatalib.word.Word<String> Returns the value of theabstractInputrecord component.booleanbooleanReturns the value of theconfirmedrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.net.automatalib.word.Word<String> Returns the value of thehypothesisOutputrecord component.property()Returns the value of thepropertyrecord component.net.automatalib.word.Word<String> Returns the value of thesutOutputrecord component.final StringtoString()Returns a string representation of this record class.witness()Returns the value of thewitnessrecord component.
-
Field Details
-
property
The field for thepropertyrecord component. -
abstractInput
The field for theabstractInputrecord component. -
hypothesisOutput
The field for thehypothesisOutputrecord component. -
sutOutput
The field for thesutOutputrecord component. -
confirmed
private final boolean confirmedThe field for theconfirmedrecord component. -
witness
The field for thewitnessrecord component.
-
-
Constructor Details
-
Counterexample
public Counterexample(TemporalLogic<I> property, net.automatalib.word.Word<String> abstractInput, net.automatalib.word.Word<String> hypothesisOutput, net.automatalib.word.Word<String> sutOutput, boolean confirmed, net.automatalib.automaton.transducer.MealyMachine<?, String, ?, String> witness) Creates an instance of aCounterexamplerecord class.- Parameters:
property- the value for thepropertyrecord componentabstractInput- the value for theabstractInputrecord componenthypothesisOutput- the value for thehypothesisOutputrecord componentsutOutput- the value for thesutOutputrecord componentconfirmed- the value for theconfirmedrecord componentwitness- the value for thewitnessrecord component
-
-
Method Details
-
agreesWithHypothesis
public boolean agreesWithHypothesis()- Returns:
trueif and only if the SUL produced the same output as the learned Mealy machine. A disagreement means that the learned Mealy machine is not yet accurate for the input.
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
property
Returns the value of thepropertyrecord component.- Returns:
- the value of the
propertyrecord component
-
abstractInput
Returns the value of theabstractInputrecord component.- Returns:
- the value of the
abstractInputrecord component
-
hypothesisOutput
Returns the value of thehypothesisOutputrecord component.- Returns:
- the value of the
hypothesisOutputrecord component
-
sutOutput
Returns the value of thesutOutputrecord component.- Returns:
- the value of the
sutOutputrecord component
-
confirmed
public boolean confirmed()Returns the value of theconfirmedrecord component.- Returns:
- the value of the
confirmedrecord component
-
witness
Returns the value of thewitnessrecord component.- Returns:
- the value of the
witnessrecord component
-